From d035d7362cf7d6a7d862f9ba1213870d4650aef2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8A=9B=E7=9A=93?= Date: Fri, 4 Dec 2020 14:13:51 +0800 Subject: [PATCH] =?UTF-8?q?chore:=20=E5=88=A0=E9=99=A4=20plugins=20/=20run?= =?UTF-8?q?time=20/=20react-provider=20/=20rax-provider?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/plugin-components-pane/CHANGELOG.md | 653 ---------------- packages/plugin-components-pane/README.md | 1 - packages/plugin-components-pane/build.json | 9 - packages/plugin-components-pane/package.json | 43 -- .../src/components/base/index.less | 116 --- .../src/components/base/index.tsx | 264 ------- .../src/components/button/index.less | 18 - .../src/components/button/index.tsx | 22 - .../src/components/card/index.less | 130 ---- .../src/components/card/index.tsx | 141 ---- .../src/components/component-list/index.less | 117 --- .../src/components/component-list/index.tsx | 286 ------- .../src/components/snippet/index.less | 120 --- .../src/components/snippet/index.tsx | 46 -- .../plugin-components-pane/src/i18n/index.ts | 45 -- .../src/i18n/strings/en-US.json | 27 - .../src/i18n/strings/index.ts | 4 - .../src/i18n/strings/zh-CN.json | 26 - .../plugin-components-pane/src/index.scss | 25 - packages/plugin-components-pane/src/index.tsx | 149 ---- .../plugin-components-pane/src/module.d.ts | 1 - packages/plugin-components-pane/src/utils.ts | 98 --- packages/plugin-components-pane/tsconfig.json | 10 - packages/plugin-designer/.eslintrc.js | 14 - packages/plugin-designer/CHANGELOG.md | 676 ----------------- packages/plugin-designer/README.md | 1 - packages/plugin-designer/build.json | 5 - packages/plugin-designer/package.json | 37 - packages/plugin-designer/src/index.scss | 4 - packages/plugin-designer/src/index.tsx | 109 --- packages/plugin-designer/tsconfig.json | 9 - .../plugin-event-bind-dialog/CHANGELOG.md | 485 ------------ packages/plugin-event-bind-dialog/README.md | 1 - packages/plugin-event-bind-dialog/build.json | 9 - .../plugin-event-bind-dialog/package.json | 39 - .../plugin-event-bind-dialog/src/index.scss | 75 -- .../plugin-event-bind-dialog/src/index.tsx | 238 ------ .../plugin-event-bind-dialog/tsconfig.json | 9 - packages/plugin-outline-pane/.eslintrc.js | 7 - packages/plugin-outline-pane/CHANGELOG.md | 665 ----------------- packages/plugin-outline-pane/README.md | 1 - packages/plugin-outline-pane/build.json | 9 - packages/plugin-outline-pane/package.json | 50 -- packages/plugin-outline-pane/src/README.md | 1 - .../src/helper/dwell-timer.ts | 55 -- .../src/helper/indent-track.ts | 54 -- .../src/icons/arrow-right.tsx | 11 - .../plugin-outline-pane/src/icons/cond.tsx | 11 - .../src/icons/eye-close.tsx | 12 - .../plugin-outline-pane/src/icons/eye.tsx | 12 - .../plugin-outline-pane/src/icons/lock.tsx | 11 - .../plugin-outline-pane/src/icons/loop.tsx | 11 - .../plugin-outline-pane/src/icons/outline.tsx | 12 - .../src/icons/radio-active.tsx | 12 - .../plugin-outline-pane/src/icons/radio.tsx | 12 - .../plugin-outline-pane/src/icons/unlock.tsx | 12 - packages/plugin-outline-pane/src/index.ts | 16 - .../plugin-outline-pane/src/locale/en-US.json | 14 - .../plugin-outline-pane/src/locale/index.ts | 10 - .../plugin-outline-pane/src/locale/zh-CN.json | 14 - packages/plugin-outline-pane/src/main.ts | 667 ----------------- .../plugin-outline-pane/src/tree-master.ts | 122 --- packages/plugin-outline-pane/src/tree-node.ts | 235 ------ packages/plugin-outline-pane/src/tree.ts | 34 - .../src/views/backup-pane.tsx | 18 - .../plugin-outline-pane/src/views/pane.tsx | 40 - .../src/views/root-tree-node.tsx | 94 --- .../plugin-outline-pane/src/views/style.less | 387 ---------- .../src/views/tree-branches.tsx | 140 ---- .../src/views/tree-node.tsx | 46 -- .../src/views/tree-title.tsx | 295 -------- .../plugin-outline-pane/src/views/tree.tsx | 165 ---- packages/plugin-outline-pane/tsconfig.json | 9 - packages/plugin-sample-logo/CHANGELOG.md | 472 ------------ packages/plugin-sample-logo/README.md | 3 - packages/plugin-sample-logo/build.json | 5 - packages/plugin-sample-logo/package.json | 35 - packages/plugin-sample-logo/src/index.scss | 11 - packages/plugin-sample-logo/src/index.tsx | 18 - packages/plugin-sample-logo/tsconfig.json | 9 - packages/plugin-sample-preview/CHANGELOG.md | 706 ------------------ packages/plugin-sample-preview/README.md | 3 - packages/plugin-sample-preview/build.json | 9 - packages/plugin-sample-preview/demo/usage.md | 24 - packages/plugin-sample-preview/package.json | 41 - packages/plugin-sample-preview/src/index.scss | 9 - packages/plugin-sample-preview/src/index.tsx | 79 -- packages/plugin-sample-preview/tsconfig.json | 9 - packages/plugin-source-editor/CHANGELOG.md | 497 ------------ packages/plugin-source-editor/README.md | 1 - packages/plugin-source-editor/build.json | 9 - packages/plugin-source-editor/package.json | 41 - packages/plugin-source-editor/src/index.scss | 66 -- packages/plugin-source-editor/src/index.tsx | 372 --------- packages/plugin-source-editor/src/module.d.ts | 1 - .../plugin-source-editor/src/transform.ts | 257 ------- packages/plugin-source-editor/tsconfig.json | 9 - packages/plugin-undo-redo/CHANGELOG.md | 658 ---------------- packages/plugin-undo-redo/README.md | 1 - packages/plugin-undo-redo/build.json | 9 - packages/plugin-undo-redo/package.json | 41 - packages/plugin-undo-redo/src/index.scss | 8 - packages/plugin-undo-redo/src/index.tsx | 105 --- packages/plugin-undo-redo/tsconfig.json | 9 - packages/plugin-utils-pane/CHANGELOG.md | 1 - packages/plugin-utils-pane/README.md | 3 - packages/plugin-utils-pane/build.json | 9 - packages/plugin-utils-pane/package.json | 48 -- .../src/form-components/index.ts | 1 - .../src/form-components/js-function.tsx | 64 -- packages/plugin-utils-pane/src/index.scss | 116 --- packages/plugin-utils-pane/src/index.tsx | 86 --- packages/plugin-utils-pane/src/list.tsx | 191 ----- .../plugin-utils-pane/src/locale/en-US.json | 3 - .../plugin-utils-pane/src/locale/index.ts | 10 - .../plugin-utils-pane/src/locale/zh-CN.json | 3 - packages/plugin-utils-pane/src/pane.tsx | 308 -------- .../plugin-utils-pane/src/utils-defaults.tsx | 31 - packages/plugin-utils-pane/src/utils-form.tsx | 247 ------ .../plugin-utils-pane/src/utils-types.tsx | 16 - packages/plugin-utils-pane/tsconfig.json | 10 - .../plugin-variable-bind-dialog/CHANGELOG.md | 464 ------------ .../plugin-variable-bind-dialog/README.md | 1 - .../plugin-variable-bind-dialog/build.json | 9 - .../plugin-variable-bind-dialog/package.json | 38 - .../src/index.scss | 90 --- .../plugin-variable-bind-dialog/src/index.tsx | 162 ---- .../plugin-variable-bind-dialog/tsconfig.json | 9 - packages/plugin-zh-en/CHANGELOG.md | 500 ------------- packages/plugin-zh-en/README.md | 1 - packages/plugin-zh-en/build.json | 5 - packages/plugin-zh-en/package.json | 32 - packages/plugin-zh-en/src/icons/en.tsx | 11 - packages/plugin-zh-en/src/icons/zh.tsx | 11 - packages/plugin-zh-en/src/index.less | 11 - packages/plugin-zh-en/src/index.tsx | 40 - packages/plugin-zh-en/src/locale/en-US.json | 3 - packages/plugin-zh-en/src/locale/index.ts | 10 - packages/plugin-zh-en/src/locale/zh-CN.json | 3 - packages/plugin-zh-en/tsconfig.json | 9 - packages/rax-provider/CHANGELOG.md | 261 ------- packages/rax-provider/README.md | 1 - packages/rax-provider/build.json | 11 - packages/rax-provider/package.json | 33 - packages/rax-provider/src/index.ts | 5 - packages/rax-provider/src/lazy-component.ts | 28 - packages/rax-provider/src/provider.ts | 109 --- packages/rax-provider/src/router.ts | 26 - packages/rax-provider/tsconfig.json | 25 - packages/react-provider/CHANGELOG.md | 262 ------- packages/react-provider/README.md | 1 - packages/react-provider/build.json | 5 - packages/react-provider/package.json | 44 -- .../src/components/LazyComponent/index.tsx | 81 -- packages/react-provider/src/index.ts | 5 - packages/react-provider/src/provider.tsx | 125 ---- packages/react-provider/tsconfig.json | 9 - packages/runtime/CHANGELOG.md | 330 -------- packages/runtime/README.md | 1 - packages/runtime/build.json | 5 - packages/runtime/package.json | 39 - packages/runtime/src/core/index.ts | 99 --- packages/runtime/src/core/provider.ts | 428 ----------- packages/runtime/src/core/runApp.ts | 51 -- packages/runtime/src/index.ts | 4 - packages/runtime/tsconfig.json | 9 - 166 files changed, 15396 deletions(-) delete mode 100644 packages/plugin-components-pane/CHANGELOG.md delete mode 100644 packages/plugin-components-pane/README.md delete mode 100644 packages/plugin-components-pane/build.json delete mode 100644 packages/plugin-components-pane/package.json delete mode 100644 packages/plugin-components-pane/src/components/base/index.less delete mode 100644 packages/plugin-components-pane/src/components/base/index.tsx delete mode 100644 packages/plugin-components-pane/src/components/button/index.less delete mode 100644 packages/plugin-components-pane/src/components/button/index.tsx delete mode 100644 packages/plugin-components-pane/src/components/card/index.less delete mode 100644 packages/plugin-components-pane/src/components/card/index.tsx delete mode 100644 packages/plugin-components-pane/src/components/component-list/index.less delete mode 100644 packages/plugin-components-pane/src/components/component-list/index.tsx delete mode 100644 packages/plugin-components-pane/src/components/snippet/index.less delete mode 100644 packages/plugin-components-pane/src/components/snippet/index.tsx delete mode 100644 packages/plugin-components-pane/src/i18n/index.ts delete mode 100644 packages/plugin-components-pane/src/i18n/strings/en-US.json delete mode 100644 packages/plugin-components-pane/src/i18n/strings/index.ts delete mode 100644 packages/plugin-components-pane/src/i18n/strings/zh-CN.json delete mode 100644 packages/plugin-components-pane/src/index.scss delete mode 100644 packages/plugin-components-pane/src/index.tsx delete mode 100644 packages/plugin-components-pane/src/module.d.ts delete mode 100644 packages/plugin-components-pane/src/utils.ts delete mode 100644 packages/plugin-components-pane/tsconfig.json delete mode 100644 packages/plugin-designer/.eslintrc.js delete mode 100644 packages/plugin-designer/CHANGELOG.md delete mode 100644 packages/plugin-designer/README.md delete mode 100644 packages/plugin-designer/build.json delete mode 100644 packages/plugin-designer/package.json delete mode 100644 packages/plugin-designer/src/index.scss delete mode 100644 packages/plugin-designer/src/index.tsx delete mode 100644 packages/plugin-designer/tsconfig.json delete mode 100644 packages/plugin-event-bind-dialog/CHANGELOG.md delete mode 100644 packages/plugin-event-bind-dialog/README.md delete mode 100644 packages/plugin-event-bind-dialog/build.json delete mode 100644 packages/plugin-event-bind-dialog/package.json delete mode 100644 packages/plugin-event-bind-dialog/src/index.scss delete mode 100644 packages/plugin-event-bind-dialog/src/index.tsx delete mode 100644 packages/plugin-event-bind-dialog/tsconfig.json delete mode 100644 packages/plugin-outline-pane/.eslintrc.js delete mode 100644 packages/plugin-outline-pane/CHANGELOG.md delete mode 100644 packages/plugin-outline-pane/README.md delete mode 100644 packages/plugin-outline-pane/build.json delete mode 100644 packages/plugin-outline-pane/package.json delete mode 100644 packages/plugin-outline-pane/src/README.md delete mode 100644 packages/plugin-outline-pane/src/helper/dwell-timer.ts delete mode 100644 packages/plugin-outline-pane/src/helper/indent-track.ts delete mode 100644 packages/plugin-outline-pane/src/icons/arrow-right.tsx delete mode 100644 packages/plugin-outline-pane/src/icons/cond.tsx delete mode 100644 packages/plugin-outline-pane/src/icons/eye-close.tsx delete mode 100644 packages/plugin-outline-pane/src/icons/eye.tsx delete mode 100644 packages/plugin-outline-pane/src/icons/lock.tsx delete mode 100644 packages/plugin-outline-pane/src/icons/loop.tsx delete mode 100644 packages/plugin-outline-pane/src/icons/outline.tsx delete mode 100644 packages/plugin-outline-pane/src/icons/radio-active.tsx delete mode 100644 packages/plugin-outline-pane/src/icons/radio.tsx delete mode 100644 packages/plugin-outline-pane/src/icons/unlock.tsx delete mode 100644 packages/plugin-outline-pane/src/index.ts delete mode 100644 packages/plugin-outline-pane/src/locale/en-US.json delete mode 100644 packages/plugin-outline-pane/src/locale/index.ts delete mode 100644 packages/plugin-outline-pane/src/locale/zh-CN.json delete mode 100644 packages/plugin-outline-pane/src/main.ts delete mode 100644 packages/plugin-outline-pane/src/tree-master.ts delete mode 100644 packages/plugin-outline-pane/src/tree-node.ts delete mode 100644 packages/plugin-outline-pane/src/tree.ts delete mode 100644 packages/plugin-outline-pane/src/views/backup-pane.tsx delete mode 100644 packages/plugin-outline-pane/src/views/pane.tsx delete mode 100644 packages/plugin-outline-pane/src/views/root-tree-node.tsx delete mode 100644 packages/plugin-outline-pane/src/views/style.less delete mode 100644 packages/plugin-outline-pane/src/views/tree-branches.tsx delete mode 100644 packages/plugin-outline-pane/src/views/tree-node.tsx delete mode 100644 packages/plugin-outline-pane/src/views/tree-title.tsx delete mode 100644 packages/plugin-outline-pane/src/views/tree.tsx delete mode 100644 packages/plugin-outline-pane/tsconfig.json delete mode 100644 packages/plugin-sample-logo/CHANGELOG.md delete mode 100644 packages/plugin-sample-logo/README.md delete mode 100644 packages/plugin-sample-logo/build.json delete mode 100644 packages/plugin-sample-logo/package.json delete mode 100644 packages/plugin-sample-logo/src/index.scss delete mode 100644 packages/plugin-sample-logo/src/index.tsx delete mode 100644 packages/plugin-sample-logo/tsconfig.json delete mode 100644 packages/plugin-sample-preview/CHANGELOG.md delete mode 100644 packages/plugin-sample-preview/README.md delete mode 100644 packages/plugin-sample-preview/build.json delete mode 100644 packages/plugin-sample-preview/demo/usage.md delete mode 100644 packages/plugin-sample-preview/package.json delete mode 100644 packages/plugin-sample-preview/src/index.scss delete mode 100644 packages/plugin-sample-preview/src/index.tsx delete mode 100644 packages/plugin-sample-preview/tsconfig.json delete mode 100644 packages/plugin-source-editor/CHANGELOG.md delete mode 100644 packages/plugin-source-editor/README.md delete mode 100644 packages/plugin-source-editor/build.json delete mode 100644 packages/plugin-source-editor/package.json delete mode 100644 packages/plugin-source-editor/src/index.scss delete mode 100644 packages/plugin-source-editor/src/index.tsx delete mode 100644 packages/plugin-source-editor/src/module.d.ts delete mode 100644 packages/plugin-source-editor/src/transform.ts delete mode 100644 packages/plugin-source-editor/tsconfig.json delete mode 100644 packages/plugin-undo-redo/CHANGELOG.md delete mode 100644 packages/plugin-undo-redo/README.md delete mode 100644 packages/plugin-undo-redo/build.json delete mode 100644 packages/plugin-undo-redo/package.json delete mode 100644 packages/plugin-undo-redo/src/index.scss delete mode 100644 packages/plugin-undo-redo/src/index.tsx delete mode 100644 packages/plugin-undo-redo/tsconfig.json delete mode 100644 packages/plugin-utils-pane/CHANGELOG.md delete mode 100644 packages/plugin-utils-pane/README.md delete mode 100644 packages/plugin-utils-pane/build.json delete mode 100644 packages/plugin-utils-pane/package.json delete mode 100644 packages/plugin-utils-pane/src/form-components/index.ts delete mode 100644 packages/plugin-utils-pane/src/form-components/js-function.tsx delete mode 100644 packages/plugin-utils-pane/src/index.scss delete mode 100644 packages/plugin-utils-pane/src/index.tsx delete mode 100644 packages/plugin-utils-pane/src/list.tsx delete mode 100644 packages/plugin-utils-pane/src/locale/en-US.json delete mode 100644 packages/plugin-utils-pane/src/locale/index.ts delete mode 100644 packages/plugin-utils-pane/src/locale/zh-CN.json delete mode 100644 packages/plugin-utils-pane/src/pane.tsx delete mode 100644 packages/plugin-utils-pane/src/utils-defaults.tsx delete mode 100644 packages/plugin-utils-pane/src/utils-form.tsx delete mode 100644 packages/plugin-utils-pane/src/utils-types.tsx delete mode 100644 packages/plugin-utils-pane/tsconfig.json delete mode 100644 packages/plugin-variable-bind-dialog/CHANGELOG.md delete mode 100644 packages/plugin-variable-bind-dialog/README.md delete mode 100644 packages/plugin-variable-bind-dialog/build.json delete mode 100644 packages/plugin-variable-bind-dialog/package.json delete mode 100644 packages/plugin-variable-bind-dialog/src/index.scss delete mode 100644 packages/plugin-variable-bind-dialog/src/index.tsx delete mode 100644 packages/plugin-variable-bind-dialog/tsconfig.json delete mode 100644 packages/plugin-zh-en/CHANGELOG.md delete mode 100644 packages/plugin-zh-en/README.md delete mode 100644 packages/plugin-zh-en/build.json delete mode 100644 packages/plugin-zh-en/package.json delete mode 100644 packages/plugin-zh-en/src/icons/en.tsx delete mode 100644 packages/plugin-zh-en/src/icons/zh.tsx delete mode 100644 packages/plugin-zh-en/src/index.less delete mode 100644 packages/plugin-zh-en/src/index.tsx delete mode 100644 packages/plugin-zh-en/src/locale/en-US.json delete mode 100644 packages/plugin-zh-en/src/locale/index.ts delete mode 100644 packages/plugin-zh-en/src/locale/zh-CN.json delete mode 100644 packages/plugin-zh-en/tsconfig.json delete mode 100644 packages/rax-provider/CHANGELOG.md delete mode 100644 packages/rax-provider/README.md delete mode 100644 packages/rax-provider/build.json delete mode 100644 packages/rax-provider/package.json delete mode 100644 packages/rax-provider/src/index.ts delete mode 100644 packages/rax-provider/src/lazy-component.ts delete mode 100644 packages/rax-provider/src/provider.ts delete mode 100644 packages/rax-provider/src/router.ts delete mode 100644 packages/rax-provider/tsconfig.json delete mode 100644 packages/react-provider/CHANGELOG.md delete mode 100644 packages/react-provider/README.md delete mode 100644 packages/react-provider/build.json delete mode 100644 packages/react-provider/package.json delete mode 100644 packages/react-provider/src/components/LazyComponent/index.tsx delete mode 100644 packages/react-provider/src/index.ts delete mode 100644 packages/react-provider/src/provider.tsx delete mode 100644 packages/react-provider/tsconfig.json delete mode 100644 packages/runtime/CHANGELOG.md delete mode 100644 packages/runtime/README.md delete mode 100644 packages/runtime/build.json delete mode 100644 packages/runtime/package.json delete mode 100644 packages/runtime/src/core/index.ts delete mode 100644 packages/runtime/src/core/provider.ts delete mode 100644 packages/runtime/src/core/runApp.ts delete mode 100644 packages/runtime/src/index.ts delete mode 100644 packages/runtime/tsconfig.json diff --git a/packages/plugin-components-pane/CHANGELOG.md b/packages/plugin-components-pane/CHANGELOG.md deleted file mode 100644 index d3f78ba93..000000000 --- a/packages/plugin-components-pane/CHANGELOG.md +++ /dev/null @@ -1,653 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - - -## [1.0.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.21...@ali/lowcode-plugin-components-pane@1.0.22) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.20...@ali/lowcode-plugin-components-pane@1.0.21) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.19...@ali/lowcode-plugin-components-pane@1.0.20) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.18...@ali/lowcode-plugin-components-pane@1.0.19) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.17...@ali/lowcode-plugin-components-pane@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.16...@ali/lowcode-plugin-components-pane@1.0.17) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.15...@ali/lowcode-plugin-components-pane@1.0.16) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.13...@ali/lowcode-plugin-components-pane@1.0.15) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.13...@ali/lowcode-plugin-components-pane@1.0.14) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.12...@ali/lowcode-plugin-components-pane@1.0.13) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.11...@ali/lowcode-plugin-components-pane@1.0.12) (2020-10-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.10...@ali/lowcode-plugin-components-pane@1.0.11) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.9...@ali/lowcode-plugin-components-pane@1.0.10) (2020-09-29) - - -### Bug Fixes - -* 修复组件面板 i18n 警告 ([37a409d](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/37a409d)) - - - - - -## [1.0.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.8...@ali/lowcode-plugin-components-pane@1.0.9) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.8-0...@ali/lowcode-plugin-components-pane@1.0.8) (2020-09-28) - - -### Bug Fixes - -* 修复 asset 中 componentList 为空时报错的 bug ([49517a6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/49517a6)) - - -### Features - -* 组件面板支持业务组件独立展示 ([e9d8d3d](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/e9d8d3d)) - - - - - -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.57...@ali/lowcode-plugin-components-pane@1.0.8-0) (2020-09-09) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) - - - - - -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.6-0...@ali/lowcode-plugin-components-pane@1.0.7-0) (2020-09-02) - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.54...@ali/lowcode-plugin-components-pane@1.0.6-0) (2020-09-02) - - -## [0.8.57](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.56...@ali/lowcode-plugin-components-pane@0.8.57) (2020-09-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.56](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.55...@ali/lowcode-plugin-components-pane@0.8.56) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.55](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.54...@ali/lowcode-plugin-components-pane@0.8.55) (2020-09-03) - - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) - - - - - -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.4-0...@ali/lowcode-plugin-components-pane@1.0.5-0) (2020-08-20) - - -## [0.8.54](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.53...@ali/lowcode-plugin-components-pane@0.8.54) (2020-08-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.53](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.52...@ali/lowcode-plugin-components-pane@0.8.53) (2020-08-26) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.52](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.51...@ali/lowcode-plugin-components-pane@0.8.52) (2020-08-24) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.51](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.50...@ali/lowcode-plugin-components-pane@0.8.51) (2020-08-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.50](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.49...@ali/lowcode-plugin-components-pane@0.8.50) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.3-0...@ali/lowcode-plugin-components-pane@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.2-0...@ali/lowcode-plugin-components-pane@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@1.0.1-0...@ali/lowcode-plugin-components-pane@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.49...@ali/lowcode-plugin-components-pane@1.0.1-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.13.0...@ali/lowcode-plugin-components-pane@1.0.0) (2020-08-17) - -## [0.8.49](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.48...@ali/lowcode-plugin-components-pane@0.8.49) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.48](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.47...@ali/lowcode-plugin-components-pane@0.8.48) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.47](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.46...@ali/lowcode-plugin-components-pane@0.8.47) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.46](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.45...@ali/lowcode-plugin-components-pane@0.8.46) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.45](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.44...@ali/lowcode-plugin-components-pane@0.8.45) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.12.0...@ali/lowcode-plugin-components-pane@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.10.0...@ali/lowcode-plugin-components-pane@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.10.0...@ali/lowcode-plugin-components-pane@0.11.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.9.0...@ali/lowcode-plugin-components-pane@0.10.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.39...@ali/lowcode-plugin-components-pane@0.9.0) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.39](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.38...@ali/lowcode-plugin-components-pane@0.8.39) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.38](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.36...@ali/lowcode-plugin-components-pane@0.8.38) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.37](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.36...@ali/lowcode-plugin-components-pane@0.8.37) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.36](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.35...@ali/lowcode-plugin-components-pane@0.8.36) (2020-07-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.35](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.34...@ali/lowcode-plugin-components-pane@0.8.35) (2020-07-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.34](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.33...@ali/lowcode-plugin-components-pane@0.8.34) (2020-07-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.33](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.32...@ali/lowcode-plugin-components-pane@0.8.33) (2020-07-22) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.32](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.31...@ali/lowcode-plugin-components-pane@0.8.32) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.31](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.30...@ali/lowcode-plugin-components-pane@0.8.31) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.30](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.29...@ali/lowcode-plugin-components-pane@0.8.30) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.29](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.28...@ali/lowcode-plugin-components-pane@0.8.29) (2020-07-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.28](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.27...@ali/lowcode-plugin-components-pane@0.8.28) (2020-07-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.27](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.26...@ali/lowcode-plugin-components-pane@0.8.27) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.26](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.25...@ali/lowcode-plugin-components-pane@0.8.26) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.25](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.24...@ali/lowcode-plugin-components-pane@0.8.25) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.24](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.23...@ali/lowcode-plugin-components-pane@0.8.24) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.22...@ali/lowcode-plugin-components-pane@0.8.23) (2020-06-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.21...@ali/lowcode-plugin-components-pane@0.8.22) (2020-06-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.20...@ali/lowcode-plugin-components-pane@0.8.21) (2020-05-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.19...@ali/lowcode-plugin-components-pane@0.8.20) (2020-05-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.18...@ali/lowcode-plugin-components-pane@0.8.19) (2020-05-18) - - -### Features - -* use new ComponentPane ([56ae5ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/56ae5ad)) - - - - - -## [0.8.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.17...@ali/lowcode-plugin-components-pane@0.8.18) (2020-05-18) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.16...@ali/lowcode-plugin-components-pane@0.8.17) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.15...@ali/lowcode-plugin-components-pane@0.8.16) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.14...@ali/lowcode-plugin-components-pane@0.8.15) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.13...@ali/lowcode-plugin-components-pane@0.8.14) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.12...@ali/lowcode-plugin-components-pane@0.8.13) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.11...@ali/lowcode-plugin-components-pane@0.8.12) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.10...@ali/lowcode-plugin-components-pane@0.8.11) (2020-05-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.9...@ali/lowcode-plugin-components-pane@0.8.10) (2020-05-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.8...@ali/lowcode-plugin-components-pane@0.8.9) (2020-05-07) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.7...@ali/lowcode-plugin-components-pane@0.8.8) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.6...@ali/lowcode-plugin-components-pane@0.8.7) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.5...@ali/lowcode-plugin-components-pane@0.8.6) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.5](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.4...@ali/lowcode-plugin-components-pane@0.8.5) (2020-04-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.3...@ali/lowcode-plugin-components-pane@0.8.4) (2020-04-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## [0.8.3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-components-pane@0.8.2...@ali/lowcode-plugin-components-pane@0.8.3) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## 0.8.2 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane - - -## 0.8.1 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-components-pane diff --git a/packages/plugin-components-pane/README.md b/packages/plugin-components-pane/README.md deleted file mode 100644 index 8a6fb13f0..000000000 --- a/packages/plugin-components-pane/README.md +++ /dev/null @@ -1 +0,0 @@ -## todo diff --git a/packages/plugin-components-pane/build.json b/packages/plugin-components-pane/build.json deleted file mode 100644 index 77627cdf9..000000000 --- a/packages/plugin-components-pane/build.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "plugins": [ - "build-plugin-component", - "build-plugin-fusion", - ["build-plugin-moment-locales", { - "locales": ["zh-cn"] - }] - ] -} \ No newline at end of file diff --git a/packages/plugin-components-pane/package.json b/packages/plugin-components-pane/package.json deleted file mode 100644 index 2a847db83..000000000 --- a/packages/plugin-components-pane/package.json +++ /dev/null @@ -1,43 +0,0 @@ -{ - "name": "@ali/lowcode-plugin-components-pane", - "version": "1.0.22", - "description": "alibaba lowcode editor component-list plugin", - "files": [ - "es/", - "lib/" - ], - "main": "lib/index.js", - "module": "es/index.js", - "stylePath": "style.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "keywords": [ - "lowcode", - "editor" - ], - "author": "xiayang.xy", - "dependencies": { - "@ali/intl-universal": "^0.4.12", - "@ali/lowcode-designer": "^1.0.22", - "@ali/lowcode-editor-core": "^1.0.22", - "@ali/lowcode-types": "^1.0.20", - "@ali/vu-layer": "^4.0.1", - "@ali/vu-uxcore-legao-design": "^1.4.0", - "@alifd/next": "^1.19.19", - "react": "^16.8.1" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.3", - "@types/react": "^16.9.13", - "@types/react-dom": "^16.9.4", - "build-plugin-component": "^0.2.7-1", - "build-plugin-fusion": "^0.1.0", - "build-plugin-moment-locales": "^0.1.0" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/plugin-components-pane/src/components/base/index.less b/packages/plugin-components-pane/src/components/base/index.less deleted file mode 100644 index d257a0cbe..000000000 --- a/packages/plugin-components-pane/src/components/base/index.less +++ /dev/null @@ -1,116 +0,0 @@ -@import "~@ali/ve-less-variables/index.less"; - -.ve-component-list { - position: absolute; - top: 45px; - right: 0; - bottom: 0; - left: 0; - .ve-component-list-head { - height: 56px; - padding: 12px; - border-bottom: 1px solid var(--color-line-normal, rgba(31, 56, 88, 0.1)); - .ve-search-control { - width: 256px; - height: 32px; - margin: 0; - } - } - .ve-component-list-body { - display: flex; - height: 100%; - overflow: auto; - .ve-component-list-empty { - width: 100%; - padding: 20px; - text-align: center; - &.kuma-empty-data.normal .kuma-empty-data-icon { - width: 50px; - height: 50px; - background-size: 100% 100%; - display: inline-block; - } - } - .component-description-item-icon-group { - display: flex; - justify-content: flex-start; - align-items: center; - .component-description-item-icon { - margin-left: 4px; - &.tag { - display: flex; - justify-content: center; - align-items: center; - background: rgba(249, 189, 15, 0.1); - color: #ff6f00; - font-size: 12px; - width: 48px; - height: 24px; - } - } - icon { - position: relative; - font-size: 14px; - cursor: pointer; - color: rgba(31, 56, 88, 0.4); - transition: color @transition-duration @transition-ease; - &:hover { - color: rgba(31, 56, 88, 0.6); - } - a { - position: absolute; - left: 0; - top: 0; - display: inline-block; - width: 14px; - height: 14px; - } - } - } - &.small { - height: calc(100% - 56px - 48px); - } - &.medium { - height: calc(100% - 56px); - } - &.large { - height: calc(100% - 48px); - } - } - .ve-component-list-foot { - display: flex; - justify-content: center; - align-items: center; - position: absolute; - bottom: 0; - .btn { - margin-right: 8px; - flex: 1; - &:last-child { - margin-right: 0; - } - } - .kuma-button-primary { - background-color: var(--color-brand, @brand-color-1); - border-color: var(--color-brand, @brand-color-1); - border-radius: @global-border-radius; - color: var(--color-text-reverse, @white-alpha-2); - transition: background-color @transition-duration @transition-ease; - &:hover { - background-color: var(--color-brand-dark, @brand-color-3); - border-color: var(--color-brand-dark, @brand-color-3); - transition: background-color @transition-duration @transition-ease; - } - } - &.exist { - width: 100%; - height: 48px; - border-top: 1px solid var(--color-line-normal, rgba(31, 56, 88, 0.1)); - background: #fff; - padding: 0 12px; - } - } - ::-webkit-scrollbar { - display: none; - } -} diff --git a/packages/plugin-components-pane/src/components/base/index.tsx b/packages/plugin-components-pane/src/components/base/index.tsx deleted file mode 100644 index ccb8e8ba2..000000000 --- a/packages/plugin-components-pane/src/components/base/index.tsx +++ /dev/null @@ -1,264 +0,0 @@ -import React from 'react'; -import PropTypes from 'prop-types'; -import { Search, Box } from '@alifd/next'; -import Button from '../button'; -import Card from '../card'; -import $i18n from '../../i18n/index'; -import { searchComponent, builtinSearchMap } from '../../utils'; -import './index.less'; - -/** - * 配置元素的操作类型 - * Draggable:可拖拽 - * Clickable:可点击 - * All:可拖拽也可点击 - */ -export const AdditiveType = { - Draggable: 'additive-drag', - Clickable: 'additive-click', - All: 'additive', -}; - -class Base extends React.Component { - static propTypes = { - metaData: PropTypes.array, - className: PropTypes.string, - registerAdditive: PropTypes.func, - actions: PropTypes.array, - getComponentInfo: PropTypes.func, - enableSearch: PropTypes.bool, - placeholder: PropTypes.string, - }; - - static defaultProps = { - metaData: [], - registerAdditive: () => {}, - className: '', - renderCustomSnippet: null, - actions: [], - getComponentInfo: null, - enableSearch: false, - enableCard: true, - enableReport: true, - placeholder: '', - }; - - state = { - searchText: '', - currentCard: null, - target: null, - currentCardImage: '', - }; - - shell = null; - - isEmpty = false; - - mode = 'advance'; - - searchMap = {}; - - timer = null; - - isMouseEnterCard = false; - - - UNSAFE_componentWillMount() { - // TODO get remote search map - this.searchMap = builtinSearchMap; - } - - hasActions() { - const { actions } = this.props; - if (!actions || !Array.isArray(actions) || !actions.length) { - return false; - } - return true; - } - - onSearch(val) { - this.setState({ - searchText: val, - currentCard: null, // 清空卡片 - }); - } - - normalizeBundle(mode) { - const { metaData } = this.props; - const { searchText = '' } = this.state; - const groupList = metaData.filter((comp, index) => { - const { title = '', componentName = '', id = '' } = comp; - if (!id) { - comp.id = `${comp.componentName}_${index}`; - } - const query = searchText.toLowerCase(); - return ( - !![title, componentName].find( - (it) => it.toLowerCase().indexOf(query) > -1, - ) || !!searchComponent(title, query, this.searchMap) - ); - }); - - if (mode === 'simple') { - return groupList; - } - - const bundle = {}; - // 按一定顺序排列 - groupList.forEach((m) => { - const c = m.category || 'Others'; - if (!bundle[c]) { - bundle[c] = []; - } - bundle[c].push(m); - }); - return bundle; - } - - renderEmptyData() { - this.isEmpty = true; - return ( - - -
-
暂无组件,请在物料站点添加
-
-
- ); - } - - renderHeader() { - const { placeholder } = this.props; - return ( - - ); - } - - renderActions() { - const { actions = [] } = this.props; - if (!this.hasActions()) { - return null; - } - // const len = actions.length; - // TODO:len = 1:只有一个主按钮;len = 2:一个主按钮、一个次按钮;len >=3:一个主按钮、一个次按钮、其余放在按钮组里; - return actions.map((action, idx) => { - return ( - - ); - }); - } - - renderBundle() { - const { metaData } = this.props; - if (!metaData || !Array.isArray(metaData) || !metaData.length) { - return this.renderEmptyData(); - } - const bundle = this.normalizeBundle(this.mode); - if (!Object.keys(bundle).length || (Array.isArray(bundle) && bundle.length === 0)) { - return this.renderEmptyData(); - } - this.isEmpty = false; - return this.getBundle ? this.getBundle(bundle) : this.renderEmptyData(); - } - - renderCard() { - const { currentCard, target, currentCardImage } = this.state; - const { getComponentInfo } = this.props; - - if (!currentCard || !getComponentInfo) return null; - - return ( - { - this.setState({ currentCard: null }); - this.isMouseEnterCard = false; - }} - offset={{ - top: 10, - left: 10, - }} - onMouseEnter={() => { - this.isMouseEnterCard = true; - }} - /> - ); - } - - render() { - const { - enableSearch, - className, - registerAdditive = () => { - - }, - } = this.props; - let bodyExtraClass = ''; - if (this.hasActions() && enableSearch) { - bodyExtraClass = 'small'; - } else if (!this.hasActions() && enableSearch) { - bodyExtraClass = 'medium'; - } else if (this.hasActions() && !enableSearch) { - bodyExtraClass = 'large'; - } else { - bodyExtraClass = ''; - } - - return ( -
- {enableSearch ? ( -
- {this.renderHeader()} -
- ) : null} -
{ - if (this.shell || !shell || this.isEmpty) { - return; - } - if (!this.shell) { - this.shell = shell; - } - registerAdditive(shell); - }} - > - {this.renderBundle()} -
-
- {this.renderActions()} -
- {this.renderCard ? this.renderCard() : null} -
- ); - } -} - -export default Base; diff --git a/packages/plugin-components-pane/src/components/button/index.less b/packages/plugin-components-pane/src/components/button/index.less deleted file mode 100644 index ef62922e6..000000000 --- a/packages/plugin-components-pane/src/components/button/index.less +++ /dev/null @@ -1,18 +0,0 @@ -.ve-component-list { - .kuma-button-outline { - border-color: #0079f2; - color: #0079f2; - &:hover { - border-color: #0079f2; - color: #0079f2; - background-color: #f0f7ff; - } - &.kuma-button-danger { - border-color: #f04631; - color: #f04631; - &:hover { - background-color: rgba(240, 70, 49, 0.06); - } - } - } -} diff --git a/packages/plugin-components-pane/src/components/button/index.tsx b/packages/plugin-components-pane/src/components/button/index.tsx deleted file mode 100644 index 929915344..000000000 --- a/packages/plugin-components-pane/src/components/button/index.tsx +++ /dev/null @@ -1,22 +0,0 @@ -import { Button } from '@ali/vu-uxcore-legao-design'; -import './index.less'; - -const MyButton = (props) => { - const { action, componentPrototype, type, className } = props; - return ( - - ); -}; - -export default MyButton; diff --git a/packages/plugin-components-pane/src/components/card/index.less b/packages/plugin-components-pane/src/components/card/index.less deleted file mode 100644 index 00d7960eb..000000000 --- a/packages/plugin-components-pane/src/components/card/index.less +++ /dev/null @@ -1,130 +0,0 @@ -@import "~@ali/ve-less-variables/index.less"; - -.ve-card-wrapper { - width: 320px; - max-height: 360px; - overflow: auto; - justify-content: center; - - &.ve-card-wrapper-loading { - display: flex; - justify-content: center; - text-align: center; - overflow: hidden; - } - - .ve-card-top { - height: 186px; - background: rgba(31, 56, 88, 0.1); - padding: 16px; - - .ve-card-title { - display: flex; - align-items: center; - padding-bottom: 12px; - position: relative; - height: 31px; - color: rgba(0, 0, 0, 0.8); - - .title { - line-height: 22px; - font-size: 16px; - } - - .version { - margin-left: 8px; - font-size: 12px; - line-height: 22px; - color: rgba(31, 56, 88, 0.4); - } - } - - .ve-card-image-wrapper { - background-color: #fff; - .ve-card-image { - max-width: 100%; - height: 120px; - margin: 0 auto; - display: block; - padding: 10px; - } - } - } - - .ve-card-bottom { - padding: 8px 16px 16px 16px; - .ve-card-description { - user-select: text; - text-align: left; - line-height: 18px; - font-size: 12px; - color: rgba(0, 0, 0, 0.6); - letter-spacing: 0; - line-height: 18px; - width: 280px; - - p { - margin-bottom: 8px; - } - - p:last-child { - margin-bottom: 0; - } - } - - .ve-operation-container { - margin-top: 12px; - position: relative; - .actions { - margin-top: 16px; - } - } - } - - .ve-operation-item { - color: @brand-color-1; - cursor: pointer; - margin-right: 8px; - } - - .ve-operation-delete { - position: absolute; - top: 0; - right: 0; - } - - .ve-card-more-operation { - display: flex; - justify-content: space-between; - > a { - cursor: pointer; - } - } - - .ve-loading-icon { - animation: spining 0.9s infinite linear; - } - .ve-loading-content { - padding: 10px; - text-align: center; - } - - .ve-card-action { - padding: 0 8px !important; - margin-right: 8px; - } -} - -.ve-component-list { - .vu-layer { - border-radius: 4px !important; - .vu-layer-content { - padding-top: 0 !important; - } - } - - .vu-layer .vu-layer-close { - right: 9px !important; - top: 9px !important; - } -} diff --git a/packages/plugin-components-pane/src/components/card/index.tsx b/packages/plugin-components-pane/src/components/card/index.tsx deleted file mode 100644 index c03020ca3..000000000 --- a/packages/plugin-components-pane/src/components/card/index.tsx +++ /dev/null @@ -1,141 +0,0 @@ -import React from 'react'; -import Layer from '@ali/vu-layer'; -import { Icon } from '@alifd/next'; -import $i18n from '../../i18n/index'; -import Button from '../button'; -import './index.less'; - -export default class Card extends React.Component { - static propTypes = {}; - - constructor(props) { - super(props); - - this.state = { - isLoading: true, - errorMsg: false, - componentInfo: {}, - }; - } - - componentDidMount() { - if (!this.props.getComponentInfo) return; - this.loadComponentInfo(this.props.componentPrototype); - } - - UNSAFE_componentWillReceiveProps(nextProps) { - if (nextProps.componentPrototype !== this.props.componentPrototype) { - // 延迟执行数据加载和渲染,等 props 更新之后 - this.loadComponentInfo(nextProps.componentPrototype); - } - } - - loadComponentInfo(componentPrototype) { - if (!this.props.getComponentInfo) return; - this.setState({ isLoading: true }); - this.props - .getComponentInfo(componentPrototype) - .then((componentInfo) => { - this.setState({ - componentInfo, - isLoading: false, - }); - }) - .catch((e) => { - this.setState({ errorMsg: e.message }); - console.error(e); - }); - } - - render() { - const { componentPrototype, subTitle, customImage } = this.props; - const { componentInfo } = this.state; - - const loadingContent = this.state.errorMsg ? ( -
-
{this.state.errorMsg}
-
- ) : ( -
- -
- {$i18n.get({ id: 'trunkPaneLoading', dm: '加载中...' })} -
-
- ); - - const { - title, - version, - image = 'https://img.alicdn.com/tfs/TB1XHG6ehrI8KJjy0FpXXb5hVXa-740-608.png', - desc, - detailUrl, - actions, - } = componentInfo; - - let layerContent = null; - const cardTitle = subTitle && !subTitle.includes(title) ? `${title}(${subTitle})` : title; - - if (this.state.isLoading) { - layerContent = ( -
- {loadingContent} -
- ); - } else { - layerContent = ( -
-
-
- {cardTitle} - {version} -
-
- {cardTitle} -
-
-
-
-

{desc}

-
-
- {detailUrl ? ( - - {$i18n.get({ - id: 'trunkPaneDetailedDocumentation', - dm: '详细文档', - })} - - ) : null} -
- { - actions ? actions.map((action, idx) => { - return ( -
-
-
-
- ); - } - - return ( - - {layerContent} - - ); - } -} diff --git a/packages/plugin-components-pane/src/components/component-list/index.less b/packages/plugin-components-pane/src/components/component-list/index.less deleted file mode 100644 index 62f60096f..000000000 --- a/packages/plugin-components-pane/src/components/component-list/index.less +++ /dev/null @@ -1,117 +0,0 @@ -@import "~@ali/ve-less-variables/index.less"; - -@text-color-active: #0079f2; - -.ve-component-list { - .ve-component-list-body { - .ve-component-list-sidebar { - flex: 0 0 110px; - width: 110px; - // height: 100%; - padding-top: 11px; - border-right: 1px solid var(--color-line-normal, rgba(31, 56, 88, 0.1)); - overflow: auto; - .ve-component-list-navigator { - .navigator-group { - margin-bottom: 8px; - & > div { - display: flex; - align-items: center; - width: 100%; - } - .navigator-group-head { - padding: 0px 12px; - color: @dark-alpha-2; - .navigator-group-title { - padding: 4px 0; - width: 100%; - line-height: 16px; - font-size: @fontSize-5; - font-weight: 700; - border-bottom: 1px solid - var(--color-line-normal, rgba(31, 56, 88, 0.1)); - } - } - .navigator-group-item { - height: 32px; - padding: 8px 12px; - color: #666666; - cursor: pointer; - .navigator-group-item-title { - font-size: @fontSize-5; - white-space: nowrap; - overflow: hidden; - text-overflow: ellipsis; - text-align: left; - } - &:hover { - color: @text-color-active; - } - &.active { - background: rgba(0, 121, 242, 0.1); - color: @text-color-active; - border-right: 2px solid @text-color-active; - } - } - } - } - } - .ve-component-list-content { - flex: 1; - width: 250px; - // height: 100%; - overflow-y: auto; - overflow-x: hidden; - .component-description-list { - padding: 10px 4px; - .component-description-item { - padding-bottom: 24px; - .component-description-item-header { - display: flex; - justify-content: flex-start; - align-items: center; - .component-description-item-title { - font-family: @font-family; - font-size: @fontSize-5; - font-weight: 700; - color: @text-color; - line-height: 20px; - padding-left: 8px; - } - .component-description-item-icon-group { - display: flex; - justify-content: flex-start; - align-items: center; - .component-description-item-icon { - margin-left: 4px; - } - icon { - position: relative; - font-size: 14px; - cursor: pointer; - color: rgba(31, 56, 88, 0.4); - transition: color @transition-duration @transition-ease; - &:hover { - color: rgba(31, 56, 88, 0.6); - } - a { - position: absolute; - left: 0; - top: 0; - display: inline-block; - width: 14px; - height: 14px; - } - } - } - } - .component-description-item-snippets { - display: flex; - justify-content: flex-start; - flex-flow: row wrap; - } - } - } - } - } -} diff --git a/packages/plugin-components-pane/src/components/component-list/index.tsx b/packages/plugin-components-pane/src/components/component-list/index.tsx deleted file mode 100644 index d23c386ca..000000000 --- a/packages/plugin-components-pane/src/components/component-list/index.tsx +++ /dev/null @@ -1,286 +0,0 @@ -import Base, { AdditiveType } from '../base/index'; -import Snippet from '../snippet'; -import './index.less'; - -// 滚动事件触发灵敏度 -const OFFSET_ACCURCY = 25; - -const categoryMap = { - General: '常用', - Navigation: '导航', - DataEntry: '输入', - DataDisplay: '展示', - Feedback: '反馈', - Util: '工具', - Chart: '图表', - Others: '其他', -}; - -export default class ComponentList extends Base { - static displayName = 'ComponentList'; - - descRefList = new Map(); - - navRefList = new Map(); - - descHeightList = new Map(); - - snippetMap = new Map(); - - currentScrollHeight = 0; - - scrollFlag = true; - - scroll; - - scrollTimer; - - state = { - selected: '', - searchText: '', - currentCard: null, - currentCardImage: '', - }; - - componentDidMount() { - setTimeout(() => { - this.calDescHeightList(); - - // mock 滚动结束事件 - if (this.scroll) { - this.scroll.addEventListener('scroll', this.handleScrollEnd); - } - }, 20); - const bundle = this.normalizeBundle(); - if (!bundle) { - return; - } - const cats = Object.keys(bundle); - if (cats.length > 0) { - const k = cats[0]; - const comps = bundle[k]; - if (!comps || !Array.isArray(comps) || !comps.length) { - return; - } - this.setState({ selected: comps[0].id }); - } - } - - componentWillUnmount() { - if (this.scroll) { - this.scroll.removeEventListener('scroll', this.handleScrollEnd); - } - } - - handleScrollEnd = () => { - clearTimeout(this.scrollTimer); - this.scrollTimer = setTimeout(() => { - // 滚动结束时归位 - this.scrollFlag = true; - }, 100); - }; - - toggleComponent(id) { - const element = this.descRefList.get(id); - // 切换组件时滚动事件回调不可用 - this.scrollFlag = false; - element.scrollIntoView(); - this.setState({ selected: id }); - } - - handleScroll(e) { - // 清空卡片 - if (this.state.currentCard) { - this.setState({ currentCard: null }); - } - clearTimeout(this.timer); - this.timer = null; - - if (!this.scrollFlag) { - return; - } - const element = e.target; - const { scrollTop } = element; - - // 延迟处理 - if (Math.abs(scrollTop - this.currentScrollHeight) < OFFSET_ACCURCY) { - return; - } - this.currentScrollHeight = scrollTop; - - // 处理导航块滚动高亮效果 - const heightList = [...this.descHeightList.entries()]; - let selected; - // 当在顶部 - if (scrollTop >= 0 && scrollTop < heightList[0][1]) { - selected = heightList[0][0]; - } else if (scrollTop >= heightList[heightList.length - 1][1]) { - // 底部 - selected = heightList[heightList.length - 1][0]; - } else { - // 当在中部 - for (let i = 0; i < heightList.length - 2; i++) { - const height1 = heightList[i][1]; - const height2 = heightList[i + 1][1]; - if (scrollTop > height1 && scrollTop < height2) { - selected = heightList[i + 1][0]; - } - } - } - this.fixSideBarView(selected); - this.setState({ selected }); - } - - // 导航高亮块超出视口时滚动 - fixSideBarView(selected) { - const nav = this.navRefList.get(selected); - if (nav) { - nav.scrollIntoView({ block: 'center' }); - } - } - - calDescHeightList() { - let height = 0; - this.descRefList.forEach((ele, key) => { - if (!ele) { - return; - } - height += ele.clientHeight; - this.descHeightList.set(key, height); - }); - } - - renderNavigator(bundle) { - return ( -
- {Object.keys(bundle).map((c) => { - const catTitle = categoryMap[c] || c; - const catData = bundle[c]; - return this.renderNavigatorGroup(catTitle, catData); - })} -
- ); - } - - renderNavigatorGroup(title, metaData) { - const { selected } = this.state; - if (!metaData) { - return null; - } - return ( -
-
-
{title}
-
- {metaData.map((comp) => ( -
{ - this.navRefList.set(comp.id, item); - }} - onClick={() => this.toggleComponent(comp.id)} - > - {comp.title} -
- ))} -
- ); - } - - renderComponentDescriptionList(bundle) { - const { renderCustomSnippet = '', enableCard = true } = this.props; - return ( -
- {Object.keys(bundle).map((cat) => { - const catData = bundle[cat]; - if (!catData) { - return null; - } - return catData.map((comp) => ( -
{ - this.descRefList.set(comp.id, item); - }} - > -
- {comp.title ? ( -
- {comp.title} -
- ) : null} -
-
-
- {comp.snippets && - comp.snippets.map((snippet, idx) => ( -
{ - this.snippetMap.set(`${comp.id}-${idx}`, i); - }} - onMouseEnter={() => { - if (!enableCard) { - return; - } - this.timer = setTimeout(() => { - this.setState({ - currentCard: comp, - target: this.snippetMap.get(`${comp.id}-${idx}`), - currentCardImage: snippet.thumbnail, - }); - this.timer = null; - }, 1000); - }} - onMouseLeave={() => { - if (!enableCard) { - return; - } - clearTimeout(this.timer); - this.timer = null; - setTimeout(() => { - if (this.isMouseEnterCard) { - return; - } - this.setState({ currentCard: null }); - }, 200); - }} - > - -
- ))} -
-
- )); - })} -
- ); - } - - getBundle(bundle) { - return [ -
- {this.renderNavigator(bundle)} -
, -
this.handleScroll(e)} - ref={(scroll) => { this.scroll = scroll; }} - > - {this.renderComponentDescriptionList(bundle)} -
, - ]; - } -} diff --git a/packages/plugin-components-pane/src/components/snippet/index.less b/packages/plugin-components-pane/src/components/snippet/index.less deleted file mode 100644 index 6c3809bfa..000000000 --- a/packages/plugin-components-pane/src/components/snippet/index.less +++ /dev/null @@ -1,120 +0,0 @@ -@import "~@ali/ve-less-variables/index.less"; - -@text-color-active: #0079f2; - -.component-description-item-snippet { - position: relative; - &.small { - width: 64px; - height: 66px; - .snippet-thumbnail { - height: 40px; - img, - .icon { - max-width: 56px; - max-height: 32px; - } - } - } - &.large { - width: 132px; - height: 126px; - .snippet-thumbnail { - height: 100px; - img, - .icon { - max-width: 116px; - max-height: 83px; - } - } - } - margin: 12px 8px 0 8px; - cursor: grab; - .snippet-title { - width: 100%; - padding: 0 4px; - font-size: @fontSize-5; - color: #666666; - text-align: center; - text-overflow: ellipsis; - white-space: nowrap; - overflow: hidden; - } - .snippet-thumbnail { - display: flex; - justify-content: center; - align-items: center; - width: 100%; - margin-bottom: 9px; - border-radius: @global-border-radius; - border: 1px dashed #cdd2d9; - transition: border @transition-duration @transition-ease; - img, - .icon { - width: auto; - height: auto; - } - svg { - font-size: 28px; - } - svg * { - fill: rgba(31, 56, 88, 0.6) !important; - } - } - .component-description-item-icon { - &.tag { - display: flex; - justify-content: center; - align-items: center; - background: rgba(249, 189, 15, 0.1); - color: #ff6f00; - font-size: 12px; - border-radius: 3px; - width: 48px; - height: 24px; - } - } - .engine-additive-helper { - &.left-top { - position: absolute; - left: 0; - top: 0; - } - &.right-top { - display: none; - } - icon { - position: relative; - font-size: 14px; - cursor: pointer; - color: rgba(31, 56, 88, 0.4); - transition: color @transition-duration @transition-ease; - &:hover { - color: rgba(31, 56, 88, 0.6); - } - a { - position: absolute; - left: 0; - top: 0; - display: inline-block; - width: 14px; - height: 14px; - } - } - } - &:hover { - .snippet-thumbnail { - border: 2px solid @text-color-active; - transition: border @transition-duration @transition-ease; - } - .right-top { - display: block; - position: absolute; - right: 0; - top: 0; - height: 24px; - display: flex; - align-items: center; - } - } -} diff --git a/packages/plugin-components-pane/src/components/snippet/index.tsx b/packages/plugin-components-pane/src/components/snippet/index.tsx deleted file mode 100644 index a8f299659..000000000 --- a/packages/plugin-components-pane/src/components/snippet/index.tsx +++ /dev/null @@ -1,46 +0,0 @@ -import { Fragment } from 'react'; -import { Icon } from '@alifd/next'; -import { AdditiveType } from '../base'; -import './index.less'; - -const Snippet = (props) => { - const { - snippet, - renderCustomSnippet = '', - size = 'small', - actionsInLT, - actionsInRT, - } = props; - const { - thumbnail = 'https://img.alicdn.com/tfs/TB1XHG6ehrI8KJjy0FpXXb5hVXa-740-608.png', - description, - title = '未知', - } = snippet; - const snippetClassName = `component-description-item-snippet ${AdditiveType.All} ${size}`; - return ( -
- {typeof renderCustomSnippet === 'function' ? ( - renderCustomSnippet(snippet) - ) : ( - -
- {typeof thumbnail === 'string' && thumbnail.startsWith('http') ? ( - thumbnail - ) : ( - - )} -
-
{description || title}
-
- {actionsInLT || null} -
-
- {actionsInRT || null} -
-
- )} -
- ); -}; - -export default Snippet; diff --git a/packages/plugin-components-pane/src/i18n/index.ts b/packages/plugin-components-pane/src/i18n/index.ts deleted file mode 100644 index 9cecc0762..000000000 --- a/packages/plugin-components-pane/src/i18n/index.ts +++ /dev/null @@ -1,45 +0,0 @@ -const { provideIntl, destroyIntl } = require('@ali/intl-universal'); -const strings = require('./strings'); - -let intl; -const MEDUSA_APP_NAME = 'legao-designer'; -const PSEUDO_LANGUAGE_TAG = 'pd-KV'; -const CURRENT_LANGUAGE = (window.locale || '').replace(/_/, '-') || 'zh-CN'; - -function update(language) { - destroyIntl(); - intl = provideIntl({ - locale: language, - messagesAIO: strings, - }); -} - -function get(id, variable) { - if (!intl) update(); - let string = ''; - let key = ''; - if (typeof id === 'string') { - key = id; - string = intl.formatMessage({ id }, variable); - } - if (typeof id === 'object' && id.dm) { - id.defaultMessage = id.dm; - } - key = id.id; - string = intl.formatMessage(id, variable); - if (CURRENT_LANGUAGE === PSEUDO_LANGUAGE_TAG) { - return `##@@@${key}##${MEDUSA_APP_NAME}@@@##${string}`; - } - return string; -} - -if (PSEUDO_LANGUAGE_TAG === CURRENT_LANGUAGE) { - update('en-US'); -} else { - update(CURRENT_LANGUAGE); -} - -export default { - get, - update, -}; diff --git a/packages/plugin-components-pane/src/i18n/strings/en-US.json b/packages/plugin-components-pane/src/i18n/strings/en-US.json deleted file mode 100644 index f6873f90d..000000000 --- a/packages/plugin-components-pane/src/i18n/strings/en-US.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "trunkPaneTheComponentPrototypeView": "The component prototype view does not exist and may be caused by the following reasons:", - "trunkPaneDetailedComponentInformationIs": "Detailed component information is already printed in the Console", - "trunkPaneIsTheComponentRemoved": "Is the component removed because the component cannot find the prototype view?", - "trunkPaneLoading": "Loading...", - "trunkPaneFoundComponentNameRComponentName": "Found component name: {rComponentName} has a problem", - "trunkPaneDetailedDocumentation": "Detailed documentation", - "trunkPaneComponentComponentInfoComponentNameDeletedSuccessfully": "Component {componentInfoComponentName} deleted successfully", - "trunkPaneUpdateComponent": "Update component", - "trunkPaneComponentLibrary": "Component library", - "trunkPaneSearchComponent": "Search component", - "trunkPaneCustomize": "customize", - "trunkPaneTheComponentInQuestion": "The component in question:", - "trunkPaneComponentMarket": "Component market", - "trunkPaneUncategorized": "uncategorized", - "trunkPaneNoSearchResultsYet": "No search results yet", - "trunkPaneAll": "All", - "trunkPaneClickToTheLEGO": "Click ? to the Component Center", - "trunkPaneClickToTroubleshootThe": "Click to troubleshoot the issue", - "trunkPaneComponent": "Component", - "trunkPaneComponentCenter": "Component center", - "trunkPaneClose": "╳ Close", - "trunkPaneDetail": "Detail", - "trunkPaneEdit": "Edit", - "trunkPaneDev": "Dev", - "trunkPaneHelp": "Help" -} diff --git a/packages/plugin-components-pane/src/i18n/strings/index.ts b/packages/plugin-components-pane/src/i18n/strings/index.ts deleted file mode 100644 index 9b61c93e1..000000000 --- a/packages/plugin-components-pane/src/i18n/strings/index.ts +++ /dev/null @@ -1,4 +0,0 @@ -module.exports = { - 'en-US': require('./en-US.json'), - 'zh-CN': require('./zh-CN.json'), -}; diff --git a/packages/plugin-components-pane/src/i18n/strings/zh-CN.json b/packages/plugin-components-pane/src/i18n/strings/zh-CN.json deleted file mode 100644 index 82f52faf1..000000000 --- a/packages/plugin-components-pane/src/i18n/strings/zh-CN.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - "trunkPaneAll": "全部", - "trunkPaneFoundComponentNameRComponentName": "发现组件名为:{rComponentName}存在问题", - "trunkPaneNoResultsYet": "暂无结果", - "trunkPaneUpdateComponent": "更新组件", - "trunkPaneClickToTroubleshootThe": "点击排查问题", - "trunkPaneClickToTheLEGO": "点击 ? 前往组件中心", - "trunkPaneComponentLibrary": "组件库", - "trunkPaneComponentCenter": "组件中心", - "trunkPaneDetailedComponentInformationIs": "详细的组件信息已经打印在 Console 中", - "trunkPaneTheComponentPrototypeView": "组件原型视图不存在,可能由以下原因导致:", - "trunkPaneLoading": "加载中...", - "trunkPaneTheComponentInQuestion": "存在问题的组件:", - "trunkPaneIsTheComponentRemoved": "由于该组件找不到原型视图,是否移除组件?", - "trunkPaneDetailedDocumentation": "详细文档", - "trunkPaneUncategorized": "未分类", - "trunkPaneComponentMarket": "组件市场", - "trunkPaneCustomize": "自定义", - "trunkPaneSearchComponent": "搜索组件", - "trunkPaneComponent": "组件", - "trunkPaneClose": "╳ 关闭", - "trunkPaneDetail": "详情", - "trunkPaneEdit": "编辑", - "detrunkPaneDev": "开发版", - "trunkPaneHelp": "帮助" -} diff --git a/packages/plugin-components-pane/src/index.scss b/packages/plugin-components-pane/src/index.scss deleted file mode 100644 index 73206cc27..000000000 --- a/packages/plugin-components-pane/src/index.scss +++ /dev/null @@ -1,25 +0,0 @@ -.lowcode-component-list { - height: 100%; - display: flex; - flex-flow: column; - .title { - height: 40px; - line-height: 39px; - border-bottom: 1px solid $color-line1-1; - padding: 0 8px; - position: relative; - } - .search { - display: block; - width: auto; - margin: 8px 8px 0; - } - .select { - display: block; - margin: 8px 8px 4px; - } - .components-show { - flex: 1 1 0%; - overflow: hidden; - } -} diff --git a/packages/plugin-components-pane/src/index.tsx b/packages/plugin-components-pane/src/index.tsx deleted file mode 100644 index f166bca9f..000000000 --- a/packages/plugin-components-pane/src/index.tsx +++ /dev/null @@ -1,149 +0,0 @@ -import { Component, ReactNode } from 'react'; -import { Tab } from '@alifd/next'; -import ComponentList from './components/component-list'; -import { AdditiveType } from './components/base'; -import { PluginProps } from '@ali/lowcode-types'; -import { Designer } from '@ali/lowcode-designer'; - -import './index.scss'; - -export interface IState { - metaData: Array>; - bizComponents: Array>; -} - -export default class ComponentListPlugin extends Component { - static displayName = 'LowcodeComponentListPlugin'; - - snippetsMap = new Map(); - - constructor(props: any) { - super(props); - this.state = { - metaData: [], - bizComponents: [], - }; - } - - componentDidMount(): void { - const { editor } = this.props; - if (editor.get('assets')) { - this.initComponentList(); - } else { - editor.once('editor.ready', this.initComponentList); - } - } - - transformMetaData(componentList: any, scope: string): any { - const metaData: Array> = []; - if (!componentList || !Array.isArray(componentList) || !componentList.length) { - return metaData; - } - componentList.forEach((category: any, categoryId: number) => { - if (Array.isArray(category?.children)) { - category.children.forEach((comp: any, compId: number) => { - metaData.push({ - id: `${scope}-${categoryId}-${compId}`, - componentName: comp.componentName, - title: comp.title, - category: category.title, - snippets: comp.snippets.map((snippet: any, snippetId: number) => { - const item = { - id: `${scope}-${categoryId}-${compId}-${snippetId}`, - description: snippet.title, - thumbnail: snippet.screenshot, - schema: snippet.schema, - }; - this.snippetsMap.set(item.id, item.schema); - return item; - }), - }); - }); - } - }); - return metaData; - } - - initComponentList = (): void => { - const { editor } = this.props; - const assets = editor.get('assets') || {}; - const metaData = this.transformMetaData(assets.componentList, 'basic'); - const bizComponents = this.transformMetaData(assets.bizComponentList, 'biz'); - - this.setState({ - metaData, - bizComponents, - }); - }; - - registerAdditive(shell: Element | null) { - if (!shell) { - return; - } - - function getSnippetId(elem: any, operation = AdditiveType.All) { - if (!elem || !operation) { - return null; - } - while (shell !== elem) { - if (elem.classList.contains(operation) || elem.classList.contains(AdditiveType.All)) { - return elem.dataset.id; - } - // tslint:disable-next-line - elem = elem.parentNode; - } - return null; - } - - const { editor } = this.props; - const designer = editor.get(Designer); - if (!designer) { - return; - } - - const click = (e: Event) => { console.log(e); }; - - shell.addEventListener('click', click); - - designer.dragon.from(shell, (e: Event) => { - const doc = designer.currentDocument; - const id = getSnippetId(e.target, AdditiveType.Draggable); - - if (!doc || !id) { - return false; - } - - const dragTarget = { - type: 'nodedata', - data: this.snippetsMap.get(id), - }; - return dragTarget; - }); - } - - render(): ReactNode { - const { metaData, bizComponents } = this.state; - return ( -
- - - this.registerAdditive(shell)} - enableSearch - /> - - - this.registerAdditive(shell)} - enableSearch - /> - - -
- ); - } -} diff --git a/packages/plugin-components-pane/src/module.d.ts b/packages/plugin-components-pane/src/module.d.ts deleted file mode 100644 index 82b99e111..000000000 --- a/packages/plugin-components-pane/src/module.d.ts +++ /dev/null @@ -1 +0,0 @@ -declare module '@ali/ve-component-list'; diff --git a/packages/plugin-components-pane/src/utils.ts b/packages/plugin-components-pane/src/utils.ts deleted file mode 100644 index c8b6cbb64..000000000 --- a/packages/plugin-components-pane/src/utils.ts +++ /dev/null @@ -1,98 +0,0 @@ -export const builtinSearchMap = { - 容器: '容器、rongqi、rq、分栏、ColumnsLayout、Columns、layout、grid', - 分栏: '分栏、ColumnsLayout、Columns、layout、grid、容器、rongqi、rq、fl、fenlan', - 卡片: '卡片、card、kapian、kp', - 选项卡: '选项卡、tab、tabs、页签、xuanxiangka、xxk、yeqian、yq', - 按钮: '按钮、button、anniu、an', - 图标: '图标、icon、tubiao、tb', - 标题: '标题、title、biaoti、bt', - 图片: '图片、image、pic、picture、tupian、tp', - Dialog: '对话框、Dialog、弹框、弹出框、duihuakuang、dhk', - Drawer: '抽屉、Drawer、chouti、ct、couti', - 文本: '文本、文字、text、wenzi、wz、wenben', - 链接: '链接、link、lianjie、lj', - 链接块: '链接块、链接、link、lianjie、lj、ljk', - 表单容器: '表单容器、表单、form、biaodan、bd', - 输入框: '输入框、文本框、密码框、input、shurukuang、srk、wenbenkuang、wbk', - 数字输入框: '数字输入框、数字、输入框、Number、NumberPicker、shuzi、sz、srk、shurukuang', - 单选: '单选、radio button、radio、danxuan、dx', - 多选: '复选、复选框、多选、Checkbox、check、fuxuan、fx、dx、duoxuan', - 下拉选择: '下拉选择、Select、选择器、下拉、xiala、xl、xialaxuanze、xlxz', - 开关: '开关、switch、kaiguan、kg', - 日期: '日期选择、date、DatePicker、riqi、riqixuanz、rq、rqxz', - 日期区间: '日期区间、Cascade、date、riqiqujian、rq', - 时间选择框: '时间选择、time、TimePicker、shijian、sj、shijianxuanze、sjxz、xuanzekuang', - 上传图片: '上传图片、upload、上传、shangchuan、sc、tupian', - 上传附件: '上传附件、upload、上传、shangchuan、sc、fujian', - 树形选择: '树形选择、树型选择、树选择、tree、TreeSelect、shu、sxz、shuxingxuanze', - 级联选择: '级联选择、Cascade、Cascadeselect、级联、jilian、jl、jilianxuanze、jlxz', - 地区选择: '地区选择、city、地址、address、地区、diqu、dq、diquxuanze、dqxz', - 国家选择: '国家选择、country、国家、guojia、gj、guojiaxuanze、gjxz', - 评分: '评分、Rate、Rating、星、pingfen、pf', - 明细: '明细、table、表格、表单、form、mingxi、mx', - 穿梭框: '穿梭框、transfer、chuansuokuang、csk', - 人员搜索框: '人员搜索框、employee、人员选择、选人、xuanren、xr、renyuansousuo、ryss', - 筛选: '筛选、pickable、shaixuan、sx', - 金额输入框: '金额输入框、输入框、shurukuang、srk、money、金额、jine、je', - 金额区间: '金额区间、money、金额、jine、je', - 查询: '查询、filter、chaxun、cx', - 表格: '表格、table、biaoge、bg', - 数据文本: '数据文本、Number Info、数据、shuju、sj、shujuwenben、sjwb', - 数据趋势: '数据趋势、Number Trend、数据、shuju、sj、shujuqushi、sjqs', - 勾选框: '勾选框、复选框、check box、gouxuankuang、gxk、fuxuankuang、fxk', - 图片浏览: '图片浏览、图片预览、image、pic、picture、图片、预览、tupianyulan、tupianliulan、tupian、tp、yulan、yl', - 搜索: '搜索、搜索框、查询框、查询、search、sousuo、ss', - 树形控件: '树形控件、树组件、tree、shuzujian、shuxingkongjian、shu、szj、sxkj', - 富文本框: '富文本框、RichText、fuwenben、fwb', - 步骤: '步骤、步骤条、step、steps、buzhoutiao、buzhou、bzt、bz', - 时间轴: '时间轴、时间线、timeline、shijianzhou、shijianxian、sjz、sjx', - 菜单: '菜单、menu、caidan、cd', - 气泡提示: '气泡提示、tip、tips、balloon、气泡、qipao、qp、qipaotishi、qpts', - 面包屑: '面包屑、breadcrumb、crumb、mianbaoxie、mbx', - 日历: '日历、calendar、rili、rl', - 折叠面板: '折叠面板、collapse、折叠、zhedie、zd、zhediemianban、zdmb', - 下拉菜单: '下拉菜单、dropdown、下拉、xiala、xl、xialacaidan、xlcd、菜单、caidan、cd', - 信息提示: '信息提示、message、alert、信息、提示、警示、xinxitishi、xxts、xinxi、xx、tishi、ts、消息、xiaoxi', - 进度指示器: '进度指示器、进度条、progress、jindutiao、jdt、进度、jindu、jd', - 翻页器: '翻页器、分页器、pagination、fanyeqi、fyq、分页、fenye、fy', - 轮播图: '轮播图、图片轮播、slider、轮播、lunbo、lb、lunbotu、lbt', - 底部通栏: '底部通栏、tool bar、通栏、dibutonglan、dbtl、浮动工具条、浮动、工具条、工具、fudong、gongju、toolbar、tool bar、fd、gj', - HTML: 'html', - JSX: 'jsx', - 浮动导航: '浮动导航、nav、floatNav、fudongdaohang、fddh', - Iframe: 'Iframe', - Markdown: 'Markdown', - 区段选择器: '区段选择、滑块选择、区段、滑块、选择、Range、quduan、huakuai、xuanze、qdxz、hkxz、xz', -}; - -/** - * @param {string} title 组件名 - * @param {string} query 搜索词 - * @param {object} map 映射关系 - */ -export function searchComponent(title, query, map = {}) { - if (!title || !query || !map || !map[title]) { - return false; - } - const keys = (map[title] || '').split('、'); - return !!keys.find(key => { - if (!key) { - return false; - } - return key.indexOf(query) > -1; - }); -} - -export function debounce(func, delay) { - let timer; - return function (...args) { - if (timer) { - return; - } - timer = setTimeout(() => { - func.apply(this, args); - clearTimeout(timer); - timer = null; - }, delay); - }; -} diff --git a/packages/plugin-components-pane/tsconfig.json b/packages/plugin-components-pane/tsconfig.json deleted file mode 100644 index 4a965ec62..000000000 --- a/packages/plugin-components-pane/tsconfig.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -} - diff --git a/packages/plugin-designer/.eslintrc.js b/packages/plugin-designer/.eslintrc.js deleted file mode 100644 index c4749b311..000000000 --- a/packages/plugin-designer/.eslintrc.js +++ /dev/null @@ -1,14 +0,0 @@ -module.exports = { - extends: '../../.eslintrc.js', - rules: { - 'react/no-multi-comp': 1, - 'no-unused-expressions': 1, - 'implicit-arrow-linebreak': 1, - 'no-nested-ternary': 1, - 'no-mixed-operators': 1, - '@typescript-eslint/no-parameter-properties': 1, - '@typescript-eslint/ban-types': 1, - 'no-shadow': 1, - 'no-prototype-builtins': 1, - } -} \ No newline at end of file diff --git a/packages/plugin-designer/CHANGELOG.md b/packages/plugin-designer/CHANGELOG.md deleted file mode 100644 index 1824e47eb..000000000 --- a/packages/plugin-designer/CHANGELOG.md +++ /dev/null @@ -1,676 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - - -## [1.0.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.21...@ali/lowcode-plugin-designer@1.0.22) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.20...@ali/lowcode-plugin-designer@1.0.21) (2020-11-10) - - -### Bug Fixes - -* 修复数据源的接入问题 ([98ae1ed](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/98ae1ed)) - - - - - -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.19...@ali/lowcode-plugin-designer@1.0.20) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.18...@ali/lowcode-plugin-designer@1.0.19) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.17...@ali/lowcode-plugin-designer@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.16...@ali/lowcode-plugin-designer@1.0.17) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.15...@ali/lowcode-plugin-designer@1.0.16) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.13...@ali/lowcode-plugin-designer@1.0.15) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.12...@ali/lowcode-plugin-designer@1.0.13) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.11...@ali/lowcode-plugin-designer@1.0.12) (2020-10-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.10...@ali/lowcode-plugin-designer@1.0.11) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.9...@ali/lowcode-plugin-designer@1.0.10) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.8...@ali/lowcode-plugin-designer@1.0.9) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.8-0...@ali/lowcode-plugin-designer@1.0.8) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.55...@ali/lowcode-plugin-designer@1.0.8-0) (2020-09-09) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) - - -### Features - -* 新增simulatorurl,可以设置cdn使用simulator ([1f45b05](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/1f45b05)) - - - - - -## [0.9.55](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.54...@ali/lowcode-plugin-designer@0.9.55) (2020-09-08) - -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.6-0...@ali/lowcode-plugin-designer@1.0.7-0) (2020-09-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.54](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.53...@ali/lowcode-plugin-designer@0.9.54) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.53](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.52...@ali/lowcode-plugin-designer@0.9.53) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.52...@ali/lowcode-plugin-designer@1.0.6-0) (2020-09-02) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) - - -### Features - -* 新增simulatorurl,可以设置cdn使用simulator ([1f45b05](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/1f45b05)) - - - - - -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.4-0...@ali/lowcode-plugin-designer@1.0.5-0) (2020-08-20) - - -## [0.9.52](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.51...@ali/lowcode-plugin-designer@0.9.52) (2020-08-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.51](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.50...@ali/lowcode-plugin-designer@0.9.51) (2020-08-26) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.50](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.49...@ali/lowcode-plugin-designer@0.9.50) (2020-08-24) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.49](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.48...@ali/lowcode-plugin-designer@0.9.49) (2020-08-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.48](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.47...@ali/lowcode-plugin-designer@0.9.48) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.3-0...@ali/lowcode-plugin-designer@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.2-0...@ali/lowcode-plugin-designer@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@1.0.1-0...@ali/lowcode-plugin-designer@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.47...@ali/lowcode-plugin-designer@1.0.1-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.14.0...@ali/lowcode-plugin-designer@1.0.0) (2020-08-17) - -## [0.9.47](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.46...@ali/lowcode-plugin-designer@0.9.47) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.46](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.45...@ali/lowcode-plugin-designer@0.9.46) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.45](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.44...@ali/lowcode-plugin-designer@0.9.45) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.44](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.43...@ali/lowcode-plugin-designer@0.9.44) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.43](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.42...@ali/lowcode-plugin-designer@0.9.43) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -# [0.14.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.13.0...@ali/lowcode-plugin-designer@0.14.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.11.0...@ali/lowcode-plugin-designer@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.11.0...@ali/lowcode-plugin-designer@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.10.0...@ali/lowcode-plugin-designer@0.11.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.37...@ali/lowcode-plugin-designer@0.10.0) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.37](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.36...@ali/lowcode-plugin-designer@0.9.37) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.36](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.34...@ali/lowcode-plugin-designer@0.9.36) (2020-08-04) - - -### Bug Fixes - -* plugin-desiger 支持从 editor 获取 device 参数 ([43bc29b](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/43bc29b)) - - - - - -## [0.9.35](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.34...@ali/lowcode-plugin-designer@0.9.35) (2020-08-04) - - -### Bug Fixes - -* plugin-desiger 支持从 editor 获取 device 参数 ([43bc29b](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/43bc29b)) - - - - - -## [0.9.34](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.33...@ali/lowcode-plugin-designer@0.9.34) (2020-07-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.33](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.32...@ali/lowcode-plugin-designer@0.9.33) (2020-07-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.32](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.31...@ali/lowcode-plugin-designer@0.9.32) (2020-07-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.31](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.30...@ali/lowcode-plugin-designer@0.9.31) (2020-07-22) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.30](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.29...@ali/lowcode-plugin-designer@0.9.30) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.29](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.28...@ali/lowcode-plugin-designer@0.9.29) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.28](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.27...@ali/lowcode-plugin-designer@0.9.28) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.27](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.26...@ali/lowcode-plugin-designer@0.9.27) (2020-07-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.26](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.25...@ali/lowcode-plugin-designer@0.9.26) (2020-07-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.25](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.24...@ali/lowcode-plugin-designer@0.9.25) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.24](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.23...@ali/lowcode-plugin-designer@0.9.24) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.21...@ali/lowcode-plugin-designer@0.9.23) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.20...@ali/lowcode-plugin-designer@0.9.21) (2020-06-23) - - -### Bug Fixes - -* add extraEnv ([9058ac8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/9058ac8)) - - - - - -## [0.9.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.19...@ali/lowcode-plugin-designer@0.9.20) (2020-06-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.18...@ali/lowcode-plugin-designer@0.9.19) (2020-06-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.17...@ali/lowcode-plugin-designer@0.9.18) (2020-05-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.16...@ali/lowcode-plugin-designer@0.9.17) (2020-05-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.15...@ali/lowcode-plugin-designer@0.9.16) (2020-05-18) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.14...@ali/lowcode-plugin-designer@0.9.15) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.13...@ali/lowcode-plugin-designer@0.9.14) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.12...@ali/lowcode-plugin-designer@0.9.13) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.11...@ali/lowcode-plugin-designer@0.9.12) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.10...@ali/lowcode-plugin-designer@0.9.11) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.9...@ali/lowcode-plugin-designer@0.9.10) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.8...@ali/lowcode-plugin-designer@0.9.9) (2020-05-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.7...@ali/lowcode-plugin-designer@0.9.8) (2020-05-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.6...@ali/lowcode-plugin-designer@0.9.7) (2020-05-07) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.5...@ali/lowcode-plugin-designer@0.9.6) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.5](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.4...@ali/lowcode-plugin-designer@0.9.5) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.3...@ali/lowcode-plugin-designer@0.9.4) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.2...@ali/lowcode-plugin-designer@0.9.3) (2020-04-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.9.2](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.1...@ali/lowcode-plugin-designer@0.9.2) (2020-04-15) - - -### Bug Fixes - -* plugin-designer ([2dfbcd4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/2dfbcd4)) - - - - - -## [0.9.1](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.9.0...@ali/lowcode-plugin-designer@0.9.1) (2020-03-31) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.8.4...@ali/lowcode-plugin-designer@0.9.0) (2020-03-30) - - -### Features - -* **designer:** add blank page logic ([aeeb9ba](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/aeeb9ba)) - - - - - -## [0.8.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.8.3...@ali/lowcode-plugin-designer@0.8.4) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## [0.8.3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-designer@0.8.2...@ali/lowcode-plugin-designer@0.8.3) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## 0.8.2 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer - - -## 0.8.1 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-designer diff --git a/packages/plugin-designer/README.md b/packages/plugin-designer/README.md deleted file mode 100644 index 8a6fb13f0..000000000 --- a/packages/plugin-designer/README.md +++ /dev/null @@ -1 +0,0 @@ -## todo diff --git a/packages/plugin-designer/build.json b/packages/plugin-designer/build.json deleted file mode 100644 index bd5cf18dd..000000000 --- a/packages/plugin-designer/build.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "plugins": [ - "build-plugin-component" - ] -} diff --git a/packages/plugin-designer/package.json b/packages/plugin-designer/package.json deleted file mode 100644 index 6f31209ba..000000000 --- a/packages/plugin-designer/package.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "name": "@ali/lowcode-plugin-designer", - "version": "1.0.22", - "description": "alibaba lowcode editor designer plugin", - "files": [ - "es", - "lib" - ], - "main": "lib/index.js", - "module": "es/index.js", - "stylePath": "style.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "keywords": [ - "lowcode", - "editor" - ], - "author": "xiayang.xy", - "dependencies": { - "@ali/lowcode-designer": "^1.0.22", - "@ali/lowcode-editor-core": "^1.0.22", - "react": "^16.8.1", - "react-dom": "^16.8.1" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.3", - "@types/react": "^16.9.13", - "@types/react-dom": "^16.9.4", - "build-plugin-component": "^0.2.7-1" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/plugin-designer/src/index.scss b/packages/plugin-designer/src/index.scss deleted file mode 100644 index 395bb8961..000000000 --- a/packages/plugin-designer/src/index.scss +++ /dev/null @@ -1,4 +0,0 @@ -.lowcode-plugin-designer { - width: 100%; - height: 100%; -} diff --git a/packages/plugin-designer/src/index.tsx b/packages/plugin-designer/src/index.tsx deleted file mode 100644 index bcbb3ee58..000000000 --- a/packages/plugin-designer/src/index.tsx +++ /dev/null @@ -1,109 +0,0 @@ -import React, { PureComponent } from 'react'; -import { Editor } from '@ali/lowcode-editor-core'; -import { DesignerView, Designer } from '@ali/lowcode-designer'; -import { Asset } from '@ali/lowcode-utils'; -import './index.scss'; - -export interface PluginProps { - editor: Editor; -} - -interface DesignerPluginState { - componentMetadatas?: any[] | null; - library?: any[] | null; - extraEnvironment?: any[] | null; - renderEnv?: string; - device?: string; - simulatorUrl: Asset | null; - // @TODO 类型定义 - requestHandlersMap: any; -} - -export default class DesignerPlugin extends PureComponent { - static displayName: 'LowcodePluginDesigner'; - - state: DesignerPluginState = { - componentMetadatas: null, - library: null, - extraEnvironment: null, - renderEnv: 'default', - device: 'default', - simulatorUrl: null, - requestHandlersMap: null, - }; - - private _mounted = true; - - constructor(props: any) { - super(props); - this.setupAssets(); - } - - private async setupAssets() { - const { editor } = this.props; - try { - const assets = await editor.onceGot('assets'); - const renderEnv = await editor.get('renderEnv'); - const device = await editor.get('device'); - const simulatorUrl = await editor.get('simulatorUrl'); - // @TODO setupAssets 里设置 requestHandlersMap 不太合适 - const requestHandlersMap = await editor.get('requestHandlersMap'); - if (!this._mounted) { - return; - } - const { components, packages, extraEnvironment } = assets; - const state = { - componentMetadatas: components || [], - library: packages || [], - extraEnvironment, - renderEnv, - device, - simulatorUrl, - requestHandlersMap, - }; - this.setState(state); - } catch (e) { - console.log(e); - } - } - - componentWillUnmount() { - this._mounted = false; - } - - private handleDesignerMount = (designer: Designer): void => { - const { editor } = this.props; - editor.set(Designer, designer); - editor.emit('designer.ready', designer); - editor.onGot('schema', (schema) => { - designer.project.open(schema); - }); - }; - - render(): React.ReactNode { - const { editor } = this.props; - const { componentMetadatas, library, extraEnvironment, renderEnv, device, simulatorUrl, requestHandlersMap } = this.state; - if (!library || !componentMetadatas) { - // TODO: use a Loading - return null; - } - - return ( - - ); - } -} diff --git a/packages/plugin-designer/tsconfig.json b/packages/plugin-designer/tsconfig.json deleted file mode 100644 index c37b76ecc..000000000 --- a/packages/plugin-designer/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -} diff --git a/packages/plugin-event-bind-dialog/CHANGELOG.md b/packages/plugin-event-bind-dialog/CHANGELOG.md deleted file mode 100644 index c491ab12f..000000000 --- a/packages/plugin-event-bind-dialog/CHANGELOG.md +++ /dev/null @@ -1,485 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - - -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.20...@ali/lowcode-plugin-event-bind-dialog@1.0.21) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.19...@ali/lowcode-plugin-event-bind-dialog@1.0.20) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.18...@ali/lowcode-plugin-event-bind-dialog@1.0.19) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.17...@ali/lowcode-plugin-event-bind-dialog@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.16...@ali/lowcode-plugin-event-bind-dialog@1.0.17) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.15...@ali/lowcode-plugin-event-bind-dialog@1.0.16) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.14...@ali/lowcode-plugin-event-bind-dialog@1.0.15) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.13...@ali/lowcode-plugin-event-bind-dialog@1.0.14) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.12...@ali/lowcode-plugin-event-bind-dialog@1.0.13) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.11...@ali/lowcode-plugin-event-bind-dialog@1.0.12) (2020-10-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.10...@ali/lowcode-plugin-event-bind-dialog@1.0.11) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.9...@ali/lowcode-plugin-event-bind-dialog@1.0.10) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.8...@ali/lowcode-plugin-event-bind-dialog@1.0.9) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.8-0...@ali/lowcode-plugin-event-bind-dialog@1.0.8) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.34...@ali/lowcode-plugin-event-bind-dialog@1.0.8-0) (2020-09-09) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) -* fix function-setter bug ([dced647](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/dced647)) - - -### Features - -* 新增事件入参功能 ([0614fa7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/0614fa7)) -* 新增functionSetter ([9359ac6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/9359ac6)) - - - - - -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.6-0...@ali/lowcode-plugin-event-bind-dialog@1.0.7-0) (2020-09-02) - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.32...@ali/lowcode-plugin-event-bind-dialog@1.0.6-0) (2020-09-02) - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.34](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.33...@ali/lowcode-plugin-event-bind-dialog@0.8.34) (2020-09-03) - - -## [0.8.33](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.32...@ali/lowcode-plugin-event-bind-dialog@0.8.33) (2020-09-03) - - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) -* fix function-setter bug ([dced647](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/dced647)) - - -### Features - -* 新增事件入参功能 ([0614fa7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/0614fa7)) -* 新增functionSetter ([9359ac6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/9359ac6)) - - - - - -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.4-0...@ali/lowcode-plugin-event-bind-dialog@1.0.5-0) (2020-08-20) - -## [0.8.32](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.31...@ali/lowcode-plugin-event-bind-dialog@0.8.32) (2020-08-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.31](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.30...@ali/lowcode-plugin-event-bind-dialog@0.8.31) (2020-08-24) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.30](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.29...@ali/lowcode-plugin-event-bind-dialog@0.8.30) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.3-0...@ali/lowcode-plugin-event-bind-dialog@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.2-0...@ali/lowcode-plugin-event-bind-dialog@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@1.0.1-0...@ali/lowcode-plugin-event-bind-dialog@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.29...@ali/lowcode-plugin-event-bind-dialog@1.0.1-0) (2020-08-20) - - -### Features - -* 新增functionSetter ([9359ac6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/9359ac6)) - - - - - -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.13.0...@ali/lowcode-plugin-event-bind-dialog@1.0.0) (2020-08-17) - -## [0.8.29](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.28...@ali/lowcode-plugin-event-bind-dialog@0.8.29) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.12.0...@ali/lowcode-plugin-event-bind-dialog@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.10.0...@ali/lowcode-plugin-event-bind-dialog@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.10.0...@ali/lowcode-plugin-event-bind-dialog@0.11.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.9.0...@ali/lowcode-plugin-event-bind-dialog@0.10.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.27...@ali/lowcode-plugin-event-bind-dialog@0.9.0) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.27](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.26...@ali/lowcode-plugin-event-bind-dialog@0.8.27) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.26](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.24...@ali/lowcode-plugin-event-bind-dialog@0.8.26) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.25](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.24...@ali/lowcode-plugin-event-bind-dialog@0.8.25) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.24](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.23...@ali/lowcode-plugin-event-bind-dialog@0.8.24) (2020-07-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.22...@ali/lowcode-plugin-event-bind-dialog@0.8.23) (2020-07-22) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.21...@ali/lowcode-plugin-event-bind-dialog@0.8.22) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.20...@ali/lowcode-plugin-event-bind-dialog@0.8.21) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.19...@ali/lowcode-plugin-event-bind-dialog@0.8.20) (2020-07-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.18...@ali/lowcode-plugin-event-bind-dialog@0.8.19) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.17...@ali/lowcode-plugin-event-bind-dialog@0.8.18) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.16...@ali/lowcode-plugin-event-bind-dialog@0.8.17) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.15...@ali/lowcode-plugin-event-bind-dialog@0.8.16) (2020-06-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.14...@ali/lowcode-plugin-event-bind-dialog@0.8.15) (2020-05-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.13...@ali/lowcode-plugin-event-bind-dialog@0.8.14) (2020-05-18) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.12...@ali/lowcode-plugin-event-bind-dialog@0.8.13) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.11...@ali/lowcode-plugin-event-bind-dialog@0.8.12) (2020-05-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.10...@ali/lowcode-plugin-event-bind-dialog@0.8.11) (2020-05-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.9...@ali/lowcode-plugin-event-bind-dialog@0.8.10) (2020-05-07) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.8...@ali/lowcode-plugin-event-bind-dialog@0.8.9) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.7...@ali/lowcode-plugin-event-bind-dialog@0.8.8) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.6...@ali/lowcode-plugin-event-bind-dialog@0.8.7) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.5...@ali/lowcode-plugin-event-bind-dialog@0.8.6) (2020-04-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.5](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.4...@ali/lowcode-plugin-event-bind-dialog@0.8.5) (2020-04-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## [0.8.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-event-bind-dialog@0.8.3...@ali/lowcode-plugin-event-bind-dialog@0.8.4) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## 0.8.3 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog - - -## 0.8.2 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-event-bind-dialog diff --git a/packages/plugin-event-bind-dialog/README.md b/packages/plugin-event-bind-dialog/README.md deleted file mode 100644 index 8a6fb13f0..000000000 --- a/packages/plugin-event-bind-dialog/README.md +++ /dev/null @@ -1 +0,0 @@ -## todo diff --git a/packages/plugin-event-bind-dialog/build.json b/packages/plugin-event-bind-dialog/build.json deleted file mode 100644 index e791d5b6b..000000000 --- a/packages/plugin-event-bind-dialog/build.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "plugins": [ - "build-plugin-component", - "build-plugin-fusion", - ["build-plugin-moment-locales", { - "locales": ["zh-cn"] - }] - ] -} diff --git a/packages/plugin-event-bind-dialog/package.json b/packages/plugin-event-bind-dialog/package.json deleted file mode 100644 index 01bbbf9fb..000000000 --- a/packages/plugin-event-bind-dialog/package.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "name": "@ali/lowcode-plugin-event-bind-dialog", - "version": "1.0.21", - "description": "alibaba lowcode editor event bind dialog plugin", - "files": [ - "es", - "lib" - ], - "main": "lib/index.js", - "module": "es/index.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "keywords": [ - "lowcode", - "editor" - ], - "author": "zude.hzd", - "dependencies": { - "@ali/lowcode-editor-core": "^1.0.22", - "@ali/lowcode-types": "^1.0.20", - "@alifd/next": "^1.19.16", - "react": "^16.8.1", - "react-dom": "^16.8.1" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.3", - "@types/react": "^16.9.13", - "@types/react-dom": "^16.9.4", - "build-plugin-component": "^0.2.7-1", - "build-plugin-fusion": "^0.1.0", - "build-plugin-moment-locales": "^0.1.0" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/plugin-event-bind-dialog/src/index.scss b/packages/plugin-event-bind-dialog/src/index.scss deleted file mode 100644 index d84fdb51d..000000000 --- a/packages/plugin-event-bind-dialog/src/index.scss +++ /dev/null @@ -1,75 +0,0 @@ -.event-dialog-body { - width: 800px; - height: 450px; - - - .dialog-small-title { - font-weight: 700; - margin-bottom: 8px; - color: rgb(0, 0, 0); - } - - .editor-container{ - border: 1px solid rgba(31, 56, 88, 0.3); - } - - .dialog-left-container { - float: left; - - .dialog-left-context { - width: 268px; - height: 392px; - border: 1px solid rgba(31, 56, 88, 0.3); - border-radius: 3px; - - .event-type-container { - width: 110px; - height: 390px; - border-right: 1px solid rgba(31, 56, 88, 0.3); - float: left; - } - - .select-item { - font-size: 12px; - height: 28px; - line-height: 28px; - padding: 0 30px 0 12px; - cursor: pointer; - position: relative; - overflow: hidden; - text-overflow: ellipsis; - white-space: nowrap; - } - - .select-item-active { - background: rgba(31, 56, 88, 0.06); - } - - .event-select-container { - width: 156px; - float: left; - - .event-search-box { - width: 135px; - margin: 10px; - } - } - - .event-list { - overflow-y: auto; - overflow-x: hidden; - height: 342px; - } - } - } - - .dialog-right-container { - width: 530px; - padding-left: 20px; - float: left; - - .event-input-container { - margin-bottom: 20px; - } - } -} diff --git a/packages/plugin-event-bind-dialog/src/index.tsx b/packages/plugin-event-bind-dialog/src/index.tsx deleted file mode 100644 index 7af71729a..000000000 --- a/packages/plugin-event-bind-dialog/src/index.tsx +++ /dev/null @@ -1,238 +0,0 @@ -import { Component } from 'react'; -import { Dialog, Search, Input } from '@alifd/next'; -import { PluginProps } from '@ali/lowcode-types'; -import MonacoEditor from 'react-monaco-editor'; -import './index.scss'; - - -const defaultEditorOption = { - width: '100%', - height: '319px', - options: { - readOnly: false, - automaticLayout: true, - folding: true, // 默认开启折叠代码功能 - lineNumbers: 'on', - wordWrap: 'off', - formatOnPaste: true, - fontSize: 12, - tabSize: 2, - scrollBeyondLastLine: false, - fixedOverflowWidgets: false, - snippetSuggestions: 'top', - minimap: { - enabled: false, - }, - scrollbar: { - vertical: 'auto', - horizontal: 'auto', - }, - }, -}; -export default class EventBindDialog extends Component { - private eventList: any[] = [ - // { - // name: 'getData', - // }, - // { - // name: 'deleteData', - // }, - // { - // name: 'initData', - // }, - // { - // name: 'editData', - // }, - // { - // name: 'submitData', - // }, - ]; - - private bindEventName :''; - - state: any = { - visiable: false, - setterName: 'event-setter', - selectedEventName: '', - eventName: '', - paramStr: '', - }; - - openDialog = (bindEventName: string, isEdit:boolean) => { - this.bindEventName = bindEventName; - - this.initEventName(isEdit); - - }; - - closeDialog = () => { - this.setState({ - visiable: false, - }); - }; - - componentDidMount() { - const { editor, config } = this.props; - editor.on(`${config.pluginKey}.openDialog`, (bindEventName: string, setterName:string, paramStr:string, isEdit:boolean) => { - console.log(`paramStr:${ paramStr}`); - this.setState({ - setterName, - paramStr, - }); - - const schema = editor.get('designer').project.getSchema(); - const pageNode = schema.componentsTree[0]; - if (pageNode.methods) { - this.eventList = []; - for (const key in pageNode.methods) { - this.eventList.push({ - name: key, - }); - } - } - - this.openDialog(bindEventName, isEdit); - }); - } - - initEventName = (isEdit:boolean) => { - let eventName = this.bindEventName; - - if (!isEdit) { - this.eventList.forEach((item) => { - if (item.name === eventName) { - eventName = `${eventName}_new`; - } - }); - } - - this.setState({ - eventName, - selectedEventName: (isEdit ? eventName : ''), - visiable: true, - }); - }; - - onInputChange = (eventName: string) => { - this.setState({ - eventName, - }); - }; - - onSelectItem = (eventName: string) => { - this.setState({ - selectedEventName: eventName, - }); - - // 为空是新建事件 - if (eventName === '') { - this.initEventName(); - } else { - this.setState({ - selectedEventName: eventName, - eventName, - }); - } - }; - - onSearchEvent = () => {}; - - onOk = () => { - console.log(this); - const { editor } = this.props; - const { setterName, eventName, paramStr } = this.state; - editor.emit(`${setterName}.bindEvent`, eventName, paramStr); - - // 选中的是新建事件 - if (this.state.selectedEventName == '') { - // 判断面板是否处于激活状态 - // debugger; - editor.get('skeleton').getPanel('sourceEditor').show(); - - setTimeout(() => { - editor.emit('sourceEditor.addFunction', { - functionName: this.state.eventName, - }); - }, 300); - } - - this.closeDialog(); - }; - - onChangeEditor = (paramStr) => { - this.setState({ - paramStr, - }); - // console.log(newCode); - }; - - - render() { - const { selectedEventName, eventName, visiable, paramStr } = this.state; - console.log('selectedEventName:' + selectedEventName); - return ( - this.onOk()} - > -
-
-
事件选择
- -
-
    -
  • 内置函数
  • -
  • 组件事件
  • -
- -
-
- - -
    -
  • this.onSelectItem('')} - > - 新建事件 -
  • - {this.eventList.map((item, index) => ( -
  • this.onSelectItem(item.name)} - > - {item.name} -
  • - ))} -
-
-
-
-
- -
-
事件名称
-
- -
- -
参数设置
-
- this.onChangeEditor(newCode)} - /> -
- -
-
-
- ); - } -} diff --git a/packages/plugin-event-bind-dialog/tsconfig.json b/packages/plugin-event-bind-dialog/tsconfig.json deleted file mode 100644 index c37b76ecc..000000000 --- a/packages/plugin-event-bind-dialog/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -} diff --git a/packages/plugin-outline-pane/.eslintrc.js b/packages/plugin-outline-pane/.eslintrc.js deleted file mode 100644 index a4f723cdf..000000000 --- a/packages/plugin-outline-pane/.eslintrc.js +++ /dev/null @@ -1,7 +0,0 @@ -module.exports = { - extends: '../../.eslintrc.js', - rules: { - 'no-unused-expressions': 1, - 'react/no-multi-comp': 1, - } -} \ No newline at end of file diff --git a/packages/plugin-outline-pane/CHANGELOG.md b/packages/plugin-outline-pane/CHANGELOG.md deleted file mode 100644 index e87015e18..000000000 --- a/packages/plugin-outline-pane/CHANGELOG.md +++ /dev/null @@ -1,665 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - - -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.20...@ali/lowcode-plugin-outline-pane@1.0.21) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.19...@ali/lowcode-plugin-outline-pane@1.0.20) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.18...@ali/lowcode-plugin-outline-pane@1.0.19) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.17...@ali/lowcode-plugin-outline-pane@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.16...@ali/lowcode-plugin-outline-pane@1.0.17) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.15...@ali/lowcode-plugin-outline-pane@1.0.16) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.14...@ali/lowcode-plugin-outline-pane@1.0.15) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.13...@ali/lowcode-plugin-outline-pane@1.0.14) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.12...@ali/lowcode-plugin-outline-pane@1.0.13) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.11...@ali/lowcode-plugin-outline-pane@1.0.12) (2020-10-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.10...@ali/lowcode-plugin-outline-pane@1.0.11) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.9...@ali/lowcode-plugin-outline-pane@1.0.10) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.8...@ali/lowcode-plugin-outline-pane@1.0.9) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.8-0...@ali/lowcode-plugin-outline-pane@1.0.8) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.61...@ali/lowcode-plugin-outline-pane@1.0.8-0) (2020-09-09) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) -* 兼容modal模式 ([1092ee9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/1092ee9)) - - - - - -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.6-0...@ali/lowcode-plugin-outline-pane@1.0.7-0) (2020-09-02) - - - -## [0.8.61](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.60...@ali/lowcode-plugin-outline-pane@0.8.61) (2020-09-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.60](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.59...@ali/lowcode-plugin-outline-pane@0.8.60) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.59](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.58...@ali/lowcode-plugin-outline-pane@0.8.59) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.58](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.57...@ali/lowcode-plugin-outline-pane@0.8.58) (2020-08-27) - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.58...@ali/lowcode-plugin-outline-pane@1.0.6-0) (2020-09-02) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) -* 兼容modal模式 ([1092ee9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/1092ee9)) - - - - - -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.4-0...@ali/lowcode-plugin-outline-pane@1.0.5-0) (2020-08-20) - -## [0.8.54](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.53...@ali/lowcode-plugin-outline-pane@0.8.54) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.3-0...@ali/lowcode-plugin-outline-pane@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.2-0...@ali/lowcode-plugin-outline-pane@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@1.0.1-0...@ali/lowcode-plugin-outline-pane@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.53...@ali/lowcode-plugin-outline-pane@1.0.1-0) (2020-08-20) - - -### Bug Fixes - -* 兼容modal模式 ([1092ee9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/1092ee9)) - - - - - -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.13.0...@ali/lowcode-plugin-outline-pane@1.0.0) (2020-08-17) - -## [0.8.53](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.52...@ali/lowcode-plugin-outline-pane@0.8.53) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.52](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.51...@ali/lowcode-plugin-outline-pane@0.8.52) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.51](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.50...@ali/lowcode-plugin-outline-pane@0.8.51) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.50](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.49...@ali/lowcode-plugin-outline-pane@0.8.50) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.49](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.48...@ali/lowcode-plugin-outline-pane@0.8.49) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.12.0...@ali/lowcode-plugin-outline-pane@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.10.0...@ali/lowcode-plugin-outline-pane@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.10.0...@ali/lowcode-plugin-outline-pane@0.11.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.9.0...@ali/lowcode-plugin-outline-pane@0.10.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.43...@ali/lowcode-plugin-outline-pane@0.9.0) (2020-08-14) - - -### Bug Fixes - -* 兼容modal模式 ([1092ee9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/1092ee9)) - - - - - -## [0.8.43](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.42...@ali/lowcode-plugin-outline-pane@0.8.43) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.42](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.40...@ali/lowcode-plugin-outline-pane@0.8.42) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.41](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.40...@ali/lowcode-plugin-outline-pane@0.8.41) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.40](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.39...@ali/lowcode-plugin-outline-pane@0.8.40) (2020-07-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.39](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.38...@ali/lowcode-plugin-outline-pane@0.8.39) (2020-07-28) - - -### Bug Fixes - -* 🐛 getPrototype is undefined ([95b3409](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/95b3409)) - - - - - -## [0.8.38](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.37...@ali/lowcode-plugin-outline-pane@0.8.38) (2020-07-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.37](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.36...@ali/lowcode-plugin-outline-pane@0.8.37) (2020-07-22) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.36](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.35...@ali/lowcode-plugin-outline-pane@0.8.36) (2020-07-21) - - -### Bug Fixes - -* 修复导入的组件拖入画布报错 ([caf9915](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/caf9915)) - - - - - -## [0.8.35](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.34...@ali/lowcode-plugin-outline-pane@0.8.35) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.34](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.33...@ali/lowcode-plugin-outline-pane@0.8.34) (2020-07-21) - - -### Bug Fixes - -* modal node locate ([9a72dd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/9a72dd7)) -* 大纲树节点显示隐藏埋点 ([e91ab1f](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/e91ab1f)) -* 没有 modal node 时不显示模态视图 ([555824c](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/555824c)) - - -### Features - -* 大纲树展开折叠埋点 ([d9828f2](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/d9828f2)) -* 大纲树支持模态视图 ([3785e1c](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/3785e1c)) - - - - - -## [0.8.33](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.32...@ali/lowcode-plugin-outline-pane@0.8.33) (2020-07-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.32](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.31...@ali/lowcode-plugin-outline-pane@0.8.32) (2020-07-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.31](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.30...@ali/lowcode-plugin-outline-pane@0.8.31) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.30](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.29...@ali/lowcode-plugin-outline-pane@0.8.30) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.29](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.27...@ali/lowcode-plugin-outline-pane@0.8.29) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.27](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.26...@ali/lowcode-plugin-outline-pane@0.8.27) (2020-06-23) - - -### Features - -* 大纲树埋点 ([fa24821](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/fa24821)) - - - - - -## [0.8.26](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.25...@ali/lowcode-plugin-outline-pane@0.8.26) (2020-06-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.25](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.24...@ali/lowcode-plugin-outline-pane@0.8.25) (2020-06-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.24](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.23...@ali/lowcode-plugin-outline-pane@0.8.24) (2020-05-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.22...@ali/lowcode-plugin-outline-pane@0.8.23) (2020-05-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.21...@ali/lowcode-plugin-outline-pane@0.8.22) (2020-05-18) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.20...@ali/lowcode-plugin-outline-pane@0.8.21) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.19...@ali/lowcode-plugin-outline-pane@0.8.20) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.18...@ali/lowcode-plugin-outline-pane@0.8.19) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.17...@ali/lowcode-plugin-outline-pane@0.8.18) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.16...@ali/lowcode-plugin-outline-pane@0.8.17) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.15...@ali/lowcode-plugin-outline-pane@0.8.16) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.14...@ali/lowcode-plugin-outline-pane@0.8.15) (2020-05-13) - - -### Features - -* show value state ([bd49e50](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd49e50)) -* support plaintext liveediting ([ea62f12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/ea62f12)) - - - - - -## [0.8.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.13...@ali/lowcode-plugin-outline-pane@0.8.14) (2020-05-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.12...@ali/lowcode-plugin-outline-pane@0.8.13) (2020-05-07) - - -### Bug Fixes - -* intl ([8a061ab](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/8a061ab)) - - - - - -## [0.8.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.11...@ali/lowcode-plugin-outline-pane@0.8.12) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.10...@ali/lowcode-plugin-outline-pane@0.8.11) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.9...@ali/lowcode-plugin-outline-pane@0.8.10) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.8...@ali/lowcode-plugin-outline-pane@0.8.9) (2020-04-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.7...@ali/lowcode-plugin-outline-pane@0.8.8) (2020-04-15) - - -### Bug Fixes - -* plugin-designer ([2dfbcd4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/2dfbcd4)) - - - - - -## [0.8.7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.6...@ali/lowcode-plugin-outline-pane@0.8.7) (2020-03-31) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.5...@ali/lowcode-plugin-outline-pane@0.8.6) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.5](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.4...@ali/lowcode-plugin-outline-pane@0.8.5) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## [0.8.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-outline-pane@0.8.3...@ali/lowcode-plugin-outline-pane@0.8.4) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-outline-pane - - -## 0.8.3 (2020-03-30) - - -### Features - -* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7)) - - - - - -## 0.8.2 (2020-03-30) - - -### Features - -* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7)) diff --git a/packages/plugin-outline-pane/README.md b/packages/plugin-outline-pane/README.md deleted file mode 100644 index 6c8d94003..000000000 --- a/packages/plugin-outline-pane/README.md +++ /dev/null @@ -1 +0,0 @@ -大纲面板 diff --git a/packages/plugin-outline-pane/build.json b/packages/plugin-outline-pane/build.json deleted file mode 100644 index e791d5b6b..000000000 --- a/packages/plugin-outline-pane/build.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "plugins": [ - "build-plugin-component", - "build-plugin-fusion", - ["build-plugin-moment-locales", { - "locales": ["zh-cn"] - }] - ] -} diff --git a/packages/plugin-outline-pane/package.json b/packages/plugin-outline-pane/package.json deleted file mode 100644 index e9f441738..000000000 --- a/packages/plugin-outline-pane/package.json +++ /dev/null @@ -1,50 +0,0 @@ -{ - "name": "@ali/lowcode-plugin-outline-pane", - "version": "1.0.21", - "description": "Outline pane for Ali lowCode engine", - "files": [ - "es", - "lib" - ], - "main": "lib/index.js", - "module": "es/index.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "dependencies": { - "@ali/lowcode-designer": "^1.0.22", - "@ali/lowcode-editor-core": "^1.0.22", - "@ali/lowcode-types": "^1.0.20", - "@ali/lowcode-utils": "^1.0.21", - "@alifd/next": "^1.19.16", - "classnames": "^2.2.6", - "react": "^16", - "react-dom": "^16.7.0" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.18", - "@types/classnames": "^2.2.7", - "@types/node": "^13.7.1", - "@types/react": "^16", - "@types/react-dom": "^16", - "build-plugin-component": "^0.2.10", - "build-plugin-fusion": "^0.1.1", - "build-plugin-moment-locales": "^0.1.0" - }, - "ava": { - "compileEnhancements": false, - "snapshotDir": "test/fixtures/__snapshots__", - "extensions": [ - "ts" - ], - "require": [ - "ts-node/register" - ] - }, - "license": "MIT", - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/plugin-outline-pane/src/README.md b/packages/plugin-outline-pane/src/README.md deleted file mode 100644 index 0171bb10e..000000000 --- a/packages/plugin-outline-pane/src/README.md +++ /dev/null @@ -1 +0,0 @@ -大纲树 diff --git a/packages/plugin-outline-pane/src/helper/dwell-timer.ts b/packages/plugin-outline-pane/src/helper/dwell-timer.ts deleted file mode 100644 index 601ff6403..000000000 --- a/packages/plugin-outline-pane/src/helper/dwell-timer.ts +++ /dev/null @@ -1,55 +0,0 @@ -import { ParentalNode, DropLocation, isLocationChildrenDetail, LocateEvent } from '@ali/lowcode-designer'; - -/** - * 停留检查计时器 - */ -export default class DwellTimer { - private timer: number | undefined; - - private previous?: ParentalNode; - - private event?: LocateEvent; - - private decide: (node: ParentalNode, event: LocateEvent) => void; - - private timeout = 500; - - constructor(decide: (node: ParentalNode, event: LocateEvent) => void, timeout = 500) { - this.decide = decide; - this.timeout = timeout; - } - - focus(node: ParentalNode, event: LocateEvent) { - this.event = event; - if (this.previous === node) { - return; - } - this.reset(); - this.previous = node; - this.timer = setTimeout(() => { - this.previous && this.decide(this.previous, this.event!); - this.reset(); - }, this.timeout) as any; - } - - tryFocus(loc?: DropLocation | null) { - if (!loc || !isLocationChildrenDetail(loc.detail)) { - this.reset(); - return; - } - if (loc.detail.focus?.type === 'node') { - this.focus(loc.detail.focus.node, loc.event); - } else { - this.reset(); - } - } - - reset() { - if (this.timer) { - clearTimeout(this.timer); - this.timer = undefined; - } - - this.previous = undefined; - } -} diff --git a/packages/plugin-outline-pane/src/helper/indent-track.ts b/packages/plugin-outline-pane/src/helper/indent-track.ts deleted file mode 100644 index 659bd272a..000000000 --- a/packages/plugin-outline-pane/src/helper/indent-track.ts +++ /dev/null @@ -1,54 +0,0 @@ -import { DropLocation, ParentalNode, isLocationChildrenDetail } from '@ali/lowcode-designer'; - -const IndentSensitive = 15; -export class IndentTrack { - private indentStart: number | null = null; - - reset() { - this.indentStart = null; - } - - getIndentParent(lastLoc: DropLocation, loc: DropLocation): [ParentalNode, number] | null { - if ( - lastLoc.target !== loc.target || - !isLocationChildrenDetail(lastLoc.detail) || - !isLocationChildrenDetail(loc.detail) || - lastLoc.source !== loc.source || - lastLoc.detail.index !== loc.detail.index || - loc.detail.index == null - ) { - this.indentStart = null; - return null; - } - if (this.indentStart == null) { - this.indentStart = lastLoc.event.globalX; - } - const delta = loc.event.globalX - this.indentStart; - const indent = Math.floor(Math.abs(delta) / IndentSensitive); - if (indent < 1) { - return null; - } - this.indentStart = loc.event.globalX; - const direction = delta < 0 ? 'left' : 'right'; - - let parent = loc.target; - const { index } = loc.detail; - - if (direction === 'left') { - if (!parent.parent || index < parent.children.size || parent.isSlot()) { - return null; - } - return [(parent as any).parent, parent.index + 1]; - } else { - if (index === 0) { - return null; - } - parent = parent.children.get(index - 1) as any; - if (parent && parent.isContainer()) { - return [parent, parent.children.size]; - } - } - - return null; - } -} diff --git a/packages/plugin-outline-pane/src/icons/arrow-right.tsx b/packages/plugin-outline-pane/src/icons/arrow-right.tsx deleted file mode 100644 index 866b34cec..000000000 --- a/packages/plugin-outline-pane/src/icons/arrow-right.tsx +++ /dev/null @@ -1,11 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconArrowRight(props: IconProps) { - return ( - - - - ); -} - -IconArrowRight.displayName = 'IconArrowRight'; diff --git a/packages/plugin-outline-pane/src/icons/cond.tsx b/packages/plugin-outline-pane/src/icons/cond.tsx deleted file mode 100644 index 915efebec..000000000 --- a/packages/plugin-outline-pane/src/icons/cond.tsx +++ /dev/null @@ -1,11 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconCond(props: IconProps) { - return ( - - - - ); -} - -IconCond.displayName = 'IconCond'; diff --git a/packages/plugin-outline-pane/src/icons/eye-close.tsx b/packages/plugin-outline-pane/src/icons/eye-close.tsx deleted file mode 100644 index 4502d1f93..000000000 --- a/packages/plugin-outline-pane/src/icons/eye-close.tsx +++ /dev/null @@ -1,12 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconEyeClose(props: IconProps) { - return ( - - - - - ); -} - -IconEyeClose.displayName = 'IconEyeClose'; diff --git a/packages/plugin-outline-pane/src/icons/eye.tsx b/packages/plugin-outline-pane/src/icons/eye.tsx deleted file mode 100644 index 5490e11a5..000000000 --- a/packages/plugin-outline-pane/src/icons/eye.tsx +++ /dev/null @@ -1,12 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconEye(props: IconProps) { - return ( - - - - - ); -} - -IconEye.displayName = 'IconEye'; diff --git a/packages/plugin-outline-pane/src/icons/lock.tsx b/packages/plugin-outline-pane/src/icons/lock.tsx deleted file mode 100644 index 7a12db4a7..000000000 --- a/packages/plugin-outline-pane/src/icons/lock.tsx +++ /dev/null @@ -1,11 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconLock(props: IconProps) { - return ( - - - - ); -} - -IconLock.displayName = 'IconLock'; diff --git a/packages/plugin-outline-pane/src/icons/loop.tsx b/packages/plugin-outline-pane/src/icons/loop.tsx deleted file mode 100644 index ba86e1c86..000000000 --- a/packages/plugin-outline-pane/src/icons/loop.tsx +++ /dev/null @@ -1,11 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconLoop(props: IconProps) { - return ( - - - - ); -} - -IconLoop.displayName = 'IconLoop'; diff --git a/packages/plugin-outline-pane/src/icons/outline.tsx b/packages/plugin-outline-pane/src/icons/outline.tsx deleted file mode 100644 index 6e5a0e517..000000000 --- a/packages/plugin-outline-pane/src/icons/outline.tsx +++ /dev/null @@ -1,12 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconOutline(props: IconProps) { - return ( - - - - ); -} - -IconOutline.displayName = 'IconOutline'; - diff --git a/packages/plugin-outline-pane/src/icons/radio-active.tsx b/packages/plugin-outline-pane/src/icons/radio-active.tsx deleted file mode 100644 index 15fe2ffea..000000000 --- a/packages/plugin-outline-pane/src/icons/radio-active.tsx +++ /dev/null @@ -1,12 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconRadioActive(props: IconProps) { - return ( - - - - ); -} - -IconRadioActive.displayName = 'IconRadioActive'; - diff --git a/packages/plugin-outline-pane/src/icons/radio.tsx b/packages/plugin-outline-pane/src/icons/radio.tsx deleted file mode 100644 index f724a94c5..000000000 --- a/packages/plugin-outline-pane/src/icons/radio.tsx +++ /dev/null @@ -1,12 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconRadio(props: IconProps) { - return ( - - - - ); -} - -IconRadio.displayName = 'IconRadio'; - diff --git a/packages/plugin-outline-pane/src/icons/unlock.tsx b/packages/plugin-outline-pane/src/icons/unlock.tsx deleted file mode 100644 index 5695db95d..000000000 --- a/packages/plugin-outline-pane/src/icons/unlock.tsx +++ /dev/null @@ -1,12 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconUnlock(props: IconProps) { - return ( - - - - - ); -} - -IconUnlock.displayName = 'IconUnlock'; diff --git a/packages/plugin-outline-pane/src/index.ts b/packages/plugin-outline-pane/src/index.ts deleted file mode 100644 index 32161abb5..000000000 --- a/packages/plugin-outline-pane/src/index.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { OutlinePane } from './views/pane'; -import { OutlineBackupPane } from './views/backup-pane'; -import { IconOutline } from './icons/outline'; -import { intlNode } from './locale'; -import { getTreeMaster } from './tree-master'; - -export default { - name: 'outline-pane', - props: { - icon: IconOutline, - description: intlNode('Outline Tree'), - }, - content: OutlinePane, -}; - -export { OutlinePane, OutlineBackupPane, getTreeMaster }; diff --git a/packages/plugin-outline-pane/src/locale/en-US.json b/packages/plugin-outline-pane/src/locale/en-US.json deleted file mode 100644 index 9d04defc0..000000000 --- a/packages/plugin-outline-pane/src/locale/en-US.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "Initializing": "Initializing", - "Hide": "Hide", - "Show": "Show", - "Lock": "Lock", - "Unlock": "Unlock", - "Expand": "Expand", - "Collapse": "Collapse", - "Conditional": "Condition", - "Loop": "Loop", - "Slots": "Slots", - "Slot for {prop}": "Slot for {prop}", - "Outline Tree": "Outline Tree" -} diff --git a/packages/plugin-outline-pane/src/locale/index.ts b/packages/plugin-outline-pane/src/locale/index.ts deleted file mode 100644 index 26507f0ef..000000000 --- a/packages/plugin-outline-pane/src/locale/index.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { createIntl } from '@ali/lowcode-editor-core'; -import en_US from './en-US.json'; -import zh_CN from './zh-CN.json'; - -const { intl, intlNode, getLocale, setLocale } = createIntl({ - 'en-US': en_US, - 'zh-CN': zh_CN, -}); - -export { intl, intlNode, getLocale, setLocale }; diff --git a/packages/plugin-outline-pane/src/locale/zh-CN.json b/packages/plugin-outline-pane/src/locale/zh-CN.json deleted file mode 100644 index 08138b3b4..000000000 --- a/packages/plugin-outline-pane/src/locale/zh-CN.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "Initializing": "正在初始化", - "Hide": "隐藏", - "Show": "显示", - "Lock": "锁定", - "Unlock": "解锁", - "Expand": "展开", - "Collapse": "收起", - "Conditional": "条件式", - "Loop": "循环", - "Slots": "插槽", - "Slot for {prop}": "属性 {prop} 的插槽", - "Outline Tree": "大纲树" -} diff --git a/packages/plugin-outline-pane/src/main.ts b/packages/plugin-outline-pane/src/main.ts deleted file mode 100644 index c568082c3..000000000 --- a/packages/plugin-outline-pane/src/main.ts +++ /dev/null @@ -1,667 +0,0 @@ -import { computed, obx } from '@ali/lowcode-editor-core'; -import { - Designer, - ISensor, - LocateEvent, - isDragNodeObject, - isDragAnyObject, - DragObject, - Scroller, - ScrollTarget, - IScrollable, - DropLocation, - isLocationChildrenDetail, - LocationChildrenDetail, - LocationDetailType, - ParentalNode, - contains, - Node, -} from '@ali/lowcode-designer'; -import TreeNode from './tree-node'; -import { IndentTrack } from './helper/indent-track'; -import DwellTimer from './helper/dwell-timer'; -import { uniqueId } from '@ali/lowcode-utils'; -import { Backup } from './views/backup-pane'; -import { IEditor } from '@ali/lowcode-types'; -import { ITreeBoard, TreeMaster, getTreeMaster } from './tree-master'; - -export class OutlineMain implements ISensor, ITreeBoard, IScrollable { - private _designer?: Designer; - - @obx.ref private _master?: TreeMaster; - - get master() { - return this._master; - } - - @computed get currentTree() { - return this._master?.currentTree; - } - - readonly id = uniqueId('outline'); - - @obx.ref _visible = false; - - get visible() { - return this._visible; - } - - readonly editor: IEditor; - - readonly at: string | symbol; - - constructor(editor: IEditor, at: string | symbol) { - this.editor = editor; - this.at = at; - let inited = false; - const setup = async () => { - if (inited) { - return false; - } - inited = true; - const designer = await editor.onceGot(Designer); - this.setupDesigner(designer); - }; - - if (at === Backup) { - setup(); - } else { - editor.on('skeleton.panel.show', (key: string) => { - if (key === at) { - setup(); - this._visible = true; - } - }); - editor.on('skeleton.panel.hide', (key: string) => { - if (key === at) { - this._visible = false; - } - }); - } - } - - /** - * @see ISensor - */ - fixEvent(e: LocateEvent): LocateEvent { - if (e.fixed) { - return e; - } - - const notMyEvent = e.originalEvent.view?.document !== document; - - if (!e.target || notMyEvent) { - e.target = document.elementFromPoint(e.canvasX!, e.canvasY!); - } - - // documentModel : 目标文档 - e.documentModel = this._designer?.currentDocument; - - // 事件已订正 - e.fixed = true; - return e; - } - - private indentTrack = new IndentTrack(); - - private dwell = new DwellTimer((target, event) => { - const { document } = target; - const { designer } = document; - let index: any; - let focus: any; - let valid = true; - if (target.hasSlots()) { - index = null; - focus = { type: 'slots' }; - } else { - index = 0; - valid = document.checkNesting(target, event.dragObject as any); - } - designer.createLocation({ - target, - source: this.id, - event, - detail: { - type: LocationDetailType.Children, - index, - focus, - valid, - }, - }); - }); - - /** - * @see ISensor - */ - locate(e: LocateEvent): DropLocation | undefined | null { - this.sensing = true; - this.scroller?.scrolling(e); - const { globalY, dragObject } = e; - const { nodes } = dragObject; - - const tree = this._master?.currentTree; - if (!tree || !this._shell) { - return null; - } - - const operationalNodes = nodes?.filter((node: any) => { - const onMoveHook = node.componentMeta?.getMetadata()?.experimental?.callbacks?.onMoveHook; - const canMove = onMoveHook && typeof onMoveHook === 'function' ? onMoveHook() : true; - - return canMove; - }); - - if (!operationalNodes || operationalNodes.length === 0) { - return; - } - - const { document } = tree; - const { designer } = document; - const pos = getPosFromEvent(e, this._shell); - const irect = this.getInsertionRect(); - const originLoc = document.dropLocation; - - const prop = e.dragObject.nodes ? e.dragObject.nodes[0].getPrototype() : null; - if (e.dragObject.type === 'node' && prop && prop.isModal()) { - return designer.createLocation({ - target: document.rootNode, - detail: { - type: LocationDetailType.Children, - index: 0, - valid: true, - }, - source: this.id, - event: e, - }); - } - - if (originLoc && ((pos && pos === 'unchanged') || (irect && globalY >= irect.top && globalY <= irect.bottom))) { - const loc = originLoc.clone(e); - const indented = this.indentTrack.getIndentParent(originLoc, loc); - if (indented) { - const [parent, index] = indented; - if (checkRecursion(parent, dragObject)) { - if (tree.getTreeNode(parent).expanded) { - this.dwell.reset(); - return designer.createLocation({ - target: parent, - source: this.id, - event: e, - detail: { - type: LocationDetailType.Children, - index, - valid: document.checkNesting(parent, e.dragObject as any), - }, - }); - } - - (originLoc.detail as LocationChildrenDetail).focus = { - type: 'node', - node: parent, - }; - // focus try expand go on - this.dwell.focus(parent, e); - } else { - this.dwell.reset(); - } - // FIXME: recreate new location - } else if ((originLoc.detail as LocationChildrenDetail).near) { - (originLoc.detail as LocationChildrenDetail).near = undefined; - this.dwell.reset(); - } - return; - } - - this.indentTrack.reset(); - - if (pos && pos !== 'unchanged') { - let treeNode = tree.getTreeNodeById(pos.nodeId); - if (treeNode) { - let { focusSlots } = pos; - let { node } = treeNode; - if (isDragNodeObject(dragObject)) { - const newNodes = operationalNodes; - let i = newNodes.length; - let p: any = node; - while (i-- > 0) { - if (contains(newNodes[i], p)) { - p = newNodes[i].parent; - } - } - if (p !== node) { - node = p || document.rootNode; - treeNode = tree.getTreeNode(node); - focusSlots = false; - } - } - - if (focusSlots) { - this.dwell.reset(); - return designer.createLocation({ - target: node as ParentalNode, - source: this.id, - event: e, - detail: { - type: LocationDetailType.Children, - index: null, - valid: false, - focus: { type: 'slots' }, - }, - }); - } - - if (!treeNode.isRoot()) { - const loc = this.getNear(treeNode, e); - this.dwell.tryFocus(loc); - return loc; - } - } - } - - const loc = this.drillLocate(tree.root, e); - this.dwell.tryFocus(loc); - return loc; - } - - private getNear(treeNode: TreeNode, e: LocateEvent, index?: number, rect?: DOMRect) { - const { document } = treeNode.tree; - const { designer } = document; - const { globalY, dragObject } = e; - // TODO: check dragObject is anyData - const { node, expanded } = treeNode; - if (!rect) { - rect = this.getTreeNodeRect(treeNode); - if (!rect) { - return null; - } - } - if (index == null) { - index = node.index; - } - - if (node.isSlot()) { - // 是个插槽根节点 - if (!treeNode.isContainer() && !treeNode.hasSlots()) { - return designer.createLocation({ - target: node.parent!, - source: this.id, - event: e, - detail: { - type: LocationDetailType.Children, - index: null, - near: { node, pos: 'replace' }, - valid: true, // TODO: future validation the slot limit - }, - }); - } - const loc1 = this.drillLocate(treeNode, e); - if (loc1) { - return loc1; - } - - return designer.createLocation({ - target: node.parent!, - source: this.id, - event: e, - detail: { - type: LocationDetailType.Children, - index: null, - valid: false, - focus: { type: 'slots' }, - }, - }); - } - - let focusNode: Node | undefined; - // focus - if (!expanded && (treeNode.isContainer() || treeNode.hasSlots())) { - focusNode = node; - } - - // before - const titleRect = this.getTreeTitleRect(treeNode) || rect; - if (globalY < titleRect.top + titleRect.height / 2) { - return designer.createLocation({ - target: node.parent!, - source: this.id, - event: e, - detail: { - type: LocationDetailType.Children, - index, - valid: document.checkNesting(node.parent!, dragObject as any), - near: { node, pos: 'before' }, - focus: checkRecursion(focusNode, dragObject) ? { type: 'node', node: focusNode } : undefined, - }, - }); - } - - if (globalY > titleRect.bottom) { - focusNode = undefined; - } - - if (expanded) { - // drill - const loc = this.drillLocate(treeNode, e); - if (loc) { - return loc; - } - } - - // after - return designer.createLocation({ - target: node.parent!, - source: this.id, - event: e, - detail: { - type: LocationDetailType.Children, - index: index + 1, - valid: document.checkNesting(node.parent!, dragObject as any), - near: { node, pos: 'after' }, - focus: checkRecursion(focusNode, dragObject) ? { type: 'node', node: focusNode } : undefined, - }, - }); - } - - private drillLocate(treeNode: TreeNode, e: LocateEvent): DropLocation | null { - const { document } = treeNode.tree; - const { designer } = document; - const { dragObject, globalY } = e; - - if (!checkRecursion(treeNode.node, dragObject)) { - return null; - } - - if (isDragAnyObject(dragObject)) { - // TODO: future - return null; - } - - const container = treeNode.node as ParentalNode; - const detail: LocationChildrenDetail = { - type: LocationDetailType.Children, - }; - const locationData: any = { - target: container, - detail, - source: this.id, - event: e, - }; - const isSlotContainer = treeNode.hasSlots(); - const isContainer = treeNode.isContainer(); - - if (container.isSlot() && !treeNode.expanded) { - // 未展开,直接定位到内部第一个节点 - if (isSlotContainer) { - detail.index = null; - detail.focus = { type: 'slots' }; - detail.valid = false; - } else { - detail.index = 0; - detail.valid = document.checkNesting(container, dragObject); - } - } - - let items: TreeNode[] | null = null; - let slotsRect: DOMRect | undefined; - let focusSlots = false; - // isSlotContainer - if (isSlotContainer) { - slotsRect = this.getTreeSlotsRect(treeNode); - if (slotsRect) { - if (globalY <= slotsRect.bottom) { - focusSlots = true; - items = treeNode.slots; - } else if (!isContainer) { - // 不在 slots 范围,又不是 container 的情况,高亮 slots 区 - detail.index = null; - detail.focus = { type: 'slots' }; - detail.valid = false; - return designer.createLocation(locationData); - } - } - } - - if (!items && isContainer) { - items = treeNode.children; - } - - if (!items) { - return null; - } - - const l = items.length; - let index = 0; - let before = l < 1; - let current: TreeNode | undefined; - let currentIndex = index; - for (; index < l; index++) { - current = items[index]; - currentIndex = index; - const rect = this.getTreeNodeRect(current); - if (!rect) { - continue; - } - - // rect - if (globalY < rect.top) { - before = true; - break; - } - - if (globalY > rect.bottom) { - continue; - } - - const loc = this.getNear(current, e, index, rect); - if (loc) { - return loc; - } - } - - if (focusSlots) { - detail.focus = { type: 'slots' }; - detail.valid = false; - detail.index = null; - } else { - if (current) { - detail.index = before ? currentIndex : currentIndex + 1; - detail.near = { node: current.node, pos: before ? 'before' : 'after' }; - } else { - detail.index = l; - } - detail.valid = document.checkNesting(container, dragObject); - } - - return designer.createLocation(locationData); - } - - /** - * @see ISensor - */ - isEnter(e: LocateEvent): boolean { - if (!this._shell) { - return false; - } - const rect = this._shell.getBoundingClientRect(); - return e.globalY >= rect.top && e.globalY <= rect.bottom && e.globalX >= rect.left && e.globalX <= rect.right; - } - - private tryScrollAgain: number | null = null; - - /** - * @see IScrollBoard - */ - scrollToNode(treeNode: TreeNode, detail?: any, tryTimes = 0) { - if (tryTimes < 1 && this.tryScrollAgain) { - (window as any).cancelIdleCallback(this.tryScrollAgain); - this.tryScrollAgain = null; - } - if (this.sensing || !this.bounds || !this.scroller || !this.scrollTarget) { - // is a active sensor - return; - } - - let rect: ClientRect | undefined; - if (detail && isLocationChildrenDetail(detail)) { - rect = this.getInsertionRect(); - } else { - rect = this.getTreeNodeRect(treeNode); - } - - if (!rect) { - if (tryTimes < 3) { - this.tryScrollAgain = (window as any).requestIdleCallback(() => this.scrollToNode(treeNode, detail, tryTimes + 1)); - } - return; - } - const { scrollHeight, top: scrollTop } = this.scrollTarget; - const { height, top, bottom } = this.bounds; - if (rect.top < top || rect.bottom > bottom) { - const opt: any = {}; - opt.top = Math.min(rect.top + rect.height / 2 + scrollTop - top - height / 2, scrollHeight - height); - if (rect.height >= height) { - opt.top = Math.min(scrollTop + rect.top - top, opt.top); - } - this.scroller.scrollTo(opt); - } - // make tail scroll be sure - if (tryTimes < 4) { - this.tryScrollAgain = (window as any).requestIdleCallback(() => this.scrollToNode(treeNode, detail, 4)); - } - } - - private sensing = false; - - /** - * @see ISensor - */ - deactiveSensor() { - this.sensing = false; - this.scroller?.cancel(); - this.dwell.reset(); - this.indentTrack.reset(); - } - - /** - * @see IScrollable - */ - get bounds(): DOMRect | null { - if (!this._shell) { - return null; - } - return this._shell.getBoundingClientRect(); - } - - private _scrollTarget?: ScrollTarget; - - /** - * @see IScrollable - */ - get scrollTarget() { - return this._scrollTarget; - } - - private scroller?: Scroller; - - private setupDesigner(designer: Designer) { - this._designer = designer; - this._master = getTreeMaster(designer); - this._master.addBoard(this); - designer.dragon.addSensor(this); - this.scroller = designer.createScroller(this); - } - - purge() { - this._designer?.dragon.removeSensor(this); - this._master?.removeBoard(this); - // todo purge treeMaster if needed - } - - private _sensorAvailable = false; - - /** - * @see ISensor - */ - get sensorAvailable() { - return this._sensorAvailable; - } - - private _shell: HTMLDivElement | null = null; - - mount(shell: HTMLDivElement | null) { - if (this._shell === shell) { - return; - } - this._shell = shell; - if (shell) { - this._scrollTarget = new ScrollTarget(shell); - this._sensorAvailable = true; - } else { - this._scrollTarget = undefined; - this._sensorAvailable = false; - } - } - - private getInsertionRect(): DOMRect | undefined { - if (!this._shell) { - return undefined; - } - return this._shell.querySelector('.insertion')?.getBoundingClientRect(); - } - - private getTreeNodeRect(treeNode: TreeNode): DOMRect | undefined { - if (!this._shell) { - return undefined; - } - return this._shell.querySelector(`.tree-node[data-id="${treeNode.id}"]`)?.getBoundingClientRect(); - } - - private getTreeTitleRect(treeNode: TreeNode): DOMRect | undefined { - if (!this._shell) { - return undefined; - } - return this._shell.querySelector(`.tree-node-title[data-id="${treeNode.id}"]`)?.getBoundingClientRect(); - } - - private getTreeSlotsRect(treeNode: TreeNode): DOMRect | undefined { - if (!this._shell) { - return undefined; - } - return this._shell.querySelector(`.tree-node-slots[data-id="${treeNode.id}"]`)?.getBoundingClientRect(); - } -} - -function checkRecursion(parent: Node | undefined | null, dragObject: DragObject): parent is ParentalNode { - if (!parent) { - return false; - } - if (isDragNodeObject(dragObject)) { - const { nodes } = dragObject; - if (nodes.some((node) => node.contains(parent))) { - return false; - } - } - return true; -} - -function getPosFromEvent( - { target }: LocateEvent, - stop: Element, -): null | 'unchanged' | { nodeId: string; focusSlots: boolean } { - if (!target || !stop.contains(target)) { - return null; - } - if (target.matches('.insertion')) { - return 'unchanged'; - } - target = target.closest('[data-id]'); - if (!target || !stop.contains(target)) { - return null; - } - - const nodeId = (target as HTMLDivElement).dataset.id!; - return { - focusSlots: target.matches('.tree-node-slots'), - nodeId, - }; -} diff --git a/packages/plugin-outline-pane/src/tree-master.ts b/packages/plugin-outline-pane/src/tree-master.ts deleted file mode 100644 index 4e4049d0f..000000000 --- a/packages/plugin-outline-pane/src/tree-master.ts +++ /dev/null @@ -1,122 +0,0 @@ -import { computed, obx } from '@ali/lowcode-editor-core'; -import { Designer, isLocationChildrenDetail } from '@ali/lowcode-designer'; -import TreeNode from './tree-node'; -import { Tree } from './tree'; -import { Backup } from './views/backup-pane'; - -export interface ITreeBoard { - readonly visible: boolean; - readonly at: string | symbol; - scrollToNode(treeNode: TreeNode, detail?: any): void; -} - -export class TreeMaster { - readonly designer: Designer; - - constructor(designer: Designer) { - this.designer = designer; - let startTime: any; - designer.dragon.onDragstart(() => { - startTime = Date.now() / 1000; - // needs? - this.toVision(); - }); - designer.activeTracker.onChange(({ node, detail }) => { - const tree = this.currentTree; - if (!tree || node.document !== tree.document) { - return; - } - - const treeNode = tree.getTreeNode(node); - if (detail && isLocationChildrenDetail(detail)) { - treeNode.expand(true); - } else { - treeNode.expandParents(); - } - - this.boards.forEach((board) => { - board.scrollToNode(treeNode, detail); - }); - }); - designer.dragon.onDragend(() => { - const endTime: any = Date.now() / 1000; - const editor = designer?.editor; - const nodes = designer.currentSelection?.getNodes(); - editor?.emit('outlinePane.drag', { - selected: nodes - ?.map((n) => { - if (!n) { - return; - } - const npm = n?.componentMeta?.npm; - return ( - [npm?.package, npm?.componentName].filter((item) => !!item).join('-') || n?.componentMeta?.componentName - ); - }) - .join('&'), - time: (endTime - startTime).toFixed(2), - }); - }); - designer.editor.on('designer.document.remove', ({ id }) => { - this.treeMap.delete(id); - }); - } - - private toVision() { - const tree = this.currentTree; - if (tree) { - tree.document.selection.getTopNodes().forEach((node) => { - tree.getTreeNode(node).setExpanded(false); - }); - } - } - - @obx.val private boards = new Set(); - - addBoard(board: ITreeBoard) { - this.boards.add(board); - } - - removeBoard(board: ITreeBoard) { - this.boards.delete(board); - } - - @computed hasVisibleTreeBoard() { - for (const item of this.boards) { - if (item.visible && item.at !== Backup) { - return true; - } - } - return false; - } - - purge() { - // todo others purge - } - - private treeMap = new Map(); - - @computed get currentTree(): Tree | null { - const doc = this.designer?.currentDocument; - if (doc) { - const { id } = doc; - if (this.treeMap.has(id)) { - return this.treeMap.get(id)!; - } - const tree = new Tree(doc); - this.treeMap.set(id, tree); - return tree; - } - return null; - } -} - -const mastersMap = new Map(); -export function getTreeMaster(designer: Designer): TreeMaster { - let master = mastersMap.get(designer); - if (!master) { - master = new TreeMaster(designer); - mastersMap.set(designer, master); - } - return master; -} diff --git a/packages/plugin-outline-pane/src/tree-node.ts b/packages/plugin-outline-pane/src/tree-node.ts deleted file mode 100644 index e021d6b65..000000000 --- a/packages/plugin-outline-pane/src/tree-node.ts +++ /dev/null @@ -1,235 +0,0 @@ -import { TitleContent, isI18nData } from '@ali/lowcode-types'; -import { computed, obx, intl } from '@ali/lowcode-editor-core'; -import { Node, DocumentModel, isLocationChildrenDetail, LocationChildrenDetail, Designer } from '@ali/lowcode-designer'; -import { Tree } from './tree'; - -export default class TreeNode { - get id(): string { - return this.node.id; - } - - /** - * 是否可以展开 - */ - @computed get expandable(): boolean { - return this.hasChildren() || this.hasSlots() || this.dropDetail?.index != null; - } - - /** - * 插入"线"位置信息 - */ - @computed get dropDetail(): LocationChildrenDetail | undefined | null { - const loc = this.node.document.dropLocation; - return loc && this.isResponseDropping() && isLocationChildrenDetail(loc.detail) ? loc.detail : null; - } - - @computed get depth(): number { - return this.node.zLevel; - } - - isRoot() { - return this.tree.root === this; - } - - /** - * 是否是响应投放区 - */ - @computed isResponseDropping(): boolean { - const loc = this.node.document.dropLocation; - if (!loc) { - return false; - } - return loc.target === this.node; - } - - @computed isFocusingNode(): boolean { - const loc = this.node.document.dropLocation; - if (!loc) { - return false; - } - return ( - isLocationChildrenDetail(loc.detail) && loc.detail.focus?.type === 'node' && loc.detail.focus.node === this.node - ); - } - - /** - * 默认为折叠状态 - * 在初始化根节点时,设置为展开状态 - */ - @obx.ref private _expanded = false; - - get expanded(): boolean { - return this.isRoot() || (this.expandable && this._expanded); - } - - setExpanded(value: boolean) { - this._expanded = value; - } - - @computed get detecting() { - return this.designer.detecting.current === this.node; - } - - @computed get hidden(): boolean { - const cv = this.node.isConditionalVisible(); - if (cv == null) { - return !this.node.getVisible(); - } - return !cv; - } - - setHidden(flag: boolean) { - if (this.node.conditionGroup) { - return; - } - this.node.setVisible(!flag); - } - - @computed get locked(): boolean { - return this.node.getExtraProp('locked', false)?.getValue() === true; - } - - setLocked(flag: boolean) { - if (flag) { - this.node.getExtraProp('locked', true)?.setValue(true); - } else { - this.node.getExtraProp('locked', false)?.remove(); - } - } - - @computed get selected(): boolean { - // TODO: check is dragging - const { selection } = this.document; - return selection.has(this.node.id); - } - - @computed get title(): TitleContent { - return this.node.title; - } - - @computed get titleLabel() { - let { title } = this; - if (!title) { - return ''; - } - if ((title as any).label) { - title = (title as any).label; - } - if (typeof title === 'string') { - return title; - } - if (isI18nData(title)) { - return intl(title) as string; - } - return this.node.componentName; - } - - setTitleLabel(label: string) { - const origLabel = this.titleLabel; - if (label === origLabel) { - return; - } - if (label === '') { - this.node.getExtraProp('title', false)?.remove(); - } else { - this.node.getExtraProp('title', true)?.setValue(label); - } - } - - get icon() { - return this.node.componentMeta.icon; - } - - @computed get parent() { - const { parent } = this.node; - if (parent) { - return this.tree.getTreeNode(parent); - } - return null; - } - - @computed get slots(): TreeNode[] { - // todo: shallowEqual - return this.node.slots.map((node) => this.tree.getTreeNode(node)); - } - - @computed get children(): TreeNode[] | null { - return this.node.children?.map((node) => this.tree.getTreeNode(node)) || null; - } - - /** - * 是否是容器,允许子节点拖入 - */ - isContainer(): boolean { - return this.node.isContainer(); - } - - /** - * 判断是否有"插槽" - */ - hasSlots(): boolean { - return this.node.hasSlots(); - } - - hasChildren(): boolean { - return !!(this.isContainer() && this.node.children?.notEmpty()); - } - - select(isMulti: boolean) { - const { node } = this; - - const { selection } = node.document; - if (isMulti) { - selection.add(node.id); - } else { - selection.select(node.id); - } - } - - /** - * 展开节点,支持依次展开父节点 - */ - expand(tryExpandParents = false) { - // 这边不能直接使用 expanded,需要额外判断是否可以展开 - // 如果只使用 expanded,会漏掉不可以展开的情况,即在不可以展开的情况下,会触发展开 - if (this.expandable && !this._expanded) { - this.setExpanded(true); - } - if (tryExpandParents) { - this.expandParents(); - } - } - - expandParents() { - let p = this.node.parent; - while (p) { - this.tree.getTreeNode(p).setExpanded(true); - p = p.parent; - } - } - - readonly designer: Designer; - - readonly document: DocumentModel; - - @obx.ref private _node: Node; - - get node() { - return this._node; - } - - readonly tree: Tree; - - constructor(tree: Tree, node: Node) { - this.tree = tree; - this.document = node.document; - this.designer = this.document.designer; - this._node = node; - } - - setNode(node: Node) { - if (this._node !== node) { - this._node = node; - } - } -} diff --git a/packages/plugin-outline-pane/src/tree.ts b/packages/plugin-outline-pane/src/tree.ts deleted file mode 100644 index a34bdfd21..000000000 --- a/packages/plugin-outline-pane/src/tree.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { DocumentModel, Node } from '@ali/lowcode-designer'; -import TreeNode from './tree-node'; - -export class Tree { - private treeNodesMap = new Map(); - - readonly root: TreeNode; - - readonly id: string; - - readonly document: DocumentModel; - - constructor(document: DocumentModel) { - this.document = document; - this.root = this.getTreeNode(document.rootNode); - this.id = document.id; - } - - getTreeNode(node: Node): TreeNode { - if (this.treeNodesMap.has(node.id)) { - const tnode = this.treeNodesMap.get(node.id)!; - tnode.setNode(node); - return tnode; - } - - const treeNode = new TreeNode(this, node); - this.treeNodesMap.set(node.id, treeNode); - return treeNode; - } - - getTreeNodeById(id: string) { - return this.treeNodesMap.get(id); - } -} diff --git a/packages/plugin-outline-pane/src/views/backup-pane.tsx b/packages/plugin-outline-pane/src/views/backup-pane.tsx deleted file mode 100644 index eb933149f..000000000 --- a/packages/plugin-outline-pane/src/views/backup-pane.tsx +++ /dev/null @@ -1,18 +0,0 @@ -import { PureComponent } from 'react'; -import { PluginProps } from '@ali/lowcode-types'; -import { OutlinePane } from './pane'; - -export const Backup = Symbol.for('backup-outline'); - -export class OutlineBackupPane extends PureComponent { - render() { - return ( - - ); - } -} diff --git a/packages/plugin-outline-pane/src/views/pane.tsx b/packages/plugin-outline-pane/src/views/pane.tsx deleted file mode 100644 index d17ee1929..000000000 --- a/packages/plugin-outline-pane/src/views/pane.tsx +++ /dev/null @@ -1,40 +0,0 @@ -import React, { Component } from 'react'; -import { observer } from '@ali/lowcode-editor-core'; -import { intl } from '../locale'; -import { OutlineMain } from '../main'; -import TreeView from './tree'; -import './style.less'; -import { IEditor } from '@ali/lowcode-types'; - -@observer -export class OutlinePane extends Component<{ config: any; editor: IEditor }> { - private main = new OutlineMain(this.props.editor, this.props.config.name || this.props.config.pluginKey); - - shouldComponentUpdate() { - return false; - } - - componentWillUnmount() { - this.main.purge(); - } - - render() { - const tree = this.main.currentTree; - - if (!tree) { - return ( -
-

{intl('Initializing')}

-
- ); - } - - return ( -
-
this.main.mount(shell)} className="lc-outline-tree-container"> - -
-
- ); - } -} diff --git a/packages/plugin-outline-pane/src/views/root-tree-node.tsx b/packages/plugin-outline-pane/src/views/root-tree-node.tsx deleted file mode 100644 index 69d456ef1..000000000 --- a/packages/plugin-outline-pane/src/views/root-tree-node.tsx +++ /dev/null @@ -1,94 +0,0 @@ -import { Component } from 'react'; -import classNames from 'classnames'; -import { observer } from '@ali/lowcode-editor-core'; -import TreeNode from '../tree-node'; -import TreeTitle from './tree-title'; -import TreeBranches from './tree-branches'; -import { ModalNodesManager } from '@ali/lowcode-designer'; -import { IconEyeClose } from '../icons/eye-close'; - -@observer -class ModalTreeNodeView extends Component<{ treeNode: TreeNode }> { - private modalNodesManager: ModalNodesManager; - - constructor(props: any) { - super(props); - - // 模态管理对象 - this.modalNodesManager = props.treeNode.document.modalNodesManager; - } - - shouldComponentUpdate() { - return false; - } - - hideAllNodes() { - this.modalNodesManager.hideModalNodes(); - } - - render() { - const { treeNode } = this.props; - const modalNodes = treeNode.children?.filter((item) => { - return item.node.getPrototype()?.isModal(); - }); - if (!modalNodes || modalNodes.length === 0) { - return null; - } - - const hasVisibleModalNode = !!this.modalNodesManager.getVisibleModalNode(); - return ( -
-
- 模态视图层 -
- {hasVisibleModalNode ? : null} -
-
-
- -
-
- ); - } -} - -@observer -export default class RootTreeNodeView extends Component<{ treeNode: TreeNode }> { - shouldComponentUpdate() { - return false; - } - - render() { - const { treeNode } = this.props; - const className = classNames('tree-node', { - // 是否展开 - expanded: treeNode.expanded, - // 是否悬停中 - detecting: treeNode.detecting, - // 是否选中的 - selected: treeNode.selected, - // 是否隐藏的 - hidden: treeNode.hidden, - // 是否忽略的 - // ignored: treeNode.ignored, - // 是否锁定的 - locked: treeNode.locked, - // 是否投放响应 - dropping: treeNode.dropDetail?.index != null, - 'is-root': treeNode.isRoot(), - 'condition-flow': treeNode.node.conditionGroup != null, - highlight: treeNode.isFocusingNode(), - }); - - return ( -
- - - -
- ); - } -} diff --git a/packages/plugin-outline-pane/src/views/style.less b/packages/plugin-outline-pane/src/views/style.less deleted file mode 100644 index e2c81a033..000000000 --- a/packages/plugin-outline-pane/src/views/style.less +++ /dev/null @@ -1,387 +0,0 @@ -.lc-outline-pane { - height: 100%; - width: 100%; - position: relative; - z-index: 2; - background-color: white; - - > .lc-outline-tree-container { - top: 0; - left: 0; - bottom: 0; - right: 0; - position: absolute; - overflow: auto; - } -} - -.lc-outline-tree { - @treeNodeHeight: 30px; - overflow: hidden; - margin-bottom: @treeNodeHeight; - user-select: none; - - .tree-node-modal { - margin: 5px; - border: 1px solid rgba(31, 56, 88, 0.2); - border-radius: 3px; - box-shadow: 0 1px 4px 0 rgba(31, 56, 88, 0.15); - - .tree-node-modal-title { - position: relative; - background: rgba(31, 56, 88, 0.04); - padding: 0 10px; - height: 32px; - line-height: 32px; - border-bottom: 1px solid rgba(31, 56, 88, 0.2); - - .tree-node-modal-title-visible-icon { - position: absolute; - top: 4px; - right: 12px; - cursor: pointer; - } - } - - .tree-pane-modal-content { - & > .tree-node-branches::before { - display: none; - } - } - - .tree-node-modal-radio, .tree-node-modal-radio-active { - margin-right: 4px; - opacity: 0.8; - position: absolute; - top: 7px; - left: 6px; - } - .tree-node-modal-radio-active { - color: #006cff; - } - } - - .tree-node-branches::before { - position: absolute; - display: block; - width: 0; - border-left: 1px solid transparent; - height: 100%; - top: 0; - left: 6px; - content: ' '; - z-index: 2; - pointer-events: none; - } - - &:hover { - .tree-node-branches::before { - border-left-color: #ddd; - } - } - - .insertion { - pointer-events: all !important; - border: 1px dashed var(--color-brand-light); - height: @treeNodeHeight; - box-sizing: border-box; - transform: translateZ(0); - &.invalid { - border-color: red; - background-color: rgba(240, 154, 154, 0.719); - } - } - - .condition-group-container { - border-bottom: 1px solid #7b605b; - position: relative; - - &:before { - position: absolute; - display: block; - width: 0; - border-left: 0.5px solid #7b605b; - height: 100%; - top: 0; - left: 0; - content: ' '; - z-index: 2; - } - >.condition-group-title { - text-align: center; - background-color: #7b605b; - height: 14px; - > .lc-title { - font-size: 12px; - transform: scale(0.8); - transform-origin: top; - color: white; - text-shadow: 0px 0px 2px black; - display: block; - } - } - } - .tree-node-slots { - border-bottom: 1px solid rgb(144, 94, 190); - position: relative; - &::before { - position: absolute; - display: block; - width: 0; - border-left: 0.5px solid rgb(144, 94, 190); - height: 100%; - top: 0; - left: 0; - content: ' '; - z-index: 2; - } - >.tree-node-slots-title { - text-align: center; - background-color: rgb(144, 94, 190); - height: 14px; - > .lc-title { - font-size: 12px; - transform: scale(0.8); - transform-origin: top; - color: white; - text-shadow: 0px 0px 2px black; - display: block; - } - } - &.insertion-at-slots { - padding-bottom: @treeNodeHeight; - border-bottom-color: rgb(182, 55, 55); - >.tree-node-slots-title { - background-color: rgb(182, 55, 55); - } - &::before { - border-left-color: rgb(182, 55, 55); - } - } - } - - .tree-node { - .tree-node-expand-btn { - width: 12px; - line-height: 0; - align-self: stretch; - display: flex; - align-items: center; - transition: color 200ms ease; - color: var(--color-icon-normal); - &:hover { - color: var(--color-icon-hover); - } - > svg { - transform-origin: center; - transform: rotate(-90deg); - transition: transform 100ms ease; - } - margin-right: 4px; - } - .tree-node-expand-placeholder { - width: 12px; - height: 12px; - margin-right: 4px; - } - - .tree-node-icon { - transform: translateZ(0); - display: flex; - align-items: center; - margin-right: 4px; - color: var(--color-text); - - & > svg { - width: 16px; - height: 16px; - * { - fill: var(--color-icon-normal, rgba(31, 56, 88, 0.4)); - } - } - & > img { - width: 16px; - height: 16px; - * { - fill: var(--color-icon-normal, rgba(31, 56, 88, 0.4)); - } - } - } - - .tree-node-title { - font-size: var(--font-size-text); - cursor: pointer; - background: var(--color-pane-background); - border-bottom: 1px solid var(--color-line-normal, rgba(31, 56, 88, 0.1)); - display: flex; - align-items: center; - height: @treeNodeHeight; - box-sizing: border-box; - position: relative; - transform: translateZ(0); - padding-right: 5px; - & > :first-child { - margin-left: 2px; - } - - .tree-node-title-label { - flex: 1; - overflow: hidden; - white-space: nowrap; - text-overflow: ellipsis; - display: flex; - align-items: center; - align-self: stretch; - overflow: visible; - margin-right: 5px; - - .tree-node-title-input { - flex: 1; - border: 1px solid var(--color-brand-light); - background-color: var(--color-pane-background); - color: var(--color-text); - line-height: 18px; - padding: 2px; - outline: none; - margin-left: -3px; - border-radius: 2px; - } - } - - .tree-node-hide-btn, .tree-node-lock-btn { - opacity: 0; - color: var(--color-text); - line-height: 0; - align-self: stretch; - display: flex; - align-items: center; - justify-content: center; - width: 22px; - &:hover { - opacity: 1 !important; - } - } - &:hover { - .tree-node-hide-btn, .tree-node-lock-btn { - opacity: 0.5; - } - } - html.lc-cursor-dragging & { - // FIXME: only hide hover shows - .tree-node-hide-btn, .tree-node-lock-btn { - display: none; - } - } - &.editing { - & > .tree-node-hide-btn, & >.tree-node-lock-btn { - display: none; - } - } - - .tree-node-tag { - margin-left: 5px; - display: flex; - align-items: center; - line-height: 0; - &.cond { - color: rgb(179, 52, 6); - } - &.loop { - color: rgb(103, 187, 187); - } - &.slot { - color: rgb(211, 90, 211); - } - } - } - - &.is-root { - > .tree-node-title { - padding-left: 5px; - } - } - - &.expanded { - & > .tree-node-title > .tree-node-expand-btn > svg { - transform: rotate(0); - } - } - - &.detecting > .tree-node-title { - background: var(--color-block-background-light); - } - - // 选中节点处理 - &.selected { - & > .tree-node-title { - background: var(--color-block-background-shallow); - } - - & > .tree-node-branches::before { - border-left-color: var(--color-brand-light); - } - } - - &.hidden { - .tree-node-title-label { - color: #9b9b9b; - } - & > .tree-node-title > .tree-node-hide-btn { - opacity: 0.8; - } - .tree-node-branches { - .tree-node-hide-btn { - opacity: 0; - } - } - } - - &.condition-flow { - & > .tree-node-title > .tree-node-hide-btn { - opacity: 1; - } - &.hidden > .tree-node-title > .tree-node-hide-btn { - opacity: 0; - } - } - - &.locked { - & > .tree-node-title > .tree-node-lock-btn { - opacity: 0.8; - } - .tree-node-branches { - .tree-node-lock-btn, .tree-node-hide-btn { - opacity: 0; - } - } - } - - // 处理拖入节点 - &.dropping { - & > .tree-node-branches::before { - border-left: 1px solid var(--color-brand); - } - & > .tree-node-title { - .tree-node-expand-btn { - color: var(--color-brand); - } - .tree-node-icon { - color: var(--color-brand); - } - .tree-node-title-label > .lc-title { - color: var(--color-brand); - } - } - } - &.highlight { - & > .tree-node-title { - background: var(--color-block-background-shallow); - } - } - - .tree-node-branches { - padding-left: 12px; - position: relative; - } - } -} diff --git a/packages/plugin-outline-pane/src/views/tree-branches.tsx b/packages/plugin-outline-pane/src/views/tree-branches.tsx deleted file mode 100644 index f6471450b..000000000 --- a/packages/plugin-outline-pane/src/views/tree-branches.tsx +++ /dev/null @@ -1,140 +0,0 @@ -import { Component } from 'react'; -import classNames from 'classnames'; -import { observer, Title } from '@ali/lowcode-editor-core'; -import { ExclusiveGroup } from '@ali/lowcode-designer'; -import TreeNode from '../tree-node'; -import TreeNodeView from './tree-node'; -import { intlNode } from '../locale'; - -@observer -export default class TreeBranches extends Component<{ - treeNode: TreeNode; - isModal?: boolean; -}> { - shouldComponentUpdate() { - return false; - } - - render() { - const { treeNode, isModal } = this.props; - const { expanded } = treeNode; - - if (!expanded) { - return null; - } - - return ( -
- { - !isModal && - } - -
- ); - } -} - -@observer -class TreeNodeChildren extends Component<{ - treeNode: TreeNode; - isModal?: boolean; - }> { - shouldComponentUpdate() { - return false; - } - - render() { - const { treeNode, isModal } = this.props; - const children: any = []; - let groupContents: any[] = []; - let currentGrp: ExclusiveGroup; - const endGroup = () => { - if (groupContents.length > 0) { - children.push( -
-
- - </div> - {groupContents} - </div>, - ); - groupContents = []; - } - }; - const { dropDetail } = treeNode; - const dropIndex = dropDetail?.index; - const insertion = ( - <div - key="insertion" - className={classNames('insertion', { - invalid: dropDetail?.valid === false, - })} - /> - ); - treeNode.children?.forEach((child, index) => { - const childIsModal = child.node.getPrototype()?.isModal() || false; - if (isModal != childIsModal) { - return; - } - const { conditionGroup } = child.node; - if (conditionGroup !== currentGrp) { - endGroup(); - } - - if (conditionGroup) { - currentGrp = conditionGroup; - if (index === dropIndex) { - if (groupContents.length > 0) { - groupContents.push(insertion); - } else { - children.push(insertion); - } - } - groupContents.push(<TreeNodeView key={child.id} treeNode={child} isModal={isModal} />); - } else { - if (index === dropIndex) { - children.push(insertion); - } - children.push(<TreeNodeView key={child.id} treeNode={child} isModal={isModal} />); - } - }); - endGroup(); - const length = treeNode.children?.length || 0; - if (dropIndex != null && dropIndex >= length) { - children.push(insertion); - } - - return <div className="tree-node-children">{children}</div>; - } -} - -@observer -class TreeNodeSlots extends Component<{ - treeNode: TreeNode; - }> { - shouldComponentUpdate() { - return false; - } - - render() { - const { treeNode } = this.props; - if (!treeNode.hasSlots()) { - return null; - } - return ( - <div - className={classNames('tree-node-slots', { - 'insertion-at-slots': treeNode.dropDetail?.focus?.type === 'slots', - })} - data-id={treeNode.id} - > - <div className="tree-node-slots-title"> - <Title title={{ type: 'i18n', intl: intlNode('Slots') }} /> - </div> - {treeNode.slots.map(tnode => ( - <TreeNodeView key={tnode.id} treeNode={tnode} /> - ))} - </div> - ); - } -} diff --git a/packages/plugin-outline-pane/src/views/tree-node.tsx b/packages/plugin-outline-pane/src/views/tree-node.tsx deleted file mode 100644 index a22015cd5..000000000 --- a/packages/plugin-outline-pane/src/views/tree-node.tsx +++ /dev/null @@ -1,46 +0,0 @@ -import { Component } from 'react'; -import classNames from 'classnames'; -import { observer } from '@ali/lowcode-editor-core'; -import TreeNode from '../tree-node'; -import TreeTitle from './tree-title'; -import TreeBranches from './tree-branches'; - -@observer -export default class TreeNodeView extends Component<{ - treeNode: TreeNode; - isModal?: boolean; -}> { - shouldComponentUpdate() { - return false; - } - - render() { - const { treeNode, isModal } = this.props; - const className = classNames('tree-node', { - // 是否展开 - expanded: treeNode.expanded, - // 是否悬停中 - detecting: treeNode.detecting, - // 是否选中的 - selected: treeNode.selected, - // 是否隐藏的 - hidden: treeNode.hidden, - // 是否忽略的 - // ignored: treeNode.ignored, - // 是否锁定的 - locked: treeNode.locked, - // 是否投放响应 - dropping: treeNode.dropDetail?.index != null, - 'is-root': treeNode.isRoot(), - 'condition-flow': treeNode.node.conditionGroup != null, - highlight: treeNode.isFocusingNode(), - }); - - return ( - <div className={className} data-id={treeNode.id}> - <TreeTitle treeNode={treeNode} isModal={isModal} /> - <TreeBranches treeNode={treeNode} isModal={false} /> - </div> - ); - } -} diff --git a/packages/plugin-outline-pane/src/views/tree-title.tsx b/packages/plugin-outline-pane/src/views/tree-title.tsx deleted file mode 100644 index 165b88534..000000000 --- a/packages/plugin-outline-pane/src/views/tree-title.tsx +++ /dev/null @@ -1,295 +0,0 @@ -import { Component, KeyboardEvent, FocusEvent, Fragment } from 'react'; -import classNames from 'classnames'; -import { observer, Title, Tip, globalContext, Editor } from '@ali/lowcode-editor-core'; -import { IconArrowRight } from '../icons/arrow-right'; -import { IconEyeClose } from '../icons/eye-close'; -import { intl, intlNode } from '../locale'; -import TreeNode from '../tree-node'; -import { IconEye } from '../icons/eye'; -import { IconCond } from '../icons/cond'; -import { IconLoop } from '../icons/loop'; -import { IconRadioActive } from '../icons/radio-active'; -import { IconRadio } from '../icons/radio'; -import { createIcon } from '@ali/lowcode-utils'; - -function emitOutlineEvent(type: string, treeNode: TreeNode, rest?: Record<string, unknown>) { - const editor = globalContext.get(Editor); - const node = treeNode?.node; - const npm = node?.componentMeta?.npm; - const selected = - [npm?.package, npm?.componentName].filter((item) => !!item).join('-') || node?.componentMeta?.componentName || ''; - editor?.emit(`outlinePane.${type}`, { - selected, - ...rest, - }); -} - -@observer -export default class TreeTitle extends Component<{ - treeNode: TreeNode; - isModal?: boolean; -}> { - state: { - editing: boolean; - } = { - editing: false, - }; - - private enableEdit = () => { - this.setState({ - editing: true, - }); - }; - - private cancelEdit() { - this.setState({ - editing: false, - }); - this.lastInput = undefined; - } - - private saveEdit = (e: FocusEvent<HTMLInputElement> | KeyboardEvent<HTMLInputElement>) => { - const { treeNode } = this.props; - const value = (e.target as HTMLInputElement).value || ''; - treeNode.setTitleLabel(value); - emitOutlineEvent('rename', treeNode, { value }); - this.cancelEdit(); - }; - - private handleKeyUp = (e: KeyboardEvent<HTMLInputElement>) => { - if (e.keyCode === 13) { - this.saveEdit(e); - } - if (e.keyCode === 27) { - this.cancelEdit(); - } - }; - - private lastInput?: HTMLInputElement; - - private setCaret = (input: HTMLInputElement | null) => { - if (!input || this.lastInput === input) { - return; - } - input.focus(); - input.select(); - // 光标定位最后一个 - // input.selectionStart = input.selectionEnd; - }; - - render() { - const { treeNode, isModal } = this.props; - const { editing } = this.state; - const isCNode = !treeNode.isRoot(); - const { node } = treeNode; - const isNodeParent = node.isParental(); - let style: any; - if (isCNode) { - const { depth } = treeNode; - const indent = depth * 12; - style = { - paddingLeft: indent + (isModal ? 12 : 0), - marginLeft: -indent, - }; - } - - return ( - <div - className={classNames('tree-node-title', { - editing, - })} - style={style} - data-id={treeNode.id} - onClick={() => { - if (isModal) { - node.document.modalNodesManager.setVisible(node); - return; - } - if (node.conditionGroup) { - node.setConditionalVisible(); - } - }} - > - {isModal && node.getVisible() && ( - <div onClick={() => { - node.document.modalNodesManager.setInvisible(node); - }} - > - <IconRadioActive className="tree-node-modal-radio-active" /> - </div> - )} - {isModal && !node.getVisible() && ( - <div onClick={() => { - node.document.modalNodesManager.setVisible(node); - }} - > - <IconRadio className="tree-node-modal-radio" /> - </div> - )} - {isCNode && <ExpandBtn treeNode={treeNode} />} - <div className="tree-node-icon">{createIcon(treeNode.icon)}</div> - <div className="tree-node-title-label" onDoubleClick={isNodeParent ? this.enableEdit : undefined}> - {editing ? ( - <input - className="tree-node-title-input" - defaultValue={treeNode.titleLabel} - onBlur={this.saveEdit} - ref={this.setCaret} - onKeyUp={this.handleKeyUp} - /> - ) : ( - <Fragment> - <Title title={treeNode.title} /> - {node.slotFor && ( - <a className="tree-node-tag slot"> - {/* todo: click redirect to prop */} - <Tip>{intlNode('Slot for {prop}', { prop: node.slotFor.key })}</Tip> - </a> - )} - {node.hasLoop() && ( - <a className="tree-node-tag loop"> - {/* todo: click todo something */} - <IconLoop /> - <Tip>{intlNode('Loop')}</Tip> - </a> - )} - {node.hasCondition() && !node.conditionGroup && ( - <a className="tree-node-tag cond"> - {/* todo: click todo something */} - <IconCond /> - <Tip>{intlNode('Conditional')}</Tip> - </a> - )} - </Fragment> - )} - </div> - {isCNode && isNodeParent && !isModal && <HideBtn treeNode={treeNode} />} - {/* isCNode && isNodeParent && <LockBtn treeNode={treeNode} /> */} - </div> - ); - } -} - -// @observer -// class LockBtn extends Component<{ treeNode: TreeNode }> { -// shouldComponentUpdate() { -// return false; -// } - -// render() { -// const { treeNode } = this.props; -// return ( -// <div -// className="tree-node-lock-btn" -// onClick={(e) => { -// e.stopPropagation(); -// treeNode.setLocked(!treeNode.locked); -// }} -// > -// {treeNode.locked ? <IconLock /> : <IconUnlock />} -// <Tip>{treeNode.locked ? intl('Unlock') : intl('Lock')}</Tip> -// </div> -// ); -// } -// } - -@observer -class HideBtn extends Component<{ treeNode: TreeNode }> { - shouldComponentUpdate() { - return false; - } - - render() { - const { treeNode } = this.props; - return ( - <div - className="tree-node-hide-btn" - onClick={(e) => { - e.stopPropagation(); - emitOutlineEvent(treeNode.hidden ? 'show' : 'hide', treeNode); - treeNode.setHidden(!treeNode.hidden); - }} - > - {treeNode.hidden ? <IconEyeClose /> : <IconEye />} - <Tip>{treeNode.hidden ? intl('Show') : intl('Hide')}</Tip> - </div> - ); - } -} - -@observer -class ExpandBtn extends Component<{ treeNode: TreeNode }> { - shouldComponentUpdate() { - return false; - } - - render() { - const { treeNode } = this.props; - if (!treeNode.expandable) { - return <i className="tree-node-expand-placeholder" />; - } - return ( - <div - className="tree-node-expand-btn" - onClick={(e) => { - if (treeNode.expanded) { - e.stopPropagation(); - } - emitOutlineEvent(treeNode.expanded ? 'collapse' : 'expand', treeNode); - treeNode.setExpanded(!treeNode.expanded); - }} - > - <IconArrowRight size="small" /> - </div> - ); - } -} - -/* -interface Point { - clientX: number; - clientY: number; -} - -function setCaret(point: Point) { - debugger; - const range = getRangeFromPoint(point); - if (range) { - selectRange(range); - setTimeout(() => selectRange(range), 1); - } -} - -function getRangeFromPoint(point: Point): Range | undefined { - const x = point.clientX; - const y = point.clientY; - let range; - let pos: CaretPosition | null = null; - if (document.caretRangeFromPoint) { - range = document.caretRangeFromPoint(x, y); - } else if ((pos = document.caretPositionFromPoint(x, y))) { - range = document.createRange(); - range.setStart(pos.offsetNode, pos.offset); - range.collapse(true); - - } - return range; -} - -function selectRange(range: Range) { - const selection = document.getSelection(); - if (selection) { - selection.removeAllRanges(); - selection.addRange(range); - } -} - -function setCaretAfter(elem) { - const range = document.createRange(); - const node = elem.lastChild; - if (!node) return; - range.setStartAfter(node); - range.setEndAfter(node); - selectRange(range); -} -*/ diff --git a/packages/plugin-outline-pane/src/views/tree.tsx b/packages/plugin-outline-pane/src/views/tree.tsx deleted file mode 100644 index 4f7871e96..000000000 --- a/packages/plugin-outline-pane/src/views/tree.tsx +++ /dev/null @@ -1,165 +0,0 @@ -import { Component, MouseEvent as ReactMouseEvent } from 'react'; -import { observer, Editor, globalContext } from '@ali/lowcode-editor-core'; -import { isRootNode, Node, DragObjectType, isShaken } from '@ali/lowcode-designer'; -import { isFormEvent } from '@ali/lowcode-utils'; -import { Tree } from '../tree'; -import RootTreeNodeView from './root-tree-node'; - -function getTreeNodeIdByEvent(e: ReactMouseEvent, stop: Element): null | string { - let target: Element | null = e.target as Element; - if (!target || !stop.contains(target)) { - return null; - } - target = target.closest('[data-id]'); - if (!target || !stop.contains(target)) { - return null; - } - - return (target as HTMLDivElement).dataset.id || null; -} - -@observer -export default class TreeView extends Component<{ tree: Tree }> { - private shell: HTMLDivElement | null = null; - - private hover(e: ReactMouseEvent) { - const { tree } = this.props; - - const doc = tree.document; - const { detecting } = doc.designer; - if (!detecting.enable) { - return; - } - const node = this.getTreeNodeFromEvent(e)?.node; - detecting.capture(node || null); - } - - private onClick = (e: ReactMouseEvent) => { - if (this.ignoreUpSelected) { - this.boostEvent = undefined; - return; - } - if (this.boostEvent && isShaken(this.boostEvent, e.nativeEvent)) { - this.boostEvent = undefined; - return; - } - this.boostEvent = undefined; - const treeNode = this.getTreeNodeFromEvent(e); - if (!treeNode) { - return; - } - const { node } = treeNode; - const { designer } = treeNode; - const doc = node.document; - const { selection } = doc; - const { id } = node; - const isMulti = e.metaKey || e.ctrlKey || e.shiftKey; - designer.activeTracker.track(node); - if (isMulti && !isRootNode(node) && selection.has(id)) { - if (!isFormEvent(e.nativeEvent)) { - selection.remove(id); - } - } else { - selection.select(id); - const editor = globalContext.get(Editor); - const selectedNode = designer.currentSelection?.getNodes()?.[0]; - const npm = selectedNode?.componentMeta?.npm; - const selected = - [npm?.package, npm?.componentName].filter((item) => !!item).join('-') || - selectedNode?.componentMeta?.componentName || - ''; - editor?.emit('outlinePane.select', { - selected, - }); - } - }; - - private onMouseOver = (e: ReactMouseEvent) => { - this.hover(e); - }; - - private getTreeNodeFromEvent(e: ReactMouseEvent) { - if (!this.shell) { - return; - } - const id = getTreeNodeIdByEvent(e, this.shell); - if (!id) { - return; - } - - const { tree } = this.props; - return tree.getTreeNodeById(id); - } - - private ignoreUpSelected = false; - - private boostEvent?: MouseEvent; - - private onMouseDown = (e: ReactMouseEvent) => { - if (isFormEvent(e.nativeEvent)) { - return; - } - const treeNode = this.getTreeNodeFromEvent(e); - if (!treeNode) { - return; - } - - const { node } = treeNode; - const { designer } = treeNode; - const doc = node.document; - const { selection } = doc; - - // TODO: shift selection - const isMulti = e.metaKey || e.ctrlKey || e.shiftKey; - const isLeftButton = e.button === 0; - - if (isLeftButton && !isRootNode(node)) { - let nodes: Node[] = [node]; - this.ignoreUpSelected = false; - if (isMulti) { - // multi select mode, directily add - if (!selection.has(node.id)) { - designer.activeTracker.track(node); - selection.add(node.id); - this.ignoreUpSelected = true; - } - selection.remove(doc.rootNode.id); - // 获得顶层 nodes - nodes = selection.getTopNodes(); - } else if (selection.has(node.id)) { - nodes = selection.getTopNodes(); - } - this.boostEvent = e.nativeEvent; - designer.dragon.boost( - { - type: DragObjectType.Node, - nodes, - }, - this.boostEvent, - ); - } - }; - - private onMouseLeave = () => { - const { tree } = this.props; - const doc = tree.document; - doc.designer.detecting.leave(doc); - }; - - render() { - const { tree } = this.props; - const { root } = tree; - return ( - <div - className="lc-outline-tree" - ref={(shell) => { this.shell = shell; }} - onMouseDownCapture={this.onMouseDown} - onMouseOver={this.onMouseOver} - onClick={this.onClick} - onMouseLeave={this.onMouseLeave} - > - <RootTreeNodeView key={root.id} treeNode={root} /> - </div> - ); - } -} diff --git a/packages/plugin-outline-pane/tsconfig.json b/packages/plugin-outline-pane/tsconfig.json deleted file mode 100644 index af656bc8f..000000000 --- a/packages/plugin-outline-pane/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/", - ] -} diff --git a/packages/plugin-sample-logo/CHANGELOG.md b/packages/plugin-sample-logo/CHANGELOG.md deleted file mode 100644 index e826876f5..000000000 --- a/packages/plugin-sample-logo/CHANGELOG.md +++ /dev/null @@ -1,472 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -<a name="1.0.21"></a> -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.20...@ali/lowcode-plugin-sample-logo@1.0.21) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.20"></a> -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.19...@ali/lowcode-plugin-sample-logo@1.0.20) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.19"></a> -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.18...@ali/lowcode-plugin-sample-logo@1.0.19) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.18"></a> -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.17...@ali/lowcode-plugin-sample-logo@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.17"></a> -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.16...@ali/lowcode-plugin-sample-logo@1.0.17) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.16"></a> -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.15...@ali/lowcode-plugin-sample-logo@1.0.16) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.15"></a> -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.14...@ali/lowcode-plugin-sample-logo@1.0.15) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.14"></a> -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.13...@ali/lowcode-plugin-sample-logo@1.0.14) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.13"></a> -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.12...@ali/lowcode-plugin-sample-logo@1.0.13) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.12"></a> -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.11...@ali/lowcode-plugin-sample-logo@1.0.12) (2020-10-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.11"></a> -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.10...@ali/lowcode-plugin-sample-logo@1.0.11) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.10"></a> -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.9...@ali/lowcode-plugin-sample-logo@1.0.10) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.9"></a> -## [1.0.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.8...@ali/lowcode-plugin-sample-logo@1.0.9) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.8"></a> -## [1.0.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.8-0...@ali/lowcode-plugin-sample-logo@1.0.8) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.8-0"></a> -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.33...@ali/lowcode-plugin-sample-logo@1.0.8-0) (2020-09-09) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) - - - - -<a name="0.8.33"></a> -## [0.8.33](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.32...@ali/lowcode-plugin-sample-logo@0.8.33) (2020-09-03) -<a name="1.0.7-0"></a> -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.6-0...@ali/lowcode-plugin-sample-logo@1.0.7-0) (2020-09-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.32"></a> -## [0.8.32](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.31...@ali/lowcode-plugin-sample-logo@0.8.32) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo -<a name="1.0.6-0"></a> -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.31...@ali/lowcode-plugin-sample-logo@1.0.6-0) (2020-09-02) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) - - - - -<a name="1.0.5-0"></a> -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.4-0...@ali/lowcode-plugin-sample-logo@1.0.5-0) (2020-08-20) - -<a name="0.8.31"></a> -## [0.8.31](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.30...@ali/lowcode-plugin-sample-logo@0.8.31) (2020-08-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.30"></a> -## [0.8.30](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.29...@ali/lowcode-plugin-sample-logo@0.8.30) (2020-08-24) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.29"></a> -## [0.8.29](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.28...@ali/lowcode-plugin-sample-logo@0.8.29) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.4-0"></a> -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.3-0...@ali/lowcode-plugin-sample-logo@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.3-0"></a> -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.2-0...@ali/lowcode-plugin-sample-logo@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.2-0"></a> -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@1.0.1-0...@ali/lowcode-plugin-sample-logo@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.1-0"></a> -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.28...@ali/lowcode-plugin-sample-logo@1.0.1-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="1.0.0"></a> -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.13.0...@ali/lowcode-plugin-sample-logo@1.0.0) (2020-08-17) -<a name="0.8.28"></a> -## [0.8.28](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.27...@ali/lowcode-plugin-sample-logo@0.8.28) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.13.0"></a> -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.12.0...@ali/lowcode-plugin-sample-logo@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.12.0"></a> -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.10.0...@ali/lowcode-plugin-sample-logo@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.11.0"></a> -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.10.0...@ali/lowcode-plugin-sample-logo@0.11.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.10.0"></a> -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.9.0...@ali/lowcode-plugin-sample-logo@0.10.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.9.0"></a> -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.26...@ali/lowcode-plugin-sample-logo@0.9.0) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.26"></a> -## [0.8.26](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.25...@ali/lowcode-plugin-sample-logo@0.8.26) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.25"></a> -## [0.8.25](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.23...@ali/lowcode-plugin-sample-logo@0.8.25) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.24"></a> -## [0.8.24](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.23...@ali/lowcode-plugin-sample-logo@0.8.24) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.23"></a> -## [0.8.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.22...@ali/lowcode-plugin-sample-logo@0.8.23) (2020-07-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.22"></a> -## [0.8.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.21...@ali/lowcode-plugin-sample-logo@0.8.22) (2020-07-22) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.21"></a> -## [0.8.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.20...@ali/lowcode-plugin-sample-logo@0.8.21) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.20"></a> -## [0.8.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.19...@ali/lowcode-plugin-sample-logo@0.8.20) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.19"></a> -## [0.8.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.18...@ali/lowcode-plugin-sample-logo@0.8.19) (2020-07-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.18"></a> -## [0.8.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.17...@ali/lowcode-plugin-sample-logo@0.8.18) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.17"></a> -## [0.8.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.16...@ali/lowcode-plugin-sample-logo@0.8.17) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.16"></a> -## [0.8.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.15...@ali/lowcode-plugin-sample-logo@0.8.16) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.15"></a> -## [0.8.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.14...@ali/lowcode-plugin-sample-logo@0.8.15) (2020-06-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.14"></a> -## [0.8.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.13...@ali/lowcode-plugin-sample-logo@0.8.14) (2020-05-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.13"></a> -## [0.8.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.12...@ali/lowcode-plugin-sample-logo@0.8.13) (2020-05-18) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.12"></a> -## [0.8.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.11...@ali/lowcode-plugin-sample-logo@0.8.12) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.11"></a> -## [0.8.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.10...@ali/lowcode-plugin-sample-logo@0.8.11) (2020-05-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.10"></a> -## [0.8.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.9...@ali/lowcode-plugin-sample-logo@0.8.10) (2020-05-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.9"></a> -## [0.8.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.8...@ali/lowcode-plugin-sample-logo@0.8.9) (2020-05-07) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.8"></a> -## [0.8.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.7...@ali/lowcode-plugin-sample-logo@0.8.8) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.7"></a> -## [0.8.7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.6...@ali/lowcode-plugin-sample-logo@0.8.7) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.6"></a> -## [0.8.6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.5...@ali/lowcode-plugin-sample-logo@0.8.6) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.5"></a> -## [0.8.5](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.4...@ali/lowcode-plugin-sample-logo@0.8.5) (2020-04-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.4"></a> -## [0.8.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.3...@ali/lowcode-plugin-sample-logo@0.8.4) (2020-04-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.3"></a> -## [0.8.3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-logo@0.8.2...@ali/lowcode-plugin-sample-logo@0.8.3) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.2"></a> -## 0.8.2 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo - -<a name="0.8.1"></a> -## 0.8.1 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-logo diff --git a/packages/plugin-sample-logo/README.md b/packages/plugin-sample-logo/README.md deleted file mode 100644 index f9d7cf6f6..000000000 --- a/packages/plugin-sample-logo/README.md +++ /dev/null @@ -1,3 +0,0 @@ -## todo - -Sample logo plugin diff --git a/packages/plugin-sample-logo/build.json b/packages/plugin-sample-logo/build.json deleted file mode 100644 index bd5cf18dd..000000000 --- a/packages/plugin-sample-logo/build.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "plugins": [ - "build-plugin-component" - ] -} diff --git a/packages/plugin-sample-logo/package.json b/packages/plugin-sample-logo/package.json deleted file mode 100644 index 60475588d..000000000 --- a/packages/plugin-sample-logo/package.json +++ /dev/null @@ -1,35 +0,0 @@ -{ - "name": "@ali/lowcode-plugin-sample-logo", - "version": "1.0.21", - "description": "alibaba lowcode editor logo plugin", - "files": [ - "es/", - "lib/" - ], - "main": "lib/index.js", - "module": "es/index.js", - "stylePath": "style.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "keywords": [ - "lowcode", - "editor" - ], - "author": "xiayang.xy", - "dependencies": { - "@ali/lowcode-editor-core": "^1.0.22", - "react": "^16.8.1" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.18", - "@types/react": "^16.9.13", - "@types/react-dom": "^16.9.4", - "build-plugin-component": "^0.2.10" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/plugin-sample-logo/src/index.scss b/packages/plugin-sample-logo/src/index.scss deleted file mode 100644 index 39df8743e..000000000 --- a/packages/plugin-sample-logo/src/index.scss +++ /dev/null @@ -1,11 +0,0 @@ -.lowcode-plugin-logo { - .logo { - display: block; - width: 32px; - height: 32px; - cursor: pointer; - background-size: contain; - background-position: center; - background-repeat: no-repeat; - } -} diff --git a/packages/plugin-sample-logo/src/index.tsx b/packages/plugin-sample-logo/src/index.tsx deleted file mode 100644 index 4170481fc..000000000 --- a/packages/plugin-sample-logo/src/index.tsx +++ /dev/null @@ -1,18 +0,0 @@ -import React from 'react'; -import './index.scss'; -import { PluginProps } from '@ali/lowcode-types'; - -export interface IProps { - logo?: string; - href?: string; -} - -const Logo: React.FC<IProps & PluginProps> = (props): React.ReactElement => { - return ( - <div className="lowcode-plugin-logo"> - <a className="logo" target="blank" href={props.href || '/'} style={{ backgroundImage: `url(${props.logo})` }} /> - </div> - ); -}; - -export default Logo; diff --git a/packages/plugin-sample-logo/tsconfig.json b/packages/plugin-sample-logo/tsconfig.json deleted file mode 100644 index c37b76ecc..000000000 --- a/packages/plugin-sample-logo/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -} diff --git a/packages/plugin-sample-preview/CHANGELOG.md b/packages/plugin-sample-preview/CHANGELOG.md deleted file mode 100644 index 4fd6dfede..000000000 --- a/packages/plugin-sample-preview/CHANGELOG.md +++ /dev/null @@ -1,706 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -<a name="1.0.21"></a> -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.20...@ali/lowcode-plugin-sample-preview@1.0.21) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.20"></a> -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.19...@ali/lowcode-plugin-sample-preview@1.0.20) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.19"></a> -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.18...@ali/lowcode-plugin-sample-preview@1.0.19) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.18"></a> -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.17...@ali/lowcode-plugin-sample-preview@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.17"></a> -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.16...@ali/lowcode-plugin-sample-preview@1.0.17) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.16"></a> -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.15...@ali/lowcode-plugin-sample-preview@1.0.16) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.15"></a> -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.14...@ali/lowcode-plugin-sample-preview@1.0.15) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.14"></a> -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.13...@ali/lowcode-plugin-sample-preview@1.0.14) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.13"></a> -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.12...@ali/lowcode-plugin-sample-preview@1.0.13) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.12"></a> -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.11...@ali/lowcode-plugin-sample-preview@1.0.12) (2020-10-20) - - -### Bug Fixes - -* 合并分支 ([add2f23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/add2f23)) -* fix array and sourceeditor bugs ([26b8b2c](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/26b8b2c)) - - - - -<a name="1.0.11"></a> -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.10...@ali/lowcode-plugin-sample-preview@1.0.11) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.10"></a> -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.9...@ali/lowcode-plugin-sample-preview@1.0.10) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.9"></a> -## [1.0.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.8...@ali/lowcode-plugin-sample-preview@1.0.9) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.8"></a> -## [1.0.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.8-0...@ali/lowcode-plugin-sample-preview@1.0.8) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.8-0"></a> -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.59...@ali/lowcode-plugin-sample-preview@1.0.8-0) (2020-09-09) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) -* schema should be componentsTree ([69a2a89](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/69a2a89)) - - -### Features - -* load assets for preview ([5376469](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/5376469)) -* plugin preview ([18f149e](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/18f149e)) -* support components ([d72c0d1](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/d72c0d1)) - - - - -<a name="1.0.7-0"></a> -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.6-0...@ali/lowcode-plugin-sample-preview@1.0.7-0) (2020-09-02) - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview -<a name="1.0.6-0"></a> -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.56...@ali/lowcode-plugin-sample-preview@1.0.6-0) (2020-09-02) - -<a name="0.8.59"></a> -## [0.8.59](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.58...@ali/lowcode-plugin-sample-preview@0.8.59) (2020-09-08) - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.58"></a> -## [0.8.58](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.57...@ali/lowcode-plugin-sample-preview@0.8.58) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.57"></a> -## [0.8.57](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.56...@ali/lowcode-plugin-sample-preview@0.8.57) (2020-09-03) - - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) -* schema should be componentsTree ([69a2a89](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/69a2a89)) - - -### Features - -* load assets for preview ([5376469](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/5376469)) -* plugin preview ([18f149e](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/18f149e)) -* support components ([d72c0d1](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/d72c0d1)) - - - - -<a name="1.0.5-0"></a> -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.4-0...@ali/lowcode-plugin-sample-preview@1.0.5-0) (2020-08-20) - -<a name="0.8.56"></a> -## [0.8.56](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.55...@ali/lowcode-plugin-sample-preview@0.8.56) (2020-08-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.55"></a> -## [0.8.55](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.54...@ali/lowcode-plugin-sample-preview@0.8.55) (2020-08-26) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.54"></a> -## [0.8.54](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.53...@ali/lowcode-plugin-sample-preview@0.8.54) (2020-08-24) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.53"></a> -## [0.8.53](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.52...@ali/lowcode-plugin-sample-preview@0.8.53) (2020-08-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.52"></a> -## [0.8.52](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.51...@ali/lowcode-plugin-sample-preview@0.8.52) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.4-0"></a> -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.3-0...@ali/lowcode-plugin-sample-preview@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.3-0"></a> -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.2-0...@ali/lowcode-plugin-sample-preview@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.2-0"></a> -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@1.0.1-0...@ali/lowcode-plugin-sample-preview@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="1.0.1-0"></a> -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.51...@ali/lowcode-plugin-sample-preview@1.0.1-0) (2020-08-20) - - -### Bug Fixes - -* schema should be componentsTree ([69a2a89](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/69a2a89)) - - -### Features - -* load assets for preview ([5376469](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/5376469)) -* plugin preview ([18f149e](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/18f149e)) -* support components ([d72c0d1](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/d72c0d1)) - - - - -<a name="1.0.0"></a> -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.15.0...@ali/lowcode-plugin-sample-preview@1.0.0) (2020-08-17) -<a name="0.8.51"></a> -## [0.8.51](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.50...@ali/lowcode-plugin-sample-preview@0.8.51) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.50"></a> -## [0.8.50](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.49...@ali/lowcode-plugin-sample-preview@0.8.50) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.49"></a> -## [0.8.49](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.48...@ali/lowcode-plugin-sample-preview@0.8.49) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.48"></a> -## [0.8.48](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.47...@ali/lowcode-plugin-sample-preview@0.8.48) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.47"></a> -## [0.8.47](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.46...@ali/lowcode-plugin-sample-preview@0.8.47) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.15.0"></a> -# [0.15.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.14.0...@ali/lowcode-plugin-sample-preview@0.15.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.14.0"></a> -# [0.14.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.12.0...@ali/lowcode-plugin-sample-preview@0.14.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.13.0"></a> -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.12.0...@ali/lowcode-plugin-sample-preview@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.12.0"></a> -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.11.0...@ali/lowcode-plugin-sample-preview@0.12.0) (2020-08-16) - - -### Features - -* load assets for preview ([5376469](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/5376469)) - - - - -<a name="0.11.0"></a> -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.10.0...@ali/lowcode-plugin-sample-preview@0.11.0) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.10.0"></a> -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.9.0...@ali/lowcode-plugin-sample-preview@0.10.0) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.9.0"></a> -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.41...@ali/lowcode-plugin-sample-preview@0.9.0) (2020-08-14) - - -### Bug Fixes - -* schema should be componentsTree ([69a2a89](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/69a2a89)) - - -### Features - -* plugin preview ([18f149e](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/18f149e)) -* support components ([d72c0d1](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/d72c0d1)) - - - - -<a name="0.8.41"></a> -## [0.8.41](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.40...@ali/lowcode-plugin-sample-preview@0.8.41) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.40"></a> -## [0.8.40](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.38...@ali/lowcode-plugin-sample-preview@0.8.40) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.39"></a> -## [0.8.39](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.38...@ali/lowcode-plugin-sample-preview@0.8.39) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.38"></a> -## [0.8.38](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.37...@ali/lowcode-plugin-sample-preview@0.8.38) (2020-07-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.37"></a> -## [0.8.37](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.36...@ali/lowcode-plugin-sample-preview@0.8.37) (2020-07-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.36"></a> -## [0.8.36](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.35...@ali/lowcode-plugin-sample-preview@0.8.36) (2020-07-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.35"></a> -## [0.8.35](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.34...@ali/lowcode-plugin-sample-preview@0.8.35) (2020-07-22) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.34"></a> -## [0.8.34](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.33...@ali/lowcode-plugin-sample-preview@0.8.34) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.33"></a> -## [0.8.33](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.32...@ali/lowcode-plugin-sample-preview@0.8.33) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.32"></a> -## [0.8.32](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.31...@ali/lowcode-plugin-sample-preview@0.8.32) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.31"></a> -## [0.8.31](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.30...@ali/lowcode-plugin-sample-preview@0.8.31) (2020-07-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.30"></a> -## [0.8.30](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.29...@ali/lowcode-plugin-sample-preview@0.8.30) (2020-07-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.29"></a> -## [0.8.29](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.28...@ali/lowcode-plugin-sample-preview@0.8.29) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.28"></a> -## [0.8.28](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.27...@ali/lowcode-plugin-sample-preview@0.8.28) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.27"></a> -## [0.8.27](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.26...@ali/lowcode-plugin-sample-preview@0.8.27) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.26"></a> -## [0.8.26](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.25...@ali/lowcode-plugin-sample-preview@0.8.26) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.25"></a> -## [0.8.25](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.24...@ali/lowcode-plugin-sample-preview@0.8.25) (2020-06-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.24"></a> -## [0.8.24](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.23...@ali/lowcode-plugin-sample-preview@0.8.24) (2020-06-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.23"></a> -## [0.8.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.22...@ali/lowcode-plugin-sample-preview@0.8.23) (2020-05-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.22"></a> -## [0.8.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.21...@ali/lowcode-plugin-sample-preview@0.8.22) (2020-05-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.21"></a> -## [0.8.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.20...@ali/lowcode-plugin-sample-preview@0.8.21) (2020-05-18) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.20"></a> -## [0.8.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.19...@ali/lowcode-plugin-sample-preview@0.8.20) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.19"></a> -## [0.8.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.18...@ali/lowcode-plugin-sample-preview@0.8.19) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.18"></a> -## [0.8.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.17...@ali/lowcode-plugin-sample-preview@0.8.18) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.17"></a> -## [0.8.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.16...@ali/lowcode-plugin-sample-preview@0.8.17) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.16"></a> -## [0.8.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.15...@ali/lowcode-plugin-sample-preview@0.8.16) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.15"></a> -## [0.8.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.14...@ali/lowcode-plugin-sample-preview@0.8.15) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.14"></a> -## [0.8.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.13...@ali/lowcode-plugin-sample-preview@0.8.14) (2020-05-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.13"></a> -## [0.8.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.12...@ali/lowcode-plugin-sample-preview@0.8.13) (2020-05-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.12"></a> -## [0.8.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.11...@ali/lowcode-plugin-sample-preview@0.8.12) (2020-05-07) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.11"></a> -## [0.8.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.10...@ali/lowcode-plugin-sample-preview@0.8.11) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.10"></a> -## [0.8.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.9...@ali/lowcode-plugin-sample-preview@0.8.10) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.9"></a> -## [0.8.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.8...@ali/lowcode-plugin-sample-preview@0.8.9) (2020-04-27) - - -### Features - -* preview ([abeb2ba](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/abeb2ba)) - - - - -<a name="0.8.8"></a> -## [0.8.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.7...@ali/lowcode-plugin-sample-preview@0.8.8) (2020-04-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.7"></a> -## [0.8.7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.6...@ali/lowcode-plugin-sample-preview@0.8.7) (2020-04-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.6"></a> -## [0.8.6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.5...@ali/lowcode-plugin-sample-preview@0.8.6) (2020-03-31) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.5"></a> -## [0.8.5](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.4...@ali/lowcode-plugin-sample-preview@0.8.5) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.4"></a> -## [0.8.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.3...@ali/lowcode-plugin-sample-preview@0.8.4) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.3"></a> -## [0.8.3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-sample-preview@0.8.2...@ali/lowcode-plugin-sample-preview@0.8.3) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.2"></a> -## 0.8.2 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview - -<a name="0.8.1"></a> -## 0.8.1 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-sample-preview diff --git a/packages/plugin-sample-preview/README.md b/packages/plugin-sample-preview/README.md deleted file mode 100644 index ae315f1c4..000000000 --- a/packages/plugin-sample-preview/README.md +++ /dev/null @@ -1,3 +0,0 @@ -## todo - -Sample preview plugin diff --git a/packages/plugin-sample-preview/build.json b/packages/plugin-sample-preview/build.json deleted file mode 100644 index e791d5b6b..000000000 --- a/packages/plugin-sample-preview/build.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "plugins": [ - "build-plugin-component", - "build-plugin-fusion", - ["build-plugin-moment-locales", { - "locales": ["zh-cn"] - }] - ] -} diff --git a/packages/plugin-sample-preview/demo/usage.md b/packages/plugin-sample-preview/demo/usage.md deleted file mode 100644 index d053100a0..000000000 --- a/packages/plugin-sample-preview/demo/usage.md +++ /dev/null @@ -1,24 +0,0 @@ ---- -title: 基本使用 -order: 1 ---- - -````jsx -import React, { PureComponent } from 'react'; -import ReactDOM from 'react-dom'; -import SamplePreview from '@ali/lowcode-plugin-sample-preview'; - -class Demo extends PureComponent { - render() { - return ( - <div> - <SamplePreview /> - </div> - ) - } -} - -ReactDOM.render(( - <Demo /> -), mountNode); -```` \ No newline at end of file diff --git a/packages/plugin-sample-preview/package.json b/packages/plugin-sample-preview/package.json deleted file mode 100644 index 62ea7af1c..000000000 --- a/packages/plugin-sample-preview/package.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "name": "@ali/lowcode-plugin-sample-preview", - "version": "1.0.21", - "description": "alibaba lowcode editor sample preview plugin", - "files": [ - "es", - "lib" - ], - "main": "lib/index.js", - "module": "es/index.js", - "scripts": { - "start": "build-scripts start", - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "keywords": [ - "lowcode", - "editor" - ], - "dependencies": { - "@ali/lowcode-designer": "^1.0.22", - "@ali/lowcode-editor-core": "^1.0.22", - "@ali/lowcode-react-renderer": "^1.0.21", - "@ali/lowcode-types": "^1.0.20", - "@ali/lowcode-utils": "^1.0.21", - "@alifd/next": "^1.x", - "react": "^16.8.1" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.3", - "@types/react": "^16.9.13", - "@types/react-dom": "^16.9.4", - "build-plugin-component": "^0.2.11", - "build-plugin-fusion": "^0.1.0", - "build-plugin-moment-locales": "^0.1.0" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/plugin-sample-preview/src/index.scss b/packages/plugin-sample-preview/src/index.scss deleted file mode 100644 index d623acdd5..000000000 --- a/packages/plugin-sample-preview/src/index.scss +++ /dev/null @@ -1,9 +0,0 @@ -.lowcode-plugin-sample-preview { - padding: 10px 4px; -} - -.lowcode-plugin-sample-preview-content { - width: 80vw; - height: 80vh; - min-height: 300px; -} \ No newline at end of file diff --git a/packages/plugin-sample-preview/src/index.tsx b/packages/plugin-sample-preview/src/index.tsx deleted file mode 100644 index 9363228aa..000000000 --- a/packages/plugin-sample-preview/src/index.tsx +++ /dev/null @@ -1,79 +0,0 @@ -import React, { useState } from 'react'; -import { Button, Dialog } from '@alifd/next'; -import { PluginProps } from '@ali/lowcode-types'; -import { Designer } from '@ali/lowcode-designer'; -import { buildComponents, assetBundle, AssetList, AssetLevel, AssetLoader } from '@ali/lowcode-utils'; -import ReactRenderer from '@ali/lowcode-react-renderer'; -import './index.scss'; - -const SamplePreview = ({ editor }: PluginProps) => { - const [data, setData] = useState({}); - const [visible, setVisible] = useState(false); - async function handleClick() { - if (!editor) { - return; - } - // 由于monaco editor的cdn加载形式会占用define字段,导致预览的时候部分next组件加载异常,所以预览弹框的时候需要对define做一个临时的替换 - window.__define = window.define; - window.define = null; - const designer = editor.get(Designer); - if (designer) { - const assets = await editor.get('assets'); - const { packages } = assets; - const { componentsMap, schema } = designer; - - console.info('save schema:', designer, assets); - - const libraryMap = {}; - const libraryAsset: AssetList = []; - packages.forEach(({ package, library, urls }) => { - libraryMap[package] = library; - if (urls) { - libraryAsset.push(urls); - } - }); - - const vendors = [ - assetBundle(libraryAsset, AssetLevel.Library), - ]; - console.log('libraryMap&vendors', libraryMap, vendors); - - // TODO asset may cause pollution - const assetLoader = new AssetLoader(); - await assetLoader.load(libraryAsset); - const components = buildComponents(libraryMap, componentsMap); - console.log('components', components); - - setData({ - schema: schema.componentsTree[0], - components, - }); - setVisible(true); - - - } - } - - function handleClose() { - window.define = window.__define; - setVisible(false); - - - } - - const { schema, components } = data; - return ( - <div className="lowcode-plugin-sample-preview"> - <Button type="primary" onClick={handleClick}> - 预览 - </Button> - <Dialog visible={visible} footer={false} onClose={handleClose}> - {visible && - <ReactRenderer className="lowcode-plugin-sample-preview-content" schema={schema} components={components} /> - } - </Dialog> - </div> - ); -}; - -export default SamplePreview; diff --git a/packages/plugin-sample-preview/tsconfig.json b/packages/plugin-sample-preview/tsconfig.json deleted file mode 100644 index c37b76ecc..000000000 --- a/packages/plugin-sample-preview/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -} diff --git a/packages/plugin-source-editor/CHANGELOG.md b/packages/plugin-source-editor/CHANGELOG.md deleted file mode 100644 index 11f9643d1..000000000 --- a/packages/plugin-source-editor/CHANGELOG.md +++ /dev/null @@ -1,497 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -<a name="1.0.20"></a> -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.19...@ali/lowcode-plugin-source-editor@1.0.20) (2020-11-16) - - -### Bug Fixes - -* js编辑器移除尾逗号 ([7cd5c5c](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/7cd5c5c)) - - - - -<a name="1.0.19"></a> -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.18...@ali/lowcode-plugin-source-editor@1.0.19) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.18"></a> -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.17...@ali/lowcode-plugin-source-editor@1.0.18) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.17"></a> -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.16...@ali/lowcode-plugin-source-editor@1.0.17) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.16"></a> -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.15...@ali/lowcode-plugin-source-editor@1.0.16) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.15"></a> -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.14...@ali/lowcode-plugin-source-editor@1.0.15) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.14"></a> -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.13...@ali/lowcode-plugin-source-editor@1.0.14) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.13"></a> -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.12...@ali/lowcode-plugin-source-editor@1.0.13) (2020-11-04) - - -### Bug Fixes - -* 修复编辑器转化bug,增加窗口最大最小化功能 ([05666af](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/05666af)) - - -### Features - -* style 迁移 ([6ce97da](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/6ce97da)) - - - - -<a name="1.0.12"></a> -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.12...@ali/lowcode-plugin-source-editor@1.0.12) (2020-11-02) - - -### Bug Fixes - -* 修复编辑器转化bug,增加窗口最大最小化功能 ([05666af](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/05666af)) - - -### Features - -* style 迁移 ([6ce97da](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/6ce97da)) - - - - -<a name="1.0.12"></a> -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.11...@ali/lowcode-plugin-source-editor@1.0.12) (2020-10-20) - - -### Bug Fixes - -* 合并分支 ([add2f23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/add2f23)) -* fix array and sourceeditor bugs ([26b8b2c](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/26b8b2c)) - - - - -<a name="1.0.11"></a> -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.10...@ali/lowcode-plugin-source-editor@1.0.11) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.10"></a> -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.9...@ali/lowcode-plugin-source-editor@1.0.10) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.9"></a> -## [1.0.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.8...@ali/lowcode-plugin-source-editor@1.0.9) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.8"></a> -## [1.0.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.8-0...@ali/lowcode-plugin-source-editor@1.0.8) (2020-09-28) - - -### Bug Fixes - -* source-editor bug & exp-setter bug ([5cd88d4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/5cd88d4)) - - -### Features - -* 新增class-name setter ([a9f1131](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/a9f1131)) - - - - -<a name="1.0.8-0"></a> -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.31...@ali/lowcode-plugin-source-editor@1.0.8-0) (2020-09-09) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) -* 修改js面板的保存schema问题 ([0ee8892](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/0ee8892)) -* fix source edit bug ([047247c](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/047247c)) - - - - -<a name="0.8.31"></a> -## [0.8.31](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.30...@ali/lowcode-plugin-source-editor@0.8.31) (2020-09-03) -<a name="1.0.7-0"></a> -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.6-0...@ali/lowcode-plugin-source-editor@1.0.7-0) (2020-09-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.30"></a> -## [0.8.30](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.29...@ali/lowcode-plugin-source-editor@0.8.30) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor -<a name="1.0.6-0"></a> -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.29...@ali/lowcode-plugin-source-editor@1.0.6-0) (2020-09-02) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) -* 修改js面板的保存schema问题 ([0ee8892](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/0ee8892)) -* fix source edit bug ([047247c](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/047247c)) - - - - -<a name="1.0.5-0"></a> -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.4-0...@ali/lowcode-plugin-source-editor@1.0.5-0) (2020-08-20) - -<a name="0.8.29"></a> -## [0.8.29](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.28...@ali/lowcode-plugin-source-editor@0.8.29) (2020-08-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.28"></a> -## [0.8.28](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.27...@ali/lowcode-plugin-source-editor@0.8.28) (2020-08-24) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.27"></a> -## [0.8.27](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.26...@ali/lowcode-plugin-source-editor@0.8.27) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.4-0"></a> -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.3-0...@ali/lowcode-plugin-source-editor@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.3-0"></a> -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.2-0...@ali/lowcode-plugin-source-editor@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.2-0"></a> -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@1.0.1-0...@ali/lowcode-plugin-source-editor@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="1.0.1-0"></a> -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.26...@ali/lowcode-plugin-source-editor@1.0.1-0) (2020-08-20) - - -### Bug Fixes - -* fix source edit bug ([047247c](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/047247c)) - - - - -<a name="1.0.0"></a> -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.13.0...@ali/lowcode-plugin-source-editor@1.0.0) (2020-08-17) -<a name="0.8.26"></a> -## [0.8.26](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.25...@ali/lowcode-plugin-source-editor@0.8.26) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.13.0"></a> -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.12.0...@ali/lowcode-plugin-source-editor@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.12.0"></a> -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.10.0...@ali/lowcode-plugin-source-editor@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.11.0"></a> -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.10.0...@ali/lowcode-plugin-source-editor@0.11.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.10.0"></a> -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.9.0...@ali/lowcode-plugin-source-editor@0.10.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.9.0"></a> -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.24...@ali/lowcode-plugin-source-editor@0.9.0) (2020-08-14) - - -### Bug Fixes - -* fix source edit bug ([047247c](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/047247c)) - - - - -<a name="0.8.24"></a> -## [0.8.24](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.23...@ali/lowcode-plugin-source-editor@0.8.24) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.23"></a> -## [0.8.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.21...@ali/lowcode-plugin-source-editor@0.8.23) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.22"></a> -## [0.8.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.21...@ali/lowcode-plugin-source-editor@0.8.22) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.21"></a> -## [0.8.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.20...@ali/lowcode-plugin-source-editor@0.8.21) (2020-07-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.20"></a> -## [0.8.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.19...@ali/lowcode-plugin-source-editor@0.8.20) (2020-07-22) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.19"></a> -## [0.8.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.18...@ali/lowcode-plugin-source-editor@0.8.19) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.18"></a> -## [0.8.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.17...@ali/lowcode-plugin-source-editor@0.8.18) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.17"></a> -## [0.8.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.16...@ali/lowcode-plugin-source-editor@0.8.17) (2020-07-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.16"></a> -## [0.8.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.15...@ali/lowcode-plugin-source-editor@0.8.16) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.15"></a> -## [0.8.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.14...@ali/lowcode-plugin-source-editor@0.8.15) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.14"></a> -## [0.8.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.13...@ali/lowcode-plugin-source-editor@0.8.14) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.13"></a> -## [0.8.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.12...@ali/lowcode-plugin-source-editor@0.8.13) (2020-06-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.12"></a> -## [0.8.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.11...@ali/lowcode-plugin-source-editor@0.8.12) (2020-05-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.11"></a> -## [0.8.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.10...@ali/lowcode-plugin-source-editor@0.8.11) (2020-05-18) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.10"></a> -## [0.8.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.9...@ali/lowcode-plugin-source-editor@0.8.10) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.9"></a> -## [0.8.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.8...@ali/lowcode-plugin-source-editor@0.8.9) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.8"></a> -## [0.8.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.7...@ali/lowcode-plugin-source-editor@0.8.8) (2020-05-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.7"></a> -## [0.8.7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.6...@ali/lowcode-plugin-source-editor@0.8.7) (2020-05-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.6"></a> -## [0.8.6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.5...@ali/lowcode-plugin-source-editor@0.8.6) (2020-05-07) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.5"></a> -## [0.8.5](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.4...@ali/lowcode-plugin-source-editor@0.8.5) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.4"></a> -## [0.8.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-source-editor@0.8.3...@ali/lowcode-plugin-source-editor@0.8.4) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.3"></a> -## 0.8.3 (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.2"></a> -## [0.8.2](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.1...@ali/lowcode-plugin-variable-bind-dialog@0.8.2) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor - -<a name="0.8.1"></a> -## 0.8.1 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-source-editor diff --git a/packages/plugin-source-editor/README.md b/packages/plugin-source-editor/README.md deleted file mode 100644 index 8a6fb13f0..000000000 --- a/packages/plugin-source-editor/README.md +++ /dev/null @@ -1 +0,0 @@ -## todo diff --git a/packages/plugin-source-editor/build.json b/packages/plugin-source-editor/build.json deleted file mode 100644 index e791d5b6b..000000000 --- a/packages/plugin-source-editor/build.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "plugins": [ - "build-plugin-component", - "build-plugin-fusion", - ["build-plugin-moment-locales", { - "locales": ["zh-cn"] - }] - ] -} diff --git a/packages/plugin-source-editor/package.json b/packages/plugin-source-editor/package.json deleted file mode 100644 index 73e763777..000000000 --- a/packages/plugin-source-editor/package.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "name": "@ali/lowcode-plugin-source-editor", - "version": "1.0.20", - "description": "alibaba lowcode editor source-editor plugin", - "files": [ - "es", - "lib" - ], - "main": "lib/index.js", - "module": "es/index.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "keywords": [ - "lowcode", - "editor" - ], - "author": "zude.hzd", - "dependencies": { - "@ali/lowcode-editor-core": "^1.0.22", - "@alifd/next": "^1.19.16", - "js-beautify": "^1.10.1", - "prettier": "^1.18.2", - "react": "^16.8.1", - "react-dom": "^16.8.1", - "react-monaco-editor": "0.40.0" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.3", - "@types/react": "^16.9.13", - "@types/react-dom": "^16.9.4", - "build-plugin-component": "^0.2.7-1", - "build-plugin-fusion": "^0.1.0", - "build-plugin-moment-locales": "^0.1.0" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/plugin-source-editor/src/index.scss b/packages/plugin-source-editor/src/index.scss deleted file mode 100644 index da05d24cf..000000000 --- a/packages/plugin-source-editor/src/index.scss +++ /dev/null @@ -1,66 +0,0 @@ -.source-editor-container{ - height: 100%; - position: relative; - - .next-tabs { - -webkit-box-sizing: border-box; - box-sizing: border-box; - width: 100%; - height: 100%; - } - - .next-tabs-content{ - height: 100%; - } - - .button-container{ - position: absolute; - top: 0px; - right: 10px; - } - - .editor-context-container{ - height: 100%; - width: 100%; - position: absolute; - top: 38px; - - } - - .editor-context{ - height: 100%; - width: 100%; - } - - .next-tabs-tabpane.active { - visibility: visible; - opacity: 1; - height: 100%; - } -} - - -.full-screen-container{ - position: absolute; - top: 0px; - right: 20px; - z-index: 100; - cursor: pointer; - img{ - width: 20px; - height: 20px; - } -} - -.min-screen-container{ - position: absolute; - top: 10px; - right: 150px; - z-index: 100; - cursor: pointer; - img{ - width: 20px; - height: 20px; - } -} - diff --git a/packages/plugin-source-editor/src/index.tsx b/packages/plugin-source-editor/src/index.tsx deleted file mode 100644 index d918c7532..000000000 --- a/packages/plugin-source-editor/src/index.tsx +++ /dev/null @@ -1,372 +0,0 @@ -import React, { Component } from 'react'; -import { Tab, Button, Message } from '@alifd/next'; -import { Editor } from '@ali/lowcode-editor-core'; -import { js_beautify, css_beautify } from 'js-beautify'; -import MonacoEditor from 'react-monaco-editor'; -import * as monaco from 'monaco-editor/esm/vs/editor/editor.main.js'; - -import './index.scss'; -import transfrom from './transform'; - -const TAB_KEY = { - JS_TAB: 'js_tab', - CSS_TAB: 'css_tab', -}; - -const defaultEditorOption = { - width: '100%', - height: '95%', - options: { - readOnly: false, - automaticLayout: true, - folding: true, // 默认开启折叠代码功能 - lineNumbers: 'on', - wordWrap: 'off', - formatOnPaste: true, - fontSize: 12, - tabSize: 2, - scrollBeyondLastLine: false, - fixedOverflowWidgets: false, - snippetSuggestions: 'top', - minimap: { - enabled: false, - }, - scrollbar: { - vertical: 'auto', - horizontal: 'auto', - }, - }, -}; - -interface FunctionEventParam { - functionName: string; -} - -export default class SourceEditor extends Component<{ - editor: Editor; -}> { - private monocoEditor: any; - - private editorCmd: any; - - private editorJsRef = React.createRef(); - - private editorCssRef = React.createRef(); - - private editorNode: any; - - private originSize: { - width: '', - height: '' - }; - - state = { - isShowSaveBtn: true, - visiable: false, - fullScreenStatus: false, - }; - - // eslint-disable-next-line react/no-deprecated - componentWillMount() { - const { editor } = this.props; - - - // 添加函数 - editor.on('sourceEditor.addFunction', (params: FunctionEventParam) => { - this.callEditorEvent('sourceEditor.addFunction', params); - }); - - // 定位函数 - editor.on('sourceEditor.focusByFunction', (params: FunctionEventParam) => { - this.callEditorEvent('sourceEditor.focusByFunction', params); - }); - - // 插件面板关闭事件,监听规则同上 - editor.on('skeleton.panel-dock.unactive', (pluginName) => { - if (pluginName == 'sourceEditor') { - this.saveSchema(); - this.setState({ - visiable: false, - }); - } - }); - - // 插件面板打开事件,监听规则同上 - editor.on('skeleton.panel-dock.active', (pluginName) => { - if (pluginName == 'sourceEditor') { - this.initCode(); - } - }); - - this.initCode(); - } - - - /** - * 执行编辑器事件 - */ - callEditorEvent = (eventName, params) => { - if (!this.monocoEditor) { - this.editorCmd = { - eventName, - params, - }; - return; - } - - if (this.state.selectTab == TAB_KEY.CSS_TAB) { - this.setState({ - selectTab: TAB_KEY.JS_TAB, - }); - } - - this.showJsEditor(); - - if (eventName === 'sourceEditor.addFunction') { - setTimeout(() => { - this.addFunction(params); - }, 100); - } else if (eventName === 'sourceEditor.focusByFunction') { - setTimeout(() => { - this.focusByFunctionName(params); - }, 100); - } - }; - - initCode = () => { - const { editor } = this.props; - const schema = editor.get('designer').project.getSchema(); - const jsCode = js_beautify(transfrom.schema2Code(schema), { indent_size: 2, indent_empty_lines: true }); - let css; - - if (schema.componentsTree[0].css) { - css = css_beautify(schema.componentsTree[0].css, { indent_size: 2 }); - } - - this.setState({ - jsCode, - css, - selectTab: TAB_KEY.JS_TAB, - visiable: true, - fullScreenStatus: false, - }); - }; - - /** - * 在js面板中添加一个新函数 - * @param params - */ - addFunction(params: FunctionEventParam) { - const count = this.monocoEditor.getModel().getLineCount() || 0; - const range = new monaco.Range(count, 1, count, 1); - const functionCode = transfrom.getNewFunctionCode(params.functionName); - this.monocoEditor.executeEdits('log-source', [ - { identifier: 'event_id', range, text: functionCode, forceMoveMarkers: true }, - ]); - - setTimeout(() => { - const newPosition = new monaco.Position(count + 1, 2); - this.monocoEditor.setPosition(newPosition); - this.monocoEditor.focus(); - }, 100); - - this.updateCode(this.monocoEditor.getModel().getValue()); - } - - /** - * 根据函数名进行定位 - * @param functionName - */ - focusByFunctionName(params: FunctionEventParam) { - const { functionName } = params; - const matchedResult = this.monocoEditor - .getModel() - .findMatches(`${functionName}\\s*\\([\\s\\S]*\\)[\\s\\S]*\\{`, false, true)[0]; - if (matchedResult) { - const { monocoEditor } = this; - setTimeout(() => { - monocoEditor.revealLineInCenter(matchedResult.range.startLineNumber); - monocoEditor.setPosition({ - column: matchedResult.range.endColumn, - lineNumber: matchedResult.range.endLineNumber, - }); - monocoEditor.focus(); - }, 100); - } - } - - editorDidMount = (editor) => { - this.monocoEditor = editor; - - if (this.editorCmd) { - this.callEditorEvent(this.editorCmd.eventName, this.editorCmd.params); - } - - setTimeout(() => { - this.editorNode = this.editorJsRef.current; // 记录当前dom节点; - }, 0); - }; - - fullScreen = () => { - console.log(this.editorNode); - document.body.appendChild(this.editorNode); - // this.originSize = { - // width: this.editorNode.clientWidth, - // height: this.editorNode.clientHeight - // } - const fullScreenOption = { - ...defaultEditorOption, - lineNumbers: 'on', - folding: true, - scrollBeyondLastLine: true, - minimap: { - enabled: true, - }, - }; - - this.monocoEditor.layout({ - height: document.body.clientHeight, - width: document.body.clientWidth, - }); - - this.monocoEditor.updateOptions(fullScreenOption); - this.setState({ - fullScreenStatus: true, - }); - }; - - - minScreen = () => { - const listNode = document.getElementById('editor-context-container'); - listNode.insertBefore(this.editorNode, listNode.childNodes[0]); - - const minScreenOption = { - ...defaultEditorOption, - minimap: { - enabled: false, - }, - }; - - - this.monocoEditor.updateOptions(minScreenOption); - this.setState({ - fullScreenStatus: false, - }); - - }; - - onTabChange = (key) => { - const { editor } = this.props; - const schema = editor.get('designer').project.getSchema(); - console.log(schema); - - this.setState({ - selectTab: key, - }); - - if (key === TAB_KEY.JS_TAB) { - this.showJsEditor(); - } else { - this.showCssEditor(); - } - }; - - showJsEditor = () => { - document.getElementById('cssEditorDom').setAttribute('style', 'display:none'); - document.getElementById('jsEditorDom').setAttribute('style', 'block'); - }; - - showCssEditor = () => { - document.getElementById('jsEditorDom').setAttribute('style', 'display:none'); - document.getElementById('cssEditorDom').setAttribute('style', 'block'); - }; - - updateCode = (newCode) => { - const { selectTab } = this.state; - if (selectTab === TAB_KEY.JS_TAB) { - this.setState({ - jsCode: newCode, - }); - } else { - this.setState({ - css: newCode, - }); - } - }; - - - saveSchema = (successFlag?: boolean) => { - const { jsCode, css } = this.state; - const { editor } = this.props; - const functionMap = transfrom.code2Schema(jsCode); - - if (functionMap != null) { - const schema = editor.get('designer').project.getSchema(); - // let oldSchemaStr = JSON.stringify(schema); - const newSchema = transfrom.setFunction2Schema(functionMap, css, schema); - - if (newSchema != '') { - editor.get('designer').project.setSchema(newSchema); - successFlag && Message.success('保存成功'); - } - } - - - }; - - render() { - const { selectTab, jsCode, css, isShowSaveBtn, visiable, fullScreenStatus } = this.state; - const tabs = [ - { tab: 'index.js', key: TAB_KEY.JS_TAB }, - { tab: 'style.css', key: TAB_KEY.CSS_TAB }, - ]; - - - return ( - <div className="source-editor-container"> - - <Tab size="small" shape="wrapped" onChange={this.onTabChange} activeKey={selectTab}> - {tabs.map((item) => ( - <Tab.Item key={item.key} title={item.tab} /> - ))} - </Tab> - { isShowSaveBtn && <div className="button-container"><Button type="primary" onClick={() => this.saveSchema(true)}>保存代码</Button></div>} - { visiable && - <div style={{ height: '100%' }} className="editor-context-container" id="editor-context-container"> - <div id="jsEditorDom" className="editor-context" ref={this.editorJsRef}> - - <MonacoEditor - value={jsCode} - {...defaultEditorOption} - {...{ language: 'javascript' }} - onChange={(newCode) => this.updateCode(newCode)} - editorDidMount={(editor, useMonaco) => this.editorDidMount.call(this, editor, useMonaco, TAB_KEY.JS_TAB)} - /> - - { - !fullScreenStatus ? - <div className="full-screen-container" onClick={this.fullScreen}> - <img src="https://gw.alicdn.com/tfs/TB1d7XqE1T2gK0jSZFvXXXnFXXa-200-200.png" /> - </div> : - <div className="min-screen-container" onClick={this.minScreen}> - <img src="https://gw.alicdn.com/tfs/TB1IIonZHY1gK0jSZTEXXXDQVXa-200-200.png" /> - </div> - } - - </div> - <div className="editor-context" id="cssEditorDom" ref={this.editorCssRef}> - <MonacoEditor - value={css} - {...defaultEditorOption} - {...{ language: 'css' }} - onChange={(newCode) => this.updateCode(newCode)} - // editorDidMount={(editor, monaco) => this.editorDidMount.call(this, editor, monaco,TAB_KEY.CSS_TAB)} - /> - </div> - </div> - } - - </div> - ); - } -} diff --git a/packages/plugin-source-editor/src/module.d.ts b/packages/plugin-source-editor/src/module.d.ts deleted file mode 100644 index 46c67e95a..000000000 --- a/packages/plugin-source-editor/src/module.d.ts +++ /dev/null @@ -1 +0,0 @@ -declare module 'js-beautify'; diff --git a/packages/plugin-source-editor/src/transform.ts b/packages/plugin-source-editor/src/transform.ts deleted file mode 100644 index 1ee574452..000000000 --- a/packages/plugin-source-editor/src/transform.ts +++ /dev/null @@ -1,257 +0,0 @@ -const LIFECYCLES_FUNCTION_MAP = { - react: ['constructor', 'render', 'componentDidMount', 'componentDidUpdate', 'componentWillUnmount', 'componentDidCatch'], -}; - - -const transfrom = { - schema2Code(schema) { - const componentSchema = schema.componentsTree[0]; - const code = - `export default class LowcodeComponent extends Component { - ${initStateCode(componentSchema)} - ${initLifeCycleCode(componentSchema)} - ${initMethodsCode(componentSchema)} -}`; - console.log(code); - return code; - }, - - code2Schema(code: string) { - let codeNew = code; - const functionMap = {}; - let startIndex; - - const stateStartStr = this.pickupStateStartStr(codeNew); - if (stateStartStr != null) { - startIndex = codeNew.indexOf(stateStartStr) + stateStartStr.length; - let stateBodyStr = this.pickupFunctionBody(codeNew, startIndex); - stateBodyStr = this.filterEndComma(stateBodyStr); - const stateData = JSON.parse('{' + stateBodyStr); - functionMap.state = stateData; - } - - while (true) { - const functionNameStr = this.pickupFunctionName(codeNew); - if (functionNameStr != null) { - startIndex = codeNew.indexOf(functionNameStr) + functionNameStr.length; - const functionBodyStr = this.pickupFunctionBody(codeNew, startIndex); - const functionStr = functionNameStr + functionBodyStr; - codeNew = codeNew.replace(functionStr, ''); - const functionName = functionNameStr.match(/\w+/); - functionMap[functionName] = functionStr.replace(functionName, 'function'); - } else { - break; - } - } - - - // debugger; - // const newCode = code.replace(/export default class LowcodeComponent extends Component/, 'class A'); - // let A; let a; - // try { - // // eslint-disable-next-line no-eval - // A = eval(`(${newCode})`); - // a = new A(); - // } catch (e) { - // console.log(e.message); - // return null; - // } - - // // eslint-disable-next-line no-proto - // const functionNameList = Object.getOwnPropertyNames(a.__proto__); - - // const functionMap = {}; - // functionNameList.map((functionName) => { - // if (functionName != 'constructor') { - // if (a[functionName]) { - // const functionCode = a[functionName].toString().replace(new RegExp(functionName), 'function'); - // functionMap[functionName] = functionCode; - // } - // } - // return functionName; - // }); - - // if (a.state) { - // functionMap.state = a.state; - // } - - console.log(functionMap); - return functionMap; - }, - - /** - * 过滤掉尾逗号 - */ - filterEndComma(str) { - let commaIndex = -1; - for (let i = str.length - 1; i > 0; i--) { - if (str[i] == ',') { - commaIndex = i; - break; - } else if (/^[a-zA-Z]+$/.test(str[i])) { - break; - } - } - - - if (commaIndex > 0) { - const newStr = str.substr(0, commaIndex) + str.substr(commaIndex + 1, str.length - 1); - return newStr; - } - - return str; - - - }, - - pickupFunctionName(codeStr) { - // 函数名的正则表达式 - // eslint-disable-next-line no-useless-escape - const reg = /\w+\s?\((\w|\,|\s|\{|\}|\=|\'|\")*\)\s?\{/; - const result = codeStr.match(reg); - - - if (result && result[0]) { - const functionNameStr = result[0]; - return functionNameStr; - } - return null; - }, - - pickupFunctionBody(codeStr, startIndex) { - const startStr = codeStr.substr(startIndex); - const stack = []; let endIndex; - for (let i = 0; i < startStr.length; i++) { - // 如果发现已经有{,则是内函数或者是系统函数,需要进行排除 - if (startStr[i] === '{') { - stack.push(i); - } - - // 判断是否是函数体的结尾 - if (startStr[i] === '}') { - // 有内函数,出栈 - if (stack.length > 0) { - stack.pop(); - } else { - endIndex = i; - break; - } - } - } - - const functionBodyStr = startStr.substr(0, endIndex + 1); - // console.log(functionBodyStr); - return functionBodyStr; - }, - - // 捕获state头部部分 - pickupStateStartStr(codeStr) { - const reg = /state\s?=\s?\s?\{/; - const result = codeStr.match(reg); - if (result && result[0]) { - const stateStartStr = result[0]; - return stateStartStr; - } - return null; - }, - - getNewFunctionCode(functionName: string) { - return `\n\t${functionName}(){\n\t}\n`; - }, - - setFunction2Schema(functionMap, css, schema) { - const pageNode = schema.componentsTree[0]; - // 先清除原有的schema的值 - delete pageNode.state; - pageNode.lifeCycles = {}; - pageNode.methods = {}; - if (!pageNode) return ''; - for (const key in functionMap) { - if (key == 'state') { - pageNode.state = functionMap[key]; - } else if (LIFECYCLES_FUNCTION_MAP.react.indexOf(key) >= 0) { - // // 判断是否属于lifeCycles节点 - // if (LIFECYCLES_FUNCTION_MAP.react.indexOf(key) >= 0) { - // 判断有没有lifecycles节点 - if (!pageNode.lifeCycles) { - pageNode.lifeCycles = {}; - } else { - pageNode.lifeCycles[key] = { - type: 'JSFunction', - value: functionMap[key], - }; - } - } else if (!pageNode.methods) { - // methods节点 - pageNode.methods = {}; - // if (!pageNode.methods) { - // pageNode.methods = {}; - // } else { - // pageNode.methods[key] = { - // type: 'JSFunction', - // value: functionMap[key], - // }; - // } - } else { - pageNode.methods[key] = { - type: 'JSFunction', - value: functionMap[key], - }; - } - } - - pageNode.css = css; - - return schema; - }, -}; - - -function initStateCode(componentSchema) { - if (componentSchema.state) { - return `state = ${JSON.stringify(componentSchema.state)}`; - } - - return ''; -} - -function initLifeCycleCode(componentSchema) { - if (componentSchema.lifeCycles) { - const { lifeCycles } = componentSchema; - const codeList = []; - - for (const key in lifeCycles) { - codeList.push(createFunctionCode(key, lifeCycles[key])); - } - - return codeList.join(''); - } else { - return ''; - } -} - -function initMethodsCode(componentSchema) { - if (componentSchema.methods) { - const { methods } = componentSchema; - const codeList = []; - - for (const key in methods) { - codeList.push(createFunctionCode(key, methods[key])); - } - - return codeList.join(''); - } else { - return ''; - } -} - -function createFunctionCode(functionName: string, functionNode) { - if (functionNode.type === 'JSExpression' || functionNode.type === 'JSFunction') { - let functionCode = functionNode.value; - functionCode = functionCode.replace(/function/, functionName); - return functionCode; - } -} - - -export default transfrom; diff --git a/packages/plugin-source-editor/tsconfig.json b/packages/plugin-source-editor/tsconfig.json deleted file mode 100644 index c37b76ecc..000000000 --- a/packages/plugin-source-editor/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -} diff --git a/packages/plugin-undo-redo/CHANGELOG.md b/packages/plugin-undo-redo/CHANGELOG.md deleted file mode 100644 index 5c2f858a3..000000000 --- a/packages/plugin-undo-redo/CHANGELOG.md +++ /dev/null @@ -1,658 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -<a name="1.0.21"></a> -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.20...@ali/lowcode-plugin-undo-redo@1.0.21) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.20"></a> -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.19...@ali/lowcode-plugin-undo-redo@1.0.20) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.19"></a> -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.18...@ali/lowcode-plugin-undo-redo@1.0.19) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.18"></a> -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.17...@ali/lowcode-plugin-undo-redo@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.17"></a> -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.16...@ali/lowcode-plugin-undo-redo@1.0.17) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.16"></a> -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.15...@ali/lowcode-plugin-undo-redo@1.0.16) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.15"></a> -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.14...@ali/lowcode-plugin-undo-redo@1.0.15) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.14"></a> -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.12...@ali/lowcode-plugin-undo-redo@1.0.14) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.13"></a> -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.12...@ali/lowcode-plugin-undo-redo@1.0.13) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.12"></a> -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.11...@ali/lowcode-plugin-undo-redo@1.0.12) (2020-10-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.11"></a> -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.10...@ali/lowcode-plugin-undo-redo@1.0.11) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.10"></a> -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.9...@ali/lowcode-plugin-undo-redo@1.0.10) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.9"></a> -## [1.0.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.8...@ali/lowcode-plugin-undo-redo@1.0.9) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.8"></a> -## [1.0.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.8-0...@ali/lowcode-plugin-undo-redo@1.0.8) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.8-0"></a> -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.59...@ali/lowcode-plugin-undo-redo@1.0.8-0) (2020-09-09) - - -### Bug Fixes - -* 🐛 Tag assets ([b460dcf](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b460dcf)) -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) -* remove vision dependency from plugin-undo-redo ([08b93f9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/08b93f9)) - - - - -<a name="0.8.59"></a> -## [0.8.59](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.58...@ali/lowcode-plugin-undo-redo@0.8.59) (2020-09-08) -<a name="1.0.7-0"></a> -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.6-0...@ali/lowcode-plugin-undo-redo@1.0.7-0) (2020-09-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.58"></a> -## [0.8.58](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.57...@ali/lowcode-plugin-undo-redo@0.8.58) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.57"></a> -## [0.8.57](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.56...@ali/lowcode-plugin-undo-redo@0.8.57) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo -<a name="1.0.6-0"></a> -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.56...@ali/lowcode-plugin-undo-redo@1.0.6-0) (2020-09-02) - - -### Bug Fixes - -* 🐛 Tag assets ([b460dcf](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b460dcf)) -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) -* remove vision dependency from plugin-undo-redo ([08b93f9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/08b93f9)) - - - - -<a name="1.0.5-0"></a> -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.4-0...@ali/lowcode-plugin-undo-redo@1.0.5-0) (2020-08-20) - -<a name="0.8.56"></a> -## [0.8.56](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.55...@ali/lowcode-plugin-undo-redo@0.8.56) (2020-08-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.55"></a> -## [0.8.55](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.54...@ali/lowcode-plugin-undo-redo@0.8.55) (2020-08-26) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.54"></a> -## [0.8.54](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.53...@ali/lowcode-plugin-undo-redo@0.8.54) (2020-08-24) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.53"></a> -## [0.8.53](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.52...@ali/lowcode-plugin-undo-redo@0.8.53) (2020-08-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.52"></a> -## [0.8.52](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.51...@ali/lowcode-plugin-undo-redo@0.8.52) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.4-0"></a> -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.3-0...@ali/lowcode-plugin-undo-redo@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.3-0"></a> -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.2-0...@ali/lowcode-plugin-undo-redo@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.2-0"></a> -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@1.0.1-0...@ali/lowcode-plugin-undo-redo@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="1.0.1-0"></a> -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.51...@ali/lowcode-plugin-undo-redo@1.0.1-0) (2020-08-20) - - -### Bug Fixes - -* 🐛 Tag assets ([b460dcf](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b460dcf)) - - - - -<a name="1.0.0"></a> -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.13.0...@ali/lowcode-plugin-undo-redo@1.0.0) (2020-08-17) -<a name="0.8.51"></a> -## [0.8.51](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.50...@ali/lowcode-plugin-undo-redo@0.8.51) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.50"></a> -## [0.8.50](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.49...@ali/lowcode-plugin-undo-redo@0.8.50) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.49"></a> -## [0.8.49](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.48...@ali/lowcode-plugin-undo-redo@0.8.49) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.48"></a> -## [0.8.48](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.47...@ali/lowcode-plugin-undo-redo@0.8.48) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.47"></a> -## [0.8.47](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.46...@ali/lowcode-plugin-undo-redo@0.8.47) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.13.0"></a> -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.12.0...@ali/lowcode-plugin-undo-redo@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.12.0"></a> -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.10.0...@ali/lowcode-plugin-undo-redo@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.11.0"></a> -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.10.0...@ali/lowcode-plugin-undo-redo@0.11.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.10.0"></a> -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.9.0...@ali/lowcode-plugin-undo-redo@0.10.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.9.0"></a> -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.41...@ali/lowcode-plugin-undo-redo@0.9.0) (2020-08-14) - - -### Bug Fixes - -* 🐛 Tag assets ([b460dcf](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b460dcf)) - - - - -<a name="0.8.41"></a> -## [0.8.41](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.40...@ali/lowcode-plugin-undo-redo@0.8.41) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.40"></a> -## [0.8.40](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.38...@ali/lowcode-plugin-undo-redo@0.8.40) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.39"></a> -## [0.8.39](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.38...@ali/lowcode-plugin-undo-redo@0.8.39) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.38"></a> -## [0.8.38](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.37...@ali/lowcode-plugin-undo-redo@0.8.38) (2020-07-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.37"></a> -## [0.8.37](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.36...@ali/lowcode-plugin-undo-redo@0.8.37) (2020-07-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.36"></a> -## [0.8.36](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.35...@ali/lowcode-plugin-undo-redo@0.8.36) (2020-07-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.35"></a> -## [0.8.35](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.34...@ali/lowcode-plugin-undo-redo@0.8.35) (2020-07-22) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.34"></a> -## [0.8.34](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.33...@ali/lowcode-plugin-undo-redo@0.8.34) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.33"></a> -## [0.8.33](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.32...@ali/lowcode-plugin-undo-redo@0.8.33) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.32"></a> -## [0.8.32](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.31...@ali/lowcode-plugin-undo-redo@0.8.32) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.31"></a> -## [0.8.31](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.30...@ali/lowcode-plugin-undo-redo@0.8.31) (2020-07-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.30"></a> -## [0.8.30](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.29...@ali/lowcode-plugin-undo-redo@0.8.30) (2020-07-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.29"></a> -## [0.8.29](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.28...@ali/lowcode-plugin-undo-redo@0.8.29) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.28"></a> -## [0.8.28](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.27...@ali/lowcode-plugin-undo-redo@0.8.28) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.27"></a> -## [0.8.27](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.26...@ali/lowcode-plugin-undo-redo@0.8.27) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.26"></a> -## [0.8.26](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.25...@ali/lowcode-plugin-undo-redo@0.8.26) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.25"></a> -## [0.8.25](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.24...@ali/lowcode-plugin-undo-redo@0.8.25) (2020-06-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.24"></a> -## [0.8.24](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.23...@ali/lowcode-plugin-undo-redo@0.8.24) (2020-06-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.23"></a> -## [0.8.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.22...@ali/lowcode-plugin-undo-redo@0.8.23) (2020-05-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.22"></a> -## [0.8.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.21...@ali/lowcode-plugin-undo-redo@0.8.22) (2020-05-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.21"></a> -## [0.8.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.20...@ali/lowcode-plugin-undo-redo@0.8.21) (2020-05-18) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.20"></a> -## [0.8.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.19...@ali/lowcode-plugin-undo-redo@0.8.20) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.19"></a> -## [0.8.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.18...@ali/lowcode-plugin-undo-redo@0.8.19) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.18"></a> -## [0.8.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.17...@ali/lowcode-plugin-undo-redo@0.8.18) (2020-05-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.17"></a> -## [0.8.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.16...@ali/lowcode-plugin-undo-redo@0.8.17) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.16"></a> -## [0.8.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.15...@ali/lowcode-plugin-undo-redo@0.8.16) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.15"></a> -## [0.8.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.14...@ali/lowcode-plugin-undo-redo@0.8.15) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.14"></a> -## [0.8.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.13...@ali/lowcode-plugin-undo-redo@0.8.14) (2020-05-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.13"></a> -## [0.8.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.12...@ali/lowcode-plugin-undo-redo@0.8.13) (2020-05-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.12"></a> -## [0.8.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.11...@ali/lowcode-plugin-undo-redo@0.8.12) (2020-05-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.11"></a> -## [0.8.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.10...@ali/lowcode-plugin-undo-redo@0.8.11) (2020-05-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.10"></a> -## [0.8.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.9...@ali/lowcode-plugin-undo-redo@0.8.10) (2020-05-07) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.9"></a> -## [0.8.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.8...@ali/lowcode-plugin-undo-redo@0.8.9) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.8"></a> -## [0.8.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.7...@ali/lowcode-plugin-undo-redo@0.8.8) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.7"></a> -## [0.8.7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.6...@ali/lowcode-plugin-undo-redo@0.8.7) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.6"></a> -## [0.8.6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.5...@ali/lowcode-plugin-undo-redo@0.8.6) (2020-04-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.5"></a> -## [0.8.5](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.4...@ali/lowcode-plugin-undo-redo@0.8.5) (2020-04-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.4"></a> -## [0.8.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.3...@ali/lowcode-plugin-undo-redo@0.8.4) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.3"></a> -## [0.8.3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-undo-redo@0.8.2...@ali/lowcode-plugin-undo-redo@0.8.3) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.2"></a> -## 0.8.2 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo - -<a name="0.8.1"></a> -## 0.8.1 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-undo-redo diff --git a/packages/plugin-undo-redo/README.md b/packages/plugin-undo-redo/README.md deleted file mode 100644 index 8a6fb13f0..000000000 --- a/packages/plugin-undo-redo/README.md +++ /dev/null @@ -1 +0,0 @@ -## todo diff --git a/packages/plugin-undo-redo/build.json b/packages/plugin-undo-redo/build.json deleted file mode 100644 index e791d5b6b..000000000 --- a/packages/plugin-undo-redo/build.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "plugins": [ - "build-plugin-component", - "build-plugin-fusion", - ["build-plugin-moment-locales", { - "locales": ["zh-cn"] - }] - ] -} diff --git a/packages/plugin-undo-redo/package.json b/packages/plugin-undo-redo/package.json deleted file mode 100644 index 9e4e28e80..000000000 --- a/packages/plugin-undo-redo/package.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "name": "@ali/lowcode-plugin-undo-redo", - "version": "1.0.21", - "description": "alibaba lowcode editor undo redo plugin", - "files": [ - "es", - "lib" - ], - "main": "lib/index.js", - "module": "es/index.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "keywords": [ - "lowcode", - "editor" - ], - "author": "xiayang.xy", - "dependencies": { - "@ali/lowcode-designer": "^1.0.22", - "@ali/lowcode-editor-core": "^1.0.22", - "@ali/lowcode-editor-skeleton": "^1.0.22", - "@ali/lowcode-types": "^1.0.20", - "@ali/lowcode-utils": "^1.0.21", - "react": "^16.8.1", - "react-dom": "^16.8.1" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.3", - "@types/react": "^16.9.13", - "@types/react-dom": "^16.9.4", - "build-plugin-component": "^0.2.7-1", - "build-plugin-fusion": "^0.1.0", - "build-plugin-moment-locales": "^0.1.0" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/plugin-undo-redo/src/index.scss b/packages/plugin-undo-redo/src/index.scss deleted file mode 100644 index 1b1d2a075..000000000 --- a/packages/plugin-undo-redo/src/index.scss +++ /dev/null @@ -1,8 +0,0 @@ -.lowcode-plugin-undo-redo{ - .next-btn-ghost.next-btn-dark{ - color: #3c3c3c; - } - .next-btn-ghost.next-btn-dark[disabled]{ - color: #ccc; - } -} \ No newline at end of file diff --git a/packages/plugin-undo-redo/src/index.tsx b/packages/plugin-undo-redo/src/index.tsx deleted file mode 100644 index 42d31de1d..000000000 --- a/packages/plugin-undo-redo/src/index.tsx +++ /dev/null @@ -1,105 +0,0 @@ -import React, { PureComponent } from 'react'; -import { Editor } from '@ali/lowcode-editor-core'; -import { Button, Icon } from '@alifd/next'; -import { Designer } from '@ali/lowcode-designer'; -import { PluginProps } from '@ali/lowcode-types'; - -import './index.scss'; - -export interface IProps extends PluginProps { - editor: Editor; - logo?: string; -} - -export interface IState { - undoEnable: boolean; - redoEnable: boolean; -} - -export default class UndoRedo extends PureComponent<IProps, IState> { - static displayName = 'LowcodeUndoRedo'; - - private history: any; - - constructor(props: any) { - super(props); - this.state = { - undoEnable: false, - redoEnable: false, - }; - } - - async componentDidMount() { - const { editor } = this.props; - editor.on('designer.history.change', this.handleHistoryChange); - - const designer = await editor.onceGot(Designer); - this.history = designer.currentHistory; - this.updateState(this.history?.getState() || 0); - } - - componentWillUnmount(): void { - const { editor } = this.props; - editor.off('designer.history.change', this.handleHistoryChange); - } - - handleHistoryChange = (history: any): void => { - this.history = history; - this.updateState(this.history?.getState() || 0); - }; - - init = (): void => { - const { editor } = this.props; - - this.history = editor.get(Designer)?.currentHistory; - this.updateState(this.history?.getState() || 0); - - editor.on('designer.history.change', (history: any): void => { - this.history = history; - this.updateState(this.history?.getState() || 0); - }); - }; - - updateState = (state: number): void => { - this.setState({ - undoEnable: !!(state & 1), - redoEnable: !!(state & 2), - }); - }; - - handleUndoClick = (): void => { - this.history.back(); - }; - - handleRedoClick = (): void => { - this.history.forward(); - }; - - render(): React.ReactNode { - const { undoEnable, redoEnable } = this.state; - return ( - <div className="lowcode-plugin-undo-redo"> - <Button - size="medium" - data-tip="撤销" - data-dir="bottom" - onClick={this.handleUndoClick} - ghost - disabled={!undoEnable} - > - <Icon type="houtui" /> - </Button> - <Button - size="medium" - data-tip="恢复" - data-dir="bottom" - onClick={this.handleRedoClick} - ghost - disabled={!redoEnable} - > - <Icon type="qianjin" /> - </Button> - </div> - ); - } -} diff --git a/packages/plugin-undo-redo/tsconfig.json b/packages/plugin-undo-redo/tsconfig.json deleted file mode 100644 index c37b76ecc..000000000 --- a/packages/plugin-undo-redo/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -} diff --git a/packages/plugin-utils-pane/CHANGELOG.md b/packages/plugin-utils-pane/CHANGELOG.md deleted file mode 100644 index 420e6f23d..000000000 --- a/packages/plugin-utils-pane/CHANGELOG.md +++ /dev/null @@ -1 +0,0 @@ -# Change Log diff --git a/packages/plugin-utils-pane/README.md b/packages/plugin-utils-pane/README.md deleted file mode 100644 index fcb19d90f..000000000 --- a/packages/plugin-utils-pane/README.md +++ /dev/null @@ -1,3 +0,0 @@ -## 关于 @ali/lowcode-plugin-utils-pane - -这是低代码引擎的 utils 面板。 diff --git a/packages/plugin-utils-pane/build.json b/packages/plugin-utils-pane/build.json deleted file mode 100644 index 77627cdf9..000000000 --- a/packages/plugin-utils-pane/build.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "plugins": [ - "build-plugin-component", - "build-plugin-fusion", - ["build-plugin-moment-locales", { - "locales": ["zh-cn"] - }] - ] -} \ No newline at end of file diff --git a/packages/plugin-utils-pane/package.json b/packages/plugin-utils-pane/package.json deleted file mode 100644 index d4291b9b7..000000000 --- a/packages/plugin-utils-pane/package.json +++ /dev/null @@ -1,48 +0,0 @@ -{ - "name": "@ali/lowcode-plugin-utils-pane", - "version": "1.0.8-0", - "description": "alibaba lowcode editor utils pane plugin", - "files": [ - "es/", - "lib/" - ], - "main": "lib/index.js", - "module": "es/index.js", - "stylePath": "style.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "keywords": [ - "lowcode", - "editor" - ], - "author": "changyun.pcy", - "dependencies": { - "@alifd/next": "1.x" - }, - "peerDependencies": { - "@ali/lowcode-editor-core": "^1.0.8-0", - "@formily/next": "^1.3.2", - "@formily/next-components": "^1.3.2", - "@formily/react-schema-renderer": "^1.3.2", - "react-monaco-editor": "^0.40.0", - "styled-components": "^5.2.0", - "prop-types": "^15.5.8", - "react": "^16.8.1", - "react-dom": "^16.8.1", - "react-router-dom": "^5.1.2" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.3", - "@types/react": "^16.9.13", - "@types/react-dom": "^16.9.4", - "build-plugin-component": "^0.2.7-1", - "build-plugin-fusion": "^0.1.0", - "build-plugin-moment-locales": "^0.1.0" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/plugin-utils-pane/src/form-components/index.ts b/packages/plugin-utils-pane/src/form-components/index.ts deleted file mode 100644 index 6c3302dab..000000000 --- a/packages/plugin-utils-pane/src/form-components/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './js-function'; diff --git a/packages/plugin-utils-pane/src/form-components/js-function.tsx b/packages/plugin-utils-pane/src/form-components/js-function.tsx deleted file mode 100644 index 358b80cf8..000000000 --- a/packages/plugin-utils-pane/src/form-components/js-function.tsx +++ /dev/null @@ -1,64 +0,0 @@ -import React, { PureComponent } from 'react'; -import { connect } from '@formily/react-schema-renderer'; -import MonacoEditor, { EditorWillMount } from 'react-monaco-editor'; -import noop from 'lodash/noop'; - -export interface JSFunctionProps { - className: string; - value: string; - defaultValue: string; - onChange?: (val: string) => void; -} - -type Arg0TypeOf<T> = T extends (arg0: infer U) => any ? U : never; -type MonacoRef = Arg0TypeOf<EditorWillMount>; - -class InternalJSFunction extends PureComponent<JSFunctionProps, unknown> { - static isFieldComponent = true; - - static defaultProps = { - onChange: noop, - }; - - private monacoRef: MonacoRef | null = null; - - componentDidMount() { - const { value, defaultValue, onChange } = this.props; - - if (!value && defaultValue && onChange) { - onChange(defaultValue); - } - } - - render() { - const { value, defaultValue } = this.props; - return ( - <MonacoEditor - theme="vs-dark" - width={400} - height={150} - defaultValue={value || defaultValue} - language="js" - onChange={this.handleEditorChange} - editorWillMount={this.handleEditorWillMount} - /> - ); - } - - private handleEditorChange = () => { - if ( - this.monacoRef && - this.monacoRef.editor && - !this.monacoRef.editor.getModelMarkers({}).find((marker) => marker.owner === 'json') && - this.props.onChange - ) { - this.props.onChange(this.monacoRef.editor.getModels()?.[0]?.getValue()); - } - }; - - private handleEditorWillMount: EditorWillMount = (monaco) => { - this.monacoRef = monaco; - }; -} - -export const JSFunction = connect()(InternalJSFunction); diff --git a/packages/plugin-utils-pane/src/index.scss b/packages/plugin-utils-pane/src/index.scss deleted file mode 100644 index 13e59fbeb..000000000 --- a/packages/plugin-utils-pane/src/index.scss +++ /dev/null @@ -1,116 +0,0 @@ -.lowcode-plugin-utils-pane { - margin: 0 8px; - > .next-tabs { - > .next-tabs-bar { - .next-tabs-nav-extra { - .next-btn { - margin-left: 4px; - } - } - } - } -} - -.lowcode-plugin-utils-pane-list { - margin: 8px; - .next-search { - width: 100%; - .next-search-left { - height: 28px !important; - border-top-left-radius: 3px; - border-bottom-left-radius: 3px; - .next-before { - height: 28px !important; - .next-select { - height: 28px !important; - } - } - .next-search-input { - height: 28px !important; - input { - height: 28px !important; - } - } - .next-input { - border-top-left-radius: 0; - border-bottom-left-radius: 0; - } - } - .next-after { - // height: 28px !important; - .next-btn { - height: 30px !important; - border-top-right-radius: 3px; - border-bottom-right-radius: 3px; - .next-icon:before { - font-size: 12px; - } - } - } - } - .utils-list { - margin-top: 8px; - height: unquote('calc(100vh - 48px - 48px - 42px - 28px - 8px - 8px)'); - overflow: auto; - .next-virtual-list-wrapper > div > ul > li { - border-top: 1px solid #ddd; - &:first-child { - border-top: none; - } - } - } - .utils-item { - margin: 8px; - .utils-item-title { - display: flex; - flex-direction: row; - align-items: center; - justify-content: flex-start; - height: 28px; - .next-btn { - margin-left: 4px; - } - } - - .utils-item-name-wrap { - flex: 1; - overflow: hidden; - text-overflow: ellipsis; - white-space: nowrap; - font-size: 12px; - font-family: monospace; - } - - .utils-item-from { - color: rgba(0, 0, 0, 0.65); - font-size: 12px; - } - - .utils-item-import-from { - color: rgba(0, 0, 0, 0.45); - } - - .utils-item-desc { - .next-tag { - margin-right: 4px; - } - } - } -} - -.lowcode-plugin-utils-form { - height: unquote('calc(100vh - 48px - 48px - 42px)'); - overflow: auto; - .next-form-item { - .next-form-item-control { - font-size: 100%; - } - } -} - -.utils-item-detail-func-expr { - pre { - max-width: 100%; - overflow: auto; - } -} diff --git a/packages/plugin-utils-pane/src/index.tsx b/packages/plugin-utils-pane/src/index.tsx deleted file mode 100644 index 5b945162b..000000000 --- a/packages/plugin-utils-pane/src/index.tsx +++ /dev/null @@ -1,86 +0,0 @@ -import React, { PureComponent } from 'react'; -import { PluginProps, UtilItem, UtilsMap } from '@ali/lowcode-types'; -import get from 'lodash/get'; -import { UtilsPane, UtilTypeInfo } from './pane'; - -import './index.scss'; -import { DEFAULT_UTILS_TYPES } from './utils-types'; -import { DEFAULT_UTILS } from './utils-defaults'; - -const PLUGIN_NAME = 'utilsPane'; - -export interface UtilsPaneProps extends PluginProps { - /** - * 支持的 Util 的类型 - */ - utilsTypes?: UtilTypeInfo[]; - - /** - * 初始的 Utils (若 schema 中尚未定义 utils) - */ - initialUtils?: UtilItem[]; -} - -interface State { - active: boolean; -} - -export default class UtilsPanePlugin extends PureComponent<UtilsPaneProps, State> { - static displayName = 'UtilsPanePlugin'; - - static defaultProps = { - initialUtils: DEFAULT_UTILS, - }; - - state = { - active: false, - }; - - constructor(props: UtilsPaneProps) { - super(props); - this.state.active = true; - - const { editor } = this.props; - - // @todo pluginName, to unsubscribe - // 第一次 active 事件不会触发监听器 - editor.on('skeleton.panel-dock.active', (pluginName) => { - if (pluginName === PLUGIN_NAME) { - this.setState({ active: true }); - } - }); - - editor.on('skeleton.panel-dock.unactive', (pluginName) => { - if (pluginName === PLUGIN_NAME) { - this.setState({ active: false }); - } - }); - } - - render() { - const { initialUtils = DEFAULT_UTILS, utilsTypes = DEFAULT_UTILS_TYPES, editor } = this.props; - const { active } = this.state; - - if (!active) return null; - - const projectSchema = editor.get('designer').project.getSchema() ?? {}; - - return ( - <UtilsPane - initialUtils={initialUtils} - utilTypes={utilsTypes} - schema={get(projectSchema, 'utils')} - onSchemaChange={this.handleSchemaChange} - /> - ); - } - - private handleSchemaChange = (utilsMap: UtilsMap) => { - const { editor } = this.props; - - // @TODO 姿势是否最优? - if (editor.get('designer')) { - editor.get('designer').project.set('utils', utilsMap); - } - }; -} diff --git a/packages/plugin-utils-pane/src/list.tsx b/packages/plugin-utils-pane/src/list.tsx deleted file mode 100644 index 0cfe6e910..000000000 --- a/packages/plugin-utils-pane/src/list.tsx +++ /dev/null @@ -1,191 +0,0 @@ -import { UtilItem } from '@ali/lowcode-types'; -import { Balloon, Button, Search, Table, Tag, VirtualList } from '@alifd/next'; -import tap from 'lodash/tap'; -import React, { PureComponent } from 'react'; - -import type { UtilTypeInfo } from './pane'; - -const { Column: TableCol } = Table; - -export interface UtilsListProps { - utilTypes: UtilTypeInfo[]; - utilItems: UtilItem[] | null | undefined; - onEditUtil?: (utilName: string) => void; - onDuplicateUtil?: (utilName: string) => void; - onRemoveUtil?: (utilName: string) => void; -} - -interface State { - filteredType: string; - keyword: string; -} - -type TableRow = { - label: string; - value: any; -}; - -export class UtilList extends PureComponent<UtilsListProps, State> { - state = { - filteredType: '', - keyword: '', - }; - - private handleSearchFilterChange = (filteredType: any) => { - this.setState({ filteredType }); - }; - - private handleSearch = (keyword: any) => { - this.setState({ keyword }); - }; - - private handleEditUtilItem = (id: any) => { - if (this.props.onEditUtil) { - this.props.onEditUtil(id); - } - }; - - private handleDuplicateUtilItem = (id: any) => { - if (this.props.onDuplicateUtil) { - this.props.onDuplicateUtil(id); - } - }; - - private handleRemoveUtilItem = (id: any) => { - if (this.props.onRemoveUtil) { - this.props.onRemoveUtil(id); - } - }; - - private renderVirtualUtilsList = () => { - const { filteredType, keyword } = this.state; - const utilsMap = this.props.utilItems || []; - const { utilTypes } = this.props; - - return ( - utilsMap - .filter((item) => !filteredType || item.type === filteredType) - .filter((item) => !keyword || item.name.indexOf(keyword) >= 0) - .map((item) => ( - <li key={item.name}> - <div className="utils-item"> - <div className="utils-item-title"> - <div className="utils-item-name-wrap" title={item.name}> - <span className="utils-item-name">{item.name}</span> - - {(item.type === 'npm' || item.type === 'tnpm') && ( - <span className="utils-item-from"> - {' '} - <span className="utils-item-import-from">源自</span>{' '} - <span className="utils-item-package-name"> - "{item.content?.package} - {item.content?.main ? `/${item.content?.main}` : ''}" - </span> - <span className="utils-item-export-name"> - {item.content?.exportName && item.content?.exportName !== item.name - ? `中的 ${item.content?.exportName}${ - item.content?.subName ? `.${item.content?.subName}` : '' - }` - : ''} - </span> - </span> - )} - </div> - {!!utilTypes.some((t) => t.type === item.type) && - this.renderItemDetailBalloon(item)} - {!!utilTypes.some((t) => t.type === item.type) && ( - <Button size="small" onClick={this.handleEditUtilItem.bind(this, item.name)}> - 编辑 - </Button> - )} - {!!utilTypes.some((t) => t.type === item.type) && ( - <Button size="small" onClick={this.handleDuplicateUtilItem.bind(this, item.name)}> - 复制 - </Button> - )} - <Button size="small" onClick={this.handleRemoveUtilItem.bind(this, item.name)}> - 删除 - </Button> - </div> - <div className="utils-item-desc"> - <Tag size="small">{item.type}</Tag> - {(item.type === 'npm' || item.type === 'tnpm') && item.content?.destructuring && ( - <Tag size="small">解构</Tag> - )} - </div> - </div> - </li> - )) || [] - ); - }; - - private renderItemDetailBalloon(item: UtilItem): React.ReactNode { - return ( - <Balloon - trigger={<Button size="small">详情</Button>} - align="b" - alignEdge - triggerType="hover" - style={{ width: 300 }} - > - {item.type === 'function' ? ( - <div className="utils-item-detail-func-expr"> - <pre> - <code>{item.content?.value || ''}</code> - </pre> - </div> - ) : ( - <Table - dataSource={tap( - Object.entries({ - type: item.type, - ...item.content, - }).map<TableRow>(([key, value]) => ({ - label: key, - value: `${value}`, - })), - console.log, - )} - > - <TableCol title="" dataIndex="label" /> - <TableCol - title="" - dataIndex="value" - cell={(val: any) => <div>{typeof val === 'string' ? `"${val}"` : `${val}`}</div>} - /> - </Table> - )} - </Balloon> - ); - } - - render() { - const { utilTypes } = this.props; - const { filteredType } = this.state; - - return ( - <div className="lowcode-plugin-utils-pane-list"> - <Search - hasClear - onSearch={this.handleSearch} - filterProps={{}} - defaultFilterValue={filteredType} - filter={[ - { - label: '全部', - value: '', - }, - ...(utilTypes || []).map((utilType) => ({ - label: utilType.label, - value: utilType.type, - })), - ]} - onFilterChange={this.handleSearchFilterChange} - /> - <div className="utils-list"> - <VirtualList>{this.renderVirtualUtilsList()}</VirtualList> - </div> - </div> - ); - } -} diff --git a/packages/plugin-utils-pane/src/locale/en-US.json b/packages/plugin-utils-pane/src/locale/en-US.json deleted file mode 100644 index 24c351193..000000000 --- a/packages/plugin-utils-pane/src/locale/en-US.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "UtilsPane": "Utils Pane" -} diff --git a/packages/plugin-utils-pane/src/locale/index.ts b/packages/plugin-utils-pane/src/locale/index.ts deleted file mode 100644 index 49de985ed..000000000 --- a/packages/plugin-utils-pane/src/locale/index.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { createIntl } from '@ali/lowcode-editor-core'; -import enUS from './en-US.json'; -import zhCN from './zh-CN.json'; - -const { intl, intlNode, getLocale, setLocale } = createIntl({ - 'en-US': enUS, - 'zh-CN': zhCN, -}); - -export { intl, intlNode, getLocale, setLocale }; diff --git a/packages/plugin-utils-pane/src/locale/zh-CN.json b/packages/plugin-utils-pane/src/locale/zh-CN.json deleted file mode 100644 index 89fb4feb8..000000000 --- a/packages/plugin-utils-pane/src/locale/zh-CN.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "UtilsPane": "工具类扩展面板" -} diff --git a/packages/plugin-utils-pane/src/pane.tsx b/packages/plugin-utils-pane/src/pane.tsx deleted file mode 100644 index 01e54e4ec..000000000 --- a/packages/plugin-utils-pane/src/pane.tsx +++ /dev/null @@ -1,308 +0,0 @@ -/** - * 面板,先通过 Dialog 呈现 - */ -import { UtilItem, UtilsMap } from '@ali/lowcode-types'; -import { Button, Dialog, MenuButton, Message, Tab } from '@alifd/next'; -import cloneDeep from 'lodash/cloneDeep'; -import get from 'lodash/get'; -import isArray from 'lodash/isArray'; -import React, { PureComponent } from 'react'; - -import { UtilList } from './list'; -import { UtilsForm } from './utils-form'; - -const { Item: TabItem } = Tab; -const { Item: MenuButtonItem } = MenuButton; - -enum PaneTabKey { - List = 'list', - Create = 'create', - Edit = 'edit', -} - -export type UtilTypeInfo = { - type: UtilItem['type']; - label: string; -}; - -export interface UtilsPaneProps { - initialUtils?: UtilsMap | null; - schema?: UtilsMap | null; - utilTypes: UtilTypeInfo[]; - onSchemaChange?: (schema: UtilsMap) => void; -} - -export interface TabItem { - key: PaneTabKey; - title: string; - closeable: boolean; - data?: Partial<UtilItem>; -} - -interface State { - utilItems: UtilsMap; - tabItems: TabItem[]; - activeTabKey: PaneTabKey; -} - -export class UtilsPane extends PureComponent<UtilsPaneProps, State> { - state: State = { - utilItems: this.props.schema || this.props.initialUtils || [], - tabItems: [ - { - key: PaneTabKey.List, - title: '工具类扩展列表', - closeable: false, - }, - ], - activeTabKey: PaneTabKey.List, - }; - - private notifyItemsChanged = () => { - this.setState({}, () => { - if (this.props.onSchemaChange) { - this.props.onSchemaChange(this.state.utilItems); - } - }); - }; - - private handleCreateItem = (newItem: UtilItem) => { - const doSaveNewItem = () => { - this.closeTab(PaneTabKey.Create); - - this.setState(({ utilItems }) => ({ - utilItems: [{ ...newItem }, ...utilItems.filter((x) => x.name !== newItem.name)], - })); - - this.notifyItemsChanged(); - }; - - if (this.state.utilItems.some((util) => util.name === newItem.name)) { - Dialog.confirm({ - content: `工具类扩展 "${newItem.name}" 已存在,如果导入会替换已存在的扩展,是否继续?`, - onOk: () => { - doSaveNewItem(); - }, - }); - return; - } - - doSaveNewItem(); - }; - - private handleUpdateItem = (changedItem: UtilItem) => { - this.closeTab(PaneTabKey.Edit); - this.setState(({ utilItems }) => ({ - utilItems: utilItems.map((x) => [x.name === changedItem.name ? changedItem : x][0]), - })); - this.notifyItemsChanged(); - }; - - private handleRemoveItem = (toBeRemovedUtilName: string) => { - const doRemove = () => { - this.setState( - ({ utilItems }) => ({ - utilItems: utilItems.filter((item) => item.name !== toBeRemovedUtilName), - }), - () => { - this.notifyItemsChanged(); - }, - ); - }; - - Dialog.confirm({ - content: '确定要删除吗?', - onOk: () => { - doRemove(); - }, - }); - }; - - private handleDuplicateItem = (utilName: string) => { - const targetUtil = this.state.utilItems.find((item) => item.name === utilName); - if (!targetUtil) { - return; - } - - this.openCreateItemTab({ - ...cloneDeep(targetUtil), - name: `${targetUtil.name}Copy`, - }); - }; - - private handleEditItem = (utilName: string) => { - const targetUtil = this.state.utilItems.find((item) => item.name === utilName); - if (!targetUtil) { - return; - } - - this.openEditItemTab(cloneDeep(targetUtil)); - }; - - private handleTabChange = (activeTabKey: string | number) => { - if (isValidTabKey(activeTabKey)) { - this.setState({ activeTabKey }); - } - }; - - private openCreateItemTab = (initialItem: Partial<UtilItem>) => { - const { tabItems } = this.state; - - if (!tabItems.find((item) => item.key === PaneTabKey.Create)) { - this.setState(({ tabItems: latestTabItems }) => ({ - tabItems: latestTabItems.concat({ - key: PaneTabKey.Create, - title: '添加工具类扩展', - closeable: true, - data: { - ...initialItem, - }, - }), - })); - this.setState({ activeTabKey: PaneTabKey.Create }); - } else { - Message.notice('当前已经有一个添加工具类扩展的标签页了'); - } - }; - - private handleCreateItemBtnClick = (utilType: string) => { - this.openCreateItemTab({ - type: utilType as UtilItem['type'], - }); - }; - - private handleCreateItemMenuBtnClick = (utilType: string) => { - this.openCreateItemTab({ - type: utilType as UtilItem['type'], - }); - }; - - private openEditItemTab = (utilItem: UtilItem) => { - const { tabItems } = this.state; - - if (!tabItems.find((item) => item.key === PaneTabKey.Edit)) { - this.setState(({ tabItems: latestTabItems }) => ({ - tabItems: latestTabItems.concat({ - key: PaneTabKey.Edit, - title: '修改工具类扩展', - closeable: true, - data: { - ...utilItem, - }, - }), - })); - } - - this.setState({ activeTabKey: PaneTabKey.Edit }); - }; - - private closeTab = (tabKey: any) => { - this.setState( - ({ tabItems }) => ({ - tabItems: tabItems.filter((item) => item.key !== tabKey), - }), - () => { - this.setState(({ tabItems }) => ({ - activeTabKey: get(tabItems, '[0].key'), - })); - }, - ); - }; - - renderTabExtraContent = () => { - const { utilTypes } = this.props; - - if (isArray(utilTypes)) { - if (utilTypes.length > 1) { - return [ - <MenuButton label="添加" onItemClick={this.handleCreateItemMenuBtnClick}> - {utilTypes.map((type) => ( - <MenuButtonItem key={type.type}>{type.label}</MenuButtonItem> - ))} - </MenuButton>, - ]; - } else if (utilTypes.length === 1) { - return [ - <Button onClick={this.handleCreateItemBtnClick.bind(this, utilTypes[0].type)}> - 添加 - </Button>, - ]; - } else { - return []; - } - } - - return []; - }; - - // 更通用的处理 - private renderTabItemContent = ( - tabItemKey: PaneTabKey, - data: Partial<UtilItem> | undefined | null, - ) => { - const { utilItems } = this.state; - const { utilTypes = [] } = this.props; - - if (tabItemKey === PaneTabKey.List) { - if (utilItems.length <= 0) { - return ( - <Message type="help" title="暂无工具类扩展"> - 您可以点击右上角的【添加】按钮来添加一个。 - </Message> - ); - } - - return ( - <UtilList - utilTypes={utilTypes} - utilItems={utilItems} - onEditUtil={this.handleEditItem} - onDuplicateUtil={this.handleDuplicateItem} - onRemoveUtil={this.handleRemoveItem} - /> - ); - } else if (tabItemKey === PaneTabKey.Edit) { - return ( - <UtilsForm - item={data} - onComplete={this.handleUpdateItem} - onCancel={this.closeTab.bind(this, PaneTabKey.Edit)} - /> - ); - } else if (tabItemKey === PaneTabKey.Create) { - return ( - <UtilsForm - item={data} - onComplete={this.handleCreateItem} - onCancel={this.closeTab.bind(this, tabItemKey)} - /> - ); - } else { - console.warn('Unknown tab type: ', tabItemKey); - return null; - } - }; - - render() { - const { activeTabKey, tabItems } = this.state; - - return ( - <div className="lowcode-plugin-utils-pane"> - <Tab - activeKey={activeTabKey} - extra={this.renderTabExtraContent()} - onChange={this.handleTabChange} - onClose={this.closeTab} - > - {tabItems.map((item: TabItem) => ( - <TabItem {...item}>{this.renderTabItemContent(item.key, item.data)}</TabItem> - ))} - </Tab> - </div> - ); - } -} - -function isValidTabKey(tabKey: unknown): tabKey is PaneTabKey { - return typeof tabKey === 'string' && (Object.values(PaneTabKey) as string[]).includes(tabKey); -} diff --git a/packages/plugin-utils-pane/src/utils-defaults.tsx b/packages/plugin-utils-pane/src/utils-defaults.tsx deleted file mode 100644 index fe5e8f236..000000000 --- a/packages/plugin-utils-pane/src/utils-defaults.tsx +++ /dev/null @@ -1,31 +0,0 @@ -import { UtilItem } from '@ali/lowcode-types'; - -export const DEFAULT_UTILS: UtilItem[] = [ - // { - // type: 'npm', - // name: 'clone', - // content: { - // package: 'lodash', - // destructuring: true, - // }, - // }, - // { - // type: 'npm', - // name: 'moment', - // content: { - // package: 'moment', - // destructuring: false, - // }, - // }, - // { - // type: 'function', - // name: 'record', - // content: { - // type: 'JSFunction', - // value: `function(logkey, gmkey, gokey, reqMethod) { - // goldlog.record('/demo.event.' + logkey, gmkey, gokey, reqMethod); - // } - // `, - // }, - // }, -]; diff --git a/packages/plugin-utils-pane/src/utils-form.tsx b/packages/plugin-utils-pane/src/utils-form.tsx deleted file mode 100644 index e01ccfdc2..000000000 --- a/packages/plugin-utils-pane/src/utils-form.tsx +++ /dev/null @@ -1,247 +0,0 @@ -// @todo schema default -import { UtilItem } from '@ali/lowcode-types'; -import { Button } from '@alifd/next'; -import { FormButtonGroup, registerValidationFormats, SchemaForm, Submit } from '@formily/next'; -import { ArrayTable, Input, NumberPicker, Switch } from '@formily/next-components'; -import memorize from 'lodash/memoize'; -import React, { PureComponent } from 'react'; - -import { JSFunction } from './form-components'; - -registerValidationFormats({ - util_npm_version_format: /^\d+\.\d+\.\d+(-[a-z0-9-]+(\.[a-z0-9]+))?$/i, // 版本号的规范 - util_name_js_identifier: /^[a-z$_][a-z$_0-9]*$/i, // JS 标识符的规范 -}); - -type FlatUtilItem = { - name: string; - type: UtilItem['type']; - - // NPM/TNPM util: - componentName?: string; - package?: string; - version?: string; - destructuring?: boolean; - exportName?: string; - subName?: string; - main?: string; - - // function util - functionExpr?: string; -}; - -const FORM_SCHEMA_NPM = { - type: 'object', - properties: { - type: TYPE_FIELD(), - name: NAME_FIELD(), - componentName: { - type: 'string', - title: 'componentName', - display: false, - }, - package: { - type: 'string', - title: '包名', - required: true, - }, - version: { - type: 'string', - title: '版本号', - required: false, - 'x-rules': { - format: 'util_npm_version_format', - }, - }, - destructuring: { - type: 'boolean', - title: '需解构', - required: false, - }, - exportName: { - type: 'string', - title: '导出名', - // hide: '{{!destructuring}}', // TODO: 这联动一直报错 - required: false, - }, - subName: { - type: 'string', - title: '子导出名', - // hide: '{{!destructuring}}', - required: false, - }, - main: { - type: 'string', - title: '入口文件', - required: false, - }, - }, -}; - -const FORM_SCHEMA_FUNCTION = { - type: 'object', - properties: { - type: TYPE_FIELD(), - name: NAME_FIELD(), - functionExpr: { - type: 'string', - title: '函数定义', - required: true, - 'x-component': 'JSFunction', - 'x-component-props': { - defaultValue: `/** - * 这里是一个 util 函数的示例 - * 在工具类扩展中,可以通过 this.xxx 来访问各种上下文 API - **/ -function () { - console.log("Hello world! (Context: %o)", this); - // TODO: 完善这个 util 函数 -} -`, - }, - }, - }, -}; - -export interface UtilsFormProps { - item?: Partial<UtilItem> | null; - onComplete?: (item: UtilItem) => void; - onCancel?: () => void; -} - -/** - * 通过是否存在 ID 来决定读写状态 - */ -export class UtilsForm extends PureComponent<UtilsFormProps, unknown> { - state = {}; - - private handleFormSubmit = (formData: any) => { - const utilItem = parseFlatUtilItem(formData); - - if (this.props.onComplete) { - this.props.onComplete(utilItem); - } - }; - - private handleCancel = () => { - if (this.props.onCancel) { - this.props.onCancel(); - } - }; - - private getInitialValues = memorize((utilItem: Partial<UtilItem> | undefined | null) => { - return flattenUtilItem(utilItem || {}); - }); - - private readonly formComponents = { - string: Input, - boolean: Switch, - number: NumberPicker, - ArrayTable, - Input, - NumberPicker, - Switch, - JSFunction, - }; - - private readonly formLabelCol = { - span: 6, - }; - - private readonly formWrapperCol = { - span: 16, - }; - - private get schema() { - return this.props.item?.type === 'function' ? FORM_SCHEMA_FUNCTION : FORM_SCHEMA_NPM; - } - - render() { - const { item } = this.props; - - return ( - <div className="lowcode-plugin-utils-form"> - <SchemaForm - onSubmit={this.handleFormSubmit} - components={this.formComponents} - labelCol={this.formLabelCol} - wrapperCol={this.formWrapperCol} - schema={this.schema} - initialValues={this.getInitialValues(item)} - > - <FormButtonGroup offset={this.formLabelCol.span}> - <Submit>保存</Submit> - <Button onClick={this.handleCancel}>取消</Button> - </FormButtonGroup> - </SchemaForm> - </div> - ); - } -} - -function TYPE_FIELD() { - return { - title: '类型', - type: 'string', - editable: false, - 'x-component': 'Input', - 'x-component-props': { - readOnly: true, - }, - }; -} - -function NAME_FIELD() { - return { - type: 'string', - title: '引用名', - required: true, - 'x-component-props': { - placeholder: '请输入引用名(工具类扩展在引用时的名称)', - autoFocus: true, - }, - 'x-rules': { - format: 'util_name_js_identifier', - }, - }; -} - -function flattenUtilItem(utilItem: Partial<UtilItem>): FlatUtilItem { - return { - ...(utilItem.type === 'function' - ? { - functionExpr: utilItem.content?.value, - } - : utilItem.content), - - name: utilItem.name || '', - type: utilItem.type || 'npm', - }; -} - -function parseFlatUtilItem(flatUtil: FlatUtilItem): UtilItem { - if (flatUtil.type === 'function') { - return { - name: flatUtil.name, - type: flatUtil.type, - content: { - type: 'JSFunction', - value: flatUtil.functionExpr || '', - }, - }; - } - - return { - name: flatUtil.name, - type: flatUtil.type, - content: { - componentName: flatUtil.componentName || flatUtil.name, - package: flatUtil.package || '', - version: flatUtil.version, - destructuring: flatUtil.destructuring ?? false, - exportName: flatUtil.exportName, - subName: flatUtil.subName, - main: flatUtil.main, - }, - }; -} diff --git a/packages/plugin-utils-pane/src/utils-types.tsx b/packages/plugin-utils-pane/src/utils-types.tsx deleted file mode 100644 index 00121aba3..000000000 --- a/packages/plugin-utils-pane/src/utils-types.tsx +++ /dev/null @@ -1,16 +0,0 @@ -import { UtilTypeInfo } from './pane'; - -export const DEFAULT_UTILS_TYPES: UtilTypeInfo[] = [ - { - type: 'npm', - label: 'NPM 包', - }, - { - type: 'tnpm', - label: 'TNPM 包', - }, - { - type: 'function', - label: '自定义函数', - }, -]; diff --git a/packages/plugin-utils-pane/tsconfig.json b/packages/plugin-utils-pane/tsconfig.json deleted file mode 100644 index 4a965ec62..000000000 --- a/packages/plugin-utils-pane/tsconfig.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -} - diff --git a/packages/plugin-variable-bind-dialog/CHANGELOG.md b/packages/plugin-variable-bind-dialog/CHANGELOG.md deleted file mode 100644 index a23db60e7..000000000 --- a/packages/plugin-variable-bind-dialog/CHANGELOG.md +++ /dev/null @@ -1,464 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -<a name="1.0.21"></a> -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.20...@ali/lowcode-plugin-variable-bind-dialog@1.0.21) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.20"></a> -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.19...@ali/lowcode-plugin-variable-bind-dialog@1.0.20) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.19"></a> -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.18...@ali/lowcode-plugin-variable-bind-dialog@1.0.19) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.18"></a> -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.17...@ali/lowcode-plugin-variable-bind-dialog@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.17"></a> -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.16...@ali/lowcode-plugin-variable-bind-dialog@1.0.17) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.16"></a> -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.15...@ali/lowcode-plugin-variable-bind-dialog@1.0.16) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.15"></a> -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.14...@ali/lowcode-plugin-variable-bind-dialog@1.0.15) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.14"></a> -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.12...@ali/lowcode-plugin-variable-bind-dialog@1.0.14) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.13"></a> -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.12...@ali/lowcode-plugin-variable-bind-dialog@1.0.13) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.12"></a> -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.11...@ali/lowcode-plugin-variable-bind-dialog@1.0.12) (2020-10-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.11"></a> -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.10...@ali/lowcode-plugin-variable-bind-dialog@1.0.11) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.10"></a> -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.9...@ali/lowcode-plugin-variable-bind-dialog@1.0.10) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.9"></a> -## [1.0.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.8...@ali/lowcode-plugin-variable-bind-dialog@1.0.9) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.8"></a> -## [1.0.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.8-0...@ali/lowcode-plugin-variable-bind-dialog@1.0.8) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.8-0"></a> -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.32...@ali/lowcode-plugin-variable-bind-dialog@1.0.8-0) (2020-09-09) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) - - - - -<a name="0.8.32"></a> -## [0.8.32](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.31...@ali/lowcode-plugin-variable-bind-dialog@0.8.32) (2020-09-03) -<a name="1.0.7-0"></a> -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.6-0...@ali/lowcode-plugin-variable-bind-dialog@1.0.7-0) (2020-09-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.31"></a> -## [0.8.31](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.30...@ali/lowcode-plugin-variable-bind-dialog@0.8.31) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog -<a name="1.0.6-0"></a> -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.30...@ali/lowcode-plugin-variable-bind-dialog@1.0.6-0) (2020-09-02) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) - - - - -<a name="1.0.5-0"></a> -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.4-0...@ali/lowcode-plugin-variable-bind-dialog@1.0.5-0) (2020-08-20) - -<a name="0.8.30"></a> -## [0.8.30](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.29...@ali/lowcode-plugin-variable-bind-dialog@0.8.30) (2020-08-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.29"></a> -## [0.8.29](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.28...@ali/lowcode-plugin-variable-bind-dialog@0.8.29) (2020-08-24) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.28"></a> -## [0.8.28](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.27...@ali/lowcode-plugin-variable-bind-dialog@0.8.28) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.4-0"></a> -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.3-0...@ali/lowcode-plugin-variable-bind-dialog@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.3-0"></a> -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.2-0...@ali/lowcode-plugin-variable-bind-dialog@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.2-0"></a> -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@1.0.1-0...@ali/lowcode-plugin-variable-bind-dialog@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.1-0"></a> -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.27...@ali/lowcode-plugin-variable-bind-dialog@1.0.1-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="1.0.0"></a> -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.13.0...@ali/lowcode-plugin-variable-bind-dialog@1.0.0) (2020-08-17) -<a name="0.8.27"></a> -## [0.8.27](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.26...@ali/lowcode-plugin-variable-bind-dialog@0.8.27) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.13.0"></a> -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.12.0...@ali/lowcode-plugin-variable-bind-dialog@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.12.0"></a> -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.10.0...@ali/lowcode-plugin-variable-bind-dialog@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.11.0"></a> -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.10.0...@ali/lowcode-plugin-variable-bind-dialog@0.11.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.10.0"></a> -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.9.0...@ali/lowcode-plugin-variable-bind-dialog@0.10.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.9.0"></a> -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.25...@ali/lowcode-plugin-variable-bind-dialog@0.9.0) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.25"></a> -## [0.8.25](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.24...@ali/lowcode-plugin-variable-bind-dialog@0.8.25) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.24"></a> -## [0.8.24](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.22...@ali/lowcode-plugin-variable-bind-dialog@0.8.24) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.23"></a> -## [0.8.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.22...@ali/lowcode-plugin-variable-bind-dialog@0.8.23) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.22"></a> -## [0.8.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.21...@ali/lowcode-plugin-variable-bind-dialog@0.8.22) (2020-07-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.21"></a> -## [0.8.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.20...@ali/lowcode-plugin-variable-bind-dialog@0.8.21) (2020-07-22) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.20"></a> -## [0.8.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.19...@ali/lowcode-plugin-variable-bind-dialog@0.8.20) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.19"></a> -## [0.8.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.18...@ali/lowcode-plugin-variable-bind-dialog@0.8.19) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.18"></a> -## [0.8.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.17...@ali/lowcode-plugin-variable-bind-dialog@0.8.18) (2020-07-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.17"></a> -## [0.8.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.16...@ali/lowcode-plugin-variable-bind-dialog@0.8.17) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.16"></a> -## [0.8.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.15...@ali/lowcode-plugin-variable-bind-dialog@0.8.16) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.15"></a> -## [0.8.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.14...@ali/lowcode-plugin-variable-bind-dialog@0.8.15) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.14"></a> -## [0.8.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.13...@ali/lowcode-plugin-variable-bind-dialog@0.8.14) (2020-06-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.13"></a> -## [0.8.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.12...@ali/lowcode-plugin-variable-bind-dialog@0.8.13) (2020-05-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.12"></a> -## [0.8.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.11...@ali/lowcode-plugin-variable-bind-dialog@0.8.12) (2020-05-18) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.11"></a> -## [0.8.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.10...@ali/lowcode-plugin-variable-bind-dialog@0.8.11) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.10"></a> -## [0.8.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.9...@ali/lowcode-plugin-variable-bind-dialog@0.8.10) (2020-05-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.9"></a> -## [0.8.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.8...@ali/lowcode-plugin-variable-bind-dialog@0.8.9) (2020-05-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.8"></a> -## [0.8.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.7...@ali/lowcode-plugin-variable-bind-dialog@0.8.8) (2020-05-07) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.7"></a> -## [0.8.7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.6...@ali/lowcode-plugin-variable-bind-dialog@0.8.7) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.6"></a> -## [0.8.6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.5...@ali/lowcode-plugin-variable-bind-dialog@0.8.6) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.5"></a> -## [0.8.5](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.4...@ali/lowcode-plugin-variable-bind-dialog@0.8.5) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.4"></a> -## [0.8.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.3...@ali/lowcode-plugin-variable-bind-dialog@0.8.4) (2020-04-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.3"></a> -## [0.8.3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.2...@ali/lowcode-plugin-variable-bind-dialog@0.8.3) (2020-04-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.2"></a> -## [0.8.2](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-variable-bind-dialog@0.8.1...@ali/lowcode-plugin-variable-bind-dialog@0.8.2) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog - -<a name="0.8.1"></a> -## 0.8.1 (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-variable-bind-dialog diff --git a/packages/plugin-variable-bind-dialog/README.md b/packages/plugin-variable-bind-dialog/README.md deleted file mode 100644 index 8a6fb13f0..000000000 --- a/packages/plugin-variable-bind-dialog/README.md +++ /dev/null @@ -1 +0,0 @@ -## todo diff --git a/packages/plugin-variable-bind-dialog/build.json b/packages/plugin-variable-bind-dialog/build.json deleted file mode 100644 index e791d5b6b..000000000 --- a/packages/plugin-variable-bind-dialog/build.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "plugins": [ - "build-plugin-component", - "build-plugin-fusion", - ["build-plugin-moment-locales", { - "locales": ["zh-cn"] - }] - ] -} diff --git a/packages/plugin-variable-bind-dialog/package.json b/packages/plugin-variable-bind-dialog/package.json deleted file mode 100644 index e1465e713..000000000 --- a/packages/plugin-variable-bind-dialog/package.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "name": "@ali/lowcode-plugin-variable-bind-dialog", - "version": "1.0.21", - "description": "alibaba lowcode editor variable bind dialog plugin", - "files": [ - "es", - "lib" - ], - "main": "lib/index.js", - "module": "es/index.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "keywords": [ - "lowcode", - "editor" - ], - "author": "zude.hzd", - "dependencies": { - "@ali/lowcode-editor-core": "^1.0.22", - "@alifd/next": "^1.19.16", - "react": "^16.8.1", - "react-dom": "^16.8.1" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.3", - "@types/react": "^16.9.13", - "@types/react-dom": "^16.9.4", - "build-plugin-component": "^0.2.7-1", - "build-plugin-fusion": "^0.1.0", - "build-plugin-moment-locales": "^0.1.0" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/plugin-variable-bind-dialog/src/index.scss b/packages/plugin-variable-bind-dialog/src/index.scss deleted file mode 100644 index afc59c927..000000000 --- a/packages/plugin-variable-bind-dialog/src/index.scss +++ /dev/null @@ -1,90 +0,0 @@ -.variable-dialog-body { - width: 730px; - height: 450px; - - - .dialog-small-title { - font-weight: 700; - margin-bottom: 8px; - color: rgb(0, 0, 0); - } - - .dialog-left-container { - float: left; - - .dialog-left-context { - width: 200px; - height: 392px; - border: 1px solid rgba(31, 56, 88, 0.3); - border-radius: 3px; - - .variable-type-container { - width: 200px; - height: 390px; - float: left; - } - - .select-item { - font-size: 12px; - height: 28px; - line-height: 28px; - padding: 0 30px 0 12px; - cursor: pointer; - position: relative; - overflow: hidden; - text-overflow: ellipsis; - white-space: nowrap; - } - - .select-item-active { - background: rgba(128, 128, 128, 0.15); - } - - .event-select-container { - width: 156px; - float: left; - - .event-search-box { - width: 135px; - margin: 10px; - } - } - - .event-list { - overflow-y: auto; - overflow-x: hidden; - height: 342px; - } - - .variable-list{ - font-size: 13px; - .variable-item{ - padding-left: 30px; - cursor: pointer; - height: 30px; - line-height: 30px; - } - - .variable-item:hover{ - background-color: rgba(31, 56, 88, 0.06); - } - } - } - } - - .dialog-right-container { - width: 530px; - padding-left: 20px; - float: left; - - .event-input-container { - margin-bottom: 20px; - } - } -} - -.variable-bind-dialog-bottom{ - .bottom-left-container{ - float: left; - } -} diff --git a/packages/plugin-variable-bind-dialog/src/index.tsx b/packages/plugin-variable-bind-dialog/src/index.tsx deleted file mode 100644 index 1ea9fc466..000000000 --- a/packages/plugin-variable-bind-dialog/src/index.tsx +++ /dev/null @@ -1,162 +0,0 @@ -import { Component } from 'react'; -import { Dialog, Input, Button } from '@alifd/next'; -import { PluginProps } from '@ali/lowcode-types'; -import './index.scss'; - -export default class VariableBindDialog extends Component<PluginProps> { - private loopVariableList: any[] = [ - { - name: 'item', - }, - { - name: 'index', - }, - ]; - - private stateVaroableList: any[] = [ - { - name: 'abc', - }, - { - name: 'title', - }, - { - name: 'jdata', - }, - ]; - - state = { - visiable: false, - variableContext: '', - }; - - openDialog = (bindEventName: string) => { - this.setState({ - visiable: true, - eventName: bindEventName, - }); - }; - - closeDialog = () => { - this.setState({ - visiable: false, - }); - }; - - componentDidMount() { - const { editor, config } = this.props; - editor.on(`${config.pluginKey}.openDialog`, (bindEventName: string) => { - this.openDialog(bindEventName); - }); - } - - initEventName = () => { - const { bindEventName } = this.state; - let eventName = bindEventName; - this.eventList.forEach((item) => { - if (item.name === eventName) { - eventName = `${eventName}_new`; - } - }); - - this.setState({ - eventName, - }); - }; - - onInputChange = (eventName: string) => { - this.setState({ - eventName, - }); - }; - - onSelectItem = (variableName: string) => { - this.setState({ - variableContext: variableName, - }); - - // // 为空是新建事件 - // if (variableName === '') { - // this.initEventName(); - // } else { - // this.setState({ - // selectedEventName: eventName, - // eventName, - // }); - // } - }; - - - onOk = () => { - const { editor } = this.props; - editor.emit('event-setter.bindEvent', this.state.eventName); - this.closeDialog(); - }; - - renderBottom = () => { - return ( - <div className="variable-bind-dialog-bottom"> - <div className="bottom-left-container"> - <Button type="normal" warning>移除绑定</Button> - </div> - - <div className="bottom-right-container"> - <Button type="primary" onClick={this.onOk}>确定</Button>   - <Button type="normal" onClick={this.closeDialog}>取消</Button> - </div> - </div> - ); - }; - - render() { - const { visiable, variableContext } = this.state; - return ( - <Dialog - visible={visiable} - title="变量绑定" - onClose={this.closeDialog} - onCancel={this.closeDialog} - onOk={this.onOk} - footer={this.renderBottom()} - > - <div className="variable-dialog-body"> - <div className="dialog-left-container"> - <div className="dialog-small-title">变量选择</div> - - <div className="dialog-left-context"> - <div className="variable-type-container"> - <div> - <div className="select-item select-item-active">当前上下文</div> - <div className="variable-list"> - {this.loopVariableList.map((item) => ( - <div className="variable-item" onClick={() => this.onSelectItem(item.name)}> - <span>{item.name}</span> - </div> - ))} - </div> - </div> - - <div className="select-item select-item-active">State属性</div> - <div className="variable-list"> - {this.stateVaroableList.map((item) => ( - <div className="variable-item" onClick={() => this.onSelectItem(item.name)}> - <span>{item.name}</span> - </div> - ))} - </div> - </div> - </div> - </div> - - <div className="dialog-right-container"> - <div className="dialog-small-title">绑定</div> - <Input.TextArea style={{ width: '100%', height: '219px' }} value={variableContext} /> - - <div className="dialog-small-title" style={{ marginTop: '13px' }}>帮助</div> - <Input.TextArea style={{ width: '100%', height: '137px' }} /> - </div> - </div> - </Dialog> - ); - } -} diff --git a/packages/plugin-variable-bind-dialog/tsconfig.json b/packages/plugin-variable-bind-dialog/tsconfig.json deleted file mode 100644 index c37b76ecc..000000000 --- a/packages/plugin-variable-bind-dialog/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -} diff --git a/packages/plugin-zh-en/CHANGELOG.md b/packages/plugin-zh-en/CHANGELOG.md deleted file mode 100644 index e7afaf9c9..000000000 --- a/packages/plugin-zh-en/CHANGELOG.md +++ /dev/null @@ -1,500 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -<a name="1.0.21"></a> -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.20...@ali/lowcode-plugin-zh-en@1.0.21) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.20"></a> -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.19...@ali/lowcode-plugin-zh-en@1.0.20) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.19"></a> -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.18...@ali/lowcode-plugin-zh-en@1.0.19) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.18"></a> -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.17...@ali/lowcode-plugin-zh-en@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.17"></a> -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.16...@ali/lowcode-plugin-zh-en@1.0.17) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.16"></a> -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.15...@ali/lowcode-plugin-zh-en@1.0.16) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.15"></a> -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.14...@ali/lowcode-plugin-zh-en@1.0.15) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.14"></a> -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.12...@ali/lowcode-plugin-zh-en@1.0.14) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.13"></a> -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.12...@ali/lowcode-plugin-zh-en@1.0.13) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.12"></a> -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.11...@ali/lowcode-plugin-zh-en@1.0.12) (2020-10-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.11"></a> -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.10...@ali/lowcode-plugin-zh-en@1.0.11) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.10"></a> -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.9...@ali/lowcode-plugin-zh-en@1.0.10) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.9"></a> -## [1.0.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.8...@ali/lowcode-plugin-zh-en@1.0.9) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.8"></a> -## [1.0.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.8-0...@ali/lowcode-plugin-zh-en@1.0.8) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.8-0"></a> -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.36...@ali/lowcode-plugin-zh-en@1.0.8-0) (2020-09-09) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) - - - - -<a name="0.8.36"></a> -## [0.8.36](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.35...@ali/lowcode-plugin-zh-en@0.8.36) (2020-09-03) -<a name="1.0.7-0"></a> -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.6-0...@ali/lowcode-plugin-zh-en@1.0.7-0) (2020-09-02) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.35"></a> -## [0.8.35](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.34...@ali/lowcode-plugin-zh-en@0.8.35) (2020-09-03) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en -<a name="1.0.6-0"></a> -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.34...@ali/lowcode-plugin-zh-en@1.0.6-0) (2020-09-02) - - -### Bug Fixes - -* 合并master分支 ([bd2c6ad](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/bd2c6ad)) - - - - -<a name="1.0.5-0"></a> -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.4-0...@ali/lowcode-plugin-zh-en@1.0.5-0) (2020-08-20) - - -<a name="0.8.34"></a> -## [0.8.34](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.33...@ali/lowcode-plugin-zh-en@0.8.34) (2020-08-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.33"></a> -## [0.8.33](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.32...@ali/lowcode-plugin-zh-en@0.8.33) (2020-08-24) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.32"></a> -## [0.8.32](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.31...@ali/lowcode-plugin-zh-en@0.8.32) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.4-0"></a> -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.3-0...@ali/lowcode-plugin-zh-en@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.3-0"></a> -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.2-0...@ali/lowcode-plugin-zh-en@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.2-0"></a> -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@1.0.1-0...@ali/lowcode-plugin-zh-en@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.1-0"></a> -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.31...@ali/lowcode-plugin-zh-en@1.0.1-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="1.0.0"></a> -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.13.0...@ali/lowcode-plugin-zh-en@1.0.0) (2020-08-17) -<a name="0.8.31"></a> -## [0.8.31](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.30...@ali/lowcode-plugin-zh-en@0.8.31) (2020-08-19) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.13.0"></a> -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.12.0...@ali/lowcode-plugin-zh-en@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.12.0"></a> -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.10.0...@ali/lowcode-plugin-zh-en@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.11.0"></a> -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.10.0...@ali/lowcode-plugin-zh-en@0.11.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.10.0"></a> -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.9.0...@ali/lowcode-plugin-zh-en@0.10.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.9.0"></a> -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.29...@ali/lowcode-plugin-zh-en@0.9.0) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.29"></a> -## [0.8.29](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.28...@ali/lowcode-plugin-zh-en@0.8.29) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.28"></a> -## [0.8.28](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.26...@ali/lowcode-plugin-zh-en@0.8.28) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.27"></a> -## [0.8.27](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.26...@ali/lowcode-plugin-zh-en@0.8.27) (2020-08-04) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.26"></a> -## [0.8.26](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.25...@ali/lowcode-plugin-zh-en@0.8.26) (2020-07-28) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.25"></a> -## [0.8.25](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.24...@ali/lowcode-plugin-zh-en@0.8.25) (2020-07-22) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.24"></a> -## [0.8.24](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.23...@ali/lowcode-plugin-zh-en@0.8.24) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.23"></a> -## [0.8.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.22...@ali/lowcode-plugin-zh-en@0.8.23) (2020-07-21) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.22"></a> -## [0.8.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.21...@ali/lowcode-plugin-zh-en@0.8.22) (2020-07-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.21"></a> -## [0.8.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.20...@ali/lowcode-plugin-zh-en@0.8.21) (2020-07-12) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.20"></a> -## [0.8.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.19...@ali/lowcode-plugin-zh-en@0.8.20) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.19"></a> -## [0.8.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.18...@ali/lowcode-plugin-zh-en@0.8.19) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.18"></a> -## [0.8.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.17...@ali/lowcode-plugin-zh-en@0.8.18) (2020-06-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.17"></a> -## [0.8.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.16...@ali/lowcode-plugin-zh-en@0.8.17) (2020-05-20) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.16"></a> -## [0.8.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.15...@ali/lowcode-plugin-zh-en@0.8.16) (2020-05-18) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.15"></a> -## [0.8.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.14...@ali/lowcode-plugin-zh-en@0.8.15) (2020-05-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.14"></a> -## [0.8.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.13...@ali/lowcode-plugin-zh-en@0.8.14) (2020-05-13) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.13"></a> -## [0.8.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.12...@ali/lowcode-plugin-zh-en@0.8.13) (2020-05-08) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.12"></a> -## [0.8.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.11...@ali/lowcode-plugin-zh-en@0.8.12) (2020-05-07) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.11"></a> -## [0.8.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.10...@ali/lowcode-plugin-zh-en@0.8.11) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.10"></a> -## [0.8.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.9...@ali/lowcode-plugin-zh-en@0.8.10) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.9"></a> -## [0.8.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.8...@ali/lowcode-plugin-zh-en@0.8.9) (2020-04-27) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.8"></a> -## [0.8.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.7...@ali/lowcode-plugin-zh-en@0.8.8) (2020-04-16) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.7"></a> -## [0.8.7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.6...@ali/lowcode-plugin-zh-en@0.8.7) (2020-04-15) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.6"></a> -## [0.8.6](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.5...@ali/lowcode-plugin-zh-en@0.8.6) (2020-03-31) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.5"></a> -## [0.8.5](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.4...@ali/lowcode-plugin-zh-en@0.8.5) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.4"></a> -## [0.8.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.3...@ali/lowcode-plugin-zh-en@0.8.4) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.3"></a> -## [0.8.3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-plugin-zh-en@0.8.2...@ali/lowcode-plugin-zh-en@0.8.3) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-plugin-zh-en - -<a name="0.8.2"></a> -## 0.8.2 (2020-03-30) - - -### Features - -* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7)) - - - - -<a name="0.8.1"></a> -## 0.8.1 (2020-03-30) - - -### Features - -* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7)) diff --git a/packages/plugin-zh-en/README.md b/packages/plugin-zh-en/README.md deleted file mode 100644 index 8a6fb13f0..000000000 --- a/packages/plugin-zh-en/README.md +++ /dev/null @@ -1 +0,0 @@ -## todo diff --git a/packages/plugin-zh-en/build.json b/packages/plugin-zh-en/build.json deleted file mode 100644 index bd5cf18dd..000000000 --- a/packages/plugin-zh-en/build.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "plugins": [ - "build-plugin-component" - ] -} diff --git a/packages/plugin-zh-en/package.json b/packages/plugin-zh-en/package.json deleted file mode 100644 index 263f08f2f..000000000 --- a/packages/plugin-zh-en/package.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "name": "@ali/lowcode-plugin-zh-en", - "version": "1.0.21", - "description": "alibaba lowcode editor zhong english plugin", - "files": [ - "es", - "lib" - ], - "main": "lib/index.js", - "module": "es/index.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "dependencies": { - "@ali/lowcode-editor-core": "^1.0.22", - "@ali/lowcode-types": "^1.0.20", - "@ali/lowcode-utils": "^1.0.21", - "react": "^16.8.1", - "react-dom": "^16.8.1" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.3", - "@types/react": "^16.9.13", - "@types/react-dom": "^16.9.4", - "build-plugin-component": "^0.2.11" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/plugin-zh-en/src/icons/en.tsx b/packages/plugin-zh-en/src/icons/en.tsx deleted file mode 100644 index 01b545973..000000000 --- a/packages/plugin-zh-en/src/icons/en.tsx +++ /dev/null @@ -1,11 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconEn(props: IconProps) { - return ( - <SVGIcon viewBox="0 0 1024 1024" {...props}> - <path d="M885.7 796.7h-37.3v81.4c0 45-33.4 81.4-74.7 81.4H138.9c-41.2 0-74.7-36.5-74.7-81.4v-570c0-45 33.4-81.4 74.7-81.4h37.3v-81.4c0-45 33.4-81.4 74.7-81.4h634.8c41.2 0 74.7 36.4 74.7 81.4v570c0 45-33.5 81.4-74.7 81.4zM138.9 267.4c-20.6 0-37.3 18.2-37.3 40.7v570c0 22.5 16.7 40.7 37.3 40.7h634.8c20.6 0 37.3-18.2 37.3-40.7v-570c0-22.5-16.7-40.7-37.3-40.7H138.9zM923 145.3c0-22.5-16.7-40.7-37.3-40.7H250.9c-20.6 0-37.3 18.2-37.3 40.7v81.4h560.1c41.2 0 74.7 36.5 74.7 81.4V756h37.3c20.6 0 37.3-18.2 37.3-40.7v-570zM624.3 593.1s4.3-40.7-37.3-40.7c-17 0-37.3 8.9-37.3 40.7V756H475V511.7h149.4c-2.2 0 74.7-5 74.7 81.4V756h-74.7l-0.1-162.9zM213.6 389.6h224v40.7H288.2v122.1h112v40.7h-112v122.1h149.4V756h-224V389.6z" /> - </SVGIcon> - ); -} - -IconEn.displayName = 'IconEn'; diff --git a/packages/plugin-zh-en/src/icons/zh.tsx b/packages/plugin-zh-en/src/icons/zh.tsx deleted file mode 100644 index b5b324dd2..000000000 --- a/packages/plugin-zh-en/src/icons/zh.tsx +++ /dev/null @@ -1,11 +0,0 @@ -import { SVGIcon, IconProps } from '@ali/lowcode-utils'; - -export function IconZh(props: IconProps) { - return ( - <SVGIcon viewBox="0 0 1024 1024" {...props}> - <path d="M885.6 789.8h-37.4v80.6c0 44.5-33.5 80.6-74.8 80.6H138.1c-41.3 0-74.8-36.1-74.8-80.6V306.1c0-44.5 33.5-80.6 74.8-80.6h37.4v-80.6c0-44.5 33.5-80.6 74.8-80.6h635.4c41.3 0 74.8 36.1 74.8 80.6v564.3c-0.1 44.5-33.6 80.6-74.9 80.6z m-747.5-524c-20.7 0-37.4 18.1-37.4 40.3v564.3c0 22.3 16.7 40.3 37.4 40.3h635.4c20.6 0 37.4-18.1 37.4-40.3V306.1c0-22.3-16.7-40.3-37.4-40.3H138.1z m784.9-121c0-22.3-16.7-40.3-37.4-40.3H250.2c-20.6 0-37.4 18-37.4 40.3v80.6h560.6c41.3 0 74.8 36.1 74.8 80.6v443.4h37.4c20.6 0 37.4-18 37.4-40.3V144.8zM586.6 628.5h-74.8v161.2H399.7V628.5H325v40.3h-74.8V427h149.5v-80.6h112.1V427h149.5v241.8h-74.8l0.1-40.3zM399.7 467.3H325v120.9h74.8l-0.1-120.9z m186.9 0h-74.8v120.9h74.8V467.3z" /> - </SVGIcon> - ); -} - -IconZh.displayName = 'IconZh'; diff --git a/packages/plugin-zh-en/src/index.less b/packages/plugin-zh-en/src/index.less deleted file mode 100644 index e03f646a1..000000000 --- a/packages/plugin-zh-en/src/index.less +++ /dev/null @@ -1,11 +0,0 @@ -.lowcode-plugin-zh-en { - display: flex; - align-items: center; - justify-content: center; - height: 30px; - cursor: pointer; - color: #8F9BB3; - &:hover { - color: #1F3858; - } -} diff --git a/packages/plugin-zh-en/src/index.tsx b/packages/plugin-zh-en/src/index.tsx deleted file mode 100644 index 7c6234b7a..000000000 --- a/packages/plugin-zh-en/src/index.tsx +++ /dev/null @@ -1,40 +0,0 @@ -import { PureComponent } from 'react'; -import { globalLocale, Tip } from '@ali/lowcode-editor-core'; -import { PluginProps } from '@ali/lowcode-types'; -import { intl } from './locale'; -import { IconZh } from './icons/zh'; -import { IconEn } from './icons/en'; -import './index.less'; - -export default class ZhEn extends PureComponent<PluginProps> { - static displayName = 'LowcodeZhEn'; - - state = { - locale: globalLocale.getLocale(), - }; - - private dispose = globalLocale.onLocaleChange((locale) => { - this.setState({ - locale, - }); - }); - - componentWillUnmount() { - this.dispose(); - } - - render() { - const isZh = this.state.locale === 'zh-CN'; - return ( - <div - className="lowcode-plugin-zh-en" - onClick={() => { - globalLocale.setLocale(isZh ? 'en-US' : 'zh-CN'); - }} - > - {isZh ? <IconZh size={20} /> : <IconEn size={20} />} - <Tip direction="right">{intl('To Locale')}</Tip> - </div> - ); - } -} diff --git a/packages/plugin-zh-en/src/locale/en-US.json b/packages/plugin-zh-en/src/locale/en-US.json deleted file mode 100644 index 3565e2ae1..000000000 --- a/packages/plugin-zh-en/src/locale/en-US.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "To Locale": "中/En切换" -} diff --git a/packages/plugin-zh-en/src/locale/index.ts b/packages/plugin-zh-en/src/locale/index.ts deleted file mode 100644 index dfd17521f..000000000 --- a/packages/plugin-zh-en/src/locale/index.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { createIntl } from '@ali/lowcode-editor-core'; -import en_US from './en-US.json'; -import zh_CN from './zh-CN.json'; - -const { intl, getLocale, setLocale } = createIntl({ - 'en-US': en_US, - 'zh-CN': zh_CN, -}); - -export { intl, getLocale, setLocale }; diff --git a/packages/plugin-zh-en/src/locale/zh-CN.json b/packages/plugin-zh-en/src/locale/zh-CN.json deleted file mode 100644 index 3565e2ae1..000000000 --- a/packages/plugin-zh-en/src/locale/zh-CN.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "To Locale": "中/En切换" -} diff --git a/packages/plugin-zh-en/tsconfig.json b/packages/plugin-zh-en/tsconfig.json deleted file mode 100644 index c37b76ecc..000000000 --- a/packages/plugin-zh-en/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -} diff --git a/packages/rax-provider/CHANGELOG.md b/packages/rax-provider/CHANGELOG.md deleted file mode 100644 index 1750a5f1d..000000000 --- a/packages/rax-provider/CHANGELOG.md +++ /dev/null @@ -1,261 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -<a name="1.0.21"></a> -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.20...@ali/lowcode-rax-provider@1.0.21) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.20"></a> -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.19...@ali/lowcode-rax-provider@1.0.20) (2020-11-10) - - -### Bug Fixes - -* 设计和预览两种场景下 requestHandlersMap 的接入 ([707de45](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/707de45)) - - - - -<a name="1.0.19"></a> -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.18...@ali/lowcode-rax-provider@1.0.19) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.18"></a> -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.17...@ali/lowcode-rax-provider@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.17"></a> -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.16...@ali/lowcode-rax-provider@1.0.17) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.16"></a> -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.15...@ali/lowcode-rax-provider@1.0.16) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.15"></a> -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.14...@ali/lowcode-rax-provider@1.0.15) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.14"></a> -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.12...@ali/lowcode-rax-provider@1.0.14) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.13"></a> -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.12...@ali/lowcode-rax-provider@1.0.13) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.12"></a> -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.11...@ali/lowcode-rax-provider@1.0.12) (2020-10-20) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.11"></a> -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.10...@ali/lowcode-rax-provider@1.0.11) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.10"></a> -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.9...@ali/lowcode-rax-provider@1.0.10) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.9"></a> -## [1.0.9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.8...@ali/lowcode-rax-provider@1.0.9) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.8"></a> -## [1.0.8](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.8-0...@ali/lowcode-rax-provider@1.0.8) (2020-09-28) - - -### Bug Fixes - -* 函数签名及方法名拼写问题 ([e05790b](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/e05790b)) - - - - -<a name="1.0.8-0"></a> -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.7-0...@ali/lowcode-rax-provider@1.0.8-0) (2020-09-09) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.7-0"></a> -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.6-0...@ali/lowcode-rax-provider@1.0.7-0) (2020-09-02) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.6-0"></a> -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.5-0...@ali/lowcode-rax-provider@1.0.6-0) (2020-09-02) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.5-0"></a> -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.4-0...@ali/lowcode-rax-provider@1.0.5-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.4-0"></a> -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.3-0...@ali/lowcode-rax-provider@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.3-0"></a> -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.2-0...@ali/lowcode-rax-provider@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.2-0"></a> -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.1-0...@ali/lowcode-rax-provider@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.1-0"></a> -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@1.0.0...@ali/lowcode-rax-provider@1.0.1-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="1.0.0"></a> -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@0.13.0...@ali/lowcode-rax-provider@1.0.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="0.13.0"></a> -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@0.12.0...@ali/lowcode-rax-provider@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="0.12.0"></a> -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@0.10.0...@ali/lowcode-rax-provider@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="0.11.0"></a> -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@0.10.0...@ali/lowcode-rax-provider@0.11.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="0.10.0"></a> -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@0.9.0...@ali/lowcode-rax-provider@0.10.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="0.9.0"></a> -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@0.8.15...@ali/lowcode-rax-provider@0.9.0) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-rax-provider - -<a name="0.8.15"></a> -## [0.8.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-rax-provider@0.8.14...@ali/lowcode-rax-provider@0.8.15) (2020-07-22) - - -### Features - -* rax render ([95bf331](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/95bf331)) - - - - -<a name="0.8.14"></a> -## 0.8.14 (2020-06-23) - - -### Features - -* **rax-provider:** init ([cb0f382](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/cb0f382)) - - - - -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. diff --git a/packages/rax-provider/README.md b/packages/rax-provider/README.md deleted file mode 100644 index f37b9b0f6..000000000 --- a/packages/rax-provider/README.md +++ /dev/null @@ -1 +0,0 @@ -# 低代码引擎运行时框架 diff --git a/packages/rax-provider/build.json b/packages/rax-provider/build.json deleted file mode 100644 index 3edf14380..000000000 --- a/packages/rax-provider/build.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "plugins": [ - [ - "build-plugin-rax-component", - { - "type": "rax", - "targets": ["web"] - } - ] - ] -} diff --git a/packages/rax-provider/package.json b/packages/rax-provider/package.json deleted file mode 100644 index b6da801da..000000000 --- a/packages/rax-provider/package.json +++ /dev/null @@ -1,33 +0,0 @@ -{ - "name": "@ali/lowcode-rax-provider", - "version": "1.0.21", - "description": "Rax Provider for Runtime", - "files": [ - "es", - "lib" - ], - "main": "lib/index.js", - "module": "es/index.js", - "scripts": { - "start": "build-scripts start", - "build": "build-scripts build" - }, - "peerDependencies": { - "prop-types": "^15.7.2", - "rax": "^1.1.0" - }, - "license": "MIT", - "dependencies": { - "@ali/lowcode-runtime": "^1.0.23", - "driver-universal": "^3.1.3", - "history": "^4.10.1", - "rax-use-router": "^3.0.0" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.18", - "build-plugin-rax-component": "^0.2.0" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/rax-provider/src/index.ts b/packages/rax-provider/src/index.ts deleted file mode 100644 index e51321b80..000000000 --- a/packages/rax-provider/src/index.ts +++ /dev/null @@ -1,5 +0,0 @@ -import RaxProvider from './provider'; -import getRouter from './router'; - -export { getRouter }; -export default RaxProvider; diff --git a/packages/rax-provider/src/lazy-component.ts b/packages/rax-provider/src/lazy-component.ts deleted file mode 100644 index 5430c75b9..000000000 --- a/packages/rax-provider/src/lazy-component.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { createElement, useState, useEffect } from 'rax'; -import { app } from '@ali/lowcode-runtime'; - -export default function LazyComponent(props) { - const [schema, setSchema] = useState(null); - - useEffect(() => { - (async () => { - const { getPageData } = props || {}; - if (getPageData && !schema) { - const data = await getPageData(); - setSchema(data); - } - })(); - }); - - const { getPageData, ...restProps } = props || {}; - const Renderer = app.getRenderer(); - const Loading = app.getLoading(); - if (!Renderer || !schema) { - if (!Loading) { - return null; - } - // loading扩展点 - return createElement(Loading); - } - return createElement(Renderer, { schema, loading: Loading ? createElement(Loading) : null, ...restProps }); -} diff --git a/packages/rax-provider/src/provider.ts b/packages/rax-provider/src/provider.ts deleted file mode 100644 index 2412fb55d..000000000 --- a/packages/rax-provider/src/provider.ts +++ /dev/null @@ -1,109 +0,0 @@ -import { createElement, render } from 'rax'; -import UniversalDriver from 'driver-universal'; -import { app, Provider } from '@ali/lowcode-runtime'; -import { AppHelper } from '@ali/lowcode-utils'; -import LazyComponent from './lazy-component'; -import getRouter from './router'; - -export default class RaxProvider extends Provider { - // 定制构造根组件的逻辑,如切换路由机制 - createApp() { - const RouterView = this.getRouterView(); - let App; - const layoutConfig = this.getLayoutConfig(); - if (!layoutConfig || !layoutConfig.componentName) { - App = (props) => { - return RouterView ? createElement(RouterView, { ...props }) : null; - }; - return App; - } - const { componentName: layoutName, props: layoutProps } = layoutConfig; - const { content: Layout, props: extraLayoutProps } = app.getLayout(layoutName) || {}; - if (!this.isSectionalRender && Layout) { - App = (props) => createElement( - Layout, - { ...layoutProps, ...extraLayoutProps }, - RouterView ? createElement(RouterView, props) : null, - ); - } else { - App = (props) => { - return RouterView ? createElement(RouterView, props) : null; - }; - } - return App; - } - - runApp(App, config) { - render(createElement(App), document.getElementById(config?.containerId || 'App'), { driver: UniversalDriver }); - } - - // 内置实现 for 动态化渲染 - getRouterView() { - const routerConfig = this.getRouterConfig(); - if (!routerConfig) { - return null; - } - const routes = []; - let homePageId = this.getHomePage(); - Object.keys(routerConfig).forEach((pageId, idx) => { - if (!pageId) { - return; - } - const path = routerConfig[pageId]; - routes.push({ - path, - component: (props: any) => this.getLazyComponent(pageId, { - components: this.getComponents(), - utils: this.getUtils(), - componentsMap: this.getComponentsMapObj(), - ...props, - }), - }); - if (homePageId) { - return; - } - if (idx === 0 || path === '/') { - homePageId = pageId; - } - }); - if (homePageId) { - routes.push({ - path: '**', - component: (props) => this.getLazyComponent(homePageId, { - components: this.getComponents(), - utils: this.getUtils(), - componentsMap: this.getComponentsMapObj(), - ...props, - }), - }); - } - const Router = getRouter({ - history: this.getHistory(), - routes, - }); - const appHelper = new AppHelper({}); - appHelper.set('requestHandlersMap', this.getRequestHandlersMap()); - const RouterView = (props) => createElement(Router, { - appHelper, - ...props, - }); - return RouterView; - } - - getLazyComponent(pageId, props) { - if (!pageId) { - return null; - } - if (this.getLazyElement(pageId)) { - return this.getLazyElement(pageId); - } - const lazyElement = createElement(LazyComponent, { - // eslint-disable-next-line no-return-await - getPageData: async () => await this.getPageData(pageId), - key: pageId, - ...props, - }); - this.setLazyElement(pageId, lazyElement); - return lazyElement; - } -} diff --git a/packages/rax-provider/src/router.ts b/packages/rax-provider/src/router.ts deleted file mode 100644 index 5f2ffaba4..000000000 --- a/packages/rax-provider/src/router.ts +++ /dev/null @@ -1,26 +0,0 @@ -import { useRouter } from 'rax-use-router'; -import { createHashHistory, createBrowserHistory } from 'history'; - -const getConfig = (config) => { - let { history } = config; - const { routes } = config; - if (typeof history === 'string') { - if (history === 'hash') { - history = createHashHistory(); - } else if (history === 'browser') { - history = createBrowserHistory(); - } - } - return () => ({ - history, - routes, - }); -}; - -export default function getRouter(config) { - return function Router() { - const configWrapper = getConfig(config); - const { component } = useRouter(configWrapper); - return component; - }; -} diff --git a/packages/rax-provider/tsconfig.json b/packages/rax-provider/tsconfig.json deleted file mode 100644 index e1a57bf23..000000000 --- a/packages/rax-provider/tsconfig.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "compilerOptions": { - "lib": ["es2015", "dom"], - "target": "esnext", - "module": "esnext", - "moduleResolution": "node", - "strict": false, - "strictPropertyInitialization": false, - "allowSyntheticDefaultImports": true, - "esModuleInterop": true, - "jsx": "preserve", - "importHelpers": true, - "experimentalDecorators": true, - "emitDecoratorMetadata": true, - "sourceMap": true, - "forceConsistentCasingInFileNames": true, - "resolveJsonModule": true, - "skipLibCheck": true, - "outDir": "lib" - }, - "exclude": ["test", "lib", "es", "node_modules"], - "include": [ - "src" - ] -} diff --git a/packages/react-provider/CHANGELOG.md b/packages/react-provider/CHANGELOG.md deleted file mode 100644 index c2fa6a5e6..000000000 --- a/packages/react-provider/CHANGELOG.md +++ /dev/null @@ -1,262 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -<a name="1.0.23"></a> -## [1.0.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.22...@ali/lowcode-react-provider@1.0.23) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.22"></a> -## [1.0.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.21...@ali/lowcode-react-provider@1.0.22) (2020-11-10) - - -### Bug Fixes - -* 设计和预览两种场景下 requestHandlersMap 的接入 ([707de45](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/707de45)) - - - - -<a name="1.0.21"></a> -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.20...@ali/lowcode-react-provider@1.0.21) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.20"></a> -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.19...@ali/lowcode-react-provider@1.0.20) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.19"></a> -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.18...@ali/lowcode-react-provider@1.0.19) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.18"></a> -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.17...@ali/lowcode-react-provider@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.17"></a> -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.16...@ali/lowcode-react-provider@1.0.17) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.16"></a> -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.14...@ali/lowcode-react-provider@1.0.16) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.15"></a> -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.14...@ali/lowcode-react-provider@1.0.15) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.14"></a> -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.13...@ali/lowcode-react-provider@1.0.14) (2020-10-20) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.13"></a> -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.12...@ali/lowcode-react-provider@1.0.13) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.12"></a> -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.11...@ali/lowcode-react-provider@1.0.12) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.11"></a> -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.10...@ali/lowcode-react-provider@1.0.11) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.10"></a> -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.8-0...@ali/lowcode-react-provider@1.0.10) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.8-0"></a> -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.7-0...@ali/lowcode-react-provider@1.0.8-0) (2020-09-09) - - -### Features - -* 透出错误边界捕捉不到的错误 ([f224abf](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/f224abf)) - - - - -<a name="1.0.7-0"></a> -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.6-0...@ali/lowcode-react-provider@1.0.7-0) (2020-09-02) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.6-0"></a> -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.5-0...@ali/lowcode-react-provider@1.0.6-0) (2020-09-02) - -### Features - -* 增加错误边界&pageReady钩子 ([3bb2fc1](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/3bb2fc1)) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.5-0"></a> -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.4-0...@ali/lowcode-react-provider@1.0.5-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.4-0"></a> -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.3-0...@ali/lowcode-react-provider@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.3-0"></a> -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.2-0...@ali/lowcode-react-provider@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.2-0"></a> -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.1-0...@ali/lowcode-react-provider@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.1-0"></a> -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@1.0.0...@ali/lowcode-react-provider@1.0.1-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="1.0.0"></a> -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@0.13.0...@ali/lowcode-react-provider@1.0.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="0.13.0"></a> -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@0.12.0...@ali/lowcode-react-provider@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="0.12.0"></a> -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@0.10.0...@ali/lowcode-react-provider@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="0.11.0"></a> -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@0.10.0...@ali/lowcode-react-provider@0.11.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="0.10.0"></a> -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@0.9.0...@ali/lowcode-react-provider@0.10.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="0.9.0"></a> -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@0.8.16...@ali/lowcode-react-provider@0.9.0) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="0.8.16"></a> -## [0.8.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-react-provider@0.8.15...@ali/lowcode-react-provider@0.8.16) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-react-provider - -<a name="0.8.15"></a> -## 0.8.15 (2020-06-23) - - -### Features - -* ReactProvider ([0e50a20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/0e50a20)) - - - - -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. diff --git a/packages/react-provider/README.md b/packages/react-provider/README.md deleted file mode 100644 index f37b9b0f6..000000000 --- a/packages/react-provider/README.md +++ /dev/null @@ -1 +0,0 @@ -# 低代码引擎运行时框架 diff --git a/packages/react-provider/build.json b/packages/react-provider/build.json deleted file mode 100644 index bd5cf18dd..000000000 --- a/packages/react-provider/build.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "plugins": [ - "build-plugin-component" - ] -} diff --git a/packages/react-provider/package.json b/packages/react-provider/package.json deleted file mode 100644 index f13d49b0a..000000000 --- a/packages/react-provider/package.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "name": "@ali/lowcode-react-provider", - "version": "1.0.23", - "description": "React Provider for Runtime", - "files": [ - "es", - "lib" - ], - "main": "lib/index.js", - "module": "es/index.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "ava": { - "compileEnhancements": false, - "snapshotDir": "test/fixtures/__snapshots__", - "extensions": [ - "ts" - ], - "require": [ - "ts-node/register" - ] - }, - "license": "MIT", - "dependencies": { - "@ali/lowcode-runtime": "^1.0.23", - "@ali/lowcode-utils": "^1.0.21", - "@recore/router": "^1.0.11", - "react": "^16", - "react-dom": "^16" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.18", - "@types/node": "^13.7.1", - "@types/react": "^16", - "@types/react-dom": "^16", - "build-plugin-component": "^0.2.16" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/react-provider/src/components/LazyComponent/index.tsx b/packages/react-provider/src/components/LazyComponent/index.tsx deleted file mode 100644 index d483400c0..000000000 --- a/packages/react-provider/src/components/LazyComponent/index.tsx +++ /dev/null @@ -1,81 +0,0 @@ -import { Component } from 'react'; -import { app, Provider } from '@ali/lowcode-runtime'; - -interface IProps { - getPageData: () => any; - context: Provider; - [key: string]: any; -} - -interface IState { - schema: Record<string, unknown> | null; - hasError: boolean; -} - -export default class LazyComponent extends Component<IProps, IState> { - constructor(props: IProps) { - super(props); - this.state = { - schema: null, - hasError: false, - }; - } - - static getDerivedStateFromError() { - return { hasError: true }; - } - - async componentDidMount() { - const { getPageData, context } = this.props; - if (getPageData && !this.state.schema) { - try { - const schema = await getPageData(); - this.setState({ schema }); - context.emitPageReady(); - } catch (err) { - this.setState({ hasError: true }); - this.exeAfterCatch(err.message, err.stack); - } - } - } - - exeAfterCatch(error: any, errorInfo?: any) { - const { afterCatch } = app.getErrorBoundary() || {}; - if (typeof afterCatch === 'function') { - afterCatch.call(this, error, errorInfo); - } - } - - componentDidCatch(error: any, errorInfo: any) { - this.exeAfterCatch(error, errorInfo); - } - - render() { - const { schema, hasError } = this.state; - if (hasError) { - const { fallbackUI: ErrorView } = app.getErrorBoundary() || {}; - if (!ErrorView) { - return ''; - } - return <ErrorView />; - } - - const { getPageData, ...restProps } = this.props; - const Renderer = app.getRenderer(); - const Loading = app.getLoading(); - if (!Renderer || !schema) { - if (!Loading) { - return null; - } - // loading扩展点 - return <Loading />; - } - return ( - <Renderer - schema={schema} - loading={Loading ? <Loading /> : null} - {...restProps} - /> - ); - } -} diff --git a/packages/react-provider/src/index.ts b/packages/react-provider/src/index.ts deleted file mode 100644 index 515d26e3e..000000000 --- a/packages/react-provider/src/index.ts +++ /dev/null @@ -1,5 +0,0 @@ -import ReactProvider from './provider'; -import { Router } from '@recore/router'; - -export { Router }; -export default ReactProvider; diff --git a/packages/react-provider/src/provider.tsx b/packages/react-provider/src/provider.tsx deleted file mode 100644 index 377f3359a..000000000 --- a/packages/react-provider/src/provider.tsx +++ /dev/null @@ -1,125 +0,0 @@ -import { createElement, ComponentType, ReactElement } from 'react'; -import ReactDOM from 'react-dom'; -import { Router } from '@recore/router'; -import { app, Provider } from '@ali/lowcode-runtime'; -import { AppHelper } from '@ali/lowcode-utils'; -import LazyComponent from './components/LazyComponent'; - -export default class ReactProvider extends Provider { - // 定制构造根组件的逻辑,如切换路由机制 - createApp() { - const RouterView = this.getRouterView(); - let App: any; - const layoutConfig = this.getLayoutConfig(); - if (!layoutConfig || !layoutConfig.componentName) { - App = (props: any) => { - return (RouterView ? createElement(RouterView, { ...props }) : null); - }; - return App; - } - const { componentName: layoutName, props: layoutProps } = layoutConfig; - const { content: Layout, props: extraLayoutProps } = app.getLayout(layoutName) || {}; - const sectionalRender = this.isSectionalRender; - if (!sectionalRender && Layout) { - App = (props: any) => createElement( - Layout, - { ...layoutProps, ...extraLayoutProps }, - RouterView ? createElement(RouterView, props) : null, - ); - } else { - App = (props: any) => { - return (RouterView ? createElement(RouterView, props) : null); - }; - } - return App; - } - - runApp(App: any, config: any) { - const containerId = config?.containerId || 'App'; - let container = document.getElementById(containerId); - if (!container) { - container = document.createElement('div'); - document.body.appendChild(container); - container.id = containerId; - } - ReactDOM.render(<App />, container); - } - - // 内置实现 for 动态化渲染 - getRouterView(): ComponentType { - const routerConfig = this.getRouterConfig(); - if (!routerConfig) { - return () => null; - } - const routes: Array<{ - path: string; - children: any; - exact: boolean; - defined: { keepAlive: boolean; [key: string]: any }; - }> = []; - let homePageId = this.getHomePage(); - Object.keys(routerConfig).forEach((pageId: string, idx: number) => { - if (!pageId) { - return; - } - const path = routerConfig[pageId]; - routes.push({ - path, - children: (props: any) => this.getLazyComponent(pageId, props), - exact: true, - defined: { keepAlive: true }, - }); - if (homePageId) { - return; - } - if (idx === 0 || path === '/') { - homePageId = pageId; - } - }); - if (homePageId) { - routes.push({ - path: '**', - children: (props: any) => this.getLazyComponent(homePageId, { ...props }), - exact: true, - defined: { keepAlive: true }, - }); - } - const appHelper = new AppHelper({}); - appHelper.set('utils', this.getUtils()); - appHelper.set('constants', this.getConstants()); - appHelper.set('requestHandlersMap', this.getRequestHandlersMap()); - const self = this; - const RouterView = (props: any) => { - return createElement(Router as any, { - routes, - components: self.getComponents(), - utils: self.getUtils(), - appHelper, - componentsMap: self.getComponentsMapObj(), - ...props, - }); - }; - return RouterView; - } - - getLazyComponent(pageId: string, props: any): ReactElement | null { - if (!pageId) { - return null; - } - if (this.getLazyElement(pageId)) { - return this.getLazyElement(pageId); - } else { - const lazyElement = createElement(LazyComponent as any, { - getPageData: async () => { - const pageData = await this.getPageData(pageId); - return pageData; - }, - key: pageId, - context: this, - ...props, - }); - this.setLazyElement(pageId, lazyElement); - return lazyElement; - } - } -} diff --git a/packages/react-provider/tsconfig.json b/packages/react-provider/tsconfig.json deleted file mode 100644 index c37b76ecc..000000000 --- a/packages/react-provider/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -} diff --git a/packages/runtime/CHANGELOG.md b/packages/runtime/CHANGELOG.md deleted file mode 100644 index b26a3069c..000000000 --- a/packages/runtime/CHANGELOG.md +++ /dev/null @@ -1,330 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. -See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. - -<a name="1.0.23"></a> -## [1.0.23](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.22...@ali/lowcode-runtime@1.0.23) (2020-11-16) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.22"></a> -## [1.0.22](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.21...@ali/lowcode-runtime@1.0.22) (2020-11-10) - - -### Bug Fixes - -* 设计和预览两种场景下 requestHandlersMap 的接入 ([707de45](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/707de45)) - - - - -<a name="1.0.21"></a> -## [1.0.21](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.20...@ali/lowcode-runtime@1.0.21) (2020-11-10) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.20"></a> -## [1.0.20](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.19...@ali/lowcode-runtime@1.0.20) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.19"></a> -## [1.0.19](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.18...@ali/lowcode-runtime@1.0.19) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.18"></a> -## [1.0.18](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.17...@ali/lowcode-runtime@1.0.18) (2020-11-05) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.17"></a> -## [1.0.17](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.16...@ali/lowcode-runtime@1.0.17) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.16"></a> -## [1.0.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.14...@ali/lowcode-runtime@1.0.16) (2020-11-04) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.15"></a> -## [1.0.15](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.14...@ali/lowcode-runtime@1.0.15) (2020-11-02) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.14"></a> -## [1.0.14](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.13...@ali/lowcode-runtime@1.0.14) (2020-10-20) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.13"></a> -## [1.0.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.12...@ali/lowcode-runtime@1.0.13) (2020-10-19) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.12"></a> -## [1.0.12](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.11...@ali/lowcode-runtime@1.0.12) (2020-09-29) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.11"></a> -## [1.0.11](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.10...@ali/lowcode-runtime@1.0.11) (2020-09-28) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.10"></a> -## [1.0.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.8-0...@ali/lowcode-runtime@1.0.10) (2020-09-28) - - -### Bug Fixes - -* 函数签名及方法名拼写问题 ([e05790b](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/e05790b)) - - - - -<a name="1.0.8-0"></a> -## [1.0.8-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.7-0...@ali/lowcode-runtime@1.0.8-0) (2020-09-09) - - -### Features - -* 透出错误边界捕捉不到的错误 ([f224abf](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/f224abf)) - - - - -<a name="1.0.7-0"></a> -## [1.0.7-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.6-0...@ali/lowcode-runtime@1.0.7-0) (2020-09-02) - - -**Note:** Version bump only for package @ali/lowcode-runtime - - -<a name="1.0.6-0"></a> -## [1.0.6-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.5-0...@ali/lowcode-runtime@1.0.6-0) (2020-08-31) - - -### Bug Fixes - -* 取消Provider的校验 ([a1755f2](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/a1755f2)) - - -### Features - -* 兼容通过api更新属性的场景 ([b58d59b](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b58d59b)) -* 增加错误边界&pageReady钩子 ([3bb2fc1](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/3bb2fc1)) -* 增加若干钩子方法 ([eb55712](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/eb55712)) -* 支持多个provider ([642c62e](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/642c62e)) -* 支持多个Provider ([e35357f](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/e35357f)) - - - -<a name="1.0.5-0"></a> -## [1.0.5-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.4-0...@ali/lowcode-runtime@1.0.5-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.4-0"></a> -## [1.0.4-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.3-0...@ali/lowcode-runtime@1.0.4-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.3-0"></a> -## [1.0.3-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.2-0...@ali/lowcode-runtime@1.0.3-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.2-0"></a> -## [1.0.2-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.1-0...@ali/lowcode-runtime@1.0.2-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.1-0"></a> -## [1.0.1-0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@1.0.0...@ali/lowcode-runtime@1.0.1-0) (2020-08-20) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="1.0.0"></a> -# [1.0.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.13.0...@ali/lowcode-runtime@1.0.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="0.13.0"></a> -# [0.13.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.12.0...@ali/lowcode-runtime@0.13.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="0.12.0"></a> -# [0.12.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.10.0...@ali/lowcode-runtime@0.12.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="0.11.0"></a> -# [0.11.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.10.0...@ali/lowcode-runtime@0.11.0) (2020-08-17) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="0.10.0"></a> -# [0.10.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.9.0...@ali/lowcode-runtime@0.10.0) (2020-08-16) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="0.9.0"></a> -# [0.9.0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.8.13...@ali/lowcode-runtime@0.9.0) (2020-08-14) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="0.8.16"></a> -## [0.8.16](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.8.13...@ali/lowcode-runtime@0.8.16) (2020-06-23) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="0.8.13"></a> -## [0.8.13](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.8.10...@ali/lowcode-runtime@0.8.13) (2020-04-27) - - -### Features - -* add init and ready lifecycles ([fd100c9](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/fd100c9)) -* 支持编译渲染 ([0a42151](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/0a42151)) -* 支持配置layouts属性 ([8464235](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/8464235)) -* 透出loading ([e96934a](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/e96934a)) - - - - -<a name="0.8.10"></a> -## [0.8.10](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.8.7...@ali/lowcode-runtime@0.8.10) (2020-04-15) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="0.8.7"></a> -## [0.8.7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.8.4...@ali/lowcode-runtime@0.8.7) (2020-03-31) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="0.8.4"></a> -## [0.8.4](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.8.3...@ali/lowcode-runtime@0.8.4) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="0.8.3"></a> -## [0.8.3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/compare/@ali/lowcode-runtime@0.8.2...@ali/lowcode-runtime@0.8.3) (2020-03-30) - - - - -**Note:** Version bump only for package @ali/lowcode-runtime - -<a name="0.8.2"></a> -## 0.8.2 (2020-03-30) - - -### Bug Fixes - -* remove abstract identifier ([2e45266](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/2e45266)) - - -### Features - -* complet preview ([56c16ff](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/56c16ff)) - - - - -<a name="0.8.1"></a> -## 0.8.1 (2020-03-30) - - -### Bug Fixes - -* remove abstract identifier ([2e45266](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/2e4526667d563dccb85b9e3c60d862500f308915)) - - -### Features - -* complet preview ([56c16ff](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/56c16ffa5c39c2d01abd9cfa90fea49a4539da1d)) diff --git a/packages/runtime/README.md b/packages/runtime/README.md deleted file mode 100644 index f37b9b0f6..000000000 --- a/packages/runtime/README.md +++ /dev/null @@ -1 +0,0 @@ -# 低代码引擎运行时框架 diff --git a/packages/runtime/build.json b/packages/runtime/build.json deleted file mode 100644 index bd5cf18dd..000000000 --- a/packages/runtime/build.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "plugins": [ - "build-plugin-component" - ] -} diff --git a/packages/runtime/package.json b/packages/runtime/package.json deleted file mode 100644 index 18f9f48e6..000000000 --- a/packages/runtime/package.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "name": "@ali/lowcode-runtime", - "version": "1.0.23", - "description": "Runtime for Ali lowCode engine", - "files": [ - "es", - "lib" - ], - "main": "lib/index.js", - "module": "es/index.js", - "scripts": { - "build": "build-scripts build --skip-demo", - "test": "ava", - "test:snapshot": "ava --update-snapshots" - }, - "ava": { - "compileEnhancements": false, - "snapshotDir": "test/fixtures/__snapshots__", - "extensions": [ - "ts" - ], - "require": [ - "ts-node/register" - ] - }, - "license": "MIT", - "dependencies": { - "@ali/offline-events": "^1.0.0", - "history": "^4.10.1" - }, - "devDependencies": { - "@alib/build-scripts": "^0.1.18", - "@types/node": "^13.7.1", - "build-plugin-component": "^0.2.16" - }, - "publishConfig": { - "registry": "https://registry.npm.alibaba-inc.com" - } -} diff --git a/packages/runtime/src/core/index.ts b/packages/runtime/src/core/index.ts deleted file mode 100644 index 1bc32227e..000000000 --- a/packages/runtime/src/core/index.ts +++ /dev/null @@ -1,99 +0,0 @@ -import Provider from './provider'; -import runApp from './runApp'; - -export interface ILayoutOptions { - componentName?: string; - props?: any; -} - -export interface IErrorBoundaryConfig { - fallbackUI: any; - afterCatch?: (...rest: any) => any -} - -class App { - private renderer: any = null; - - private layouts: { [key: string]: { content: any; props: any } } = {}; - - private loading: any = null; - - private errorBoundary: IErrorBoundaryConfig = { fallbackUI: () => '', afterCatch: () => {} }; - - private providers: { [key: string]: Provider; } = {}; - - run() { - runApp(); - } - - registerRenderer(renderer: any): any { - this.renderer = renderer; - } - - registerLayout(Layout: any, options: ILayoutOptions): any { - if (!options) { - return; - } - const { componentName, props = {} } = options; - if (!componentName || !Layout) { - return; - } - this.layouts[componentName] = { content: Layout, props }; - } - - registerLoading(component: any) { - if (!component) { - return; - } - this.loading = component; - } - - registerErrorBoundary(config: IErrorBoundaryConfig) { - if (!config) { - return; - } - this.errorBoundary = config; - } - - registerProvider(CustomProvider: any) { - try { - const p = new CustomProvider(); - this.providers[p.getContainerId()] = p; - } catch (error) { - console.error(error.message); - } - } - - getLayout(componentName: string) { - if (!componentName) { - return; - } - return this.layouts[componentName]; - } - - getRenderer(): any { - return this.renderer; - } - - getLoading(): any { - return this.loading; - } - - getErrorBoundary(): any { - return this.errorBoundary; - } - - getProvider(id?: string) { - if (!id) { - for (const key in this.providers) { - if (Object.prototype.hasOwnProperty.call(this.providers, key)) { - return this.providers[key]; - } - } - } else { - return this.providers[id]; - } - } -} - -export default new App(); diff --git a/packages/runtime/src/core/provider.ts b/packages/runtime/src/core/provider.ts deleted file mode 100644 index 54601af81..000000000 --- a/packages/runtime/src/core/provider.ts +++ /dev/null @@ -1,428 +0,0 @@ -import { IAppConfig, IUtils, IComponents, HistoryMode } from './runApp'; -import EventEmitter from '@ali/offline-events'; - -interface IConstants { - [key: string]: any; -} - -interface IComponentMap { - componentName: string; - package?: string; - version?: string; - destructuring?: boolean; - exportName?: string; - subName?: string; -} - -interface ILayoutConfig { - componentName: string; - props: any; -} - -interface IRouterConfig { - [key: string]: string; -} - -interface IHistoryConfig { - mode: HistoryMode; - basement?: string; -} - -export interface IAppData { - history?: HistoryMode; - layout?: ILayoutConfig; - routes?: IRouterConfig; - containerId?: string; - components?: IComponents; - componentsMap?: IComponentMap[]; - requestHandlersMap?: any; - utils?: IUtils; - constants?: IConstants; - i18n?: I18n; -} - -export interface ComponentProps { - [key: string]: any; -} - -export interface JSExpression { - type: string; - value: string; - [key: string]: string; -} - -export interface DataSourceItem { - id: string; - isInit: boolean; - type: string; - options: { - uri: string; - params: Record<string, unknown>; - method: string; - shouldFetch?: string; - willFetch?: string; - fit?: string; - didFetch?: string; - }; - dataHandler: JSExpression; -} - -export interface DataSource { - list: DataSourceItem[]; - dataHandler: JSExpression; -} - -export interface LifeCycles { - [key: string]: JSExpression; -} - -export interface Methods { - [key: string]: JSExpression; -} - -export interface ComponentModel { - id?: string; - componentName: string; - fileName?: string; - props?: ComponentProps; - css?: string; - dataSource?: DataSource; - lifeCycles?: LifeCycles; - methods?: Methods; - children?: ComponentModel[] | string[]; - condition?: JSExpression | boolean; - loop?: string[]; - loopArgs?: string[]; -} - -export interface I18n { - 'zh-CN': { [key: string]: string }; - 'en-US': { [key: string]: string }; -} - -type Locale = 'zh-CN' | 'en-US'; - -export default class Provider { - emitter: EventEmitter = new EventEmitter(); - - components: IComponents = {}; - - utils: IUtils = {}; - - constants: IConstants = {}; - - routes: IRouterConfig | null = null; - - layout: ILayoutConfig | null = null; - - componentsMap: IComponentMap[] = []; - - // @TODO 类型定义 - requestHandlersMap: any = null; - - history: HistoryMode = 'hash'; - - containerId = ''; - - i18n: I18n | null = null; - - homePage = ''; - - lazyElementsMap: { [key: string]: any } = {}; - - isSectionalRender = false; - - constructor() { - this.init(); - } - - async(): Promise<IAppConfig> { - // eslint-disable-next-line no-async-promise-executor - return new Promise(async (resolve, reject) => { - try { - const appData: IAppData = await this.getAppData(); - if (!appData) { - return; - } - const { - history, - layout, - routes, - containerId, - components, - componentsMap, - requestHandlersMap, - utils, - constants, - i18n, - } = appData; - this.setHistory(history); - this.setLayoutConfig(layout); - this.setRouterConfig(routes); - this.setContainerId(containerId); - this.setI18n(i18n); - this.registerComponents(components); - this.registerComponentsMap(componentsMap); - this.registerUtils(utils); - this.registerContants(constants); - this.registerRequestHandlersMap(requestHandlersMap); - resolve({ - history: this.getHistory(), - components: this.getComponents(), - utils: this.getUtils(), - containerId: this.getContainerId(), - requestHandlersMap: this.getRequestHandlersMap(), - }); - } catch (err) { - reject(err); - } - }); - } - - init() { - // 默认 ready,当重载了init时需手动触发 this.ready() - this.ready(); - } - - ready(params?: any) { - if (params && typeof params === 'function') { - params = params(); - } - this.emitter.emit('ready', params || ''); - } - - onReady(cb: (params?: any) => void) { - if (!cb || typeof cb !== 'function') { - return; - } - this.emitter.on('ready', cb); - } - - emitPageReady(data?: any) { - this.emitter.emit('pageReady', data || ''); - } - - emitPageEnter(data?: any) { - this.emitter.emit('pageEnter', data || ''); - } - - emitPageUpdate(data?: any) { - this.emitter.emit('pageUpdate', data || ''); - } - - emitPageLeave(data?: any) { - this.emitter.emit('pageLeave', data || ''); - } - - onPageReady(cb: (params?: any) => void) { - this.emitter.on('pageReady', cb); - return () => { - this.emitter.removeListener('pageReady', cb); - }; - } - - onPageEnter(cb: (params?: any) => void) { - this.emitter.on('pageEnter', cb); - return () => { - this.emitter.removeListener('pageEnter', cb); - }; - } - - onPageUpdate(cb: (params?: any) => void) { - this.emitter.on('pageUpdate', cb); - return () => { - this.emitter.removeListener('pageUpdate', cb); - }; - } - - onPageLeave(cb: (params?: any) => void) { - this.emitter.on('pageLeave', cb); - return () => { - this.emitter.removeListener('pageLeave', cb); - }; - } - - getAppData(): any { - throw new Error('Method called "getAppData" not implemented.'); - } - - // eslint-disable-next-line - getPageData(pageId: string): any { - throw new Error('Method called "getPageData" not implemented.'); - } - - // eslint-disable-next-line - getLazyComponent(pageId: string, props: any): any { - throw new Error('Method called "getLazyComponent" not implemented.'); - } - - // 定制构造根组件的逻辑,如切换路由机制 - // eslint-disable-next-line - createApp(params?: any) { - throw new Error('Method called "createApp" not implemented.'); - } - - // eslint-disable-next-line - runApp(App: any, config: IAppConfig) { - throw new Error('Method called "runApp" not implemented.'); - } - - registerComponents(components: IComponents | undefined) { - if (!components) { - return; - } - this.components = components; - } - - registerComponentsMap(componentsMap: IComponentMap[] | undefined) { - if (!componentsMap) { - return; - } - this.componentsMap = componentsMap; - } - - registerUtils(utils: IUtils | undefined) { - if (!utils) { - return; - } - this.utils = utils; - } - - registerContants(constants: IConstants | undefined) { - if (!constants) { - return; - } - this.constants = constants; - } - - registerRequestHandlersMap(requestHandlersMap: any) { - if (!requestHandlersMap) { - return; - } - this.requestHandlersMap = requestHandlersMap; - } - - setLayoutConfig(config: ILayoutConfig | undefined) { - if (!config) { - return; - } - this.layout = config; - } - - setRouterConfig(config: IRouterConfig | undefined) { - if (!config) { - return; - } - this.routes = config; - } - - setHistory(config: HistoryMode | undefined): any { - if (!config) { - return; - } - this.history = config; - } - - setContainerId(id: string | undefined) { - if (!id) { - return; - } - this.containerId = id; - } - - setI18n(i18n: I18n | undefined) { - if (!i18n) { - return; - } - this.i18n = i18n; - } - - setLazyElement(pageId: string, cache: any) { - if (!pageId || !cache) { - return; - } - this.lazyElementsMap[pageId] = cache; - } - - setHomePage(pageId: string) { - if (pageId) { - this.homePage = pageId; - } - } - - getComponents() { - return this.components; - } - - getComponent(name: string) { - if (!name) { - return; - } - return this.components[name]; - } - - getUtils() { - return this.utils; - } - - getConstants() { - return this.constants; - } - - getRequestHandlersMap() { - return this.requestHandlersMap; - } - - getComponentsMap() { - return this.componentsMap; - } - - getComponentsMapObj() { - const compMapArr = this.getComponentsMap(); - if (!compMapArr || !Array.isArray(compMapArr)) { - return; - } - const compMapObj: any = {}; - compMapArr.forEach((item: IComponentMap) => { - if (!item || !item.componentName) { - return; - } - compMapObj[item.componentName] = item; - }); - return compMapObj; - } - - getLayoutConfig() { - return this.layout; - } - - getRouterConfig() { - return this.routes; - } - - getHistory() { - return this.history; - } - - getContainerId() { - return this.containerId || 'App'; - } - - getI18n(locale?: Locale) { - if (!this.i18n) { - return; - } - return locale ? this.i18n[locale] : this.i18n; - } - - getHomePage() { - return this.homePage; - } - - getLazyElement(pageId: string) { - if (!pageId) { - return; - } - return this.lazyElementsMap[pageId]; - } -} diff --git a/packages/runtime/src/core/runApp.ts b/packages/runtime/src/core/runApp.ts deleted file mode 100644 index 604a4b0f6..000000000 --- a/packages/runtime/src/core/runApp.ts +++ /dev/null @@ -1,51 +0,0 @@ -import { HashHistoryBuildOptions, BrowserHistoryBuildOptions, MemoryHistoryBuildOptions } from 'history'; -import app from './index'; - -export type HistoryOptions = { - mode?: HistoryMode; -} & (HashHistoryBuildOptions | BrowserHistoryBuildOptions | MemoryHistoryBuildOptions); - -export interface IComponents { - [key: string]: any; -} - -export interface IUtils { - [key: string]: any; -} - -export type HistoryMode = 'browser' | 'hash' | 'BROWSER' | 'HASH'; - -export interface IAppConfig { - history?: HistoryMode; - components?: IComponents; - utils?: IUtils; - containerId?: string; - [key: string]: any; -} - -export default function runApp() { - const provider = app.getProvider(); - if (!provider) { - throw new Error('Please register class Provider'); - } - provider.onReady((params) => { - const promise = provider.async(); - promise.then((config: IAppConfig) => { - if (!config) { - return; - } - const App = provider.createApp(params); - provider.runApp(App, config); - }).catch((err: Error) => { - console.error(err.message); - const { fallbackUI, afterCatch } = app.getErrorBoundary() || {}; - if (typeof afterCatch === 'function') { - afterCatch(err.message, err.stack); - } - if (!fallbackUI) { - return; - } - provider.runApp(fallbackUI, {}); - }); - }); -} diff --git a/packages/runtime/src/index.ts b/packages/runtime/src/index.ts deleted file mode 100644 index 0e0c9433f..000000000 --- a/packages/runtime/src/index.ts +++ /dev/null @@ -1,4 +0,0 @@ -import Provider from './core/provider'; -import app from './core'; - -export { app, Provider }; diff --git a/packages/runtime/tsconfig.json b/packages/runtime/tsconfig.json deleted file mode 100644 index c37b76ecc..000000000 --- a/packages/runtime/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "outDir": "lib" - }, - "include": [ - "./src/" - ] -}