ronds-metadata 1.2.10 → 1.2.11
Sign up to get free protection for your applications and to get access to all the features.
- package/es/api/index.js +249 -0
- package/es/comps/DynamicPorts/comps/ContextMenu.js +44 -0
- package/es/comps/DynamicPorts/comps/DragNode.js +55 -0
- package/es/comps/DynamicPorts/comps/GraphHandler/index.js +51 -0
- package/es/comps/DynamicPorts/comps/NodeElement.js +30 -0
- package/es/comps/DynamicPorts/comps/contextMenu/EdgeContextMenu/index.js +42 -0
- package/es/comps/DynamicPorts/comps/contextMenu/GraphContextMenu/index.js +40 -0
- package/es/comps/DynamicPorts/comps/contextMenu/NodeContextMenu/index.js +55 -0
- package/es/comps/DynamicPorts/comps/shape/connector.js +19 -0
- package/es/comps/DynamicPorts/comps/shape/edge.js +91 -0
- package/es/comps/DynamicPorts/comps/shape/node.js +190 -0
- package/es/comps/DynamicPorts/constant/index.js +19 -0
- package/es/comps/DynamicPorts/graph.js +697 -0
- package/es/comps/DynamicPorts/index.js +143 -0
- package/es/comps/DynamicPorts/interface.js +6 -0
- package/es/comps/DynamicPorts/utils.js +127 -0
- package/es/comps/Editable/DataCell/ButtonCell.js +45 -0
- package/es/comps/Editable/DataCell/ColorPicker.js +33 -0
- package/es/comps/Editable/DataCell/Input.js +54 -0
- package/es/comps/Editable/DataCell/Number.js +44 -0
- package/es/comps/Editable/DataCell/Select.js +48 -0
- package/es/comps/Editable/DataCell/Switch.js +33 -0
- package/es/comps/Editable/comps/EditableAction.js +110 -0
- package/es/comps/Editable/comps/EditableCell.js +108 -0
- package/es/comps/Editable/comps/EditableHeardCell.js +172 -0
- package/es/comps/Editable/comps/EditableRow.js +118 -0
- package/es/comps/Editable/comps/Texty.js +277 -0
- package/es/comps/Editable/index.js +386 -0
- package/es/comps/Editable/interface.js +8 -0
- package/es/comps/Editable/utils.js +46 -0
- package/es/comps/FileView/index.js +198 -0
- package/es/comps/FormGenerator/Provider.js +8 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Checkbox.js +69 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Color.js +17 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Date.js +16 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Input.js +17 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/List.js +50 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/MutiSelect.js +55 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Number.js +14 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Obj.js +50 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Password.js +17 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Radio.js +69 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Select.js +55 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Switch.js +13 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Table.js +50 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/TextArea.js +14 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/Cell/Upload.js +27 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/HOC/index.js +261 -0
- package/es/comps/FormGenerator/comps/Canvas/core/RenderField/index.js +62 -0
- package/es/comps/FormGenerator/comps/Canvas/core/index.js +315 -0
- package/es/comps/FormGenerator/comps/Canvas/index.js +120 -0
- package/es/comps/FormGenerator/comps/Settings/index.js +150 -0
- package/es/comps/FormGenerator/comps/Sidebar/Elements.js +48 -0
- package/es/comps/FormGenerator/comps/Sidebar/index.js +37 -0
- package/es/comps/FormGenerator/index.js +68 -0
- package/es/comps/FormGenerator/settings/index.js +367 -0
- package/es/comps/FormGenerator/settings/ruleConfig.js +557 -0
- package/es/comps/FormGenerator/transformer.js +300 -0
- package/es/comps/Icons/index.js +23 -0
- package/es/comps/JsonEdit/constant/index.js +87 -0
- package/es/comps/JsonEdit/index.js +221 -0
- package/es/comps/JsonView/index.js +109 -0
- package/es/comps/MdEdit/index.js +41 -0
- package/es/comps/MdNavbar/index.js +180 -0
- package/es/comps/MdNavbar/utils.js +34 -0
- package/es/comps/MdView/index.js +70 -0
- package/es/comps/MetadataEdit/components/MetaFieldsEdit.js +419 -0
- package/es/comps/MetadataEdit/components/MetaPropsEdit.js +368 -0
- package/es/comps/MetadataEdit/constant/index.js +69 -0
- package/es/comps/MetadataEdit/hooks/index.js +43 -0
- package/es/comps/MetadataEdit/index.js +255 -0
- package/es/comps/MetadataEditV2/components/MetaFieldsEdit.js +237 -0
- package/es/comps/MetadataEditV2/components/MetaPropsEdit.js +367 -0
- package/es/comps/MetadataEditV2/constant/index.js +69 -0
- package/es/comps/MetadataEditV2/hooks/index.js +43 -0
- package/es/comps/MetadataEditV2/index.js +298 -0
- package/es/comps/MetadataForm/DataCell/Array.js +148 -0
- package/es/comps/MetadataForm/DataCell/Input.js +198 -0
- package/es/comps/MetadataForm/DataCell/Number.js +130 -0
- package/es/comps/MetadataForm/DataCell/Ref.js +326 -0
- package/es/comps/MetadataForm/DataCell/Select.js +557 -0
- package/es/comps/MetadataForm/DataCell/Switch.js +115 -0
- package/es/comps/MetadataForm/DataCell/layout/TableArray.js +359 -0
- package/es/comps/MetadataForm/HOC/index.js +125 -0
- package/es/comps/MetadataForm/constants.js +11 -0
- package/es/comps/MetadataForm/hooks/index.js +128 -0
- package/es/comps/MetadataForm/index.js +268 -0
- package/es/comps/MetadataForm/interface.js +8 -0
- package/es/comps/MetadataForm/utils.js +112 -0
- package/es/comps/locales/en-US.js +24 -0
- package/es/comps/locales/index.js +8 -0
- package/es/comps/locales/zh-CN.js +24 -0
- package/es/config.js +50 -0
- package/es/framework/graph/index.js +515 -0
- package/es/framework/hooks/use-async-memo.js +32 -0
- package/es/framework/hooks/use-sync-scroll.js +106 -0
- package/es/framework/http/cache.js +137 -0
- package/es/framework/http/cancel.js +44 -0
- package/es/framework/http/index.js +392 -0
- package/es/framework/http/msgpack.js +34 -0
- package/es/framework/http/msgpack5/index.js +84 -0
- package/es/framework/http/msgpack5/lib/codecs/DateCodec.js +71 -0
- package/es/framework/http/msgpack5/lib/decoder.js +287 -0
- package/es/framework/http/msgpack5/lib/encoder.js +252 -0
- package/es/framework/http/msgpack5/lib/helpers.js +23 -0
- package/es/framework/http/msgpack5/lib/streams.js +93 -0
- package/es/framework/http/types.js +1 -0
- package/es/framework/libs/jquery.min.js +4022 -0
- package/es/framework/locale/dil8/di18n.js +132 -0
- package/es/framework/locale/dil8/index.js +3 -0
- package/es/framework/locale/dil8/translate.js +76 -0
- package/es/framework/locale/dil8/util.js +17 -0
- package/es/framework/locale/index.js +26 -0
- package/es/framework/metadata/MetadataService.js +169 -0
- package/es/framework/metadata/index.js +384 -0
- package/es/framework/rxjs-hooks/useMemoSubject.js +16 -0
- package/es/framework/rxjs-hooks/useObservable.js +22 -0
- package/es/framework/rxjs-hooks/useObservableState.js +45 -0
- package/es/index.js +27 -0
- package/es/utils.js +138 -0
- package/package.json +1 -1
@@ -0,0 +1,190 @@
|
|
1
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
2
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
3
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
4
|
+
import _createSuper from "@babel/runtime/helpers/esm/createSuper";
|
5
|
+
import { Dom, Node } from '@antv/x6';
|
6
|
+
import { ReactShape } from '@antv/x6-react-shape';
|
7
|
+
import { NODE_WIDTH, NODE_HEIGHT } from '../../constant';
|
8
|
+
export var BaseNode = /*#__PURE__*/function (_ReactShape) {
|
9
|
+
_inherits(BaseNode, _ReactShape);
|
10
|
+
|
11
|
+
var _super = _createSuper(BaseNode);
|
12
|
+
|
13
|
+
function BaseNode() {
|
14
|
+
_classCallCheck(this, BaseNode);
|
15
|
+
|
16
|
+
return _super.apply(this, arguments);
|
17
|
+
}
|
18
|
+
|
19
|
+
_createClass(BaseNode, [{
|
20
|
+
key: "isGroup",
|
21
|
+
value: // eslint-disable-next-line class-methods-use-this
|
22
|
+
function isGroup() {
|
23
|
+
return false;
|
24
|
+
}
|
25
|
+
}]);
|
26
|
+
|
27
|
+
return BaseNode;
|
28
|
+
}(ReactShape);
|
29
|
+
export var DPNode = /*#__PURE__*/function (_BaseNode) {
|
30
|
+
_inherits(DPNode, _BaseNode);
|
31
|
+
|
32
|
+
var _super2 = _createSuper(DPNode);
|
33
|
+
|
34
|
+
function DPNode() {
|
35
|
+
_classCallCheck(this, DPNode);
|
36
|
+
|
37
|
+
return _super2.apply(this, arguments);
|
38
|
+
}
|
39
|
+
|
40
|
+
_createClass(DPNode, [{
|
41
|
+
key: "getInPorts",
|
42
|
+
value: function getInPorts() {
|
43
|
+
return this.getPortsByGroup('in');
|
44
|
+
}
|
45
|
+
}, {
|
46
|
+
key: "getOutPorts",
|
47
|
+
value: function getOutPorts() {
|
48
|
+
return this.getPortsByGroup('out');
|
49
|
+
}
|
50
|
+
}]);
|
51
|
+
|
52
|
+
return DPNode;
|
53
|
+
}(BaseNode);
|
54
|
+
Node.registry.register('rz-rect-port', DPNode);
|
55
|
+
DPNode.config({
|
56
|
+
width: NODE_WIDTH,
|
57
|
+
height: NODE_HEIGHT,
|
58
|
+
shape: 'rz-rect-port',
|
59
|
+
ports: {
|
60
|
+
groups: {
|
61
|
+
in: {
|
62
|
+
position: {
|
63
|
+
name: 'top'
|
64
|
+
},
|
65
|
+
zIndex: 2
|
66
|
+
},
|
67
|
+
out: {
|
68
|
+
position: {
|
69
|
+
name: 'bottom'
|
70
|
+
},
|
71
|
+
zIndex: 2
|
72
|
+
}
|
73
|
+
}
|
74
|
+
},
|
75
|
+
attrs: {
|
76
|
+
body: {
|
77
|
+
magnet: false,
|
78
|
+
fill: 'none',
|
79
|
+
stroke: 'none',
|
80
|
+
refWidth: '100%',
|
81
|
+
refHeight: '100%',
|
82
|
+
zIndex: 1
|
83
|
+
}
|
84
|
+
},
|
85
|
+
portMarkup: [{
|
86
|
+
tagName: 'foreignObject',
|
87
|
+
selector: 'fo',
|
88
|
+
attrs: {
|
89
|
+
width: 6,
|
90
|
+
height: 6,
|
91
|
+
x: -3,
|
92
|
+
y: -3,
|
93
|
+
zIndex: 10,
|
94
|
+
// magnet决定是否可交互
|
95
|
+
magnet: 'true'
|
96
|
+
},
|
97
|
+
children: [{
|
98
|
+
ns: Dom.ns.xhtml,
|
99
|
+
tagName: 'body',
|
100
|
+
selector: 'foBody',
|
101
|
+
attrs: {
|
102
|
+
xmlns: Dom.ns.xhtml
|
103
|
+
},
|
104
|
+
style: {
|
105
|
+
width: '100%',
|
106
|
+
height: '100%'
|
107
|
+
},
|
108
|
+
children: [{
|
109
|
+
tagName: 'span',
|
110
|
+
selector: 'content',
|
111
|
+
style: {
|
112
|
+
width: '100%',
|
113
|
+
height: '100%'
|
114
|
+
}
|
115
|
+
}]
|
116
|
+
}]
|
117
|
+
}]
|
118
|
+
});
|
119
|
+
export var DPGroupNode = /*#__PURE__*/function (_BaseNode2) {
|
120
|
+
_inherits(DPGroupNode, _BaseNode2);
|
121
|
+
|
122
|
+
var _super3 = _createSuper(DPGroupNode);
|
123
|
+
|
124
|
+
function DPGroupNode() {
|
125
|
+
_classCallCheck(this, DPGroupNode);
|
126
|
+
|
127
|
+
return _super3.apply(this, arguments);
|
128
|
+
}
|
129
|
+
|
130
|
+
_createClass(DPGroupNode, [{
|
131
|
+
key: "isGroup",
|
132
|
+
value: // eslint-disable-next-line class-methods-use-this
|
133
|
+
function isGroup() {
|
134
|
+
return true;
|
135
|
+
}
|
136
|
+
}]);
|
137
|
+
|
138
|
+
return DPGroupNode;
|
139
|
+
}(BaseNode);
|
140
|
+
DPGroupNode.config({
|
141
|
+
ports: {
|
142
|
+
groups: {
|
143
|
+
in: {
|
144
|
+
position: {
|
145
|
+
name: 'top'
|
146
|
+
},
|
147
|
+
zIndex: 2
|
148
|
+
},
|
149
|
+
out: {
|
150
|
+
position: {
|
151
|
+
name: 'bottom'
|
152
|
+
},
|
153
|
+
zIndex: 2
|
154
|
+
}
|
155
|
+
}
|
156
|
+
},
|
157
|
+
portMarkup: [{
|
158
|
+
tagName: 'foreignObject',
|
159
|
+
selector: 'fo',
|
160
|
+
attrs: {
|
161
|
+
width: 6,
|
162
|
+
height: 6,
|
163
|
+
x: -3,
|
164
|
+
y: -3,
|
165
|
+
zIndex: 10,
|
166
|
+
// magnet决定是否可交互
|
167
|
+
magnet: 'true'
|
168
|
+
},
|
169
|
+
children: [{
|
170
|
+
ns: Dom.ns.xhtml,
|
171
|
+
tagName: 'body',
|
172
|
+
selector: 'foBody',
|
173
|
+
attrs: {
|
174
|
+
xmlns: Dom.ns.xhtml
|
175
|
+
},
|
176
|
+
style: {
|
177
|
+
width: '100%',
|
178
|
+
height: '100%'
|
179
|
+
},
|
180
|
+
children: [{
|
181
|
+
tagName: 'span',
|
182
|
+
selector: 'content',
|
183
|
+
style: {
|
184
|
+
width: '100%',
|
185
|
+
height: '100%'
|
186
|
+
}
|
187
|
+
}]
|
188
|
+
}]
|
189
|
+
}]
|
190
|
+
});
|
@@ -0,0 +1,19 @@
|
|
1
|
+
/*
|
2
|
+
* @Author: wangxian
|
3
|
+
* @Date: 2022-05-24 08:48:57
|
4
|
+
* @LastEditTime: 2022-05-25 11:37:48
|
5
|
+
*/
|
6
|
+
export var GROUP_HORIZONTAL__PADDING = 24; // 分组横向 padding
|
7
|
+
|
8
|
+
export var GROUP_VERTICAL__PADDING = 40; // 分组纵向 padding
|
9
|
+
|
10
|
+
export var NODE_WIDTH = 180;
|
11
|
+
export var NODE_HEIGHT = 32; // 触发画布重新渲染事件
|
12
|
+
|
13
|
+
export var RERENDER_EVENT = 'RERENDER_EVENT';
|
14
|
+
/*
|
15
|
+
* 以下是拖拽相关
|
16
|
+
*/
|
17
|
+
|
18
|
+
export var DRAGGABLE_COMPONENT = 'DRAGGABLE_COMPONENT';
|
19
|
+
export var DRAGGABLE_MODEL = 'DRAGGABLE_MODEL';
|