mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2025-12-17 15:23:00 +00:00
merge
This commit is contained in:
commit
ff64a86551
@ -45,5 +45,8 @@
|
||||
"ts-node": "^7.0.1",
|
||||
"tslib": "^1.9.3",
|
||||
"typescript": "^3.2.2"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=10.0.0"
|
||||
}
|
||||
}
|
||||
|
||||
@ -31,7 +31,14 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
||||
|
||||
### Features
|
||||
|
||||
<<<<<<< HEAD
|
||||
* code generator main process ([021d6e0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/021d6e0))
|
||||
* demo schema & complex children type ([a5ee6bd](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/a5ee6bd))
|
||||
* fix gaps ([32af3d3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/32af3d3))
|
||||
* project builder fix & publish demo to disk ([26983b3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/26983b3))
|
||||
=======
|
||||
* code generator main process ([021d6e0](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/021d6e0fe9fb29a8b6c1c5d5f4d06ec71896faa5))
|
||||
* demo schema & complex children type ([a5ee6bd](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/a5ee6bd55806fc9aea695096ccd4c7f50b8e31c4))
|
||||
* fix gaps ([32af3d3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/32af3d3a3ca4d5aca15be25e05c840c8ea0cb6ae))
|
||||
* project builder fix & publish demo to disk ([26983b3](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/26983b38c2b0f1d39d79964eb54d8ce60250dd82))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
@ -29,5 +29,10 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
||||
|
||||
### Features
|
||||
|
||||
<<<<<<< HEAD
|
||||
* complet preview ([56c16ff](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/56c16ff))
|
||||
* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7))
|
||||
=======
|
||||
* complet preview ([56c16ff](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/56c16ffa5c39c2d01abd9cfa90fea49a4539da1d))
|
||||
* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7c0c488ef24f825760750a13d3fa083c96))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
23
packages/demo/src/config/components.js
Normal file
23
packages/demo/src/config/components.js
Normal file
@ -0,0 +1,23 @@
|
||||
import undoRedo from '@ali/lowcode-plugin-undo-redo';
|
||||
import zhEn from '@ali/lowcode-plugin-zh-en';
|
||||
import logo from '@ali/lowcode-plugin-sample-logo';
|
||||
import SamplePreview from '@ali/lowcode-plugin-sample-preview';
|
||||
import Designer from '@ali/lowcode-plugin-designer';
|
||||
import SettingsPane from '@ali/lowcode-plugin-settings-pane';
|
||||
import componentsPane from '@ali/lowcode-plugin-components-pane';
|
||||
import OutlinePane from '@ali/lowcode-plugin-outline-pane';
|
||||
import EventBindDialog from '@ali/lowcode-plugin-event-bind-dialog';
|
||||
import VariableBindDialog from '@ali/lowcode-plugin-variable-bind-dialog';
|
||||
import { PluginFactory } from '@ali/lowcode-editor-core';
|
||||
export default {
|
||||
undoRedo: PluginFactory(undoRedo),
|
||||
zhEn: PluginFactory(zhEn),
|
||||
designer: PluginFactory(Designer),
|
||||
componentsPane: PluginFactory(componentsPane),
|
||||
settingsPane: PluginFactory(SettingsPane),
|
||||
outlinePane: PluginFactory(OutlinePane),
|
||||
eventBindDialog:PluginFactory(EventBindDialog),
|
||||
variableBindDialog:PluginFactory(VariableBindDialog),
|
||||
logo: PluginFactory(logo),
|
||||
samplePreview: PluginFactory(SamplePreview)
|
||||
};
|
||||
@ -6,7 +6,8 @@ import designer from '@ali/lowcode-plugin-designer';
|
||||
import settingsPane from '@ali/lowcode-plugin-settings-pane';
|
||||
import componentsPane from '@ali/lowcode-plugin-components-pane';
|
||||
import outlinePane from '@ali/lowcode-plugin-outline-pane';
|
||||
import eventBindDialog from '@ali/lowcode-plugin-event-bind-dialog'
|
||||
import eventBindDialog from '@ali/lowcode-plugin-event-bind-dialog';
|
||||
import variableBindDialog from '@ali/lowcode-plugin-variable-bind-dialog'
|
||||
export default {
|
||||
undoRedo,
|
||||
zhEn,
|
||||
@ -15,6 +16,7 @@ export default {
|
||||
settingsPane,
|
||||
outlinePane,
|
||||
eventBindDialog,
|
||||
variableBindDialog,
|
||||
logo,
|
||||
samplePreview
|
||||
};
|
||||
|
||||
@ -131,6 +131,13 @@ export default {
|
||||
package: '@ali/lowcode-plugin-event-bind-dialog',
|
||||
version: '1.0.0'
|
||||
}
|
||||
},
|
||||
{
|
||||
pluginKey: 'variableBindDialog',
|
||||
config: {
|
||||
package: '@ali/lowcode-plugin-variable-bind-dialog',
|
||||
version: '1.0.0'
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
|
||||
@ -30,6 +30,12 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
||||
|
||||
### Features
|
||||
|
||||
<<<<<<< HEAD
|
||||
* 🎸 merge material-parser ([b40c286](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b40c286))
|
||||
* history log ([fbb3577](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/fbb3577))
|
||||
* import react-docgen to parse propTypes ([6e66168](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/6e66168))
|
||||
=======
|
||||
* 🎸 merge material-parser ([b40c286](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b40c2869a0bc901d855279735fe86b84dabaa04d))
|
||||
* history log ([fbb3577](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/fbb3577bd434c0ac77cc907abc36e3efe110fe8c))
|
||||
* import react-docgen to parse propTypes ([6e66168](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/6e661686e4693e69279c496f3be1dd173703c55e))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
@ -1,6 +1,10 @@
|
||||
{
|
||||
"name": "@ali/lowcode-designer",
|
||||
<<<<<<< HEAD
|
||||
"version": "0.8.4",
|
||||
=======
|
||||
"version": "0.8.2",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"description": "Designer for Ali LowCode Engine",
|
||||
"main": "lib/index.js",
|
||||
"module": "es/index.js",
|
||||
|
||||
@ -28,4 +28,8 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
||||
|
||||
### Features
|
||||
|
||||
<<<<<<< HEAD
|
||||
* 🎸 merge material-parser ([b40c286](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b40c286))
|
||||
=======
|
||||
* 🎸 merge material-parser ([b40c286](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b40c2869a0bc901d855279735fe86b84dabaa04d))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
@ -1,6 +1,10 @@
|
||||
{
|
||||
"name": "@ali/lowcode-editor-skeleton",
|
||||
<<<<<<< HEAD
|
||||
"version": "0.8.4",
|
||||
=======
|
||||
"version": "0.8.1",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"description": "alibaba lowcode editor skeleton",
|
||||
"main": "lib/index.js",
|
||||
"module": "es/index.js",
|
||||
|
||||
@ -28,4 +28,8 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
||||
|
||||
### Features
|
||||
|
||||
<<<<<<< HEAD
|
||||
* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7))
|
||||
=======
|
||||
* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7c0c488ef24f825760750a13d3fa083c96))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
@ -49,23 +49,41 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
<<<<<<< HEAD
|
||||
* 🐛 fix bug of transforming type ([ebbe58d](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/ebbe58d))
|
||||
* 🐛 fix bug of validate schema ([3f97523](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/3f97523))
|
||||
=======
|
||||
* 🐛 fix bug of transforming type ([ebbe58d](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/ebbe58df70f047f4b5fe367ac4b4a08de8a65e5d))
|
||||
* 🐛 fix bug of validate schema ([3f97523](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/3f975232c7cd551bc9c74962095dcc9b127af489))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
|
||||
### Code Refactoring
|
||||
|
||||
<<<<<<< HEAD
|
||||
* 💡 refactor with react-docgen ([64c9daa](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/64c9daa))
|
||||
=======
|
||||
* 💡 refactor with react-docgen ([64c9daa](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/64c9daa1f451fdfeab2777e4beefc5d5e1890ba1))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
<<<<<<< HEAD
|
||||
* complete component protocol json schema & validate method ([3df360d](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/3df360d))
|
||||
* immigrate aimake materialin ([44ac85f](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/44ac85f))
|
||||
* import react-docgen to parse propTypes ([6e66168](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/6e66168))
|
||||
* remove -p tslint.json for test ([6d013e1](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/6d013e1))
|
||||
* remove useless codes & modify generator ([dcd1b33](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/dcd1b33))
|
||||
* support multiple exported components ([db1b6de](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/db1b6de))
|
||||
=======
|
||||
* complete component protocol json schema & validate method ([3df360d](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/3df360de85d425b2926ea50ff26a8df27ec36a78))
|
||||
* immigrate aimake materialin ([44ac85f](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/44ac85f8a6a35bcd50f2e2b74a022e3cebe3cdef))
|
||||
* import react-docgen to parse propTypes ([6e66168](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/6e661686e4693e69279c496f3be1dd173703c55e))
|
||||
* remove -p tslint.json for test ([6d013e1](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/6d013e18f93bad5647cb9ea0a497336f64e1459a))
|
||||
* remove useless codes & modify generator ([dcd1b33](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/dcd1b33d3bf8bdf5577dcc980608d9eac8d99372))
|
||||
* support multiple exported components ([db1b6de](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/db1b6deaca256b0d107fe607de6cd0fc90517a9c))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
|
||||
### BREAKING CHANGES
|
||||
|
||||
@ -1,6 +1,10 @@
|
||||
{
|
||||
"name": "@ali/lowcode-plugin-components-pane",
|
||||
<<<<<<< HEAD
|
||||
"version": "0.8.3",
|
||||
=======
|
||||
"version": "0.8.1",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"description": "alibaba lowcode editor component-list plugin",
|
||||
"files": [
|
||||
"es/",
|
||||
|
||||
@ -1,6 +1,10 @@
|
||||
{
|
||||
"name": "@ali/lowcode-plugin-designer",
|
||||
<<<<<<< HEAD
|
||||
"version": "0.8.3",
|
||||
=======
|
||||
"version": "0.8.1",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"description": "alibaba lowcode editor designer plugin",
|
||||
"files": [
|
||||
"es",
|
||||
|
||||
@ -1,6 +1,10 @@
|
||||
{
|
||||
"name": "@ali/lowcode-plugin-event-bind-dialog",
|
||||
<<<<<<< HEAD
|
||||
"version": "0.8.4",
|
||||
=======
|
||||
"version": "0.8.2",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"description": "alibaba lowcode editor event bind dialog plugin",
|
||||
"files": [
|
||||
"es",
|
||||
|
||||
@ -28,4 +28,8 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
||||
|
||||
### Features
|
||||
|
||||
<<<<<<< HEAD
|
||||
* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7))
|
||||
=======
|
||||
* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7c0c488ef24f825760750a13d3fa083c96))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
@ -1,6 +1,10 @@
|
||||
{
|
||||
"name": "@ali/lowcode-plugin-outline-pane",
|
||||
<<<<<<< HEAD
|
||||
"version": "0.8.4",
|
||||
=======
|
||||
"version": "0.8.2",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"description": "Outline pane for Ali lowCode engine",
|
||||
"files": [
|
||||
"es",
|
||||
|
||||
@ -1,6 +1,10 @@
|
||||
{
|
||||
"name": "@ali/lowcode-plugin-sample-logo",
|
||||
<<<<<<< HEAD
|
||||
"version": "0.8.3",
|
||||
=======
|
||||
"version": "0.8.1",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"description": "alibaba lowcode editor logo plugin",
|
||||
"files": [
|
||||
"es/",
|
||||
|
||||
@ -18,8 +18,13 @@
|
||||
"editor"
|
||||
],
|
||||
"dependencies": {
|
||||
<<<<<<< HEAD
|
||||
"@ali/lowcode-designer": "^0.8.4",
|
||||
"@ali/lowcode-editor-core": "^0.8.4",
|
||||
=======
|
||||
"@ali/lowcode-designer": "^0.8.2",
|
||||
"@ali/lowcode-editor-core": "^0.8.1",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"@alifd/next": "^1.x",
|
||||
"react": "^16.8.1"
|
||||
},
|
||||
|
||||
@ -19,7 +19,11 @@
|
||||
],
|
||||
"author": "xiayang.xy",
|
||||
"dependencies": {
|
||||
<<<<<<< HEAD
|
||||
"@ali/lowcode-editor-core": "^0.8.4",
|
||||
=======
|
||||
"@ali/lowcode-editor-core": "^0.8.1",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"@alifd/next": "^1.x",
|
||||
"react": "^16.8.1"
|
||||
},
|
||||
|
||||
@ -30,6 +30,12 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
||||
|
||||
### Features
|
||||
|
||||
<<<<<<< HEAD
|
||||
* add color-setter ([a149921](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/a149921))
|
||||
* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7))
|
||||
* 增加color-setter,json-setter ([93e76ce](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/93e76ce))
|
||||
=======
|
||||
* add color-setter ([a149921](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/a14992174b65b1241e7bb82561c7efdfd6589606))
|
||||
* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7c0c488ef24f825760750a13d3fa083c96))
|
||||
* 增加color-setter,json-setter ([93e76ce](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/93e76ce3606603ee926ad83b21b29ffe28dc0682))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
@ -1,6 +1,10 @@
|
||||
{
|
||||
"name": "@ali/lowcode-plugin-settings-pane",
|
||||
<<<<<<< HEAD
|
||||
"version": "0.8.5",
|
||||
=======
|
||||
"version": "0.8.3",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"description": "Settings pane for Ali lowCode engine",
|
||||
"files": [
|
||||
"es",
|
||||
|
||||
@ -19,8 +19,13 @@
|
||||
],
|
||||
"author": "xiayang.xy",
|
||||
"dependencies": {
|
||||
<<<<<<< HEAD
|
||||
"@ali/lowcode-editor-core": "^0.8.4",
|
||||
"@ali/lowcode-editor-skeleton": "^0.8.4",
|
||||
=======
|
||||
"@ali/lowcode-editor-core": "^0.8.1",
|
||||
"@ali/lowcode-editor-skeleton": "^0.8.1",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"react": "^16.8.1",
|
||||
"react-dom": "^16.8.1"
|
||||
},
|
||||
|
||||
1
packages/plugin-variable-bind-dialog/README.md
Normal file
1
packages/plugin-variable-bind-dialog/README.md
Normal file
@ -0,0 +1 @@
|
||||
## todo
|
||||
9
packages/plugin-variable-bind-dialog/build.json
Normal file
9
packages/plugin-variable-bind-dialog/build.json
Normal file
@ -0,0 +1,9 @@
|
||||
{
|
||||
"plugins": [
|
||||
"build-plugin-component",
|
||||
"build-plugin-fusion",
|
||||
["build-plugin-moment-locales", {
|
||||
"locales": ["zh-cn"]
|
||||
}]
|
||||
]
|
||||
}
|
||||
38
packages/plugin-variable-bind-dialog/package.json
Normal file
38
packages/plugin-variable-bind-dialog/package.json
Normal file
@ -0,0 +1,38 @@
|
||||
{
|
||||
"name": "@ali/lowcode-plugin-variable-bind-dialog",
|
||||
"version": "0.8.0",
|
||||
"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": {
|
||||
"@alifd/next": "^1.19.16",
|
||||
"@ali/lowcode-editor-core": "^0.8.0",
|
||||
"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"
|
||||
}
|
||||
}
|
||||
90
packages/plugin-variable-bind-dialog/src/index.scss
Normal file
90
packages/plugin-variable-bind-dialog/src/index.scss
Normal file
@ -0,0 +1,90 @@
|
||||
.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;
|
||||
}
|
||||
}
|
||||
166
packages/plugin-variable-bind-dialog/src/index.tsx
Normal file
166
packages/plugin-variable-bind-dialog/src/index.tsx
Normal file
@ -0,0 +1,166 @@
|
||||
import { Component, isValidElement, ReactElement, ReactNode } from 'react';
|
||||
import { Dialog, Search, Input ,Button} from '@alifd/next';
|
||||
import Editor from '@ali/lowcode-editor-core';
|
||||
import './index.scss';
|
||||
|
||||
export default class VariableBindDialog extends Component<{
|
||||
editor: Editor;
|
||||
}> {
|
||||
private loopVariableList: any[] = [
|
||||
{
|
||||
name: 'item',
|
||||
},
|
||||
{
|
||||
name: 'index',
|
||||
},
|
||||
];
|
||||
|
||||
private stateVaroableList: any[] = [
|
||||
{
|
||||
name: 'abc',
|
||||
},
|
||||
{
|
||||
name: 'title',
|
||||
},
|
||||
{
|
||||
name: 'jdata',
|
||||
},
|
||||
];
|
||||
|
||||
state = {
|
||||
visiable: true,
|
||||
selectedVariableName: '',
|
||||
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.map((item) => {
|
||||
if (item.name === eventName) {
|
||||
eventName = `${eventName}_new`;
|
||||
}
|
||||
});
|
||||
|
||||
this.setState({
|
||||
eventName,
|
||||
});
|
||||
};
|
||||
|
||||
onInputChange = (eventName: String) => {
|
||||
this.setState({
|
||||
eventName,
|
||||
});
|
||||
};
|
||||
|
||||
onSelectItem = (variableName: String) => {
|
||||
this.setState({
|
||||
selectedVariableName:variableName,
|
||||
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 { selectedEventName, eventName, 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>
|
||||
);
|
||||
}
|
||||
}
|
||||
9
packages/plugin-variable-bind-dialog/tsconfig.json
Normal file
9
packages/plugin-variable-bind-dialog/tsconfig.json
Normal file
@ -0,0 +1,9 @@
|
||||
{
|
||||
"extends": "../../tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"outDir": "lib"
|
||||
},
|
||||
"include": [
|
||||
"./src/"
|
||||
]
|
||||
}
|
||||
@ -28,4 +28,8 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
||||
|
||||
### Features
|
||||
|
||||
<<<<<<< HEAD
|
||||
* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7))
|
||||
=======
|
||||
* double outline & ZH_EN support ([b379bd7](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/b379bd7c0c488ef24f825760750a13d3fa083c96))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
@ -33,9 +33,17 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
<<<<<<< HEAD
|
||||
* remove abstract identifer ([2e45266](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/2e45266))
|
||||
=======
|
||||
* remove abstract identifer ([2e45266](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/2e4526667d563dccb85b9e3c60d862500f308915))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
<<<<<<< HEAD
|
||||
* complet preview ([56c16ff](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/56c16ff))
|
||||
=======
|
||||
* complet preview ([56c16ff](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/56c16ffa5c39c2d01abd9cfa90fea49a4539da1d))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
@ -28,4 +28,8 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
<<<<<<< HEAD
|
||||
* ts type ([1732e7d](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/1732e7d))
|
||||
=======
|
||||
* ts type ([1732e7d](https://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/commit/1732e7db5fccb6e185cfa12e197ae698932fe127))
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
|
||||
@ -22,7 +22,11 @@
|
||||
"@ali/iceluna-comp-react-node": "^1.0.5",
|
||||
"@ali/iceluna-sdk": "^1.0.5-beta.24",
|
||||
"@ali/lc-style-setter": "^0.0.1",
|
||||
<<<<<<< HEAD
|
||||
"@ali/lowcode-globals": "^0.8.3",
|
||||
=======
|
||||
"@ali/lowcode-globals": "^0.8.1",
|
||||
>>>>>>> df955e1db90ff104cd11160def80113cfd6faccc
|
||||
"@alifd/next": "^1.19.16",
|
||||
"acorn": "^6.4.1",
|
||||
"classnames": "^2.2.6",
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user