forked from alibaba/lowcode-engine
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathnode-schema.ts
More file actions
56 lines (46 loc) · 1.05 KB
/
node-schema.ts
File metadata and controls
56 lines (46 loc) · 1.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
import { IPublicTypeCompositeValue, IPublicTypePropsMap, IPublicTypeNodeData } from './';
// 转换成一个 .jsx 文件内 React Class 类 render 函数返回的 jsx 代码
/**
* 搭建基础协议 - 单个组件树节点描述
*/
export interface IPublicTypeNodeSchema {
id?: string;
/**
* 组件名称 必填、首字母大写
*/
componentName: string;
/**
* 组件属性对象
*/
props?: IPublicTypePropsMap; // | PropsList;
/**
* 渲染条件
*/
condition?: IPublicTypeCompositeValue;
/**
* 循环数据
*/
loop?: IPublicTypeCompositeValue;
/**
* 循环迭代对象、索引名称 ["item", "index"]
*/
loopArgs?: [string, string];
/**
* 子节点
*/
children?: IPublicTypeNodeData | IPublicTypeNodeData[];
/**
* 是否锁定
*/
isLocked?: boolean;
// @todo
// ------- future support -----
conditionGroup?: string;
title?: string;
ignore?: boolean;
locked?: boolean;
hidden?: boolean;
isTopFixed?: boolean;
/** @experimental 编辑态内部使用 */
__ctx?: any;
}