mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2026-06-18 13:22:31 +00:00
Compare commits
11 Commits
main
...
v1.0.7-bet
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9284cf4e9b | ||
|
|
0b33f0efa8 | ||
|
|
0a2c37fea8 | ||
|
|
6ae94807a7 | ||
|
|
325d2fb413 | ||
|
|
f71d0079e8 | ||
|
|
5be9b384d6 | ||
|
|
58ed44a6d1 | ||
|
|
1ff46346ac | ||
|
|
44650604a2 | ||
|
|
82a0f50847 |
@ -1,6 +1,6 @@
|
||||
{
|
||||
"lerna": "4.0.0",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"npmClient": "yarn",
|
||||
"useWorkspaces": true,
|
||||
"packages": [
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-designer",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "Designer for Ali LowCode Engine",
|
||||
"main": "lib/index.js",
|
||||
"module": "es/index.js",
|
||||
@ -15,10 +15,10 @@
|
||||
},
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@alilc/lowcode-editor-core": "1.0.6",
|
||||
"@alilc/lowcode-shell": "1.0.6",
|
||||
"@alilc/lowcode-types": "1.0.6",
|
||||
"@alilc/lowcode-utils": "1.0.6",
|
||||
"@alilc/lowcode-editor-core": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-shell": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-types": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-utils": "1.0.7-beta.5",
|
||||
"classnames": "^2.2.6",
|
||||
"enzyme": "^3.11.0",
|
||||
"enzyme-adapter-react-16": "^1.15.5",
|
||||
@ -58,5 +58,5 @@
|
||||
"type": "http",
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/designer"
|
||||
},
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -550,7 +550,7 @@ export class Designer {
|
||||
|
||||
return reducers.reduce((xprops, reducer) => {
|
||||
try {
|
||||
return reducer(xprops, node, { stage });
|
||||
return reducer(xprops, node.internalToShellNode() as any, { stage });
|
||||
} catch (e) {
|
||||
// todo: add log
|
||||
console.warn(e);
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-editor-core",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "Core Api for Ali lowCode engine",
|
||||
"license": "MIT",
|
||||
"main": "lib/index.js",
|
||||
@ -14,8 +14,8 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@alifd/next": "^1.19.16",
|
||||
"@alilc/lowcode-types": "1.0.6",
|
||||
"@alilc/lowcode-utils": "1.0.6",
|
||||
"@alilc/lowcode-types": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-utils": "1.0.7-beta.5",
|
||||
"classnames": "^2.2.6",
|
||||
"debug": "^4.1.1",
|
||||
"intl-messageformat": "^9.3.1",
|
||||
@ -48,5 +48,5 @@
|
||||
"type": "http",
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/editor-core"
|
||||
},
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-editor-skeleton",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "alibaba lowcode editor skeleton",
|
||||
"main": "lib/index.js",
|
||||
"module": "es/index.js",
|
||||
@ -18,10 +18,10 @@
|
||||
],
|
||||
"dependencies": {
|
||||
"@alifd/next": "^1.20.12",
|
||||
"@alilc/lowcode-designer": "1.0.6",
|
||||
"@alilc/lowcode-editor-core": "1.0.6",
|
||||
"@alilc/lowcode-types": "1.0.6",
|
||||
"@alilc/lowcode-utils": "1.0.6",
|
||||
"@alilc/lowcode-designer": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-editor-core": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-types": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-utils": "1.0.7-beta.5",
|
||||
"classnames": "^2.2.6",
|
||||
"react": "^16.8.1",
|
||||
"react-dom": "^16.8.1"
|
||||
@ -42,5 +42,5 @@
|
||||
"type": "http",
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/editor-skeleton"
|
||||
},
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-engine",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "An enterprise-class low-code technology stack with scale-out design / 一套面向扩展设计的企业级低代码技术体系",
|
||||
"main": "lib/engine-core.js",
|
||||
"module": "es/engine-core.js",
|
||||
@ -19,14 +19,14 @@
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@alifd/next": "^1.19.12",
|
||||
"@alilc/lowcode-designer": "1.0.6",
|
||||
"@alilc/lowcode-editor-core": "1.0.6",
|
||||
"@alilc/lowcode-editor-skeleton": "1.0.6",
|
||||
"@alilc/lowcode-designer": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-editor-core": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-editor-skeleton": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-engine-ext": "^1.0.0",
|
||||
"@alilc/lowcode-plugin-designer": "1.0.6",
|
||||
"@alilc/lowcode-plugin-outline-pane": "1.0.6",
|
||||
"@alilc/lowcode-shell": "1.0.6",
|
||||
"@alilc/lowcode-utils": "1.0.6",
|
||||
"@alilc/lowcode-plugin-designer": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-plugin-outline-pane": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-shell": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-utils": "1.0.7-beta.5",
|
||||
"react": "^16.8.1",
|
||||
"react-dom": "^16.8.1"
|
||||
},
|
||||
@ -53,5 +53,5 @@
|
||||
"type": "http",
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/engine"
|
||||
},
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-ignitor",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "点火器,bootstrap lce project",
|
||||
"main": "lib/index.js",
|
||||
"private": true,
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-plugin-designer",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "alibaba lowcode editor designer plugin",
|
||||
"files": [
|
||||
"es",
|
||||
@ -18,9 +18,9 @@
|
||||
],
|
||||
"author": "xiayang.xy",
|
||||
"dependencies": {
|
||||
"@alilc/lowcode-designer": "1.0.6",
|
||||
"@alilc/lowcode-editor-core": "1.0.6",
|
||||
"@alilc/lowcode-utils": "1.0.6",
|
||||
"@alilc/lowcode-designer": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-editor-core": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-utils": "1.0.7-beta.5",
|
||||
"react": "^16.8.1",
|
||||
"react-dom": "^16.8.1"
|
||||
},
|
||||
@ -38,5 +38,5 @@
|
||||
"type": "http",
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/plugin-designer"
|
||||
},
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-plugin-outline-pane",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "Outline pane for Ali lowCode engine",
|
||||
"files": [
|
||||
"es",
|
||||
@ -13,10 +13,10 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@alifd/next": "^1.19.16",
|
||||
"@alilc/lowcode-designer": "1.0.6",
|
||||
"@alilc/lowcode-editor-core": "1.0.6",
|
||||
"@alilc/lowcode-types": "1.0.6",
|
||||
"@alilc/lowcode-utils": "1.0.6",
|
||||
"@alilc/lowcode-designer": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-editor-core": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-types": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-utils": "1.0.7-beta.5",
|
||||
"classnames": "^2.2.6",
|
||||
"react": "^16",
|
||||
"react-dom": "^16.7.0"
|
||||
@ -40,5 +40,5 @@
|
||||
"type": "http",
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/plugin-outline-pane"
|
||||
},
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-rax-renderer",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "Rax renderer for Ali lowCode engine",
|
||||
"main": "lib/index.js",
|
||||
"module": "es/index.js",
|
||||
@ -30,8 +30,8 @@
|
||||
"build": "build-scripts build"
|
||||
},
|
||||
"dependencies": {
|
||||
"@alilc/lowcode-renderer-core": "1.0.6",
|
||||
"@alilc/lowcode-utils": "1.0.6",
|
||||
"@alilc/lowcode-renderer-core": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-utils": "1.0.7-beta.5",
|
||||
"rax-find-dom-node": "^1.0.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
@ -49,5 +49,5 @@
|
||||
},
|
||||
"license": "MIT",
|
||||
"homepage": "https://unpkg.alibaba-inc.com/@alilc/lowcode-rax-renderer@0.1.2/build/index.html",
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-rax-simulator-renderer",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "rax simulator renderer for alibaba lowcode designer",
|
||||
"main": "lib/index.js",
|
||||
"module": "es/index.js",
|
||||
@ -13,10 +13,10 @@
|
||||
"build:umd": "build-scripts build --config build.umd.json"
|
||||
},
|
||||
"dependencies": {
|
||||
"@alilc/lowcode-designer": "1.0.6",
|
||||
"@alilc/lowcode-rax-renderer": "1.0.6",
|
||||
"@alilc/lowcode-types": "1.0.6",
|
||||
"@alilc/lowcode-utils": "1.0.6",
|
||||
"@alilc/lowcode-designer": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-rax-renderer": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-types": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-utils": "1.0.7-beta.5",
|
||||
"classnames": "^2.2.6",
|
||||
"driver-universal": "^3.1.3",
|
||||
"history": "^5.0.0",
|
||||
@ -51,5 +51,5 @@
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/rax-simulator-renderer"
|
||||
},
|
||||
"homepage": "https://unpkg.alibaba-inc.com/@alilc/lowcode-rax-simulator-renderer@1.0.73/build/index.html",
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-react-renderer",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "react renderer for ali lowcode engine",
|
||||
"main": "lib/index.js",
|
||||
"module": "es/index.js",
|
||||
@ -22,7 +22,7 @@
|
||||
],
|
||||
"dependencies": {
|
||||
"@alifd/next": "^1.21.16",
|
||||
"@alilc/lowcode-renderer-core": "1.0.6"
|
||||
"@alilc/lowcode-renderer-core": "1.0.7-beta.5"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@alib/build-scripts": "^0.1.18",
|
||||
@ -43,5 +43,5 @@
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/react-renderer"
|
||||
},
|
||||
"homepage": "https://unpkg.alibaba-inc.com/@alilc/lowcode-react-renderer@1.0.21/build/index.html",
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-react-simulator-renderer",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "react simulator renderer for alibaba lowcode designer",
|
||||
"main": "lib/index.js",
|
||||
"module": "es/index.js",
|
||||
@ -16,10 +16,10 @@
|
||||
"build:umd": "NODE_OPTIONS=--max_old_space_size=8192 build-scripts build --config build.umd.json"
|
||||
},
|
||||
"dependencies": {
|
||||
"@alilc/lowcode-designer": "1.0.6",
|
||||
"@alilc/lowcode-react-renderer": "1.0.6",
|
||||
"@alilc/lowcode-types": "1.0.6",
|
||||
"@alilc/lowcode-utils": "1.0.6",
|
||||
"@alilc/lowcode-designer": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-react-renderer": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-types": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-utils": "1.0.7-beta.5",
|
||||
"classnames": "^2.2.6",
|
||||
"mobx": "^6.3.0",
|
||||
"mobx-react": "^7.2.0",
|
||||
@ -43,5 +43,5 @@
|
||||
"type": "http",
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/react-simulator-renderer"
|
||||
},
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-renderer-core",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "renderer core",
|
||||
"license": "MIT",
|
||||
"main": "lib/index.js",
|
||||
@ -16,8 +16,8 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@alilc/lowcode-datasource-engine": "^1.0.0",
|
||||
"@alilc/lowcode-types": "1.0.6",
|
||||
"@alilc/lowcode-utils": "1.0.6",
|
||||
"@alilc/lowcode-types": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-utils": "1.0.7-beta.5",
|
||||
"classnames": "^2.2.6",
|
||||
"debug": "^4.1.1",
|
||||
"fetch-jsonp": "^1.1.3",
|
||||
@ -34,7 +34,7 @@
|
||||
},
|
||||
"devDependencies": {
|
||||
"@alib/build-scripts": "^0.1.18",
|
||||
"@alilc/lowcode-designer": "1.0.6",
|
||||
"@alilc/lowcode-designer": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-test-mate": "^1.0.1",
|
||||
"@babel/plugin-transform-typescript": "^7.16.8",
|
||||
"@testing-library/react": "^11.2.2",
|
||||
@ -60,5 +60,5 @@
|
||||
"type": "http",
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/renderer-core"
|
||||
},
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -238,7 +238,7 @@ export function leafWrapper(Comp: types.IBaseRenderComponent, {
|
||||
const {
|
||||
hidden = false,
|
||||
condition = true,
|
||||
} = this.leaf?.export(TransformStage.Render) || {};
|
||||
} = this.leaf?.export?.(TransformStage.Render) || {};
|
||||
return {
|
||||
nodeChildren: null,
|
||||
childrenInState: false,
|
||||
|
||||
@ -3,6 +3,7 @@ import { isJSFunction } from '@alilc/lowcode-types';
|
||||
import { transformArrayToMap, transformStringToFunction, clone } from './common';
|
||||
import { jsonp, request, get, post } from './request';
|
||||
import { DataSource, DataSourceItem } from '../types';
|
||||
import logger from './logger';
|
||||
|
||||
const DS_STATUS = {
|
||||
INIT: 'init',
|
||||
@ -179,7 +180,7 @@ export class DataHelper {
|
||||
const _tb_token_ = (csrfInput as any)?.value;
|
||||
asyncDataList.forEach((req) => {
|
||||
const { id, type, options } = req;
|
||||
if (!id || !type) return;
|
||||
if (!id || !type || type === 'legao') return;
|
||||
if (type === 'doServer') {
|
||||
const { uri, params } = options || {};
|
||||
if (!uri) return;
|
||||
@ -310,7 +311,7 @@ export class DataHelper {
|
||||
}
|
||||
}
|
||||
|
||||
console.error(`Engine default dataSource not support type:[${type}] dataSource request!`);
|
||||
logger.log(`Engine default dataSource not support type:[${type}] dataSource request!`, options);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-shell",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "Shell Layer for AliLowCodeEngine",
|
||||
"main": "lib/index.js",
|
||||
"module": "es/index.js",
|
||||
@ -15,11 +15,11 @@
|
||||
},
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@alilc/lowcode-designer": "1.0.6",
|
||||
"@alilc/lowcode-editor-core": "1.0.6",
|
||||
"@alilc/lowcode-editor-skeleton": "1.0.6",
|
||||
"@alilc/lowcode-types": "1.0.6",
|
||||
"@alilc/lowcode-utils": "1.0.6",
|
||||
"@alilc/lowcode-designer": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-editor-core": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-editor-skeleton": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-types": "1.0.7-beta.5",
|
||||
"@alilc/lowcode-utils": "1.0.7-beta.5",
|
||||
"classnames": "^2.2.6",
|
||||
"enzyme": "^3.11.0",
|
||||
"enzyme-adapter-react-16": "^1.15.5",
|
||||
@ -57,5 +57,5 @@
|
||||
"type": "http",
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/shell"
|
||||
},
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -61,6 +61,13 @@ export default class DocumentModel {
|
||||
return new DocumentModel(document);
|
||||
}
|
||||
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
get id() {
|
||||
return this[documentSymbol].id;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取当前文档所属的 project
|
||||
* @returns
|
||||
|
||||
@ -9,6 +9,7 @@ import Props from './props';
|
||||
import DocumentModel from './document-model';
|
||||
import NodeChildren from './node-children';
|
||||
import ComponentMeta from './component-meta';
|
||||
import SettingTopEntry from './setting-top-entry';
|
||||
import { documentSymbol, nodeSymbol } from './symbols';
|
||||
|
||||
const shellNodeSymbol = Symbol('shellNodeSymbol');
|
||||
@ -237,6 +238,10 @@ export default class Node {
|
||||
return this[nodeSymbol].schema;
|
||||
}
|
||||
|
||||
get settingEntry(): any {
|
||||
return SettingTopEntry.create(this[nodeSymbol].settingEntry as any);
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated use .children instead
|
||||
*/
|
||||
|
||||
@ -94,4 +94,23 @@ export default class Props {
|
||||
setExtraPropValue(path: string, value: CompositeValue) {
|
||||
return this.getExtraProp(path)?.setValue(value);
|
||||
}
|
||||
|
||||
/**
|
||||
* test if the specified key is existing or not.
|
||||
* @param key
|
||||
* @returns
|
||||
*/
|
||||
has(key: string) {
|
||||
return this[propsSymbol].has(key);
|
||||
}
|
||||
|
||||
/**
|
||||
* add a key with given value
|
||||
* @param value
|
||||
* @param key
|
||||
* @returns
|
||||
*/
|
||||
add(value: CompositeValue, key?: string | number | undefined) {
|
||||
return this[propsSymbol].add(value, key);
|
||||
}
|
||||
}
|
||||
@ -64,6 +64,10 @@ export default class SettingPropEntry {
|
||||
return this[settingPropEntrySymbol].extraProps;
|
||||
}
|
||||
|
||||
get props() {
|
||||
return SettingTopEntry.create(this[settingPropEntrySymbol].props);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取设置属性对应的节点实例
|
||||
*/
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-types",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "Types for Ali lowCode engine",
|
||||
"files": [
|
||||
"es",
|
||||
@ -30,5 +30,5 @@
|
||||
"type": "http",
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/types"
|
||||
},
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@alilc/lowcode-utils",
|
||||
"version": "1.0.6",
|
||||
"version": "1.0.7-beta.5",
|
||||
"description": "Utils for Ali lowCode engine",
|
||||
"files": [
|
||||
"lib",
|
||||
@ -14,7 +14,7 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@alifd/next": "^1.19.16",
|
||||
"@alilc/lowcode-types": "1.0.6",
|
||||
"@alilc/lowcode-types": "1.0.7-beta.5",
|
||||
"lodash": "^4.17.21",
|
||||
"react": "^16",
|
||||
"zen-logger": "^1.1.0"
|
||||
@ -33,5 +33,5 @@
|
||||
"type": "http",
|
||||
"url": "https://github.com/alibaba/lowcode-engine/tree/main/packages/utils"
|
||||
},
|
||||
"gitHead": "2669f179e6f899d395ce1942d0fe04f9c5ed48a6"
|
||||
"gitHead": "58ed44a6d13a316073cf2c4a012d062748877a50"
|
||||
}
|
||||
|
||||
@ -2,6 +2,15 @@ import { isJSBlock, isJSSlot, ActivityType, NodeSchema, PageSchema, RootSchema }
|
||||
import { isVariable } from './misc';
|
||||
import { isPlainObject } from './is-plain-object';
|
||||
|
||||
function isJsObject(props: any) {
|
||||
if (typeof props === 'object' && props !== null) {
|
||||
return props.type && props.source && props.compiled;
|
||||
}
|
||||
}
|
||||
function isActionRef(props: any): boolean {
|
||||
return props.type && props.type === 'actionRef';
|
||||
}
|
||||
|
||||
/**
|
||||
* 将「乐高版本」协议升级成 JSExpression / JSSlot 等标准协议的结构
|
||||
* @param props
|
||||
@ -40,6 +49,19 @@ export function compatibleLegaoSchema(props: any): any {
|
||||
mock: props.value,
|
||||
};
|
||||
}
|
||||
if (isJsObject(props)) {
|
||||
return {
|
||||
type: 'JSExpression',
|
||||
value: props.compiled,
|
||||
extType: 'function',
|
||||
};
|
||||
}
|
||||
if (isActionRef(props)) {
|
||||
return {
|
||||
type: 'JSExpression',
|
||||
value: `${props.id}.bind(this)`,
|
||||
};
|
||||
}
|
||||
const newProps: any = {};
|
||||
Object.keys(props).forEach((key) => {
|
||||
if (/^__slot__/.test(key) && props[key] === true) {
|
||||
|
||||
@ -22,4 +22,10 @@ lerna run build:umd \
|
||||
--scope @alilc/lowcode-rax-simulator-renderer \
|
||||
--scope @alilc/lowcode-react-simulator-renderer \
|
||||
--scope @alilc/lowcode-react-renderer \
|
||||
--stream
|
||||
--stream
|
||||
|
||||
cp ./packages/react-simulator-renderer/dist/js/* ./packages/engine/dist/js/
|
||||
cp ./packages/react-simulator-renderer/dist/css/* ./packages/engine/dist/css/
|
||||
|
||||
cp ./packages/rax-simulator-renderer/dist/js/* ./packages/engine/dist/js/
|
||||
cp ./packages/rax-simulator-renderer/dist/css/* ./packages/engine/dist/css/
|
||||
Loading…
x
Reference in New Issue
Block a user