@byteluck-fe/model-driven-controls 7.0.0-props.100 → 7.0.0-props.101

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15,6 +15,7 @@ export { default as ListSelectButton } from './baseControls/ListSelectButton/pro
15
15
  export { default as Pagination } from './baseControls/Pagination/property';
16
16
  export { default as Dashboard } from './baseControls/Dashboard/property';
17
17
  export { default as BarChart } from './baseControls/BarChart/property';
18
+ export { default as LineChart } from './baseControls/LineChart/property';
18
19
  export { default as PieChart } from './baseControls/PieChart/property';
19
20
  export { default as ListViewSelect } from './baseControls/ListViewSelect/property';
20
21
  export { default as TextOcrButton } from './baseControls/TextOcrButton/property';
@@ -0,0 +1,193 @@
1
+ function _assert_this_initialized(self) {
2
+ if (self === void 0) {
3
+ throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
4
+ }
5
+ return self;
6
+ }
7
+ function _call_super(_this, derived, args) {
8
+ derived = _get_prototype_of(derived);
9
+ return _possible_constructor_return(_this, _is_native_reflect_construct() ? Reflect.construct(derived, args || [], _get_prototype_of(_this).constructor) : derived.apply(_this, args));
10
+ }
11
+ function _class_call_check(instance, Constructor) {
12
+ if (!(instance instanceof Constructor)) {
13
+ throw new TypeError("Cannot call a class as a function");
14
+ }
15
+ }
16
+ function _defineProperties(target, props) {
17
+ for(var i = 0; i < props.length; i++){
18
+ var descriptor = props[i];
19
+ descriptor.enumerable = descriptor.enumerable || false;
20
+ descriptor.configurable = true;
21
+ if ("value" in descriptor) descriptor.writable = true;
22
+ Object.defineProperty(target, descriptor.key, descriptor);
23
+ }
24
+ }
25
+ function _create_class(Constructor, protoProps, staticProps) {
26
+ if (protoProps) _defineProperties(Constructor.prototype, protoProps);
27
+ if (staticProps) _defineProperties(Constructor, staticProps);
28
+ return Constructor;
29
+ }
30
+ function _define_property(obj, key, value) {
31
+ if (key in obj) {
32
+ Object.defineProperty(obj, key, {
33
+ value: value,
34
+ enumerable: true,
35
+ configurable: true,
36
+ writable: true
37
+ });
38
+ } else {
39
+ obj[key] = value;
40
+ }
41
+ return obj;
42
+ }
43
+ function _get_prototype_of(o) {
44
+ _get_prototype_of = Object.setPrototypeOf ? Object.getPrototypeOf : function getPrototypeOf(o) {
45
+ return o.__proto__ || Object.getPrototypeOf(o);
46
+ };
47
+ return _get_prototype_of(o);
48
+ }
49
+ function _inherits(subClass, superClass) {
50
+ if (typeof superClass !== "function" && superClass !== null) {
51
+ throw new TypeError("Super expression must either be null or a function");
52
+ }
53
+ subClass.prototype = Object.create(superClass && superClass.prototype, {
54
+ constructor: {
55
+ value: subClass,
56
+ writable: true,
57
+ configurable: true
58
+ }
59
+ });
60
+ if (superClass) _set_prototype_of(subClass, superClass);
61
+ }
62
+ function _possible_constructor_return(self, call) {
63
+ if (call && (_type_of(call) === "object" || typeof call === "function")) {
64
+ return call;
65
+ }
66
+ return _assert_this_initialized(self);
67
+ }
68
+ function _set_prototype_of(o, p) {
69
+ _set_prototype_of = Object.setPrototypeOf || function setPrototypeOf(o, p) {
70
+ o.__proto__ = p;
71
+ return o;
72
+ };
73
+ return _set_prototype_of(o, p);
74
+ }
75
+ function _type_of(obj) {
76
+ "@swc/helpers - typeof";
77
+ return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
78
+ }
79
+ function _is_native_reflect_construct() {
80
+ try {
81
+ var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
82
+ } catch (_) {}
83
+ return (_is_native_reflect_construct = function() {
84
+ return !!result;
85
+ })();
86
+ }
87
+ import { COMMON_SETTING_TYPE, DesignerControl } from '@byteluck-fe/model-driven-core';
88
+ import { getLocaleText } from '@byteluck-fe/locale-message';
89
+ import LineChartProperty from './property';
90
+ var LineChartControl = /*#__PURE__*/ function(DesignerControl) {
91
+ "use strict";
92
+ _inherits(LineChartControl, DesignerControl);
93
+ function LineChartControl(props) {
94
+ _class_call_check(this, LineChartControl);
95
+ var _this;
96
+ _this = _call_super(this, LineChartControl, [
97
+ props
98
+ ]), _define_property(_this, "props", void 0);
99
+ _this.props = new LineChartProperty(props === null || props === void 0 ? void 0 : props.props);
100
+ return _this;
101
+ }
102
+ _create_class(LineChartControl, null, [
103
+ {
104
+ key: "controlName",
105
+ get: function get() {
106
+ return getLocaleText('CMD.lineChart', null, '折线图');
107
+ }
108
+ },
109
+ {
110
+ key: "controlIcon",
111
+ get: function get() {
112
+ return 'iconbiaodan_tubiao';
113
+ }
114
+ },
115
+ {
116
+ key: "controlType",
117
+ get: function get() {
118
+ return 'line-chart';
119
+ }
120
+ },
121
+ {
122
+ key: "controlCustomAttributes",
123
+ get: function get() {
124
+ return [];
125
+ }
126
+ }
127
+ ]);
128
+ return LineChartControl;
129
+ }(DesignerControl);
130
+ _define_property(LineChartControl, "controlEventKeys", [
131
+ 'on_chart_change'
132
+ ]);
133
+ _define_property(LineChartControl, "setting", [
134
+ {
135
+ key: 'caption',
136
+ showItems: [
137
+ COMMON_SETTING_TYPE.CAPTION,
138
+ COMMON_SETTING_TYPE.IS_HIDE_CAPTION
139
+ ],
140
+ visible: true
141
+ },
142
+ {
143
+ key: 'common-setting',
144
+ visible: true,
145
+ showItems: [
146
+ COMMON_SETTING_TYPE.IS_HIDE,
147
+ COMMON_SETTING_TYPE.IS_SHOW_CAPTION_TIP
148
+ ]
149
+ },
150
+ {
151
+ key: 'common-select',
152
+ visible: true,
153
+ name: 'template',
154
+ label: '模版',
155
+ default: 'line-basic',
156
+ options: [
157
+ {
158
+ value: 'line-basic',
159
+ label: '基础折线图'
160
+ },
161
+ {
162
+ value: 'line-smooth',
163
+ label: '基础平滑折线图'
164
+ },
165
+ {
166
+ value: 'line-area',
167
+ label: '基础面积图'
168
+ },
169
+ {
170
+ value: 'line-stacked',
171
+ label: '堆叠折线图'
172
+ },
173
+ {
174
+ value: 'line-stacked-area',
175
+ label: '堆叠面积图'
176
+ }
177
+ ]
178
+ },
179
+ {
180
+ key: 'chart-setting',
181
+ visible: true
182
+ },
183
+ {
184
+ key: 'chart-data-bind',
185
+ visible: true
186
+ },
187
+ {
188
+ key: 'super-setting',
189
+ visible: true
190
+ }
191
+ ]);
192
+ export default LineChartControl;
193
+ export { LineChartControl as DesignerLineChartControl };
@@ -0,0 +1,11 @@
1
+ import Designer from './designer';
2
+ import Runtime from './runtime';
3
+ import Property from './property';
4
+ export default {
5
+ Designer: Designer,
6
+ Runtime: Runtime,
7
+ Property: Property
8
+ };
9
+ export * from './designer';
10
+ export * from './runtime';
11
+ export * from './property';
@@ -0,0 +1,124 @@
1
+ function _assert_this_initialized(self) {
2
+ if (self === void 0) {
3
+ throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
4
+ }
5
+ return self;
6
+ }
7
+ function _call_super(_this, derived, args) {
8
+ derived = _get_prototype_of(derived);
9
+ return _possible_constructor_return(_this, _is_native_reflect_construct() ? Reflect.construct(derived, args || [], _get_prototype_of(_this).constructor) : derived.apply(_this, args));
10
+ }
11
+ function _class_call_check(instance, Constructor) {
12
+ if (!(instance instanceof Constructor)) {
13
+ throw new TypeError("Cannot call a class as a function");
14
+ }
15
+ }
16
+ function _define_property(obj, key, value) {
17
+ if (key in obj) {
18
+ Object.defineProperty(obj, key, {
19
+ value: value,
20
+ enumerable: true,
21
+ configurable: true,
22
+ writable: true
23
+ });
24
+ } else {
25
+ obj[key] = value;
26
+ }
27
+ return obj;
28
+ }
29
+ function _get_prototype_of(o) {
30
+ _get_prototype_of = Object.setPrototypeOf ? Object.getPrototypeOf : function getPrototypeOf(o) {
31
+ return o.__proto__ || Object.getPrototypeOf(o);
32
+ };
33
+ return _get_prototype_of(o);
34
+ }
35
+ function _inherits(subClass, superClass) {
36
+ if (typeof superClass !== "function" && superClass !== null) {
37
+ throw new TypeError("Super expression must either be null or a function");
38
+ }
39
+ subClass.prototype = Object.create(superClass && superClass.prototype, {
40
+ constructor: {
41
+ value: subClass,
42
+ writable: true,
43
+ configurable: true
44
+ }
45
+ });
46
+ if (superClass) _set_prototype_of(subClass, superClass);
47
+ }
48
+ function _possible_constructor_return(self, call) {
49
+ if (call && (_type_of(call) === "object" || typeof call === "function")) {
50
+ return call;
51
+ }
52
+ return _assert_this_initialized(self);
53
+ }
54
+ function _set_prototype_of(o, p) {
55
+ _set_prototype_of = Object.setPrototypeOf || function setPrototypeOf(o, p) {
56
+ o.__proto__ = p;
57
+ return o;
58
+ };
59
+ return _set_prototype_of(o, p);
60
+ }
61
+ function _type_of(obj) {
62
+ "@swc/helpers - typeof";
63
+ return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
64
+ }
65
+ function _is_native_reflect_construct() {
66
+ try {
67
+ var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
68
+ } catch (_) {}
69
+ return (_is_native_reflect_construct = function() {
70
+ return !!result;
71
+ })();
72
+ }
73
+ /**
74
+ * name: rok_line_chart
75
+ * description: 折线图组件。用于展示静态或动态趋势数据图表,支持模板选择、数据模式切换和字段映射,适合趋势分析与看板展示场景。
76
+ */ import LineChartControl from './designer';
77
+ import { MultistageFillingItem, Property, TreeDataSourceBind } from '@byteluck-fe/model-driven-core';
78
+ var LineChartTemplate = /*#__PURE__*/ function(LineChartTemplate) {
79
+ LineChartTemplate["LINE_BASIC"] = "line-basic";
80
+ LineChartTemplate["LINE_SMOOTH"] = "line-smooth";
81
+ LineChartTemplate["LINE_AREA"] = "line-area";
82
+ LineChartTemplate["LINE_STACKED"] = "line-stacked";
83
+ LineChartTemplate["LINE_STACKED_AREA"] = "line-stacked-area";
84
+ return LineChartTemplate;
85
+ }(LineChartTemplate || {});
86
+ var LineChartProperty = /*#__PURE__*/ function(Property) {
87
+ "use strict";
88
+ _inherits(LineChartProperty, Property);
89
+ function LineChartProperty(props) {
90
+ _class_call_check(this, LineChartProperty);
91
+ var _this;
92
+ var _ref, _ref1, _ref2, _ref3, _ref4, _ref5, _ref6, _ref7, _ref8, _ref9, _ref10, _ref11, _ref12, _ref13, _ref14, _ref15;
93
+ var _props_multistageFilling;
94
+ _this = _call_super(this, LineChartProperty, [
95
+ props
96
+ ]), _define_property(_this, "caption", void 0), _define_property(_this, "isHideCaption", void 0), _define_property(_this, "isShowCaptionTip", void 0), _define_property(_this, "captionTip", void 0), _define_property(_this, "isHide", void 0), _define_property(_this, "template", void 0), _define_property(_this, "dataMode", void 0), _define_property(_this, "optionJson", void 0), _define_property(_this, "optionConfig", 'datasource'), _define_property(_this, "datasourceBind", void 0), _define_property(_this, "filterItemDatasourceBind", void 0), _define_property(_this, "multistageFilling", void 0), _define_property(_this, "defaultValue", void 0), _define_property(_this, "openMultistageFilling", void 0), _define_property(_this, "xField", void 0), _define_property(_this, "yField", void 0), _define_property(_this, "seriesConfig", void 0);
97
+ _this.caption = (_ref = props === null || props === void 0 ? void 0 : props.caption) !== null && _ref !== void 0 ? _ref : LineChartControl.controlName;
98
+ _this.isHideCaption = (_ref1 = props === null || props === void 0 ? void 0 : props.isHideCaption) !== null && _ref1 !== void 0 ? _ref1 : false;
99
+ _this.isShowCaptionTip = (_ref2 = props === null || props === void 0 ? void 0 : props.isShowCaptionTip) !== null && _ref2 !== void 0 ? _ref2 : false;
100
+ _this.captionTip = (_ref3 = props === null || props === void 0 ? void 0 : props.captionTip) !== null && _ref3 !== void 0 ? _ref3 : '';
101
+ _this.isHide = (_ref4 = props === null || props === void 0 ? void 0 : props.isHide) !== null && _ref4 !== void 0 ? _ref4 : false;
102
+ _this.template = (_ref5 = props === null || props === void 0 ? void 0 : props.template) !== null && _ref5 !== void 0 ? _ref5 : "line-basic";
103
+ _this.dataMode = (_ref6 = props === null || props === void 0 ? void 0 : props.dataMode) !== null && _ref6 !== void 0 ? _ref6 : 'static';
104
+ _this.optionJson = (_ref7 = props === null || props === void 0 ? void 0 : props.optionJson) !== null && _ref7 !== void 0 ? _ref7 : '{}';
105
+ _this.datasourceBind = new TreeDataSourceBind((_ref8 = props === null || props === void 0 ? void 0 : props.datasourceBind) !== null && _ref8 !== void 0 ? _ref8 : {
106
+ attributes: LineChartControl.controlCustomAttributes
107
+ });
108
+ _this.filterItemDatasourceBind = new TreeDataSourceBind((_ref9 = props === null || props === void 0 ? void 0 : props.filterItemDatasourceBind) !== null && _ref9 !== void 0 ? _ref9 : {
109
+ attributes: LineChartControl.controlCustomAttributes
110
+ });
111
+ _this.multistageFilling = (_ref10 = props === null || props === void 0 ? void 0 : (_props_multistageFilling = props.multistageFilling) === null || _props_multistageFilling === void 0 ? void 0 : _props_multistageFilling.map(function(item) {
112
+ return new MultistageFillingItem(item);
113
+ })) !== null && _ref10 !== void 0 ? _ref10 : [];
114
+ _this.defaultValue = (_ref11 = props === null || props === void 0 ? void 0 : props.defaultValue) !== null && _ref11 !== void 0 ? _ref11 : [];
115
+ _this.openMultistageFilling = (_ref12 = props === null || props === void 0 ? void 0 : props.openMultistageFilling) !== null && _ref12 !== void 0 ? _ref12 : false;
116
+ _this.xField = (_ref13 = props === null || props === void 0 ? void 0 : props.xField) !== null && _ref13 !== void 0 ? _ref13 : '';
117
+ _this.yField = (_ref14 = props === null || props === void 0 ? void 0 : props.yField) !== null && _ref14 !== void 0 ? _ref14 : '';
118
+ _this.seriesConfig = (_ref15 = props === null || props === void 0 ? void 0 : props.seriesConfig) !== null && _ref15 !== void 0 ? _ref15 : [];
119
+ return _this;
120
+ }
121
+ return LineChartProperty;
122
+ }(Property);
123
+ export default LineChartProperty;
124
+ export { LineChartProperty, LineChartTemplate };
@@ -0,0 +1,112 @@
1
+ function _assert_this_initialized(self) {
2
+ if (self === void 0) {
3
+ throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
4
+ }
5
+ return self;
6
+ }
7
+ function _call_super(_this, derived, args) {
8
+ derived = _get_prototype_of(derived);
9
+ return _possible_constructor_return(_this, _is_native_reflect_construct() ? Reflect.construct(derived, args || [], _get_prototype_of(_this).constructor) : derived.apply(_this, args));
10
+ }
11
+ function _class_call_check(instance, Constructor) {
12
+ if (!(instance instanceof Constructor)) {
13
+ throw new TypeError("Cannot call a class as a function");
14
+ }
15
+ }
16
+ function _defineProperties(target, props) {
17
+ for(var i = 0; i < props.length; i++){
18
+ var descriptor = props[i];
19
+ descriptor.enumerable = descriptor.enumerable || false;
20
+ descriptor.configurable = true;
21
+ if ("value" in descriptor) descriptor.writable = true;
22
+ Object.defineProperty(target, descriptor.key, descriptor);
23
+ }
24
+ }
25
+ function _create_class(Constructor, protoProps, staticProps) {
26
+ if (protoProps) _defineProperties(Constructor.prototype, protoProps);
27
+ if (staticProps) _defineProperties(Constructor, staticProps);
28
+ return Constructor;
29
+ }
30
+ function _define_property(obj, key, value) {
31
+ if (key in obj) {
32
+ Object.defineProperty(obj, key, {
33
+ value: value,
34
+ enumerable: true,
35
+ configurable: true,
36
+ writable: true
37
+ });
38
+ } else {
39
+ obj[key] = value;
40
+ }
41
+ return obj;
42
+ }
43
+ function _get_prototype_of(o) {
44
+ _get_prototype_of = Object.setPrototypeOf ? Object.getPrototypeOf : function getPrototypeOf(o) {
45
+ return o.__proto__ || Object.getPrototypeOf(o);
46
+ };
47
+ return _get_prototype_of(o);
48
+ }
49
+ function _inherits(subClass, superClass) {
50
+ if (typeof superClass !== "function" && superClass !== null) {
51
+ throw new TypeError("Super expression must either be null or a function");
52
+ }
53
+ subClass.prototype = Object.create(superClass && superClass.prototype, {
54
+ constructor: {
55
+ value: subClass,
56
+ writable: true,
57
+ configurable: true
58
+ }
59
+ });
60
+ if (superClass) _set_prototype_of(subClass, superClass);
61
+ }
62
+ function _possible_constructor_return(self, call) {
63
+ if (call && (_type_of(call) === "object" || typeof call === "function")) {
64
+ return call;
65
+ }
66
+ return _assert_this_initialized(self);
67
+ }
68
+ function _set_prototype_of(o, p) {
69
+ _set_prototype_of = Object.setPrototypeOf || function setPrototypeOf(o, p) {
70
+ o.__proto__ = p;
71
+ return o;
72
+ };
73
+ return _set_prototype_of(o, p);
74
+ }
75
+ function _type_of(obj) {
76
+ "@swc/helpers - typeof";
77
+ return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
78
+ }
79
+ function _is_native_reflect_construct() {
80
+ try {
81
+ var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
82
+ } catch (_) {}
83
+ return (_is_native_reflect_construct = function() {
84
+ return !!result;
85
+ })();
86
+ }
87
+ import { RuntimeControl } from '@byteluck-fe/model-driven-core';
88
+ import LineChartProperty from './property';
89
+ var LineChartControl = /*#__PURE__*/ function(RuntimeControl) {
90
+ "use strict";
91
+ _inherits(LineChartControl, RuntimeControl);
92
+ function LineChartControl(props) {
93
+ _class_call_check(this, LineChartControl);
94
+ var _this;
95
+ _this = _call_super(this, LineChartControl, [
96
+ props
97
+ ]), _define_property(_this, "props", void 0);
98
+ _this.props = new LineChartProperty(props === null || props === void 0 ? void 0 : props.props);
99
+ return _this;
100
+ }
101
+ _create_class(LineChartControl, null, [
102
+ {
103
+ key: "controlType",
104
+ get: function get() {
105
+ return 'line-chart';
106
+ }
107
+ }
108
+ ]);
109
+ return LineChartControl;
110
+ }(RuntimeControl);
111
+ export default LineChartControl;
112
+ export { LineChartControl as RuntimeLineChartControl };
@@ -15,6 +15,7 @@ export { default as ListSelectButton } from './ListSelectButton';
15
15
  export { default as Pagination } from './Pagination';
16
16
  export { default as Dashboard } from './Dashboard';
17
17
  export { default as BarChart } from './BarChart';
18
+ export { default as LineChart } from './LineChart';
18
19
  export { default as PieChart } from './PieChart';
19
20
  export { default as ListViewSelect } from './ListViewSelect';
20
21
  export { default as TextOcrButton } from './TextOcrButton';