cnhis-design-vue 2.1.34 → 2.1.35
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.
- package/CHANGELOG.md +28 -9
- package/es/affix/index.js +8 -8
- package/es/age/index.js +10 -10
- package/es/alert/index.js +8 -8
- package/es/anchor/index.js +8 -8
- package/es/auto-complete/index.js +8 -8
- package/es/avatar/index.js +8 -8
- package/es/back-top/index.js +8 -8
- package/es/badge/index.js +8 -8
- package/es/base/index.js +8 -8
- package/es/big-table/index.js +86 -86
- package/es/big-table/style.css +1 -1
- package/es/breadcrumb/index.js +8 -8
- package/es/button/index.js +22 -22
- package/es/calendar/index.js +8 -8
- package/es/captcha/index.js +3 -3
- package/es/card/index.js +8 -8
- package/es/carousel/index.js +8 -8
- package/es/cascader/index.js +8 -8
- package/es/checkbox/index.js +9 -9
- package/es/col/index.js +8 -8
- package/es/collapse/index.js +8 -8
- package/es/color-picker/index.js +1 -1
- package/es/comment/index.js +8 -8
- package/es/config-provider/index.js +8 -8
- package/es/date-picker/index.js +8 -8
- package/es/descriptions/index.js +8 -8
- package/es/divider/index.js +8 -8
- package/es/drag-layout/index.js +3 -3
- package/es/drawer/index.js +8 -8
- package/es/dropdown/index.js +8 -8
- package/es/editor/index.js +1 -1
- package/es/empty/index.js +8 -8
- package/es/fabric-chart/index.js +545 -2355
- package/es/fabric-chart/style.css +1 -1
- package/es/form/index.js +8 -8
- package/es/form-model/index.js +8 -8
- package/es/form-table/index.js +62 -62
- package/es/index/index.js +1117 -2909
- package/es/index/style.css +1 -1
- package/es/input/index.js +9 -9
- package/es/input-number/index.js +8 -8
- package/es/layout/index.js +8 -8
- package/es/list/index.js +8 -8
- package/es/locale-provider/index.js +8 -8
- package/es/map/index.js +9 -9
- package/es/mentions/index.js +8 -8
- package/es/menu/index.js +8 -8
- package/es/message/index.js +8 -8
- package/es/multi-chat/index.js +75 -75
- package/es/multi-chat-client/index.js +69 -69
- package/es/multi-chat-history/index.js +4 -4
- package/es/multi-chat-record/index.js +14 -14
- package/es/multi-chat-setting/index.js +22 -22
- package/es/multi-chat-sip/index.js +1 -1
- package/es/notification/index.js +8 -8
- package/es/page-header/index.js +8 -8
- package/es/pagination/index.js +8 -8
- package/es/popconfirm/index.js +8 -8
- package/es/popover/index.js +8 -8
- package/es/progress/index.js +8 -8
- package/es/radio/index.js +9 -9
- package/es/rate/index.js +8 -8
- package/es/result/index.js +8 -8
- package/es/row/index.js +8 -8
- package/es/scale-view/index.js +33 -33
- package/es/select/index.js +11 -11
- package/es/select-label/index.js +11 -11
- package/es/select-person/index.js +2 -2
- package/es/shortcut-setter/index.js +10 -10
- package/es/skeleton/index.js +8 -8
- package/es/slider/index.js +8 -8
- package/es/space/index.js +8 -8
- package/es/spin/index.js +8 -8
- package/es/statistic/index.js +8 -8
- package/es/steps/index.js +8 -8
- package/es/switch/index.js +8 -8
- package/es/table-filter/index.js +84 -73
- package/es/table-filter/style.css +1 -1
- package/es/tabs/index.js +8 -8
- package/es/tag/index.js +9 -9
- package/es/time-picker/index.js +8 -8
- package/es/timeline/index.js +8 -8
- package/es/tooltip/index.js +8 -8
- package/es/transfer/index.js +8 -8
- package/es/tree/index.js +8 -8
- package/es/tree-select/index.js +8 -8
- package/es/upload/index.js +8 -8
- package/es/verification-code/index.js +2 -2
- package/lib/cui.common.js +911 -2767
- package/lib/cui.umd.js +911 -2767
- package/lib/cui.umd.min.js +29 -29
- package/package.json +2 -1
- package/packages/big-table/src/components/AutoLayoutButton.vue +3 -3
- package/packages/fabric-chart/src/FabricChart.vue +0 -17
- package/packages/fabric-chart/src/FabricGrid.vue +3 -10
- package/packages/fabric-chart/src/components/TimeScaleValue.vue +10 -8
- package/packages/fabric-chart/src/const/defaultVaule.js +59 -59
- package/packages/fabric-chart/src/fabric-chart/FabricLines.vue +2 -22
- package/packages/fabric-chart/src/fabric-chart/FabricPolylines.vue +41 -34
- package/packages/fabric-chart/src/fabric-chart/FabricScaleValue.vue +5 -6
- package/packages/fabric-chart/src/fabric-chart/FabricTextGroup.vue +21 -16
- package/packages/fabric-chart/src/mixins/draw.js +2 -1
- package/packages/fabric-chart/src/mixins/fabricCommon.js +14 -4
- package/packages/scale-view/scaleView.vue +2010 -2010
- package/packages/table-filter/src/base-search-com/BaseSearch.vue +9 -0
- package/packages/fabric-chart/src/fabric-chart2/FabricBottom.vue +0 -108
- package/packages/fabric-chart/src/fabric-chart2/FabricCanvas.vue +0 -181
- package/packages/fabric-chart/src/fabric-chart2/FabricCenter.vue +0 -612
- package/packages/fabric-chart/src/fabric-chart2/FabricLeft.vue +0 -104
- package/packages/fabric-chart/src/fabric-chart2/FabricRight.vue +0 -112
- package/packages/fabric-chart/src/fabric-chart2/FabricTop.vue +0 -172
package/es/fabric-chart/index.js
CHANGED
|
@@ -107,6 +107,17 @@ module.exports = String(test) === '[object z]';
|
|
|
107
107
|
|
|
108
108
|
module.exports = require("core-js/modules/es.object.freeze.js");
|
|
109
109
|
|
|
110
|
+
/***/ }),
|
|
111
|
+
|
|
112
|
+
/***/ "0364":
|
|
113
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
114
|
+
|
|
115
|
+
"use strict";
|
|
116
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_TimeScaleValue_vue_vue_type_style_index_0_id_184c584a_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("b4ea");
|
|
117
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_TimeScaleValue_vue_vue_type_style_index_0_id_184c584a_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_TimeScaleValue_vue_vue_type_style_index_0_id_184c584a_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0__);
|
|
118
|
+
/* unused harmony reexport * */
|
|
119
|
+
|
|
120
|
+
|
|
110
121
|
/***/ }),
|
|
111
122
|
|
|
112
123
|
/***/ "0366":
|
|
@@ -288,12 +299,12 @@ var es_promise_finally = __webpack_require__("a79d");
|
|
|
288
299
|
// EXTERNAL MODULE: external "core-js/modules/es.function.name.js"
|
|
289
300
|
var es_function_name_js_ = __webpack_require__("db0a");
|
|
290
301
|
|
|
291
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
292
|
-
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"c-fabric-chart",style:({ width: _vm.canvasWidth })},[(_vm.rendercanvas)?_c(("FabricCanvas" + (_vm.templateData.type || '')),{ref:"canvasEle",tag:"component",attrs:{"id":_vm.id,"templateData":_vm.templateData}},[(_vm.templateData.type)?[_c('fabric-grid')
|
|
302
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"1b461ec0-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/FabricChart.vue?vue&type=template&id=b556f068&scoped=true&
|
|
303
|
+
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"c-fabric-chart",style:({ width: _vm.canvasWidth })},[(_vm.rendercanvas)?_c(("FabricCanvas" + (_vm.templateData.type || '')),{ref:"canvasEle",tag:"component",attrs:{"id":_vm.id,"templateData":_vm.templateData}},[(_vm.templateData.type)?[_c('fabric-grid')]:[(_vm.hasXScalevalue)?_c('fabric-text-group',_vm._g({attrs:{"templateData":_vm.templateData}},_vm.$listeners)):_vm._e(),_c('fabric-grid'),(_vm.hasTable)?_c('fabric-scale-value',{attrs:{"templateData":_vm.templateData}}):_vm._e(),(_vm.hasTopTable)?_c('fabric-lines',_vm._g({ref:"lines",attrs:{"linesObj":_vm.templateData.top}},_vm.$listeners)):_vm._e(),(_vm.hasTable)?_c('fabric-polylines',_vm._g({ref:"polylines",attrs:{"polyline":_vm.polylines,"other":_vm.templateData.left.other || {}},on:{"pointOperation":_vm.pointOperation}},_vm.$listeners)):_vm._e()]],2):_vm._e()],1)}
|
|
293
304
|
var staticRenderFns = []
|
|
294
305
|
|
|
295
306
|
|
|
296
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/FabricChart.vue?vue&type=template&id=
|
|
307
|
+
// CONCATENATED MODULE: ./packages/fabric-chart/src/FabricChart.vue?vue&type=template&id=b556f068&scoped=true&
|
|
297
308
|
|
|
298
309
|
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js
|
|
299
310
|
var objectSpread2 = __webpack_require__("5530");
|
|
@@ -301,7 +312,7 @@ var objectSpread2 = __webpack_require__("5530");
|
|
|
301
312
|
// EXTERNAL MODULE: ./src/core/create.js
|
|
302
313
|
var create = __webpack_require__("8aef");
|
|
303
314
|
|
|
304
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
315
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"1b461ec0-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart/FabricCanvas.vue?vue&type=template&id=8b6630b2&
|
|
305
316
|
var FabricCanvasvue_type_template_id_8b6630b2_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[_c('canvas',{attrs:{"id":_vm.id}}),_vm._t("default")],2)}
|
|
306
317
|
var FabricCanvasvue_type_template_id_8b6630b2_staticRenderFns = []
|
|
307
318
|
|
|
@@ -787,252 +798,12 @@ var component = Object(componentNormalizer["a" /* default */])(
|
|
|
787
798
|
)
|
|
788
799
|
|
|
789
800
|
/* harmony default export */ var FabricCanvas = (component.exports);
|
|
790
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
791
|
-
var
|
|
792
|
-
var
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricCanvas.vue?vue&type=template&id=d9708486&
|
|
796
|
-
|
|
797
|
-
// EXTERNAL MODULE: external "core-js/modules/es.array.concat.js"
|
|
798
|
-
var es_array_concat_js_ = __webpack_require__("ccb0");
|
|
799
|
-
|
|
800
|
-
// EXTERNAL MODULE: external "core-js/modules/es.array.flat.js"
|
|
801
|
-
var es_array_flat_js_ = __webpack_require__("da6e");
|
|
802
|
-
|
|
803
|
-
// EXTERNAL MODULE: external "core-js/modules/es.array.find.js"
|
|
804
|
-
var es_array_find_js_ = __webpack_require__("0d58");
|
|
805
|
-
|
|
806
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart2/FabricCanvas.vue?vue&type=script&lang=js&
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
//
|
|
813
|
-
//
|
|
814
|
-
//
|
|
815
|
-
//
|
|
816
|
-
//
|
|
817
|
-
//
|
|
818
|
-
//
|
|
819
|
-
|
|
820
|
-
/* harmony default export */ var fabric_chart2_FabricCanvasvue_type_script_lang_js_ = ({
|
|
821
|
-
name: 'FabricCanvas2',
|
|
822
|
-
props: {
|
|
823
|
-
id: {
|
|
824
|
-
type: String,
|
|
825
|
-
required: true
|
|
826
|
-
},
|
|
827
|
-
templateData: {
|
|
828
|
-
type: Object,
|
|
829
|
-
required: true
|
|
830
|
-
}
|
|
831
|
-
},
|
|
832
|
-
data: function data() {
|
|
833
|
-
return {
|
|
834
|
-
canvas: null,
|
|
835
|
-
type: 'canvas',
|
|
836
|
-
canvasAttr: {
|
|
837
|
-
selectable: false,
|
|
838
|
-
evented: false,
|
|
839
|
-
selection: false,
|
|
840
|
-
containerClass: 'c-fabric-canvas-container',
|
|
841
|
-
fireRightClick: true
|
|
842
|
-
},
|
|
843
|
-
fabric: external_fabric_["fabric"]
|
|
844
|
-
};
|
|
845
|
-
},
|
|
846
|
-
provide: function provide() {
|
|
847
|
-
var _this = this;
|
|
848
|
-
|
|
849
|
-
return {
|
|
850
|
-
$canvas: function $canvas() {
|
|
851
|
-
return _this.canvas;
|
|
852
|
-
},
|
|
853
|
-
$group: function $group() {
|
|
854
|
-
return null;
|
|
855
|
-
},
|
|
856
|
-
$fabric: function $fabric() {
|
|
857
|
-
return external_fabric_["fabric"];
|
|
858
|
-
},
|
|
859
|
-
$propItems: function $propItems() {
|
|
860
|
-
return {
|
|
861
|
-
type: _this.templateData.type,
|
|
862
|
-
endX: _this.endX,
|
|
863
|
-
endY: _this.endY,
|
|
864
|
-
originX: _this.originX,
|
|
865
|
-
originY: _this.originY,
|
|
866
|
-
gridYNumber: _this.gridYNumber,
|
|
867
|
-
gridXNumber: _this.gridXNumber,
|
|
868
|
-
canvasWidth: _this.canvasWidth,
|
|
869
|
-
canvasHeight: _this.canvasHeight,
|
|
870
|
-
xCellWidth: _this.xCellWidth,
|
|
871
|
-
yCellHeight: _this.yCellHeight,
|
|
872
|
-
table: Object(objectSpread2["a" /* default */])({}, _this.templateData.table),
|
|
873
|
-
xScaleList: _this.xScaleList,
|
|
874
|
-
xScaleCell: _this.xScaleCell,
|
|
875
|
-
breatheYCell: _this.breatheYCell,
|
|
876
|
-
pulseYCell: _this.pulseYCell,
|
|
877
|
-
centigradeYCell: _this.centigradeYCell,
|
|
878
|
-
eventStyle: _this.eventStyle
|
|
879
|
-
};
|
|
880
|
-
}
|
|
881
|
-
};
|
|
882
|
-
},
|
|
883
|
-
computed: {
|
|
884
|
-
canvasWidth: function canvasWidth() {
|
|
885
|
-
// 画布宽度
|
|
886
|
-
return this.templateData.canvasWidth;
|
|
887
|
-
},
|
|
888
|
-
canvasHeight: function canvasHeight() {
|
|
889
|
-
// 画布高度
|
|
890
|
-
return this.templateData.canvasHeight;
|
|
891
|
-
},
|
|
892
|
-
gridXNumber: function gridXNumber() {
|
|
893
|
-
// 网格水平方向总数 如果设置了默认值就直接取用
|
|
894
|
-
return this.templateData.table.mainXCell * this.templateData.table.subXCell;
|
|
895
|
-
},
|
|
896
|
-
gridYNumber: function gridYNumber() {
|
|
897
|
-
// 网格垂直方向总数
|
|
898
|
-
return this.templateData.table.mainYCell * this.templateData.table.subYCell;
|
|
899
|
-
},
|
|
900
|
-
originX: function originX() {
|
|
901
|
-
var originX = this.templateData.top.titleWidth;
|
|
902
|
-
var residue = (this.endX - originX) % this.gridXNumber;
|
|
903
|
-
return originX + residue;
|
|
904
|
-
},
|
|
905
|
-
originY: function originY() {
|
|
906
|
-
var _top$date;
|
|
907
|
-
|
|
908
|
-
// 顶部列表高度 网格不需要的高度放到顶部始终存在的时间那一行,因为底部不一定存在列表
|
|
909
|
-
var top = this.templateData.top;
|
|
910
|
-
var dateHeight = ((_top$date = top.date) === null || _top$date === void 0 ? void 0 : _top$date.height) || 0;
|
|
911
|
-
var dayHeight = top.dayHeight || 0;
|
|
912
|
-
var xScaleHeight = top.xScalevalue.height || 15;
|
|
913
|
-
var topHeight = dateHeight + dayHeight + xScaleHeight;
|
|
914
|
-
var residue = (this.endY - topHeight) % this.gridYNumber;
|
|
915
|
-
return topHeight + residue;
|
|
916
|
-
},
|
|
917
|
-
endX: function endX() {
|
|
918
|
-
// 网格区域水平方向最大坐标值, 也是整个画布右侧列表坐标起始值,网格右下角x轴坐标值
|
|
919
|
-
if (!this.templateData.right) return this.templateData.canvasWidth;
|
|
920
|
-
var endWidth = this.templateData.right.width || 50;
|
|
921
|
-
return this.templateData.canvasWidth - endWidth;
|
|
922
|
-
},
|
|
923
|
-
endY: function endY() {
|
|
924
|
-
// 画布高度 - 底部列表高度 ,网格右下角y轴坐标值
|
|
925
|
-
if (!this.templateData.bottom) return this.templateData.canvasHeight;
|
|
926
|
-
var endHeight = this.templateData.bottom.height || 30;
|
|
927
|
-
return this.canvasHeight - endHeight;
|
|
928
|
-
},
|
|
929
|
-
xCellWidth: function xCellWidth() {
|
|
930
|
-
// 水平方向网格宽度
|
|
931
|
-
return (this.endX - this.originX) / this.gridXNumber;
|
|
932
|
-
},
|
|
933
|
-
yCellHeight: function yCellHeight() {
|
|
934
|
-
// 垂直方向网格宽度
|
|
935
|
-
return (this.endY - this.originY) / this.gridYNumber;
|
|
936
|
-
},
|
|
937
|
-
// 转换为时间戳的x轴刻度list
|
|
938
|
-
xScaleList: function xScaleList() {
|
|
939
|
-
var dateList = this.templateData.top.date.list;
|
|
940
|
-
var dayList = this.templateData.top.xScalevalue.list;
|
|
941
|
-
var timeList = dateList.map(function (item) {
|
|
942
|
-
return dayList.map(function (v) {
|
|
943
|
-
return new Date("".concat(item, " ").concat(v, ":00")).getTime();
|
|
944
|
-
});
|
|
945
|
-
});
|
|
946
|
-
return timeList.flat();
|
|
947
|
-
},
|
|
948
|
-
// x轴每格的时间,比如4小时,不能刻度list长度值除以总格子数计算,因为有可能刻度比较短,不能满足所有的格子
|
|
949
|
-
xScaleCell: function xScaleCell() {
|
|
950
|
-
return this.xScaleList[1] - this.xScaleList[0]; // 返回时间戳
|
|
951
|
-
},
|
|
952
|
-
// y轴每一次的呼吸的高度值
|
|
953
|
-
breatheYCell: function breatheYCell() {
|
|
954
|
-
var leftYScalevalue = this.templateData.left.leftYScalevalue;
|
|
955
|
-
var list = leftYScalevalue.find(function (v) {
|
|
956
|
-
return v.type === 'breathe';
|
|
957
|
-
}).list;
|
|
958
|
-
return list ? this.yCellHeight / ((parseInt(list[1]) - parseInt(list[0])) / this.templateData.left.spaceGridNumber) : 0;
|
|
959
|
-
},
|
|
960
|
-
// y轴每mmHg的脉搏/心率的高度值
|
|
961
|
-
pulseYCell: function pulseYCell() {
|
|
962
|
-
var leftYScalevalue = this.templateData.left.leftYScalevalue;
|
|
963
|
-
var list = leftYScalevalue.find(function (v) {
|
|
964
|
-
return v.type === 'pulse';
|
|
965
|
-
}).list;
|
|
966
|
-
return this.yCellHeight / ((parseInt(list[1]) - parseInt(list[0])) / this.templateData.left.spaceGridNumber);
|
|
967
|
-
},
|
|
968
|
-
// y轴每摄氏度的高度值
|
|
969
|
-
centigradeYCell: function centigradeYCell() {
|
|
970
|
-
var _this$templateData$le = this.templateData.left,
|
|
971
|
-
leftYScalevalue = _this$templateData$le.leftYScalevalue,
|
|
972
|
-
spaceGridNumber = _this$templateData$le.spaceGridNumber;
|
|
973
|
-
var list = leftYScalevalue.find(function (v) {
|
|
974
|
-
return v.type === 'centigrade';
|
|
975
|
-
}).list;
|
|
976
|
-
return this.yCellHeight / ((parseInt(list[1]) - parseInt(list[0])) / spaceGridNumber);
|
|
977
|
-
},
|
|
978
|
-
eventStyle: function eventStyle() {
|
|
979
|
-
var _this$templateData$ta;
|
|
980
|
-
|
|
981
|
-
return ((_this$templateData$ta = this.templateData.table) === null || _this$templateData$ta === void 0 ? void 0 : _this$templateData$ta.eventStyle) || {
|
|
982
|
-
selectable: true,
|
|
983
|
-
evented: true
|
|
984
|
-
};
|
|
985
|
-
}
|
|
986
|
-
},
|
|
987
|
-
mounted: function mounted() {
|
|
988
|
-
this.init();
|
|
989
|
-
},
|
|
990
|
-
methods: {
|
|
991
|
-
init: function init() {
|
|
992
|
-
this.canvas = new this.fabric.Canvas('c-fabric-canvas', Object(objectSpread2["a" /* default */])({
|
|
993
|
-
width: this.templateData.canvasWidth,
|
|
994
|
-
height: this.templateData.canvasHeight
|
|
995
|
-
}, this.canvasAttr));
|
|
996
|
-
},
|
|
997
|
-
toDataURL: function toDataURL(option) {
|
|
998
|
-
return this.canvas.toDataURL(option);
|
|
999
|
-
},
|
|
1000
|
-
renderCanvas: function renderCanvas() {
|
|
1001
|
-
this.canvas.clear(); // this.canvas.renderCanvas();
|
|
1002
|
-
}
|
|
1003
|
-
},
|
|
1004
|
-
beforeDestroy: function beforeDestroy() {
|
|
1005
|
-
this.canvas.dispose();
|
|
1006
|
-
}
|
|
1007
|
-
});
|
|
1008
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricCanvas.vue?vue&type=script&lang=js&
|
|
1009
|
-
/* harmony default export */ var src_fabric_chart2_FabricCanvasvue_type_script_lang_js_ = (fabric_chart2_FabricCanvasvue_type_script_lang_js_);
|
|
1010
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricCanvas.vue
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
/* normalize component */
|
|
1017
|
-
|
|
1018
|
-
var FabricCanvas_component = Object(componentNormalizer["a" /* default */])(
|
|
1019
|
-
src_fabric_chart2_FabricCanvasvue_type_script_lang_js_,
|
|
1020
|
-
FabricCanvasvue_type_template_id_d9708486_render,
|
|
1021
|
-
FabricCanvasvue_type_template_id_d9708486_staticRenderFns,
|
|
1022
|
-
false,
|
|
1023
|
-
null,
|
|
1024
|
-
null,
|
|
1025
|
-
null
|
|
1026
|
-
|
|
1027
|
-
)
|
|
801
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"1b461ec0-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart/FabricPolylines.vue?vue&type=template&id=05a44150&
|
|
802
|
+
var FabricPolylinesvue_type_template_id_05a44150_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"poly-line"},[(_vm.isRightVisible)?_c('MouseRightClick',{attrs:{"getContainer":_vm.getContainer,"nodeList":_vm.rightClickNode,"rightPos":_vm.rightPos},on:{"nodeClick":_vm.handleRightClick,"closeRight":function($event){_vm.isRightVisible = false}}}):_vm._e(),_c('DropPopup',{directives:[{name:"show",rawName:"v-show",value:(_vm.isDropVisible),expression:"isDropVisible"}],attrs:{"val":_vm.dropVal,"dropPos":_vm.dropPos}})],1)}
|
|
803
|
+
var FabricPolylinesvue_type_template_id_05a44150_staticRenderFns = []
|
|
1028
804
|
|
|
1029
|
-
/* harmony default export */ var fabric_chart2_FabricCanvas = (FabricCanvas_component.exports);
|
|
1030
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"54b2b90d-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart/FabricPolylines.vue?vue&type=template&id=4464d5bc&
|
|
1031
|
-
var FabricPolylinesvue_type_template_id_4464d5bc_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"poly-line"},[(_vm.isRightVisible)?_c('MouseRightClick',{attrs:{"getContainer":_vm.getContainer,"nodeList":_vm.rightClickNode,"rightPos":_vm.rightPos},on:{"nodeClick":_vm.handleRightClick,"closeRight":function($event){_vm.isRightVisible = false}}}):_vm._e(),_c('DropPopup',{directives:[{name:"show",rawName:"v-show",value:(_vm.isDropVisible),expression:"isDropVisible"}],attrs:{"val":_vm.dropVal,"dropPos":_vm.dropPos}})],1)}
|
|
1032
|
-
var FabricPolylinesvue_type_template_id_4464d5bc_staticRenderFns = []
|
|
1033
805
|
|
|
1034
|
-
|
|
1035
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricPolylines.vue?vue&type=template&id=4464d5bc&
|
|
806
|
+
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricPolylines.vue?vue&type=template&id=05a44150&
|
|
1036
807
|
|
|
1037
808
|
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js
|
|
1038
809
|
var asyncToGenerator = __webpack_require__("1da1");
|
|
@@ -1055,6 +826,12 @@ var es_array_includes_js_ = __webpack_require__("85f7");
|
|
|
1055
826
|
// EXTERNAL MODULE: external "core-js/modules/es.string.includes.js"
|
|
1056
827
|
var es_string_includes_js_ = __webpack_require__("fd22");
|
|
1057
828
|
|
|
829
|
+
// EXTERNAL MODULE: external "core-js/modules/es.array.find.js"
|
|
830
|
+
var es_array_find_js_ = __webpack_require__("0d58");
|
|
831
|
+
|
|
832
|
+
// EXTERNAL MODULE: external "core-js/modules/es.array.concat.js"
|
|
833
|
+
var es_array_concat_js_ = __webpack_require__("ccb0");
|
|
834
|
+
|
|
1058
835
|
// EXTERNAL MODULE: external "core-js/modules/es.string.replace.js"
|
|
1059
836
|
var es_string_replace_js_ = __webpack_require__("6378");
|
|
1060
837
|
|
|
@@ -1085,15 +862,11 @@ var es_array_slice_js_ = __webpack_require__("ea12");
|
|
|
1085
862
|
// EXTERNAL MODULE: external "core-js/modules/es.object.freeze.js"
|
|
1086
863
|
var es_object_freeze_js_ = __webpack_require__("030b");
|
|
1087
864
|
|
|
1088
|
-
// EXTERNAL MODULE: external "vxe-table"
|
|
1089
|
-
var external_vxe_table_ = __webpack_require__("f906");
|
|
1090
|
-
|
|
1091
865
|
// CONCATENATED MODULE: ./packages/fabric-chart/src/mixins/fabricCommon.js
|
|
1092
866
|
|
|
1093
867
|
|
|
1094
868
|
|
|
1095
869
|
|
|
1096
|
-
|
|
1097
870
|
/* harmony default export */ var fabricCommon = ({
|
|
1098
871
|
name: 'fabric-common',
|
|
1099
872
|
inject: ['$canvas', '$group', '$propItems', '$fabric'],
|
|
@@ -1114,6 +887,22 @@ var external_vxe_table_ = __webpack_require__("f906");
|
|
|
1114
887
|
return this.$propItems();
|
|
1115
888
|
}
|
|
1116
889
|
},
|
|
890
|
+
watch: {
|
|
891
|
+
canvas: {
|
|
892
|
+
handler: function handler(value) {
|
|
893
|
+
var _this = this;
|
|
894
|
+
|
|
895
|
+
if (value) {
|
|
896
|
+
this.$nextTick(function () {
|
|
897
|
+
var _this$init;
|
|
898
|
+
|
|
899
|
+
(_this$init = _this.init) === null || _this$init === void 0 ? void 0 : _this$init.call(_this);
|
|
900
|
+
});
|
|
901
|
+
}
|
|
902
|
+
},
|
|
903
|
+
immediate: true
|
|
904
|
+
}
|
|
905
|
+
},
|
|
1117
906
|
methods: {
|
|
1118
907
|
// 根据x轴坐标获取对应的时间点
|
|
1119
908
|
// getXValue(left) {
|
|
@@ -1307,7 +1096,10 @@ var type_isObject = function isObject(obj) {
|
|
|
1307
1096
|
// });
|
|
1308
1097
|
// fabric.loadSVGFromURL的工作方式相同,只不过您传递的是包含URL而不是SVG内容的字符串
|
|
1309
1098
|
return new Promise(function (resolve, reject) {
|
|
1310
|
-
var
|
|
1099
|
+
var _document, _document$querySelect;
|
|
1100
|
+
|
|
1101
|
+
var svg = (_document = document) === null || _document === void 0 ? void 0 : (_document$querySelect = _document.querySelector(iconClassName)) === null || _document$querySelect === void 0 ? void 0 : _document$querySelect.querySelector('svg');
|
|
1102
|
+
if (!svg) reject('图片转换svg失败!');
|
|
1311
1103
|
svg.setAttribute('version', 1.1);
|
|
1312
1104
|
svg.setAttribute('xmlns', 'http://www.w3.org/2000/svg');
|
|
1313
1105
|
svg.style.color = others.color || '#000';
|
|
@@ -1627,7 +1419,7 @@ var type_isObject = function isObject(obj) {
|
|
|
1627
1419
|
}
|
|
1628
1420
|
}
|
|
1629
1421
|
});
|
|
1630
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
1422
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"1b461ec0-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/components/MouseRightClick.vue?vue&type=template&id=25d4407a&scoped=true&
|
|
1631
1423
|
var MouseRightClickvue_type_template_id_25d4407a_scoped_true_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"c-mouse-right-menu-popup c-animation-in",style:(_vm.dialogStyle)},[_c('div',{staticClass:"c-mouse-right-menu"},_vm._l((_vm.nodeList),function(item,index){return _c('div',{key:index,staticClass:"c-mouse-menu-item",on:{"click":function($event){return _vm.handleNodeClick(item)}}},[_c('span',[_vm._v(_vm._s(item.name))])])}),0)])}
|
|
1632
1424
|
var MouseRightClickvue_type_template_id_25d4407a_scoped_true_staticRenderFns = []
|
|
1633
1425
|
|
|
@@ -1735,7 +1527,7 @@ var MouseRightClick_component = Object(componentNormalizer["a" /* default */])(
|
|
|
1735
1527
|
)
|
|
1736
1528
|
|
|
1737
1529
|
/* harmony default export */ var MouseRightClick = (MouseRightClick_component.exports);
|
|
1738
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
1530
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"1b461ec0-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/components/DropPopup.vue?vue&type=template&id=c4db0ace&scoped=true&
|
|
1739
1531
|
var DropPopupvue_type_template_id_c4db0ace_scoped_true_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"c-drop-popup",style:(_vm.dialogStyle)},[_c('div',{staticClass:"c-drop-popup-list"},[_c('span',[_vm._v(_vm._s(_vm.val.title))]),_vm._l((_vm.val.list),function(item){return _c('span',{key:item.id},[_vm._v(" "+_vm._s(((item.name) + ": " + (item.value)))+" ")])})],2)])}
|
|
1740
1532
|
var DropPopupvue_type_template_id_c4db0ace_scoped_true_staticRenderFns = []
|
|
1741
1533
|
|
|
@@ -1992,22 +1784,18 @@ var rightClickNodeConnect = [{
|
|
|
1992
1784
|
}
|
|
1993
1785
|
},
|
|
1994
1786
|
watch: {},
|
|
1995
|
-
mounted: function mounted() {
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
_this2.drawPolylineTitle();
|
|
2000
|
-
|
|
2001
|
-
_this2.polylinePointList = [];
|
|
1787
|
+
mounted: function mounted() {},
|
|
1788
|
+
methods: {
|
|
1789
|
+
init: function init() {
|
|
1790
|
+
var _this2 = this;
|
|
2002
1791
|
|
|
2003
|
-
|
|
1792
|
+
this.drawPolylineTitle();
|
|
1793
|
+
this.polylinePointList = [];
|
|
1794
|
+
this.polyline.forEach(function (polylineType, polylineTypeId) {
|
|
2004
1795
|
_this2.createPolyline(polylineType, polylineTypeId);
|
|
2005
1796
|
});
|
|
2006
|
-
|
|
2007
|
-
|
|
2008
|
-
});
|
|
2009
|
-
},
|
|
2010
|
-
methods: {
|
|
1797
|
+
this.eventStyle.evented && this.createEvent();
|
|
1798
|
+
},
|
|
2011
1799
|
createEvent: function createEvent() {
|
|
2012
1800
|
var _this3 = this;
|
|
2013
1801
|
|
|
@@ -2106,8 +1894,7 @@ var rightClickNodeConnect = [{
|
|
|
2106
1894
|
height: event.pointer.y - selectAreaOrigin.top,
|
|
2107
1895
|
ponits: [selectAreaOrigin.left, selectAreaOrigin.top, event.pointer.x, event.pointer.y]
|
|
2108
1896
|
}));
|
|
2109
|
-
this.canvas.add(this.selectArea);
|
|
2110
|
-
this.canvas.renderAll();
|
|
1897
|
+
this.canvas.add(this.selectArea); // this.canvas.renderAll();
|
|
2111
1898
|
},
|
|
2112
1899
|
// 每一个折线类别
|
|
2113
1900
|
createPolyline: function createPolyline(polylineType, polylineTypeId) {
|
|
@@ -2262,8 +2049,6 @@ var rightClickNodeConnect = [{
|
|
|
2262
2049
|
scaleX: 1,
|
|
2263
2050
|
scaleY: 1
|
|
2264
2051
|
});
|
|
2265
|
-
|
|
2266
|
-
_this6.canvas.renderAll();
|
|
2267
2052
|
}
|
|
2268
2053
|
|
|
2269
2054
|
if (!cloneIconId) {
|
|
@@ -2276,8 +2061,6 @@ var rightClickNodeConnect = [{
|
|
|
2276
2061
|
clonedObj.bringForward();
|
|
2277
2062
|
|
|
2278
2063
|
_this6.canvas.add(clonedObj);
|
|
2279
|
-
|
|
2280
|
-
_this6.canvas.renderAll();
|
|
2281
2064
|
});
|
|
2282
2065
|
}
|
|
2283
2066
|
|
|
@@ -2293,17 +2076,14 @@ var rightClickNodeConnect = [{
|
|
|
2293
2076
|
_this6.showDrapPopup(icon);
|
|
2294
2077
|
} else {
|
|
2295
2078
|
_this6.isDropVisible = false;
|
|
2296
|
-
}
|
|
2079
|
+
} // this.canvas.renderAll();
|
|
2297
2080
|
|
|
2298
|
-
_this6.canvas.renderAll();
|
|
2299
2081
|
}); // 标题折线点停止拖拽后 更新
|
|
2300
2082
|
|
|
2301
2083
|
icon.on('moved', function () {
|
|
2302
2084
|
icon.set({
|
|
2303
2085
|
id: icon.id.replace('_isTitle', '')
|
|
2304
|
-
});
|
|
2305
|
-
|
|
2306
|
-
_this6.canvas.renderAll();
|
|
2086
|
+
}); // this.canvas.renderAll();
|
|
2307
2087
|
|
|
2308
2088
|
_this6.removeTitle();
|
|
2309
2089
|
|
|
@@ -2455,9 +2235,8 @@ var rightClickNodeConnect = [{
|
|
|
2455
2235
|
lines.push(_line, _text);
|
|
2456
2236
|
}
|
|
2457
2237
|
|
|
2458
|
-
(_this$canvas = this.canvas).add.apply(_this$canvas, lines);
|
|
2238
|
+
(_this$canvas = this.canvas).add.apply(_this$canvas, lines); // this.canvas.renderAll();
|
|
2459
2239
|
|
|
2460
|
-
this.canvas.renderAll();
|
|
2461
2240
|
},
|
|
2462
2241
|
|
|
2463
2242
|
/**
|
|
@@ -2668,9 +2447,8 @@ var rightClickNodeConnect = [{
|
|
|
2668
2447
|
|
|
2669
2448
|
_this10.pointMoveUpdateLine(point);
|
|
2670
2449
|
|
|
2671
|
-
_this10.addPoint(point);
|
|
2450
|
+
_this10.addPoint(point); // this.canvas.renderAll();
|
|
2672
2451
|
|
|
2673
|
-
_this10.canvas.renderAll();
|
|
2674
2452
|
|
|
2675
2453
|
_this10.showDrapPopup(point);
|
|
2676
2454
|
}); // 折线点停止拖拽后 更新polyline中对应的坐标
|
|
@@ -2742,8 +2520,16 @@ var rightClickNodeConnect = [{
|
|
|
2742
2520
|
|
|
2743
2521
|
this.$emit('pointChange', data);
|
|
2744
2522
|
} else {
|
|
2523
|
+
this.$nextTick(function () {
|
|
2524
|
+
// 拖动新增节点时默认所有节点可删除
|
|
2525
|
+
_this11.currentDelPoint = null;
|
|
2526
|
+
});
|
|
2745
2527
|
var lastPoint = this.addPointList.at(-1);
|
|
2746
|
-
var position = this.polyline[point.polylineTypeId].position;
|
|
2528
|
+
var position = this.polyline[point.polylineTypeId].position;
|
|
2529
|
+
|
|
2530
|
+
var _this$addPointList = Object(slicedToArray["a" /* default */])(this.addPointList, 1),
|
|
2531
|
+
firstPoint = _this$addPointList[0]; // 如果是重合/连线节点
|
|
2532
|
+
|
|
2747
2533
|
|
|
2748
2534
|
if (point.get('scaleX') !== point.scale) {
|
|
2749
2535
|
var _this$_concatPoint, _this$_concatPoint2;
|
|
@@ -2774,7 +2560,7 @@ var rightClickNodeConnect = [{
|
|
|
2774
2560
|
return;
|
|
2775
2561
|
}
|
|
2776
2562
|
|
|
2777
|
-
!point.line2 && this.addPointList.splice(0, 1);
|
|
2563
|
+
!point.line2 && firstPoint.left <= point.originLeft && this.addPointList.splice(0, 1);
|
|
2778
2564
|
!point.id.includes('isTitle') && this.removePolyline(point.id);
|
|
2779
2565
|
|
|
2780
2566
|
if (this.addPointList.length > 0) {
|
|
@@ -2809,237 +2595,214 @@ var rightClickNodeConnect = [{
|
|
|
2809
2595
|
addPoint: function addPoint(point) {
|
|
2810
2596
|
var _this12 = this;
|
|
2811
2597
|
|
|
2812
|
-
|
|
2813
|
-
|
|
2598
|
+
var _this$propItems4 = this.propItems,
|
|
2599
|
+
xCellWidth = _this$propItems4.xCellWidth,
|
|
2600
|
+
table = _this$propItems4.table,
|
|
2601
|
+
originX = _this$propItems4.originX; // const addPointSpaceGridNumbers = table.addPointSpaceGridNumbers || [];
|
|
2602
|
+
|
|
2603
|
+
var addPointSpaceGridNumber = table.addPointSpaceGridNumber || 1;
|
|
2604
|
+
var left = point.left,
|
|
2605
|
+
top = point.top,
|
|
2606
|
+
originLeft = point.originLeft,
|
|
2607
|
+
originTop = point.originTop;
|
|
2608
|
+
var currentLeft = left;
|
|
2609
|
+
var startLength = this.addPointList.length;
|
|
2610
|
+
var n = 6; // 拖动范围,在需要增加节点的刻度左右吸入的范围值
|
|
2611
|
+
|
|
2612
|
+
var spaceWidth = xCellWidth * addPointSpaceGridNumber;
|
|
2613
|
+
var residue = (left - originLeft) % spaceWidth;
|
|
2614
|
+
var condition = residue > 0 && (residue > spaceWidth - n || residue < n);
|
|
2615
|
+
var conditionNoLine2 = !point.line2 && left > originLeft;
|
|
2616
|
+
var conditionHasLine2 = point.line2 && left > originLeft + spaceWidth; // if (!point.line2 && left > originLeft && condition) {
|
|
2617
|
+
|
|
2618
|
+
if (condition && (conditionNoLine2 || conditionHasLine2)) {
|
|
2619
|
+
if (residue > spaceWidth - n) left = left - residue + spaceWidth;
|
|
2620
|
+
if (residue < n) left = left - residue;
|
|
2621
|
+
point.set({
|
|
2622
|
+
left: left
|
|
2623
|
+
});
|
|
2814
2624
|
|
|
2815
|
-
|
|
2816
|
-
|
|
2817
|
-
switch (_context3.prev = _context3.next) {
|
|
2818
|
-
case 0:
|
|
2819
|
-
concatPoint = function _concatPoint(target) {
|
|
2820
|
-
var targetLeft = target.left,
|
|
2821
|
-
targetTop = target.top;
|
|
2822
|
-
point.setCoords();
|
|
2823
|
-
|
|
2824
|
-
if (left >= targetLeft - n && left <= targetLeft + n && top <= targetTop + n && top >= targetTop - n) {
|
|
2825
|
-
point.set({
|
|
2826
|
-
left: targetLeft,
|
|
2827
|
-
top: targetTop,
|
|
2828
|
-
scaleX: point.scale === 1 ? 2.5 : 0.1,
|
|
2829
|
-
scaleY: point.scale === 1 ? 2.5 : 0.1
|
|
2830
|
-
});
|
|
2831
|
-
} else {
|
|
2832
|
-
point.set({
|
|
2833
|
-
scaleX: point.scale,
|
|
2834
|
-
scaleY: point.scale
|
|
2835
|
-
});
|
|
2836
|
-
}
|
|
2837
|
-
};
|
|
2625
|
+
var checkPoints = function checkPoints() {
|
|
2626
|
+
var _this12$addPointList;
|
|
2838
2627
|
|
|
2839
|
-
|
|
2628
|
+
var PointLens = Math.floor((left - originLeft) / spaceWidth);
|
|
2840
2629
|
|
|
2841
|
-
|
|
2842
|
-
|
|
2843
|
-
|
|
2844
|
-
|
|
2845
|
-
|
|
2630
|
+
if (PointLens > 1 && ((_this12$addPointList = _this12.addPointList) === null || _this12$addPointList === void 0 ? void 0 : _this12$addPointList.length) <= PointLens) {
|
|
2631
|
+
for (var k = 0; k < PointLens; k++) {
|
|
2632
|
+
if (k > 0) {
|
|
2633
|
+
(function () {
|
|
2634
|
+
var curLeft = originLeft + spaceWidth * k; // 判断this.addPointList中的left是否包含curLeft,不包含就说明是漏了
|
|
2635
|
+
// const hasPoint = this.addPointList.some(v => Math.abs(v.left - curLeft) <= 0.0001);
|
|
2846
2636
|
|
|
2847
|
-
|
|
2848
|
-
|
|
2849
|
-
|
|
2850
|
-
conditionNoLine2 = !point.line2 && left > originLeft;
|
|
2851
|
-
conditionHasLine2 = point.line2 && left > originLeft + spaceWidth; // if (!point.line2 && left > originLeft && condition) {
|
|
2637
|
+
var hasPoint = _this12.addPointList.some(function (v) {
|
|
2638
|
+
return v.left == curLeft;
|
|
2639
|
+
});
|
|
2852
2640
|
|
|
2853
|
-
|
|
2854
|
-
|
|
2855
|
-
break;
|
|
2856
|
-
}
|
|
2641
|
+
if (!hasPoint) {
|
|
2642
|
+
var index;
|
|
2857
2643
|
|
|
2858
|
-
|
|
2859
|
-
|
|
2860
|
-
|
|
2861
|
-
|
|
2862
|
-
});
|
|
2644
|
+
var pointObj = _this12.addPointList.find(function (v, i) {
|
|
2645
|
+
if (v.left > curLeft) {
|
|
2646
|
+
index = i;
|
|
2647
|
+
}
|
|
2863
2648
|
|
|
2864
|
-
|
|
2865
|
-
|
|
2649
|
+
return v.left > curLeft;
|
|
2650
|
+
});
|
|
2866
2651
|
|
|
2867
|
-
|
|
2652
|
+
if (pointObj) {
|
|
2653
|
+
var cloneObj = JSON.parse(JSON.stringify(pointObj));
|
|
2654
|
+
var len = ~~((pointObj.left - (curLeft - spaceWidth)) / spaceWidth);
|
|
2655
|
+
var prePoint = _this12.addPointList[index - 1] || pointObj;
|
|
2656
|
+
var spaceHeight = (pointObj.top - prePoint.top) / len;
|
|
2657
|
+
var position = _this12.polyline[point.polylineTypeId].position;
|
|
2658
|
+
cloneObj.top = prePoint.top + spaceHeight;
|
|
2659
|
+
cloneObj.value.time = _this12.getXValue(curLeft);
|
|
2660
|
+
cloneObj.value.value = _this12.getYValue(position, cloneObj.top);
|
|
2661
|
+
cloneObj.left = curLeft;
|
|
2868
2662
|
|
|
2869
|
-
|
|
2870
|
-
for (var k = 0; k < PointLens; k++) {
|
|
2871
|
-
if (k > 0) {
|
|
2872
|
-
(function () {
|
|
2873
|
-
var curLeft = originLeft + spaceWidth * k; // 判断this.addPointList中的left是否包含curLeft,不包含就说明是漏了
|
|
2663
|
+
_this12.addPointList.splice(index, 0, cloneObj);
|
|
2874
2664
|
|
|
2875
|
-
|
|
2876
|
-
|
|
2877
|
-
|
|
2665
|
+
_this12.clonePoint(point, [prePoint.left, prePoint.top, cloneObj.left, cloneObj.top]);
|
|
2666
|
+
}
|
|
2667
|
+
}
|
|
2668
|
+
})();
|
|
2669
|
+
}
|
|
2670
|
+
}
|
|
2671
|
+
}
|
|
2672
|
+
}; // const i = Math.floor((left - originLeft) / spaceWidth);
|
|
2673
|
+
// 复制点和线
|
|
2674
|
+
|
|
2675
|
+
|
|
2676
|
+
if (conditionNoLine2 || conditionHasLine2) {
|
|
2677
|
+
// point.line1 && this.removePolyline(point.line1.id);
|
|
2678
|
+
setPointLineColor(point, 'transparent', conditionHasLine2);
|
|
2679
|
+
this.addPointList.length == 0 && this.clonePoint(point, [point.line1 ? point.line1.x1 : originLeft, point.line1 ? point.line1.y1 : originTop, originLeft, originTop]);
|
|
2680
|
+
|
|
2681
|
+
if (this.addPointList.every(function (v) {
|
|
2682
|
+
return v.left !== left;
|
|
2683
|
+
})) {
|
|
2684
|
+
// const points1 = i === 1 ? [originLeft, originTop] : point.prePoints;
|
|
2685
|
+
var points1 = this.addPointList.length == 0 ? [originLeft, originTop] : point.prePoints;
|
|
2686
|
+
|
|
2687
|
+
if (points1) {
|
|
2688
|
+
// this.setAddPointList(point);
|
|
2689
|
+
// 调用上面方法就会导致线段绘制失败,目前还不知道为啥子
|
|
2690
|
+
var _this$getValue3 = this.getValue(point),
|
|
2691
|
+
data = _this$getValue3.data,
|
|
2692
|
+
x = _this$getValue3.x,
|
|
2693
|
+
y = _this$getValue3.y;
|
|
2694
|
+
|
|
2695
|
+
data.value = {
|
|
2696
|
+
time: x,
|
|
2697
|
+
value: y
|
|
2698
|
+
};
|
|
2699
|
+
data.left = left;
|
|
2700
|
+
data.top = top;
|
|
2701
|
+
this.addPointList.push(data);
|
|
2702
|
+
this.clonePoint(point, [].concat(Object(toConsumableArray["a" /* default */])(points1), [left, top]));
|
|
2703
|
+
}
|
|
2704
|
+
}
|
|
2878
2705
|
|
|
2879
|
-
|
|
2880
|
-
|
|
2706
|
+
checkPoints();
|
|
2707
|
+
}
|
|
2708
|
+
} // 断点相连
|
|
2881
2709
|
|
|
2882
|
-
var pointObj = _this12.addPointList.find(function (v, i) {
|
|
2883
|
-
if (v.left > curLeft) {
|
|
2884
|
-
index = i;
|
|
2885
|
-
}
|
|
2886
2710
|
|
|
2887
|
-
|
|
2888
|
-
|
|
2711
|
+
function concatPoint(target) {
|
|
2712
|
+
var targetLeft = target.left,
|
|
2713
|
+
targetTop = target.top;
|
|
2714
|
+
point.setCoords();
|
|
2889
2715
|
|
|
2890
|
-
|
|
2891
|
-
|
|
2892
|
-
|
|
2893
|
-
|
|
2894
|
-
|
|
2716
|
+
if (left >= targetLeft - n && left <= targetLeft + n && top <= targetTop + n && top >= targetTop - n) {
|
|
2717
|
+
point.set({
|
|
2718
|
+
left: targetLeft,
|
|
2719
|
+
top: targetTop,
|
|
2720
|
+
scaleX: point.scale === 1 ? 2.5 : 0.1,
|
|
2721
|
+
scaleY: point.scale === 1 ? 2.5 : 0.1
|
|
2722
|
+
});
|
|
2723
|
+
} else {
|
|
2724
|
+
point.set({
|
|
2725
|
+
scaleX: point.scale,
|
|
2726
|
+
scaleY: point.scale
|
|
2727
|
+
});
|
|
2728
|
+
}
|
|
2729
|
+
} // 检查是否显示重合连线放大节点的标识
|
|
2895
2730
|
|
|
2896
|
-
_this12.addPointList.splice(index, 0, cloneObj);
|
|
2897
|
-
}
|
|
2898
|
-
}
|
|
2899
|
-
})();
|
|
2900
|
-
}
|
|
2901
|
-
}
|
|
2902
|
-
}
|
|
2903
|
-
}; // const i = Math.floor((left - originLeft) / spaceWidth);
|
|
2904
|
-
// 复制点和线
|
|
2905
2731
|
|
|
2732
|
+
var polylineTypeId = point.polylineTypeId,
|
|
2733
|
+
polylineIndex = point.polylineIndex;
|
|
2734
|
+
var polylineObj = this.polylinePointList.find(function (v) {
|
|
2735
|
+
return v.polylineTypeId == polylineTypeId && v.polylineIndex == polylineIndex;
|
|
2736
|
+
});
|
|
2737
|
+
polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.pointList.forEach(function (v) {
|
|
2738
|
+
return v.bringToFront();
|
|
2739
|
+
});
|
|
2906
2740
|
|
|
2907
|
-
|
|
2908
|
-
|
|
2909
|
-
break;
|
|
2910
|
-
}
|
|
2741
|
+
if (point.nextPoint) {
|
|
2742
|
+
var _polylineObj$pointLis;
|
|
2911
2743
|
|
|
2912
|
-
|
|
2913
|
-
|
|
2914
|
-
|
|
2744
|
+
this._concatIndex = polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.pointerList.findIndex(function (v) {
|
|
2745
|
+
return v + n > left && v > originLeft;
|
|
2746
|
+
});
|
|
2915
2747
|
|
|
2916
|
-
|
|
2917
|
-
|
|
2918
|
-
|
|
2919
|
-
|
|
2920
|
-
|
|
2921
|
-
|
|
2922
|
-
|
|
2923
|
-
|
|
2924
|
-
case 23:
|
|
2925
|
-
if (!_this12.addPointList.every(function (v) {
|
|
2926
|
-
return v.left !== left;
|
|
2927
|
-
})) {
|
|
2928
|
-
_context3.next = 34;
|
|
2929
|
-
break;
|
|
2930
|
-
}
|
|
2931
|
-
|
|
2932
|
-
// const points1 = i === 1 ? [originLeft, originTop] : point.prePoints;
|
|
2933
|
-
points1 = _this12.addPointList.length == 0 ? [originLeft, originTop] : point.prePoints;
|
|
2934
|
-
_context3.t1 = points1;
|
|
2935
|
-
|
|
2936
|
-
if (!_context3.t1) {
|
|
2937
|
-
_context3.next = 29;
|
|
2938
|
-
break;
|
|
2939
|
-
}
|
|
2940
|
-
|
|
2941
|
-
_context3.next = 29;
|
|
2942
|
-
return _this12.clonePoint(point, [].concat(Object(toConsumableArray["a" /* default */])(points1), [left, top]));
|
|
2943
|
-
|
|
2944
|
-
case 29:
|
|
2945
|
-
// this.setAddPointList(point);
|
|
2946
|
-
// 调用上面方法就会导致线段绘制失败,目前还不知道为啥子
|
|
2947
|
-
_this12$getValue = _this12.getValue(point), data = _this12$getValue.data, x = _this12$getValue.x, y = _this12$getValue.y;
|
|
2948
|
-
data.value = {
|
|
2949
|
-
time: x,
|
|
2950
|
-
value: y
|
|
2951
|
-
};
|
|
2952
|
-
data.left = point.left;
|
|
2953
|
-
data.top = top;
|
|
2954
|
-
|
|
2955
|
-
_this12.addPointList.push(data);
|
|
2956
|
-
|
|
2957
|
-
case 34:
|
|
2958
|
-
checkPoints();
|
|
2959
|
-
|
|
2960
|
-
case 35:
|
|
2961
|
-
// 检查是否显示重合连线放大节点的标识
|
|
2962
|
-
polylineTypeId = point.polylineTypeId, polylineIndex = point.polylineIndex;
|
|
2963
|
-
polylineObj = _this12.polylinePointList.find(function (v) {
|
|
2964
|
-
return v.polylineTypeId == polylineTypeId && v.polylineIndex == polylineIndex;
|
|
2965
|
-
});
|
|
2966
|
-
polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.pointList.forEach(function (v) {
|
|
2967
|
-
return v.bringToFront();
|
|
2968
|
-
});
|
|
2969
|
-
|
|
2970
|
-
if (point.nextPoint) {
|
|
2971
|
-
_this12._concatIndex = polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.pointerList.findIndex(function (v) {
|
|
2972
|
-
return v + n > left && v > originLeft;
|
|
2973
|
-
});
|
|
2974
|
-
|
|
2975
|
-
if (!~_this12._concatIndex) {
|
|
2976
|
-
point.set({
|
|
2977
|
-
scaleX: point.scale,
|
|
2978
|
-
scaleY: point.scale
|
|
2979
|
-
});
|
|
2980
|
-
} else {
|
|
2981
|
-
concatPoint(polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.pointList[_this12._concatIndex]);
|
|
2982
|
-
}
|
|
2983
|
-
|
|
2984
|
-
_this12._concatPoint = (polylineObj === null || polylineObj === void 0 ? void 0 : (_polylineObj$pointLis = polylineObj.pointList) === null || _polylineObj$pointLis === void 0 ? void 0 : _polylineObj$pointLis[_this12._concatIndex]) || null; // 被覆盖节点置灰配置
|
|
2985
|
-
|
|
2986
|
-
polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.pointerList.forEach(function (v, i) {
|
|
2987
|
-
var obj = polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.pointList[i];
|
|
2988
|
-
|
|
2989
|
-
if (v > originLeft && v < left) {
|
|
2990
|
-
var _obj$line;
|
|
2748
|
+
if (!~this._concatIndex) {
|
|
2749
|
+
point.set({
|
|
2750
|
+
scaleX: point.scale,
|
|
2751
|
+
scaleY: point.scale
|
|
2752
|
+
});
|
|
2753
|
+
} else {
|
|
2754
|
+
concatPoint(polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.pointList[this._concatIndex]);
|
|
2755
|
+
}
|
|
2991
2756
|
|
|
2992
|
-
|
|
2993
|
-
resetPointColor([obj], '#999');
|
|
2994
|
-
(_obj$line = obj.line2) === null || _obj$line === void 0 ? void 0 : _obj$line.set({
|
|
2995
|
-
stroke: '#999'
|
|
2996
|
-
});
|
|
2997
|
-
} else {
|
|
2998
|
-
var _obj$line2;
|
|
2757
|
+
this._concatPoint = (polylineObj === null || polylineObj === void 0 ? void 0 : (_polylineObj$pointLis = polylineObj.pointList) === null || _polylineObj$pointLis === void 0 ? void 0 : _polylineObj$pointLis[this._concatIndex]) || null; // 被覆盖节点置灰配置
|
|
2999
2758
|
|
|
3000
|
-
|
|
3001
|
-
|
|
3002
|
-
stroke: polylineObj.color
|
|
3003
|
-
});
|
|
3004
|
-
}
|
|
3005
|
-
});
|
|
2759
|
+
polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.pointerList.forEach(function (v, i) {
|
|
2760
|
+
var obj = polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.pointList[i];
|
|
3006
2761
|
|
|
3007
|
-
|
|
3008
|
-
|
|
3009
|
-
} else {
|
|
3010
|
-
setPointLineColor(point, 'transparent', true);
|
|
3011
|
-
}
|
|
3012
|
-
} // 如果往回拖动则删除经过的已存在的节点
|
|
2762
|
+
if (v > originLeft && v < left) {
|
|
2763
|
+
var _obj$line;
|
|
3013
2764
|
|
|
2765
|
+
// 此处需要递归遍历group节点的所有子节点,然后更改其颜色
|
|
2766
|
+
resetPointColor([obj], '#999');
|
|
2767
|
+
(_obj$line = obj.line2) === null || _obj$line === void 0 ? void 0 : _obj$line.set({
|
|
2768
|
+
stroke: '#999'
|
|
2769
|
+
});
|
|
2770
|
+
} else {
|
|
2771
|
+
var _obj$line2;
|
|
3014
2772
|
|
|
3015
|
-
|
|
3016
|
-
|
|
2773
|
+
resetPointColor([obj], polylineObj.color);
|
|
2774
|
+
(_obj$line2 = obj.line2) === null || _obj$line2 === void 0 ? void 0 : _obj$line2.set({
|
|
2775
|
+
stroke: polylineObj.color
|
|
2776
|
+
});
|
|
2777
|
+
}
|
|
2778
|
+
});
|
|
3017
2779
|
|
|
3018
|
-
|
|
3019
|
-
|
|
3020
|
-
|
|
3021
|
-
|
|
2780
|
+
if ((point.line1 || point.line2) && left < originLeft + spaceWidth) {
|
|
2781
|
+
setPointLineColor(point, polylineObj.color, true);
|
|
2782
|
+
} else {
|
|
2783
|
+
setPointLineColor(point, 'transparent', true);
|
|
2784
|
+
}
|
|
2785
|
+
} // 如果往回拖动则删除经过的已存在的节点
|
|
3022
2786
|
|
|
3023
|
-
if (endLength === 0) {
|
|
3024
|
-
setPointLineColor(point, polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.color, conditionHasLine2);
|
|
3025
2787
|
|
|
3026
|
-
|
|
3027
|
-
|
|
2788
|
+
if (startLength > 0 && currentLeft <= this.addPointList[startLength - 1].left) {
|
|
2789
|
+
this.removePolyline('increasePointBatch', left);
|
|
2790
|
+
this.addPointList = this.addPointList.filter(function (v) {
|
|
2791
|
+
return v.left < left;
|
|
2792
|
+
});
|
|
2793
|
+
var endLength = this.addPointList.length;
|
|
3028
2794
|
|
|
3029
|
-
|
|
3030
|
-
|
|
3031
|
-
|
|
3032
|
-
|
|
3033
|
-
}
|
|
3034
|
-
}
|
|
2795
|
+
if (endLength === 0) {
|
|
2796
|
+
setPointLineColor(point, polylineObj === null || polylineObj === void 0 ? void 0 : polylineObj.color, conditionHasLine2);
|
|
2797
|
+
this.removePolyline('increasePointBatch', originLeft);
|
|
2798
|
+
}
|
|
3035
2799
|
|
|
3036
|
-
|
|
3037
|
-
|
|
3038
|
-
|
|
3039
|
-
|
|
3040
|
-
|
|
3041
|
-
|
|
3042
|
-
}))();
|
|
2800
|
+
if (endLength > 0) {
|
|
2801
|
+
point.set({
|
|
2802
|
+
prePoints: [this.addPointList[endLength - 1].left, this.addPointList[endLength - 1].top]
|
|
2803
|
+
});
|
|
2804
|
+
}
|
|
2805
|
+
}
|
|
3043
2806
|
},
|
|
3044
2807
|
clonePoint: function clonePoint(point, points) {
|
|
3045
2808
|
var _this13 = this;
|
|
@@ -3064,9 +2827,7 @@ var rightClickNodeConnect = [{
|
|
|
3064
2827
|
scaleY: point.scale
|
|
3065
2828
|
});
|
|
3066
2829
|
clonedObj.hasControls = clonedObj.hasBorders = false;
|
|
3067
|
-
point.
|
|
3068
|
-
prePoints: [point.left, point.top]
|
|
3069
|
-
});
|
|
2830
|
+
point.prePoints = [point.left, point.top];
|
|
3070
2831
|
|
|
3071
2832
|
var line = _this13.drawLine(Object(toConsumableArray["a" /* default */])(points), Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({
|
|
3072
2833
|
evented: evented,
|
|
@@ -3085,8 +2846,6 @@ var rightClickNodeConnect = [{
|
|
|
3085
2846
|
|
|
3086
2847
|
_this13.canvas.add(clonedObj);
|
|
3087
2848
|
|
|
3088
|
-
_this13.canvas.renderAll();
|
|
3089
|
-
|
|
3090
2849
|
resolve(clonedObj);
|
|
3091
2850
|
});
|
|
3092
2851
|
});
|
|
@@ -3104,12 +2863,11 @@ var rightClickNodeConnect = [{
|
|
|
3104
2863
|
y: y
|
|
3105
2864
|
};
|
|
3106
2865
|
} else {
|
|
3107
|
-
var
|
|
3108
|
-
|
|
2866
|
+
var left = this.getYValue('left', point.top);
|
|
3109
2867
|
var right = this.getYValue('right', point.top);
|
|
3110
2868
|
return {
|
|
3111
2869
|
x: x,
|
|
3112
|
-
left:
|
|
2870
|
+
left: left,
|
|
3113
2871
|
right: right
|
|
3114
2872
|
};
|
|
3115
2873
|
}
|
|
@@ -3152,10 +2910,10 @@ var rightClickNodeConnect = [{
|
|
|
3152
2910
|
}
|
|
3153
2911
|
};
|
|
3154
2912
|
|
|
3155
|
-
var _this$
|
|
3156
|
-
x = _this$
|
|
3157
|
-
y = _this$
|
|
3158
|
-
data = _this$
|
|
2913
|
+
var _this$getValue4 = this.getValue(point),
|
|
2914
|
+
x = _this$getValue4.x,
|
|
2915
|
+
y = _this$getValue4.y,
|
|
2916
|
+
data = _this$getValue4.data;
|
|
3159
2917
|
|
|
3160
2918
|
var getY = function getY(y) {
|
|
3161
2919
|
if ((data === null || data === void 0 ? void 0 : data.position) == 'right') {
|
|
@@ -3163,9 +2921,9 @@ var rightClickNodeConnect = [{
|
|
|
3163
2921
|
var _y$toString$split = y.toString().split('.'),
|
|
3164
2922
|
_y$toString$split2 = Object(slicedToArray["a" /* default */])(_y$toString$split, 2),
|
|
3165
2923
|
m = _y$toString$split2[0],
|
|
3166
|
-
|
|
2924
|
+
n = _y$toString$split2[1];
|
|
3167
2925
|
|
|
3168
|
-
return parseFloat("".concat(m, ".").concat(
|
|
2926
|
+
return parseFloat("".concat(m, ".").concat(n.slice(0, 1))) * 10 / 10;
|
|
3169
2927
|
}
|
|
3170
2928
|
|
|
3171
2929
|
return y;
|
|
@@ -3408,8 +3166,8 @@ var rightClickNodeConnect = [{
|
|
|
3408
3166
|
|
|
3409
3167
|
var FabricPolylines_component = Object(componentNormalizer["a" /* default */])(
|
|
3410
3168
|
fabric_chart_FabricPolylinesvue_type_script_lang_js_,
|
|
3411
|
-
|
|
3412
|
-
|
|
3169
|
+
FabricPolylinesvue_type_template_id_05a44150_render,
|
|
3170
|
+
FabricPolylinesvue_type_template_id_05a44150_staticRenderFns,
|
|
3413
3171
|
false,
|
|
3414
3172
|
null,
|
|
3415
3173
|
null,
|
|
@@ -3429,15 +3187,8 @@ var FabricPolylines_component = Object(componentNormalizer["a" /* default */])(
|
|
|
3429
3187
|
data: function data() {
|
|
3430
3188
|
return {};
|
|
3431
3189
|
},
|
|
3432
|
-
mounted: function mounted() {
|
|
3433
|
-
var _this = this;
|
|
3434
|
-
|
|
3435
|
-
this.$nextTick(function () {
|
|
3436
|
-
_this.initGrid();
|
|
3437
|
-
});
|
|
3438
|
-
},
|
|
3439
3190
|
methods: {
|
|
3440
|
-
|
|
3191
|
+
init: function init() {
|
|
3441
3192
|
// 主表格
|
|
3442
3193
|
this.createGrid(this.propItems.originY, this.propItems.endY, this.propItems.gridYNumber, this.propItems.yCellHeight); // 上方表格
|
|
3443
3194
|
|
|
@@ -3483,8 +3234,7 @@ var FabricPolylines_component = Object(componentNormalizer["a" /* default */])(
|
|
|
3483
3234
|
selectable: false
|
|
3484
3235
|
});
|
|
3485
3236
|
this.canvas.add(group);
|
|
3486
|
-
this.canvas.sendToBack(group);
|
|
3487
|
-
this.canvas.renderAll();
|
|
3237
|
+
this.canvas.sendToBack(group); // this.canvas.renderAll();
|
|
3488
3238
|
}
|
|
3489
3239
|
},
|
|
3490
3240
|
render: function render(h) {
|
|
@@ -3513,12 +3263,12 @@ var FabricGrid_component = Object(componentNormalizer["a" /* default */])(
|
|
|
3513
3263
|
)
|
|
3514
3264
|
|
|
3515
3265
|
/* harmony default export */ var FabricGrid = (FabricGrid_component.exports);
|
|
3516
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
3517
|
-
var
|
|
3518
|
-
var
|
|
3266
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"1b461ec0-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart/FabricTextGroup.vue?vue&type=template&id=3504e5af&
|
|
3267
|
+
var FabricTextGroupvue_type_template_id_3504e5af_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"text-group"},[(_vm.isRightVisible)?_c('MouseRightClick',{attrs:{"getContainer":_vm.getContainer,"nodeList":_vm.rightClickNode,"rightPos":_vm.rightPos},on:{"nodeClick":_vm.handleRightClick,"closeRight":function($event){_vm.isRightVisible = false}}}):_vm._e(),(_vm.isDropVisible)?_c('DropPopup',{attrs:{"val":_vm.dropVal,"dropPos":_vm.dropPos}}):_vm._e()],1)}
|
|
3268
|
+
var FabricTextGroupvue_type_template_id_3504e5af_staticRenderFns = []
|
|
3519
3269
|
|
|
3520
3270
|
|
|
3521
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricTextGroup.vue?vue&type=template&id=
|
|
3271
|
+
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricTextGroup.vue?vue&type=template&id=3504e5af&
|
|
3522
3272
|
|
|
3523
3273
|
// EXTERNAL MODULE: external "core-js/modules/es.array.sort.js"
|
|
3524
3274
|
var es_array_sort_js_ = __webpack_require__("4c07");
|
|
@@ -3591,10 +3341,15 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
3591
3341
|
watch: {
|
|
3592
3342
|
'templateData.other': {
|
|
3593
3343
|
handler: function handler(value) {
|
|
3344
|
+
var _this = this;
|
|
3345
|
+
|
|
3594
3346
|
if (value) {
|
|
3595
|
-
this
|
|
3596
|
-
|
|
3597
|
-
|
|
3347
|
+
this.$nextTick(function () {
|
|
3348
|
+
_this.removeOther();
|
|
3349
|
+
|
|
3350
|
+
_this.drawTextDataGroup(value); // this.canvas.renderAll();
|
|
3351
|
+
|
|
3352
|
+
});
|
|
3598
3353
|
}
|
|
3599
3354
|
},
|
|
3600
3355
|
deep: true
|
|
@@ -3619,13 +3374,7 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
3619
3374
|
|
|
3620
3375
|
};
|
|
3621
3376
|
},
|
|
3622
|
-
mounted: function mounted() {
|
|
3623
|
-
var _this = this;
|
|
3624
|
-
|
|
3625
|
-
this.$nextTick(function () {
|
|
3626
|
-
_this.init();
|
|
3627
|
-
});
|
|
3628
|
-
},
|
|
3377
|
+
mounted: function mounted() {},
|
|
3629
3378
|
computed: {
|
|
3630
3379
|
girdLineStyle: function girdLineStyle() {
|
|
3631
3380
|
return Object.assign({}, defaultVaule.borderStyle, this.templateData.borderStyle || {});
|
|
@@ -3653,8 +3402,8 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
3653
3402
|
this.templateData.left && this.drawLeftScaleGroup(this.templateData.left);
|
|
3654
3403
|
this.templateData.other && this.drawTextDataGroup(this.templateData.other);
|
|
3655
3404
|
this.eventStyle.evented && this.createEvent();
|
|
3656
|
-
this.drawBorder();
|
|
3657
|
-
|
|
3405
|
+
this.drawBorder(); // this.canvas.renderAll();
|
|
3406
|
+
|
|
3658
3407
|
this.templateData.bottom && this.drawBottomTextDataGroup(this.templateData.bottom);
|
|
3659
3408
|
},
|
|
3660
3409
|
drawBorder: function drawBorder() {
|
|
@@ -3842,9 +3591,13 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
3842
3591
|
dataIndex: index,
|
|
3843
3592
|
index: i,
|
|
3844
3593
|
type: 'colList',
|
|
3845
|
-
id: "".concat(index, "_").concat(i, "_other_").concat(Date.now())
|
|
3594
|
+
id: "".concat(index, "_").concat(i, "_other_").concat(Date.now()),
|
|
3595
|
+
name: v.value
|
|
3846
3596
|
}, _this7.eventStyle));
|
|
3847
3597
|
text.hasControls = text.hasBorders = false;
|
|
3598
|
+
|
|
3599
|
+
_this7.setPopup(text);
|
|
3600
|
+
|
|
3848
3601
|
textList.push(text);
|
|
3849
3602
|
});
|
|
3850
3603
|
}
|
|
@@ -3891,9 +3644,13 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
3891
3644
|
dataIndex: index,
|
|
3892
3645
|
index: i,
|
|
3893
3646
|
type: 'list',
|
|
3894
|
-
id: "".concat(index, "_").concat(i, "_other_").concat(Date.now())
|
|
3647
|
+
id: "".concat(index, "_").concat(i, "_other_").concat(Date.now()),
|
|
3648
|
+
name: v.value
|
|
3895
3649
|
}, _this8.eventStyle));
|
|
3896
3650
|
text.hasControls = text.hasBorders = false;
|
|
3651
|
+
|
|
3652
|
+
_this8.setPopup(text);
|
|
3653
|
+
|
|
3897
3654
|
textList.push(text);
|
|
3898
3655
|
}
|
|
3899
3656
|
});
|
|
@@ -3901,6 +3658,16 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
3901
3658
|
|
|
3902
3659
|
(_this$canvas3 = this.canvas).add.apply(_this$canvas3, textList);
|
|
3903
3660
|
},
|
|
3661
|
+
setPopup: function setPopup(point) {
|
|
3662
|
+
var _this9 = this;
|
|
3663
|
+
|
|
3664
|
+
point.on('mouseover', function () {
|
|
3665
|
+
_this9.showDrapPopup(point, true);
|
|
3666
|
+
});
|
|
3667
|
+
point.on('mouseout', function () {
|
|
3668
|
+
_this9.isDropVisible = false;
|
|
3669
|
+
});
|
|
3670
|
+
},
|
|
3904
3671
|
// 判断当前时间是否超出网格区域
|
|
3905
3672
|
isLimit: function isLimit(value) {
|
|
3906
3673
|
var xScaleList = this.propItems.xScaleList;
|
|
@@ -3910,11 +3677,11 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
3910
3677
|
return time >= minTime && time <= maxTime;
|
|
3911
3678
|
},
|
|
3912
3679
|
removeMark: function removeMark() {
|
|
3913
|
-
var
|
|
3680
|
+
var _this10 = this;
|
|
3914
3681
|
|
|
3915
3682
|
this.canvas.forEachObject(function (obj) {
|
|
3916
3683
|
if (obj.type && obj.type === 'mark') {
|
|
3917
|
-
|
|
3684
|
+
_this10.canvas.remove(obj);
|
|
3918
3685
|
}
|
|
3919
3686
|
});
|
|
3920
3687
|
},
|
|
@@ -3924,7 +3691,7 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
3924
3691
|
_obj$iconStyle,
|
|
3925
3692
|
_obj$seqStyle,
|
|
3926
3693
|
_obj$seqStyle$circle,
|
|
3927
|
-
|
|
3694
|
+
_this11 = this;
|
|
3928
3695
|
|
|
3929
3696
|
if (!obj.list) {
|
|
3930
3697
|
return;
|
|
@@ -3962,9 +3729,9 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
3962
3729
|
|
|
3963
3730
|
var y = baseY;
|
|
3964
3731
|
|
|
3965
|
-
var x =
|
|
3732
|
+
var x = _this11.cumputedX(item[0]);
|
|
3966
3733
|
|
|
3967
|
-
if (
|
|
3734
|
+
if (_this11.isLimit(item[0])) {
|
|
3968
3735
|
item[1].forEach( /*#__PURE__*/function () {
|
|
3969
3736
|
var _ref2 = Object(asyncToGenerator["a" /* default */])( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(v, i) {
|
|
3970
3737
|
var common, setTop, eventStyle, addCanvas, option, ele, img, _obj$seqStyle2, _obj$seqStyle3, circle, text, group, _text;
|
|
@@ -4002,7 +3769,7 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
4002
3769
|
name: v.name,
|
|
4003
3770
|
type: 'mark'
|
|
4004
3771
|
};
|
|
4005
|
-
eventStyle = !
|
|
3772
|
+
eventStyle = !_this11.eventStyle.evented ? {
|
|
4006
3773
|
lockMovementX: true,
|
|
4007
3774
|
lockMovementY: true
|
|
4008
3775
|
} : {};
|
|
@@ -4015,11 +3782,11 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
4015
3782
|
case 0:
|
|
4016
3783
|
point.hasControls = point.hasBorders = false;
|
|
4017
3784
|
|
|
4018
|
-
|
|
3785
|
+
_this11.pointEvent(point);
|
|
4019
3786
|
|
|
4020
|
-
|
|
3787
|
+
_this11.canvas.add(point);
|
|
4021
3788
|
|
|
4022
|
-
|
|
3789
|
+
_this11.canvas.requestRenderAll();
|
|
4023
3790
|
|
|
4024
3791
|
case 4:
|
|
4025
3792
|
case "end":
|
|
@@ -4034,7 +3801,7 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
4034
3801
|
};
|
|
4035
3802
|
}();
|
|
4036
3803
|
|
|
4037
|
-
if (!(
|
|
3804
|
+
if (!(_this11.isObject(v) && !v.value)) {
|
|
4038
3805
|
_context2.next = 17;
|
|
4039
3806
|
break;
|
|
4040
3807
|
}
|
|
@@ -4048,14 +3815,14 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
4048
3815
|
}
|
|
4049
3816
|
|
|
4050
3817
|
_context2.next = 10;
|
|
4051
|
-
return
|
|
3818
|
+
return _this11.createImage(v.iconClassName, v);
|
|
4052
3819
|
|
|
4053
3820
|
case 10:
|
|
4054
3821
|
ele = _context2.sent;
|
|
4055
3822
|
|
|
4056
3823
|
case 11:
|
|
4057
3824
|
_context2.next = 13;
|
|
4058
|
-
return
|
|
3825
|
+
return _this11.createPoint(v !== null && v !== void 0 && v.url || v !== null && v !== void 0 && v.iconClassName ? 'img' : v.type, Object(objectSpread2["a" /* default */])({
|
|
4059
3826
|
ele: ele || ''
|
|
4060
3827
|
}, option));
|
|
4061
3828
|
|
|
@@ -4079,7 +3846,7 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
4079
3846
|
setTop(lineHeightSeq); // 标记增加序号
|
|
4080
3847
|
|
|
4081
3848
|
_context2.next = 22;
|
|
4082
|
-
return
|
|
3849
|
+
return _this11.createPoint('circle', Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, common), {}, {
|
|
4083
3850
|
radius: 5,
|
|
4084
3851
|
strokeWidth: 1,
|
|
4085
3852
|
stroke: '#000',
|
|
@@ -4088,15 +3855,15 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
4088
3855
|
|
|
4089
3856
|
case 22:
|
|
4090
3857
|
circle = _context2.sent;
|
|
4091
|
-
text = new
|
|
4092
|
-
group = new
|
|
3858
|
+
text = new _this11.fabric.Text(String(v.value), Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, defaultVaule.textStyle), common), ((_obj$seqStyle3 = obj.seqStyle) === null || _obj$seqStyle3 === void 0 ? void 0 : _obj$seqStyle3.text) || {}));
|
|
3859
|
+
group = new _this11.fabric.Group([circle, text], Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, common), eventStyle));
|
|
4093
3860
|
addCanvas(group);
|
|
4094
3861
|
_context2.next = 31;
|
|
4095
3862
|
break;
|
|
4096
3863
|
|
|
4097
3864
|
case 28:
|
|
4098
3865
|
setTop(lineHeightText);
|
|
4099
|
-
_text = new
|
|
3866
|
+
_text = new _this11.fabric.Text(String(v.value), Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, defaultVaule.textStyle), obj.style), common), eventStyle));
|
|
4100
3867
|
addCanvas(_text);
|
|
4101
3868
|
|
|
4102
3869
|
case 31:
|
|
@@ -4115,32 +3882,26 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
4115
3882
|
}); // this.canvas.add(...textList);
|
|
4116
3883
|
},
|
|
4117
3884
|
pointEvent: function pointEvent(point) {
|
|
4118
|
-
var
|
|
3885
|
+
var _this12 = this;
|
|
4119
3886
|
|
|
4120
|
-
|
|
4121
|
-
_this11.showDrapPopup(point, true);
|
|
4122
|
-
});
|
|
4123
|
-
point.on('mouseout', function () {
|
|
4124
|
-
_this11.isDropVisible = false;
|
|
4125
|
-
}); // 移动中 实时更新相关联的线的坐标
|
|
3887
|
+
this.setPopup(point); // 移动中 实时更新相关联的线的坐标
|
|
4126
3888
|
|
|
4127
3889
|
if (this.eventStyle.evented) {
|
|
4128
3890
|
point.on('moving', function () {
|
|
4129
|
-
|
|
3891
|
+
_this12.moveLimit(point); // this.canvas.renderAll();
|
|
4130
3892
|
|
|
4131
|
-
_this11.canvas.renderAll();
|
|
4132
3893
|
|
|
4133
|
-
|
|
3894
|
+
_this12.showDrapPopup(point);
|
|
4134
3895
|
});
|
|
4135
3896
|
point.on('moved', function () {
|
|
4136
|
-
|
|
3897
|
+
_this12.isDropVisible = false;
|
|
4137
3898
|
var value = {
|
|
4138
3899
|
data: point.data,
|
|
4139
3900
|
oldVal: point.time,
|
|
4140
|
-
newVal:
|
|
3901
|
+
newVal: _this12.getXValue(point.left)
|
|
4141
3902
|
};
|
|
4142
3903
|
|
|
4143
|
-
|
|
3904
|
+
_this12.$emit('markChange', value);
|
|
4144
3905
|
});
|
|
4145
3906
|
}
|
|
4146
3907
|
},
|
|
@@ -4295,8 +4056,8 @@ var getTopTotalList = function getTopTotalList(tree, topTotalList) {
|
|
|
4295
4056
|
|
|
4296
4057
|
var FabricTextGroup_component = Object(componentNormalizer["a" /* default */])(
|
|
4297
4058
|
fabric_chart_FabricTextGroupvue_type_script_lang_js_,
|
|
4298
|
-
|
|
4299
|
-
|
|
4059
|
+
FabricTextGroupvue_type_template_id_3504e5af_render,
|
|
4060
|
+
FabricTextGroupvue_type_template_id_3504e5af_staticRenderFns,
|
|
4300
4061
|
false,
|
|
4301
4062
|
null,
|
|
4302
4063
|
null,
|
|
@@ -4305,19 +4066,19 @@ var FabricTextGroup_component = Object(componentNormalizer["a" /* default */])(
|
|
|
4305
4066
|
)
|
|
4306
4067
|
|
|
4307
4068
|
/* harmony default export */ var FabricTextGroup = (FabricTextGroup_component.exports);
|
|
4308
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
4309
|
-
var
|
|
4310
|
-
var
|
|
4069
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"1b461ec0-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart/FabricScaleValue.vue?vue&type=template&id=9c461680&
|
|
4070
|
+
var FabricScaleValuevue_type_template_id_9c461680_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return (_vm.templateData.top.xScalevalue.popupTop)?_c('TimeScaleValue',{attrs:{"times":_vm.timeList,"templateData":_vm.templateData}}):_vm._e()}
|
|
4071
|
+
var FabricScaleValuevue_type_template_id_9c461680_staticRenderFns = []
|
|
4311
4072
|
|
|
4312
4073
|
|
|
4313
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricScaleValue.vue?vue&type=template&id=
|
|
4074
|
+
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricScaleValue.vue?vue&type=template&id=9c461680&
|
|
4314
4075
|
|
|
4315
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
4316
|
-
var
|
|
4317
|
-
var
|
|
4076
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"1b461ec0-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/components/TimeScaleValue.vue?vue&type=template&id=184c584a&scoped=true&
|
|
4077
|
+
var TimeScaleValuevue_type_template_id_184c584a_scoped_true_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.isShow),expression:"isShow"}],staticClass:"c-time-scalevalue",style:({ '--left': _vm.popupStyle.left, '--top': _vm.popupStyle.top, '--height': _vm.popupStyle.height, '--width': _vm.popupStyle.width })},_vm._l((_vm.times),function(item,index){return _c('span',{directives:[{name:"show",rawName:"v-show",value:(index % 2 == 0),expression:"index % 2 == 0"}],key:item.left,staticClass:"c-time-scalevalue-list",style:({ left: ((item.left - item.width / 2) + "px"), '--font-size': _vm.popupStyle.fontSize })},[_vm._v(" "+_vm._s(item.time)+" ")])}),0)}
|
|
4078
|
+
var TimeScaleValuevue_type_template_id_184c584a_scoped_true_staticRenderFns = []
|
|
4318
4079
|
|
|
4319
4080
|
|
|
4320
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/components/TimeScaleValue.vue?vue&type=template&id=
|
|
4081
|
+
// CONCATENATED MODULE: ./packages/fabric-chart/src/components/TimeScaleValue.vue?vue&type=template&id=184c584a&scoped=true&
|
|
4321
4082
|
|
|
4322
4083
|
// EXTERNAL MODULE: external "cnhis-design-vue/es/utils/vexutils"
|
|
4323
4084
|
var vexutils_ = __webpack_require__("9715");
|
|
@@ -4375,15 +4136,17 @@ var vexutils_default = /*#__PURE__*/__webpack_require__.n(vexutils_);
|
|
|
4375
4136
|
mounted: function mounted() {
|
|
4376
4137
|
var _this = this;
|
|
4377
4138
|
|
|
4378
|
-
this
|
|
4379
|
-
|
|
4380
|
-
_this.
|
|
4381
|
-
|
|
4382
|
-
|
|
4139
|
+
this._timer = setInterval(function () {
|
|
4140
|
+
if (document.readyState === 'complete') {
|
|
4141
|
+
_this.initDoc();
|
|
4142
|
+
|
|
4143
|
+
clearInterval(_this._timer);
|
|
4144
|
+
}
|
|
4145
|
+
}, 500);
|
|
4383
4146
|
},
|
|
4384
4147
|
methods: {
|
|
4385
|
-
|
|
4386
|
-
var _xScalevalue$style;
|
|
4148
|
+
initDoc: function initDoc() {
|
|
4149
|
+
var _this$cFabricChart, _this$cFabricChart$ge, _this$cFabricChart2, _this$cFabricChart2$g, _xScalevalue$style;
|
|
4387
4150
|
|
|
4388
4151
|
// this.to = this.templateData.top?.xScalevalue?.to || 'body';
|
|
4389
4152
|
var _ref = this.$attrs.templateData.top || {},
|
|
@@ -4395,9 +4158,9 @@ var vexutils_default = /*#__PURE__*/__webpack_require__.n(vexutils_);
|
|
|
4395
4158
|
xCellWidth = _this$propItems.xCellWidth;
|
|
4396
4159
|
this.cFabricChart = document.querySelector('.c-fabric-chart'); // this.bodyHeight = document.body.getBoundingClientRect().height;
|
|
4397
4160
|
|
|
4398
|
-
this.top = this.cFabricChart.getBoundingClientRect().top;
|
|
4161
|
+
this.top = ((_this$cFabricChart = this.cFabricChart) === null || _this$cFabricChart === void 0 ? void 0 : (_this$cFabricChart$ge = _this$cFabricChart.getBoundingClientRect()) === null || _this$cFabricChart$ge === void 0 ? void 0 : _this$cFabricChart$ge.top) || 0;
|
|
4399
4162
|
this.popupStyle = {
|
|
4400
|
-
left: "".concat(this.cFabricChart.getBoundingClientRect().left, "px"),
|
|
4163
|
+
left: "".concat(((_this$cFabricChart2 = this.cFabricChart) === null || _this$cFabricChart2 === void 0 ? void 0 : (_this$cFabricChart2$g = _this$cFabricChart2.getBoundingClientRect()) === null || _this$cFabricChart2$g === void 0 ? void 0 : _this$cFabricChart2$g.left) || 0, "px"),
|
|
4401
4164
|
top: "".concat((xScalevalue === null || xScalevalue === void 0 ? void 0 : xScalevalue.popupTop) || 0, "px"),
|
|
4402
4165
|
width: "".concat(canvasWidth, "px"),
|
|
4403
4166
|
height: "".concat(spaceHeight, "px"),
|
|
@@ -4426,13 +4189,14 @@ var vexutils_default = /*#__PURE__*/__webpack_require__.n(vexutils_);
|
|
|
4426
4189
|
}
|
|
4427
4190
|
},
|
|
4428
4191
|
beforeDestroy: function beforeDestroy() {
|
|
4192
|
+
this._timer && clearInterval(this._timer);
|
|
4429
4193
|
window.removeEventListener('scroll', this.scroll, true);
|
|
4430
4194
|
}
|
|
4431
4195
|
});
|
|
4432
4196
|
// CONCATENATED MODULE: ./packages/fabric-chart/src/components/TimeScaleValue.vue?vue&type=script&lang=js&
|
|
4433
4197
|
/* harmony default export */ var components_TimeScaleValuevue_type_script_lang_js_ = (TimeScaleValuevue_type_script_lang_js_);
|
|
4434
|
-
// EXTERNAL MODULE: ./packages/fabric-chart/src/components/TimeScaleValue.vue?vue&type=style&index=0&id=
|
|
4435
|
-
var
|
|
4198
|
+
// EXTERNAL MODULE: ./packages/fabric-chart/src/components/TimeScaleValue.vue?vue&type=style&index=0&id=184c584a&lang=less&scoped=true&
|
|
4199
|
+
var TimeScaleValuevue_type_style_index_0_id_184c584a_lang_less_scoped_true_ = __webpack_require__("0364");
|
|
4436
4200
|
|
|
4437
4201
|
// CONCATENATED MODULE: ./packages/fabric-chart/src/components/TimeScaleValue.vue
|
|
4438
4202
|
|
|
@@ -4445,11 +4209,11 @@ var TimeScaleValuevue_type_style_index_0_id_a10b6e3e_lang_less_scoped_true_ = __
|
|
|
4445
4209
|
|
|
4446
4210
|
var TimeScaleValue_component = Object(componentNormalizer["a" /* default */])(
|
|
4447
4211
|
components_TimeScaleValuevue_type_script_lang_js_,
|
|
4448
|
-
|
|
4449
|
-
|
|
4212
|
+
TimeScaleValuevue_type_template_id_184c584a_scoped_true_render,
|
|
4213
|
+
TimeScaleValuevue_type_template_id_184c584a_scoped_true_staticRenderFns,
|
|
4450
4214
|
false,
|
|
4451
4215
|
null,
|
|
4452
|
-
"
|
|
4216
|
+
"184c584a",
|
|
4453
4217
|
null
|
|
4454
4218
|
|
|
4455
4219
|
)
|
|
@@ -4495,23 +4259,16 @@ var TimeScaleValue_component = Object(componentNormalizer["a" /* default */])(
|
|
|
4495
4259
|
});
|
|
4496
4260
|
}
|
|
4497
4261
|
},
|
|
4498
|
-
mounted: function mounted() {
|
|
4499
|
-
var _this = this;
|
|
4500
|
-
|
|
4501
|
-
this.$nextTick(function () {
|
|
4502
|
-
_this.topScaleValue(_this.templateData.top);
|
|
4503
|
-
|
|
4504
|
-
_this.rightScaleValue(_this.templateData.right);
|
|
4505
|
-
|
|
4506
|
-
_this.leftScaleValue(_this.templateData.left);
|
|
4507
|
-
|
|
4508
|
-
_this.canvas.renderAll();
|
|
4509
|
-
});
|
|
4510
|
-
},
|
|
4262
|
+
mounted: function mounted() {},
|
|
4511
4263
|
methods: {
|
|
4264
|
+
init: function init() {
|
|
4265
|
+
this.topScaleValue(this.templateData.top);
|
|
4266
|
+
this.rightScaleValue(this.templateData.right);
|
|
4267
|
+
this.leftScaleValue(this.templateData.left); // this.canvas.renderAll();
|
|
4268
|
+
},
|
|
4512
4269
|
// x轴时间刻度绘制
|
|
4513
4270
|
topScaleValue: function topScaleValue(obj) {
|
|
4514
|
-
var
|
|
4271
|
+
var _this = this;
|
|
4515
4272
|
|
|
4516
4273
|
var _this$propItems = this.propItems,
|
|
4517
4274
|
originX = _this$propItems.originX,
|
|
@@ -4529,11 +4286,11 @@ var TimeScaleValue_component = Object(componentNormalizer["a" /* default */])(
|
|
|
4529
4286
|
list.reduce(function (pre, cur, i) {
|
|
4530
4287
|
var newStyle = pre && new Date(cur).getTime() - new Date(pre).getTime() < defaultSpaceTime ? Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, style), customStyle) : style;
|
|
4531
4288
|
|
|
4532
|
-
var text =
|
|
4289
|
+
var text = _this.createText(cur.slice(-5), originX + i * spaceGridNumber * xCellWidth, top, 'center', newStyle);
|
|
4533
4290
|
|
|
4534
4291
|
textList.push(text);
|
|
4535
4292
|
|
|
4536
|
-
|
|
4293
|
+
_this.timeList.push({
|
|
4537
4294
|
time: cur.slice(-5),
|
|
4538
4295
|
left: originX + i * spaceGridNumber * xCellWidth,
|
|
4539
4296
|
width: text.width
|
|
@@ -4549,7 +4306,7 @@ var TimeScaleValue_component = Object(componentNormalizer["a" /* default */])(
|
|
|
4549
4306
|
this.canvas.sendBackwards(group);
|
|
4550
4307
|
},
|
|
4551
4308
|
rightScaleValue: function rightScaleValue(obj) {
|
|
4552
|
-
var
|
|
4309
|
+
var _this2 = this;
|
|
4553
4310
|
|
|
4554
4311
|
if (!obj) return;
|
|
4555
4312
|
var spaceGridNumber = obj.rightYScalevalue.spaceGridNumber || 2;
|
|
@@ -4558,7 +4315,7 @@ var TimeScaleValue_component = Object(componentNormalizer["a" /* default */])(
|
|
|
4558
4315
|
var style = obj.rightYScalevalue.style ? obj.rightYScalevalue.style : {};
|
|
4559
4316
|
var textList = [];
|
|
4560
4317
|
obj.rightYScalevalue.list.forEach(function (item, index) {
|
|
4561
|
-
textList.push(
|
|
4318
|
+
textList.push(_this2.createText(item, originX, _this2.propItems.endY - index * _this2.propItems.yCellHeight * spaceGridNumber, 'left', style));
|
|
4562
4319
|
}); // 添加单位
|
|
4563
4320
|
|
|
4564
4321
|
if (obj.rightYScalevalue.unit) {
|
|
@@ -4575,7 +4332,7 @@ var TimeScaleValue_component = Object(componentNormalizer["a" /* default */])(
|
|
|
4575
4332
|
},
|
|
4576
4333
|
leftScaleValue: function leftScaleValue(obj) {
|
|
4577
4334
|
var _obj$leftYScalevalue,
|
|
4578
|
-
|
|
4335
|
+
_this3 = this;
|
|
4579
4336
|
|
|
4580
4337
|
var _this$propItems2 = this.propItems,
|
|
4581
4338
|
endY = _this$propItems2.endY,
|
|
@@ -4592,7 +4349,7 @@ var TimeScaleValue_component = Object(componentNormalizer["a" /* default */])(
|
|
|
4592
4349
|
var originX = this.propItems.originX;
|
|
4593
4350
|
var textList = [];
|
|
4594
4351
|
obj.leftYScalevalue.list.forEach(function (item, index) {
|
|
4595
|
-
textList.push(
|
|
4352
|
+
textList.push(_this3.createText(item, originX - listMarginRight, endY - index * yCellHeight * spaceGridNumber, 'right', style));
|
|
4596
4353
|
}); // 添加标题和单位
|
|
4597
4354
|
|
|
4598
4355
|
var txt = '';
|
|
@@ -4636,8 +4393,8 @@ var TimeScaleValue_component = Object(componentNormalizer["a" /* default */])(
|
|
|
4636
4393
|
|
|
4637
4394
|
var FabricScaleValue_component = Object(componentNormalizer["a" /* default */])(
|
|
4638
4395
|
fabric_chart_FabricScaleValuevue_type_script_lang_js_,
|
|
4639
|
-
|
|
4640
|
-
|
|
4396
|
+
FabricScaleValuevue_type_template_id_9c461680_render,
|
|
4397
|
+
FabricScaleValuevue_type_template_id_9c461680_staticRenderFns,
|
|
4641
4398
|
false,
|
|
4642
4399
|
null,
|
|
4643
4400
|
null,
|
|
@@ -4646,12 +4403,12 @@ var FabricScaleValue_component = Object(componentNormalizer["a" /* default */])(
|
|
|
4646
4403
|
)
|
|
4647
4404
|
|
|
4648
4405
|
/* harmony default export */ var FabricScaleValue = (FabricScaleValue_component.exports);
|
|
4649
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
4650
|
-
var
|
|
4651
|
-
var
|
|
4406
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"1b461ec0-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart/FabricLines.vue?vue&type=template&id=7d4d7ba0&
|
|
4407
|
+
var FabricLinesvue_type_template_id_7d4d7ba0_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"line"},[(_vm.isRightVisible)?_c('MouseRightClick',{attrs:{"getContainer":_vm.getContainer,"nodeList":_vm.rightClickNode,"rightPos":_vm.rightPos},on:{"nodeClick":_vm.handleRightClick,"closeRight":function($event){_vm.isRightVisible = false}}}):_vm._e(),(_vm.isDropVisible)?_c('DropPopup',{attrs:{"val":_vm.dropVal,"dropPos":_vm.dropPos}}):_vm._e()],1)}
|
|
4408
|
+
var FabricLinesvue_type_template_id_7d4d7ba0_staticRenderFns = []
|
|
4652
4409
|
|
|
4653
4410
|
|
|
4654
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricLines.vue?vue&type=template&id=
|
|
4411
|
+
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricLines.vue?vue&type=template&id=7d4d7ba0&
|
|
4655
4412
|
|
|
4656
4413
|
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart/FabricLines.vue?vue&type=script&lang=js&
|
|
4657
4414
|
|
|
@@ -4727,26 +4484,7 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4727
4484
|
};
|
|
4728
4485
|
}
|
|
4729
4486
|
},
|
|
4730
|
-
|
|
4731
|
-
// handler(value) {
|
|
4732
|
-
// if (value) {
|
|
4733
|
-
// if (this.lines.length) {
|
|
4734
|
-
// this.removeLines();
|
|
4735
|
-
// }
|
|
4736
|
-
// this.getLineList(this.linesObj.list);
|
|
4737
|
-
// this.createLine();
|
|
4738
|
-
// }
|
|
4739
|
-
// },
|
|
4740
|
-
// deep: true
|
|
4741
|
-
// },
|
|
4742
|
-
},
|
|
4743
|
-
mounted: function mounted() {
|
|
4744
|
-
var _this = this;
|
|
4745
|
-
|
|
4746
|
-
this.$nextTick(function () {
|
|
4747
|
-
_this.init();
|
|
4748
|
-
});
|
|
4749
|
-
},
|
|
4487
|
+
mounted: function mounted() {},
|
|
4750
4488
|
methods: {
|
|
4751
4489
|
init: function init() {
|
|
4752
4490
|
this.getLineList(this.linesObj.list);
|
|
@@ -4754,7 +4492,7 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4754
4492
|
this.eventStyle.evented && this.createEvent();
|
|
4755
4493
|
},
|
|
4756
4494
|
createEvent: function createEvent() {
|
|
4757
|
-
var
|
|
4495
|
+
var _this = this;
|
|
4758
4496
|
|
|
4759
4497
|
this.canvas.on('mouse:up', function (event) {
|
|
4760
4498
|
if (event.button === 3) {
|
|
@@ -4762,14 +4500,14 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4762
4500
|
x = _event$pointer.x,
|
|
4763
4501
|
y = _event$pointer.y;
|
|
4764
4502
|
|
|
4765
|
-
var
|
|
4766
|
-
originX =
|
|
4767
|
-
endX =
|
|
4768
|
-
endYTop =
|
|
4503
|
+
var _this$$propItems = _this.$propItems(),
|
|
4504
|
+
originX = _this$$propItems.originX,
|
|
4505
|
+
endX = _this$$propItems.endX,
|
|
4506
|
+
endYTop = _this$$propItems.endYTop;
|
|
4769
4507
|
|
|
4770
4508
|
if (!(x < originX || x > endX || y < 0 || y > endYTop)) {
|
|
4771
|
-
|
|
4772
|
-
document.querySelector('.upper-canvas').addEventListener('contextmenu',
|
|
4509
|
+
_this.activeEvent = event;
|
|
4510
|
+
document.querySelector('.upper-canvas').addEventListener('contextmenu', _this.addEventListenerContextmenu, true);
|
|
4773
4511
|
}
|
|
4774
4512
|
}
|
|
4775
4513
|
});
|
|
@@ -4783,10 +4521,10 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4783
4521
|
var x = event.offsetX;
|
|
4784
4522
|
var y = event.offsetY;
|
|
4785
4523
|
|
|
4786
|
-
var _this$$
|
|
4787
|
-
originX = _this$$
|
|
4788
|
-
endX = _this$$
|
|
4789
|
-
endYTop = _this$$
|
|
4524
|
+
var _this$$propItems2 = this.$propItems(),
|
|
4525
|
+
originX = _this$$propItems2.originX,
|
|
4526
|
+
endX = _this$$propItems2.endX,
|
|
4527
|
+
endYTop = _this$$propItems2.endYTop;
|
|
4790
4528
|
|
|
4791
4529
|
if (!(x < originX || x > endX || y < 0 || y > endYTop)) {
|
|
4792
4530
|
this.openRightModal(this.activeEvent);
|
|
@@ -4796,7 +4534,7 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4796
4534
|
},
|
|
4797
4535
|
// 打开右键菜单
|
|
4798
4536
|
openRightModal: function openRightModal(event) {
|
|
4799
|
-
var
|
|
4537
|
+
var _this2 = this;
|
|
4800
4538
|
|
|
4801
4539
|
this.rightPos = {
|
|
4802
4540
|
clientX: event.e.clientX || event.e.pageX,
|
|
@@ -4807,9 +4545,9 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4807
4545
|
var id = target ? target.id : '';
|
|
4808
4546
|
this.$nextTick(function () {
|
|
4809
4547
|
if (id && id.includes('_lineGroup_')) {
|
|
4810
|
-
|
|
4811
|
-
|
|
4812
|
-
|
|
4548
|
+
_this2._currentPoint = target || '';
|
|
4549
|
+
_this2.rightClickNode = Object.freeze(FabricLinesvue_type_script_lang_js_rightClickNode.slice());
|
|
4550
|
+
_this2.isRightVisible = true;
|
|
4813
4551
|
}
|
|
4814
4552
|
});
|
|
4815
4553
|
},
|
|
@@ -4828,29 +4566,29 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4828
4566
|
},
|
|
4829
4567
|
// 递归返回一维数据
|
|
4830
4568
|
getLineList: function getLineList(list) {
|
|
4831
|
-
var
|
|
4569
|
+
var _this3 = this;
|
|
4832
4570
|
|
|
4833
4571
|
list.forEach(function (item) {
|
|
4834
4572
|
var _item$children;
|
|
4835
4573
|
|
|
4836
4574
|
if (item !== null && item !== void 0 && (_item$children = item.children) !== null && _item$children !== void 0 && _item$children.length) {
|
|
4837
|
-
|
|
4575
|
+
_this3.getLineList(item.children);
|
|
4838
4576
|
} else {
|
|
4839
4577
|
var obj = JSON.parse(JSON.stringify(item));
|
|
4840
4578
|
|
|
4841
|
-
|
|
4579
|
+
_this3.lines.push(obj);
|
|
4842
4580
|
}
|
|
4843
4581
|
});
|
|
4844
4582
|
},
|
|
4845
4583
|
createLine: function createLine() {
|
|
4846
|
-
var
|
|
4584
|
+
var _this4 = this;
|
|
4847
4585
|
|
|
4848
4586
|
this.lines.forEach(function (line, i) {
|
|
4849
|
-
|
|
4587
|
+
_this4.drawLineData(line, i);
|
|
4850
4588
|
});
|
|
4851
4589
|
},
|
|
4852
4590
|
drawLineData: function drawLineData(line, i) {
|
|
4853
|
-
var
|
|
4591
|
+
var _this5 = this,
|
|
4854
4592
|
_this$canvas;
|
|
4855
4593
|
|
|
4856
4594
|
var lineList = line.lineList || [];
|
|
@@ -4873,9 +4611,9 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4873
4611
|
var startMinute = new Date(item[0]).getTime();
|
|
4874
4612
|
var endMinute = item[1] ? new Date(item[1]).getTime() : '';
|
|
4875
4613
|
|
|
4876
|
-
var x1 =
|
|
4614
|
+
var x1 = _this5.cumputedX(item[0]);
|
|
4877
4615
|
|
|
4878
|
-
var x2 =
|
|
4616
|
+
var x2 = _this5.cumputedX(item[1]); // 数字文字
|
|
4879
4617
|
|
|
4880
4618
|
|
|
4881
4619
|
var textObj = item[3] || {};
|
|
@@ -4884,7 +4622,7 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4884
4622
|
var leftLine;
|
|
4885
4623
|
|
|
4886
4624
|
if (x1 && x1 >= originX && x1 <= endX) {
|
|
4887
|
-
leftLine =
|
|
4625
|
+
leftLine = _this5.drawGroup(x1, x2, y1 + spaceHeight, y2 - spaceHeight, i, j, {
|
|
4888
4626
|
position: 'left'
|
|
4889
4627
|
});
|
|
4890
4628
|
lineItemList.push(leftLine);
|
|
@@ -4906,7 +4644,7 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4906
4644
|
var centerLine;
|
|
4907
4645
|
|
|
4908
4646
|
if (item[1] && !(endMinute >= maxMinute && startMinute >= maxMinute) && !(endMinute <= minMinute && startMinute <= minMinute)) {
|
|
4909
|
-
centerLine =
|
|
4647
|
+
centerLine = _this5.drawLine([x1, y1 + yCellHeightTop / 2, x2, y1 + yCellHeightTop / 2], Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, _this5.linesObj.dataLineStyle), {}, {
|
|
4910
4648
|
selectable: false,
|
|
4911
4649
|
evented: false,
|
|
4912
4650
|
id: '_lineGroup_' + new Date().getTime(),
|
|
@@ -4914,7 +4652,7 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4914
4652
|
}));
|
|
4915
4653
|
lineItemList.push(centerLine); // 添加透明矩形,便于选择横线右键删除
|
|
4916
4654
|
|
|
4917
|
-
var centerRect = new
|
|
4655
|
+
var centerRect = new _this5.fabric.Rect({
|
|
4918
4656
|
id: '_lineGroup_' + new Date().getTime(),
|
|
4919
4657
|
fill: 'transparent',
|
|
4920
4658
|
width: x2 - x1 - 20,
|
|
@@ -4931,7 +4669,7 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4931
4669
|
centerRect.lockMovementX = centerRect.lockMovementY = true;
|
|
4932
4670
|
centerRect.hasControls = centerRect.hasBorders = false;
|
|
4933
4671
|
|
|
4934
|
-
|
|
4672
|
+
_this5.hoverEvent(centerRect, {
|
|
4935
4673
|
textObj: textObj,
|
|
4936
4674
|
startTime: item[0],
|
|
4937
4675
|
endTime: item[1]
|
|
@@ -4945,7 +4683,7 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4945
4683
|
var rightLine;
|
|
4946
4684
|
|
|
4947
4685
|
if (item[1] && endMinute <= maxMinute && endMinute >= minMinute) {
|
|
4948
|
-
rightLine =
|
|
4686
|
+
rightLine = _this5.drawGroup(x1, x2, y1 + spaceHeight, y2 - spaceHeight, i, j, {
|
|
4949
4687
|
position: 'right'
|
|
4950
4688
|
});
|
|
4951
4689
|
lineItemList.push(rightLine);
|
|
@@ -4954,23 +4692,23 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4954
4692
|
|
|
4955
4693
|
var textTop = x2 ? (y1 + y2) / 2 : y1 + yCellHeightTop / 2;
|
|
4956
4694
|
var textLimitRight;
|
|
4957
|
-
var text = endMinute === '' && leftLine || item[1] && !(x1 === originX && x2 === originX) && !(x1 === endX && x2 === endX) ?
|
|
4695
|
+
var text = endMinute === '' && leftLine || item[1] && !(x1 === originX && x2 === originX) && !(x1 === endX && x2 === endX) ? _this5.drawLineText(textArr.concat([textContent]), textTop, i, j, centerLine, x1, x2) : null; // 文字内容居右侧竖线且超出当前线段右边界则移除
|
|
4958
4696
|
|
|
4959
4697
|
if (text) {
|
|
4960
4698
|
var _lineList;
|
|
4961
4699
|
|
|
4962
|
-
textLimitRight = (_lineList = lineList[j + 1]) !== null && _lineList !== void 0 && _lineList[0] &&
|
|
4700
|
+
textLimitRight = (_lineList = lineList[j + 1]) !== null && _lineList !== void 0 && _lineList[0] && _this5.cumputedX(lineList[j + 1][0]) <= endX ? _this5.cumputedX(lineList[j + 1][0]) : endX;
|
|
4963
4701
|
|
|
4964
4702
|
if (text.originX === 'left' && text.left + text.width + 2 >= textLimitRight) {
|
|
4965
4703
|
textLimitRight !== endX && textArr.push(textContent);
|
|
4966
4704
|
|
|
4967
|
-
|
|
4705
|
+
_this5.canvas.remove(text);
|
|
4968
4706
|
|
|
4969
4707
|
text = null;
|
|
4970
4708
|
} else {
|
|
4971
4709
|
textArr = [];
|
|
4972
4710
|
|
|
4973
|
-
|
|
4711
|
+
_this5.hoverEvent(text, {
|
|
4974
4712
|
textObj: textObj,
|
|
4975
4713
|
startTime: item[0],
|
|
4976
4714
|
endTime: item[1]
|
|
@@ -4992,10 +4730,10 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
4992
4730
|
|
|
4993
4731
|
if (preItem1) {
|
|
4994
4732
|
var preEndMinute = new Date(preItem1).getTime();
|
|
4995
|
-
if (preEndMinute >= minMinute && preEndMinute < maxMinute) leftLimit.x1 =
|
|
4733
|
+
if (preEndMinute >= minMinute && preEndMinute < maxMinute) leftLimit.x1 = _this5.cumputedX(preItem1);
|
|
4996
4734
|
} else {
|
|
4997
4735
|
var preStartMinute = new Date(preItem0).getTime();
|
|
4998
|
-
if (preStartMinute >= minMinute && preStartMinute < maxMinute) leftLimit.x1 =
|
|
4736
|
+
if (preStartMinute >= minMinute && preStartMinute < maxMinute) leftLimit.x1 = _this5.cumputedX(preItem0);
|
|
4999
4737
|
}
|
|
5000
4738
|
}
|
|
5001
4739
|
|
|
@@ -5010,11 +4748,11 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
5010
4748
|
if (_preItem) {
|
|
5011
4749
|
var _preStartMinute = new Date(_preItem).getTime();
|
|
5012
4750
|
|
|
5013
|
-
if (_preStartMinute > minMinute && _preStartMinute <= maxMinute) rightLimt.x2 =
|
|
4751
|
+
if (_preStartMinute > minMinute && _preStartMinute <= maxMinute) rightLimt.x2 = _this5.cumputedX(_preItem);
|
|
5014
4752
|
}
|
|
5015
4753
|
}
|
|
5016
4754
|
|
|
5017
|
-
|
|
4755
|
+
_this5.lineEvent({
|
|
5018
4756
|
line: leftLine,
|
|
5019
4757
|
line1: centerLine,
|
|
5020
4758
|
text: text,
|
|
@@ -5026,7 +4764,7 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
5026
4764
|
textLimitRight: textLimitRight
|
|
5027
4765
|
});
|
|
5028
4766
|
|
|
5029
|
-
|
|
4767
|
+
_this5.lineEvent({
|
|
5030
4768
|
line: rightLine,
|
|
5031
4769
|
line2: centerLine,
|
|
5032
4770
|
text: text,
|
|
@@ -5127,7 +4865,7 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
5127
4865
|
}));
|
|
5128
4866
|
},
|
|
5129
4867
|
hoverEvent: function hoverEvent(point, attr) {
|
|
5130
|
-
var
|
|
4868
|
+
var _this6 = this;
|
|
5131
4869
|
|
|
5132
4870
|
var textObj = attr.textObj,
|
|
5133
4871
|
startTime = attr.startTime,
|
|
@@ -5136,14 +4874,14 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
5136
4874
|
endTime && (point.endTime = endTime);
|
|
5137
4875
|
textObj && (point.textObj = textObj);
|
|
5138
4876
|
point.on('mouseover', function () {
|
|
5139
|
-
|
|
4877
|
+
_this6.showDrapPopup(point);
|
|
5140
4878
|
});
|
|
5141
4879
|
point.on('mouseout', function () {
|
|
5142
|
-
|
|
4880
|
+
_this6.isDropVisible = false;
|
|
5143
4881
|
});
|
|
5144
4882
|
},
|
|
5145
4883
|
lineEvent: function lineEvent(attr) {
|
|
5146
|
-
var
|
|
4884
|
+
var _this7 = this;
|
|
5147
4885
|
|
|
5148
4886
|
var line = attr.line,
|
|
5149
4887
|
line1 = attr.line1,
|
|
@@ -5171,27 +4909,26 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
5171
4909
|
}); // 移动中 实时更新相关联的线的坐标
|
|
5172
4910
|
|
|
5173
4911
|
line.on('moving', function () {
|
|
5174
|
-
|
|
4912
|
+
_this7.lineMoveLimit(line);
|
|
5175
4913
|
|
|
5176
|
-
|
|
4914
|
+
_this7.lineMoveUpdateLine(line);
|
|
5177
4915
|
|
|
5178
|
-
|
|
4916
|
+
_this7.textUpdatePositionX(line); // this.canvas.renderAll();
|
|
5179
4917
|
|
|
5180
|
-
_this8.canvas.renderAll();
|
|
5181
4918
|
|
|
5182
|
-
|
|
4919
|
+
_this7.showDrapPopup(line);
|
|
5183
4920
|
});
|
|
5184
4921
|
line.on('moved', function () {
|
|
5185
4922
|
// const objBoundingBox = line.getBoundingRect();
|
|
5186
4923
|
if (line && line.id.includes('_lineGroup_')) {
|
|
5187
|
-
|
|
4924
|
+
_this7.isDropVisible = false;
|
|
5188
4925
|
|
|
5189
|
-
var
|
|
5190
|
-
lineObj =
|
|
4926
|
+
var _this7$updateData = _this7.updateData(line),
|
|
4927
|
+
lineObj = _this7$updateData.lineObj;
|
|
5191
4928
|
|
|
5192
|
-
|
|
4929
|
+
_this7.updateLine(line.rowIndex);
|
|
5193
4930
|
|
|
5194
|
-
|
|
4931
|
+
_this7.$emit('lineChange', {
|
|
5195
4932
|
ponits: {
|
|
5196
4933
|
x: line.left,
|
|
5197
4934
|
y: line.top
|
|
@@ -5285,1635 +5022,130 @@ var FabricLinesvue_type_script_lang_js_rightClickNode = [{
|
|
|
5285
5022
|
linesRow.lineList[colIndex][1] = x;
|
|
5286
5023
|
}
|
|
5287
5024
|
|
|
5288
|
-
return {
|
|
5289
|
-
lineObj: {
|
|
5290
|
-
title: linesRow.title,
|
|
5291
|
-
obj: linesRow.lineList[colIndex],
|
|
5292
|
-
val: x
|
|
5293
|
-
},
|
|
5294
|
-
x: x
|
|
5295
|
-
};
|
|
5296
|
-
},
|
|
5297
|
-
// 直线数组更新后 移除旧的直线并绘制新的直线,处理拖动限制不能更新的问题
|
|
5298
|
-
updateLine: function updateLine(rowIndex) {
|
|
5299
|
-
var
|
|
5300
|
-
|
|
5301
|
-
this.canvas.forEachObject(function (obj) {
|
|
5302
|
-
if (obj.rowIndex === rowIndex) {
|
|
5303
|
-
_this9.canvas.remove(obj);
|
|
5304
|
-
}
|
|
5305
|
-
});
|
|
5306
|
-
this.drawLineData(this.lines[rowIndex], rowIndex);
|
|
5307
|
-
},
|
|
5308
|
-
// 移除头部表格所有线条数字数据
|
|
5309
|
-
removeLines: function removeLines() {
|
|
5310
|
-
var _this10 = this;
|
|
5311
|
-
|
|
5312
|
-
this.canvas.forEachObject(function (obj) {
|
|
5313
|
-
if (obj.id && obj.id.includes('_lineGroup_')) {
|
|
5314
|
-
_this10.canvas.remove(obj);
|
|
5315
|
-
}
|
|
5316
|
-
});
|
|
5317
|
-
this.lines = [];
|
|
5318
|
-
},
|
|
5319
|
-
drawLine: function drawLine(lines, others) {
|
|
5320
|
-
var line = new this.fabric.Line(lines, Object(objectSpread2["a" /* default */])({
|
|
5321
|
-
objectCaching: false
|
|
5322
|
-
}, others));
|
|
5323
|
-
return line;
|
|
5324
|
-
},
|
|
5325
|
-
lineMoveLimit: function lineMoveLimit(line) {
|
|
5326
|
-
line.setCoords(); // 需调用setCoords()才能重新计算控制位置(改变Object状态)
|
|
5327
|
-
|
|
5328
|
-
if (line.left < line.limitX.x1) {
|
|
5329
|
-
line.set('left', line.limitX.x1);
|
|
5330
|
-
}
|
|
5331
|
-
|
|
5332
|
-
if (line.left > line.limitX.x2) {
|
|
5333
|
-
line.set('left', line.limitX.x2);
|
|
5334
|
-
}
|
|
5335
|
-
},
|
|
5336
|
-
lineMoveUpdateLine: function lineMoveUpdateLine(line) {
|
|
5337
|
-
if (line.line1) {
|
|
5338
|
-
line.line1.setCoords();
|
|
5339
|
-
line.line1.set({
|
|
5340
|
-
x1: line.left
|
|
5341
|
-
});
|
|
5342
|
-
}
|
|
5343
|
-
|
|
5344
|
-
if (line.line2) {
|
|
5345
|
-
line.line2.setCoords();
|
|
5346
|
-
line.line2.set({
|
|
5347
|
-
x2: line.left
|
|
5348
|
-
});
|
|
5349
|
-
}
|
|
5350
|
-
},
|
|
5351
|
-
textUpdatePositionX: function textUpdatePositionX(line) {
|
|
5352
|
-
var text = line.text || null;
|
|
5353
|
-
|
|
5354
|
-
if (text) {
|
|
5355
|
-
// 如果line2存在说明当前拖动的是右边手柄,line1存在则是左边手柄,都不存在说明不存在中间线
|
|
5356
|
-
var centerLine = line.line1 || line.line2 || null;
|
|
5357
|
-
var left = line.left;
|
|
5358
|
-
|
|
5359
|
-
var _limitWidth = text.width + 2;
|
|
5360
|
-
|
|
5361
|
-
var originX = text.originX;
|
|
5362
|
-
var v;
|
|
5363
|
-
|
|
5364
|
-
if ((centerLine === null || centerLine === void 0 ? void 0 : centerLine.x2) - (centerLine === null || centerLine === void 0 ? void 0 : centerLine.x1) > _limitWidth) {
|
|
5365
|
-
v = left + centerLine.width / 2 * (line.line2 ? -1 : 1);
|
|
5366
|
-
originX = 'center';
|
|
5367
|
-
} else {
|
|
5368
|
-
v = this.textMarginLeft + (centerLine ? centerLine.x2 : left);
|
|
5369
|
-
originX = 'left'; // 移动到最右边界时候文字超出当前线段可拖动的右边界的情况
|
|
5370
|
-
|
|
5371
|
-
if (line.textLimitRight && v + _limitWidth > line.textLimitRight) {
|
|
5372
|
-
v = this.propItems.endX + 100; // 此值随便设置,只要达到隐藏效果即可
|
|
5373
|
-
}
|
|
5374
|
-
}
|
|
5375
|
-
|
|
5376
|
-
text.setCoords();
|
|
5377
|
-
text.set({
|
|
5378
|
-
left: v,
|
|
5379
|
-
originX: originX
|
|
5380
|
-
});
|
|
5381
|
-
} // 拖动左侧竖线时需要更改上一线段文字的位置,以防止文字被遮挡
|
|
5382
|
-
|
|
5383
|
-
|
|
5384
|
-
var preText = line.preText || null;
|
|
5385
|
-
if (!preText) return;
|
|
5386
|
-
var limitWidth = preText.width + 2;
|
|
5387
|
-
|
|
5388
|
-
if (preText.originX === 'left' && preText.left + limitWidth > line.left) {
|
|
5389
|
-
var _v = this.propItems.endX + 100; // 此值随便设置,只要达到隐藏效果即可
|
|
5390
|
-
|
|
5391
|
-
|
|
5392
|
-
preText.setCoords();
|
|
5393
|
-
preText.set({
|
|
5394
|
-
left: _v
|
|
5395
|
-
});
|
|
5396
|
-
}
|
|
5397
|
-
},
|
|
5398
|
-
repaintLine: function repaintLine() {
|
|
5399
|
-
if (this.lines.length) {
|
|
5400
|
-
this.removeLines();
|
|
5401
|
-
}
|
|
5402
|
-
|
|
5403
|
-
this.getLineList(this.linesObj.list);
|
|
5404
|
-
this.createLine();
|
|
5405
|
-
}
|
|
5406
|
-
},
|
|
5407
|
-
beforeDestroy: function beforeDestroy() {}
|
|
5408
|
-
});
|
|
5409
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricLines.vue?vue&type=script&lang=js&
|
|
5410
|
-
/* harmony default export */ var fabric_chart_FabricLinesvue_type_script_lang_js_ = (FabricLinesvue_type_script_lang_js_);
|
|
5411
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricLines.vue
|
|
5412
|
-
|
|
5413
|
-
|
|
5414
|
-
|
|
5415
|
-
|
|
5416
|
-
|
|
5417
|
-
/* normalize component */
|
|
5418
|
-
|
|
5419
|
-
var FabricLines_component = Object(componentNormalizer["a" /* default */])(
|
|
5420
|
-
fabric_chart_FabricLinesvue_type_script_lang_js_,
|
|
5421
|
-
FabricLinesvue_type_template_id_229d2d58_render,
|
|
5422
|
-
FabricLinesvue_type_template_id_229d2d58_staticRenderFns,
|
|
5423
|
-
false,
|
|
5424
|
-
null,
|
|
5425
|
-
null,
|
|
5426
|
-
null
|
|
5427
|
-
|
|
5428
|
-
)
|
|
5429
|
-
|
|
5430
|
-
/* harmony default export */ var FabricLines = (FabricLines_component.exports);
|
|
5431
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart2/FabricTop.vue?vue&type=script&lang=js&
|
|
5432
|
-
|
|
5433
|
-
|
|
5434
|
-
|
|
5435
|
-
|
|
5436
|
-
|
|
5437
|
-
|
|
5438
|
-
|
|
5439
|
-
/* harmony default export */ var FabricTopvue_type_script_lang_js_ = ({
|
|
5440
|
-
name: 'fabric-top2',
|
|
5441
|
-
mixins: [fabricCommon, draw],
|
|
5442
|
-
props: {
|
|
5443
|
-
templateData: {
|
|
5444
|
-
type: Object,
|
|
5445
|
-
required: true
|
|
5446
|
-
}
|
|
5447
|
-
},
|
|
5448
|
-
data: function data() {
|
|
5449
|
-
return {};
|
|
5450
|
-
},
|
|
5451
|
-
mounted: function mounted() {
|
|
5452
|
-
var _this = this;
|
|
5453
|
-
|
|
5454
|
-
this.$nextTick(function () {
|
|
5455
|
-
_this.init();
|
|
5456
|
-
});
|
|
5457
|
-
},
|
|
5458
|
-
computed: {
|
|
5459
|
-
girdLineStyle: function girdLineStyle() {
|
|
5460
|
-
return Object.assign({}, defaultVaule.borderStyle, this.templateData.borderStyle || {});
|
|
5461
|
-
}
|
|
5462
|
-
},
|
|
5463
|
-
methods: {
|
|
5464
|
-
init: function init() {
|
|
5465
|
-
this.drawTop(this.templateData.top);
|
|
5466
|
-
this.canvas.renderAll();
|
|
5467
|
-
},
|
|
5468
|
-
drawTop: function drawTop(top) {
|
|
5469
|
-
var list = []; // 日期
|
|
5470
|
-
|
|
5471
|
-
this.drawTopDate(top, list); // 上午/下午
|
|
5472
|
-
|
|
5473
|
-
this.drawTopDay(top, list); // 时间刻度
|
|
5474
|
-
|
|
5475
|
-
this.drawTopTime(top, list);
|
|
5476
|
-
var group = list.length > 0 ? new this.fabric.Group([].concat(list), Object(objectSpread2["a" /* default */])({}, defaultVaule.style)) : null;
|
|
5477
|
-
group && group.sendToBack(); // 向下跳底层
|
|
5478
|
-
|
|
5479
|
-
group && this.canvas.add(group);
|
|
5480
|
-
},
|
|
5481
|
-
drawTopTime: function drawTopTime(top, list) {
|
|
5482
|
-
var _top$date,
|
|
5483
|
-
_this2 = this;
|
|
5484
|
-
|
|
5485
|
-
var _this$propItems = this.propItems,
|
|
5486
|
-
originX = _this$propItems.originX,
|
|
5487
|
-
originY = _this$propItems.originY,
|
|
5488
|
-
xCellWidth = _this$propItems.xCellWidth,
|
|
5489
|
-
table = _this$propItems.table;
|
|
5490
|
-
var dateHeight = ((_top$date = top.date) === null || _top$date === void 0 ? void 0 : _top$date.height) || 0;
|
|
5491
|
-
var dayHeight = top.dayHeight || 0;
|
|
5492
|
-
var height = originY - dateHeight - dayHeight;
|
|
5493
|
-
var titleHeight = dayHeight + height; // 标题
|
|
5494
|
-
|
|
5495
|
-
var title = this.drawTextGroup(Object(objectSpread2["a" /* default */])({
|
|
5496
|
-
width: originX,
|
|
5497
|
-
height: titleHeight
|
|
5498
|
-
}, defaultVaule.rectStyle), Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({
|
|
5499
|
-
text: String(top.xScalevalue.title)
|
|
5500
|
-
}, defaultVaule.textStyle), top.textGroupStyle), {
|
|
5501
|
-
left: 0,
|
|
5502
|
-
top: dateHeight
|
|
5503
|
-
});
|
|
5504
|
-
list.push(title); // 时间列表
|
|
5505
|
-
|
|
5506
|
-
var timeList = [];
|
|
5507
|
-
|
|
5508
|
-
for (var j = 0; j < table.mainXCell; j++) {
|
|
5509
|
-
timeList.push(top.xScalevalue.list);
|
|
5510
|
-
}
|
|
5511
|
-
|
|
5512
|
-
timeList.flat().forEach(function (v, i) {
|
|
5513
|
-
var left = originX + i * xCellWidth;
|
|
5514
|
-
|
|
5515
|
-
var textGroup = _this2.drawTextGroup({
|
|
5516
|
-
width: xCellWidth,
|
|
5517
|
-
height: height
|
|
5518
|
-
}, Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({
|
|
5519
|
-
text: String(v)
|
|
5520
|
-
}, defaultVaule.textStyle), top.textGroupStyle), {
|
|
5521
|
-
left: left,
|
|
5522
|
-
top: dateHeight + dayHeight
|
|
5523
|
-
});
|
|
5524
|
-
|
|
5525
|
-
list.push(textGroup);
|
|
5526
|
-
});
|
|
5527
|
-
},
|
|
5528
|
-
drawTopDay: function drawTopDay(top, list) {
|
|
5529
|
-
if (!top.dayHeight) return false;
|
|
5530
|
-
var _this$propItems2 = this.propItems,
|
|
5531
|
-
originX = _this$propItems2.originX,
|
|
5532
|
-
xCellWidth = _this$propItems2.xCellWidth,
|
|
5533
|
-
gridXNumber = _this$propItems2.gridXNumber,
|
|
5534
|
-
table = _this$propItems2.table;
|
|
5535
|
-
var height = top.dayHeight; // 上午下午列表
|
|
5536
|
-
|
|
5537
|
-
var width = xCellWidth * table.subSecondXCell;
|
|
5538
|
-
var dayList = gridXNumber / table.subSecondXCell;
|
|
5539
|
-
|
|
5540
|
-
for (var i = 0; i < dayList; i++) {
|
|
5541
|
-
var left = originX + i * width;
|
|
5542
|
-
var value = i % 2 === 0 ? '上午' : '下午';
|
|
5543
|
-
var textGroup = this.drawTextGroup({
|
|
5544
|
-
width: width,
|
|
5545
|
-
height: height
|
|
5546
|
-
}, Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({
|
|
5547
|
-
text: String(value)
|
|
5548
|
-
}, defaultVaule.textStyle), top.textGroupStyle), {
|
|
5549
|
-
left: left,
|
|
5550
|
-
top: top.date.height || 0
|
|
5551
|
-
});
|
|
5552
|
-
list.push(textGroup);
|
|
5553
|
-
}
|
|
5554
|
-
},
|
|
5555
|
-
drawTopDate: function drawTopDate(top, list) {
|
|
5556
|
-
var _this3 = this;
|
|
5557
|
-
|
|
5558
|
-
if (!top.date.height) return false;
|
|
5559
|
-
var _this$propItems3 = this.propItems,
|
|
5560
|
-
originX = _this$propItems3.originX,
|
|
5561
|
-
xCellWidth = _this$propItems3.xCellWidth,
|
|
5562
|
-
table = _this$propItems3.table;
|
|
5563
|
-
var height = top.date.height; // 标题
|
|
5564
|
-
|
|
5565
|
-
var title = this.drawTextGroup(Object(objectSpread2["a" /* default */])({
|
|
5566
|
-
width: originX,
|
|
5567
|
-
height: height
|
|
5568
|
-
}, defaultVaule.rectStyle), Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({
|
|
5569
|
-
text: String(top.date.title)
|
|
5570
|
-
}, defaultVaule.textStyle), top.textGroupStyle), {
|
|
5571
|
-
left: 0,
|
|
5572
|
-
top: 0
|
|
5573
|
-
});
|
|
5574
|
-
list.push(title); // 日期列表
|
|
5575
|
-
|
|
5576
|
-
var width = xCellWidth * table.subXCell;
|
|
5577
|
-
top.date.list.forEach(function (v, i) {
|
|
5578
|
-
var left = originX + i * width;
|
|
5579
|
-
|
|
5580
|
-
var textGroup = _this3.drawTextGroup({
|
|
5581
|
-
width: width,
|
|
5582
|
-
height: height
|
|
5583
|
-
}, Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({
|
|
5584
|
-
text: String(v)
|
|
5585
|
-
}, defaultVaule.textStyle), top.textGroupStyle), {
|
|
5586
|
-
left: left,
|
|
5587
|
-
top: 0
|
|
5588
|
-
});
|
|
5589
|
-
|
|
5590
|
-
list.push(textGroup);
|
|
5591
|
-
});
|
|
5592
|
-
}
|
|
5593
|
-
},
|
|
5594
|
-
render: function render(h) {
|
|
5595
|
-
return this.$slots.default ? h('div', this.$slots.default) : undefined;
|
|
5596
|
-
}
|
|
5597
|
-
});
|
|
5598
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricTop.vue?vue&type=script&lang=js&
|
|
5599
|
-
/* harmony default export */ var fabric_chart2_FabricTopvue_type_script_lang_js_ = (FabricTopvue_type_script_lang_js_);
|
|
5600
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricTop.vue
|
|
5601
|
-
var FabricTop_render, FabricTop_staticRenderFns
|
|
5602
|
-
|
|
5603
|
-
|
|
5604
|
-
|
|
5605
|
-
|
|
5606
|
-
/* normalize component */
|
|
5607
|
-
|
|
5608
|
-
var FabricTop_component = Object(componentNormalizer["a" /* default */])(
|
|
5609
|
-
fabric_chart2_FabricTopvue_type_script_lang_js_,
|
|
5610
|
-
FabricTop_render,
|
|
5611
|
-
FabricTop_staticRenderFns,
|
|
5612
|
-
false,
|
|
5613
|
-
null,
|
|
5614
|
-
null,
|
|
5615
|
-
null
|
|
5616
|
-
|
|
5617
|
-
)
|
|
5618
|
-
|
|
5619
|
-
/* harmony default export */ var FabricTop = (FabricTop_component.exports);
|
|
5620
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart2/FabricLeft.vue?vue&type=script&lang=js&
|
|
5621
|
-
|
|
5622
|
-
|
|
5623
|
-
|
|
5624
|
-
|
|
5625
|
-
|
|
5626
|
-
|
|
5627
|
-
/* harmony default export */ var FabricLeftvue_type_script_lang_js_ = ({
|
|
5628
|
-
name: 'fabric-left2',
|
|
5629
|
-
mixins: [fabricCommon],
|
|
5630
|
-
props: {
|
|
5631
|
-
templateData: {
|
|
5632
|
-
type: Object,
|
|
5633
|
-
required: true
|
|
5634
|
-
}
|
|
5635
|
-
},
|
|
5636
|
-
data: function data() {
|
|
5637
|
-
return {};
|
|
5638
|
-
},
|
|
5639
|
-
computed: {
|
|
5640
|
-
defaultTextStyle: function defaultTextStyle() {
|
|
5641
|
-
return Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, defaultVaule.style), defaultVaule.textStyle), {}, {
|
|
5642
|
-
centeredRotation: true,
|
|
5643
|
-
originX: 'center',
|
|
5644
|
-
originY: 'center'
|
|
5645
|
-
});
|
|
5646
|
-
}
|
|
5647
|
-
},
|
|
5648
|
-
mounted: function mounted() {
|
|
5649
|
-
var _this = this;
|
|
5650
|
-
|
|
5651
|
-
this.$nextTick(function () {
|
|
5652
|
-
_this.init();
|
|
5653
|
-
});
|
|
5654
|
-
},
|
|
5655
|
-
methods: {
|
|
5656
|
-
init: function init() {
|
|
5657
|
-
this.leftScaleValue(this.templateData.left);
|
|
5658
|
-
this.canvas.renderAll();
|
|
5659
|
-
},
|
|
5660
|
-
leftScaleValue: function leftScaleValue(left) {
|
|
5661
|
-
var _this2 = this;
|
|
5662
|
-
|
|
5663
|
-
var groupList = [];
|
|
5664
|
-
var _this$propItems = this.propItems,
|
|
5665
|
-
originX = _this$propItems.originX,
|
|
5666
|
-
originY = _this$propItems.originY,
|
|
5667
|
-
endY = _this$propItems.endY,
|
|
5668
|
-
yCellHeight = _this$propItems.yCellHeight;
|
|
5669
|
-
var column = left.leftYScalevalue.length;
|
|
5670
|
-
var colWidth = originX / column;
|
|
5671
|
-
var residue = originX % column;
|
|
5672
|
-
var firstColWidth = colWidth + residue;
|
|
5673
|
-
left.leftYScalevalue.forEach(function (item, index) {
|
|
5674
|
-
var list = []; // 刻度外框
|
|
5675
|
-
|
|
5676
|
-
var rectWidth = index === 0 ? firstColWidth : colWidth;
|
|
5677
|
-
var rectLeft = index === 0 ? 0 : firstColWidth + (index - 1) * colWidth;
|
|
5678
|
-
var line = index > 0 ? new _this2.fabric.Line([rectLeft, originY, rectLeft, endY], Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, defaultVaule.style), defaultVaule.borderStyle)) : null;
|
|
5679
|
-
line && list.push(line);
|
|
5680
|
-
var leftVal = rectLeft + rectWidth / 2; // 刻度列表
|
|
5681
|
-
|
|
5682
|
-
item.list.forEach(function (v, i) {
|
|
5683
|
-
var top = endY - i * yCellHeight * left.spaceGridNumber;
|
|
5684
|
-
|
|
5685
|
-
var text = _this2.createText(v, leftVal, i === 0 ? top - 5 : top, 'center', item.style);
|
|
5686
|
-
|
|
5687
|
-
list.push(text);
|
|
5688
|
-
}); // 添加标题和单位
|
|
5689
|
-
|
|
5690
|
-
var title = item.name || '';
|
|
5691
|
-
if (item.unit) title += '\n' + item.unit;
|
|
5692
|
-
title && list.push(_this2.createText(title, leftVal, originY + yCellHeight * left.spaceGridNumber / 2, 'center', Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, item.style), {}, {
|
|
5693
|
-
textAlign: 'center'
|
|
5694
|
-
})));
|
|
5695
|
-
var group = new _this2.fabric.Group(list, defaultVaule.style);
|
|
5696
|
-
groupList.push(group);
|
|
5697
|
-
}); // 外框
|
|
5698
|
-
|
|
5699
|
-
groupList.push(new this.fabric.Rect(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, defaultVaule.style), defaultVaule.rectStyle), {}, {
|
|
5700
|
-
width: originX,
|
|
5701
|
-
height: endY - originY,
|
|
5702
|
-
left: 0,
|
|
5703
|
-
top: originY
|
|
5704
|
-
})));
|
|
5705
|
-
var group = groupList.length > 0 ? new this.fabric.Group([].concat(groupList), Object(objectSpread2["a" /* default */])({}, defaultVaule.style)) : null;
|
|
5706
|
-
group && group.sendToBack(); // 向下跳底层
|
|
5707
|
-
|
|
5708
|
-
group && this.canvas.add(group);
|
|
5709
|
-
},
|
|
5710
|
-
createText: function createText(text, left, top, originX, style) {
|
|
5711
|
-
return new this.fabric.Text(String(text), Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, this.defaultTextStyle), {}, {
|
|
5712
|
-
left: left,
|
|
5713
|
-
top: top,
|
|
5714
|
-
originX: originX
|
|
5715
|
-
}, style));
|
|
5716
|
-
}
|
|
5717
|
-
},
|
|
5718
|
-
render: function render(h) {
|
|
5719
|
-
return this.$slots.default ? h('div', this.$slots.default) : undefined;
|
|
5720
|
-
}
|
|
5721
|
-
});
|
|
5722
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricLeft.vue?vue&type=script&lang=js&
|
|
5723
|
-
/* harmony default export */ var fabric_chart2_FabricLeftvue_type_script_lang_js_ = (FabricLeftvue_type_script_lang_js_);
|
|
5724
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricLeft.vue
|
|
5725
|
-
var FabricLeft_render, FabricLeft_staticRenderFns
|
|
5726
|
-
|
|
5727
|
-
|
|
5728
|
-
|
|
5729
|
-
|
|
5730
|
-
/* normalize component */
|
|
5731
|
-
|
|
5732
|
-
var FabricLeft_component = Object(componentNormalizer["a" /* default */])(
|
|
5733
|
-
fabric_chart2_FabricLeftvue_type_script_lang_js_,
|
|
5734
|
-
FabricLeft_render,
|
|
5735
|
-
FabricLeft_staticRenderFns,
|
|
5736
|
-
false,
|
|
5737
|
-
null,
|
|
5738
|
-
null,
|
|
5739
|
-
null
|
|
5740
|
-
|
|
5741
|
-
)
|
|
5742
|
-
|
|
5743
|
-
/* harmony default export */ var FabricLeft = (FabricLeft_component.exports);
|
|
5744
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart2/FabricRight.vue?vue&type=script&lang=js&
|
|
5745
|
-
|
|
5746
|
-
|
|
5747
|
-
|
|
5748
|
-
|
|
5749
|
-
|
|
5750
|
-
|
|
5751
|
-
|
|
5752
|
-
|
|
5753
|
-
|
|
5754
|
-
|
|
5755
|
-
/* harmony default export */ var FabricRightvue_type_script_lang_js_ = ({
|
|
5756
|
-
name: 'fabric-right2',
|
|
5757
|
-
mixins: [fabricCommon],
|
|
5758
|
-
props: {
|
|
5759
|
-
templateData: {
|
|
5760
|
-
type: Object,
|
|
5761
|
-
required: true
|
|
5762
|
-
}
|
|
5763
|
-
},
|
|
5764
|
-
data: function data() {
|
|
5765
|
-
return {};
|
|
5766
|
-
},
|
|
5767
|
-
computed: {
|
|
5768
|
-
defaultTextStyle: function defaultTextStyle() {
|
|
5769
|
-
return Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, defaultVaule.style), defaultVaule.textStyle), {}, {
|
|
5770
|
-
centeredRotation: true,
|
|
5771
|
-
originX: 'center',
|
|
5772
|
-
originY: 'center'
|
|
5773
|
-
});
|
|
5774
|
-
}
|
|
5775
|
-
},
|
|
5776
|
-
mounted: function mounted() {
|
|
5777
|
-
var _this = this;
|
|
5778
|
-
|
|
5779
|
-
this.$nextTick(function () {
|
|
5780
|
-
_this.init();
|
|
5781
|
-
});
|
|
5782
|
-
},
|
|
5783
|
-
methods: {
|
|
5784
|
-
init: function init() {
|
|
5785
|
-
this.rightScaleValue(this.templateData.right || null);
|
|
5786
|
-
this.canvas.renderAll();
|
|
5787
|
-
},
|
|
5788
|
-
rightScaleValue: function rightScaleValue(right) {
|
|
5789
|
-
var _this2 = this;
|
|
5790
|
-
|
|
5791
|
-
var _this$propItems = this.propItems,
|
|
5792
|
-
endX = _this$propItems.endX,
|
|
5793
|
-
endY = _this$propItems.endY,
|
|
5794
|
-
centigradeYCell = _this$propItems.centigradeYCell,
|
|
5795
|
-
canvasWidth = _this$propItems.canvasWidth,
|
|
5796
|
-
canvasHeight = _this$propItems.canvasHeight;
|
|
5797
|
-
|
|
5798
|
-
if (!right) {
|
|
5799
|
-
this.canvas.add(new this.fabric.Line([canvasWidth - 1, 0, canvasWidth - 1, canvasHeight], defaultVaule.borderStyle));
|
|
5800
|
-
return false;
|
|
5801
|
-
}
|
|
5802
|
-
|
|
5803
|
-
var list = []; // 华氏度外框
|
|
5804
|
-
|
|
5805
|
-
list.push(new this.fabric.Rect(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, defaultVaule.style), defaultVaule.rectStyle), {}, {
|
|
5806
|
-
width: canvasWidth - endX - 1,
|
|
5807
|
-
height: canvasHeight - 1,
|
|
5808
|
-
left: endX,
|
|
5809
|
-
top: 0
|
|
5810
|
-
}))); // 华氏度列表,目前是整数列表(33℃对应91℉,所以存在误差),如果是正对应的如33℃对应91.4℉则不需要计算difVal和spaceHVaule和spaceHVaule0
|
|
5811
|
-
|
|
5812
|
-
var difVal = 6;
|
|
5813
|
-
var spaceScaleNumber = right.rightYScalevalue.spaceScaleNumber || 5;
|
|
5814
|
-
var mainScaleWidth = 9;
|
|
5815
|
-
var subScaleWidth = 5;
|
|
5816
|
-
var cList = this.templateData.left.leftYScalevalue.find(function (v) {
|
|
5817
|
-
return v.type === 'centigrade';
|
|
5818
|
-
}).list; // 左侧摄氏度温度list
|
|
5819
|
-
|
|
5820
|
-
var minC = Math.min.apply(Math, Object(toConsumableArray["a" /* default */])(cList)); // 左侧温度刻度最小值
|
|
5821
|
-
|
|
5822
|
-
var h1 = right.rightYScalevalue.list[1];
|
|
5823
|
-
var h0 = right.rightYScalevalue.list[0];
|
|
5824
|
-
var c1 = 5 * (h1 - 32) / 9;
|
|
5825
|
-
var c0 = 5 * (h0 - 32) / 9;
|
|
5826
|
-
var top1 = endY - (c1 - minC) * centigradeYCell - difVal;
|
|
5827
|
-
var top0 = endY - (c0 - minC) * centigradeYCell - difVal;
|
|
5828
|
-
var spaceHVaule = (top0 - top1) / spaceScaleNumber; // 每华氏度之间的间隔高度值
|
|
5829
|
-
|
|
5830
|
-
var endTop; // 记录最上一个刻度数的高度值,用于计算单位的高度
|
|
5831
|
-
|
|
5832
|
-
right.rightYScalevalue.list.forEach(function (v, i) {
|
|
5833
|
-
var c = 5 * (v - 32) / 9; // 华氏转换为摄氏,此为固定公式
|
|
5834
|
-
|
|
5835
|
-
var top = endY - (c - minC) * centigradeYCell - difVal; // 存在6px的误差,因为比如34℃=93.2华氏度而不是93华氏度
|
|
5836
|
-
|
|
5837
|
-
if (i === right.rightYScalevalue.list.length - 1) endTop = top;
|
|
5838
|
-
|
|
5839
|
-
var text = _this2.createText("".concat(v, "\xB0"), endX + mainScaleWidth, i === 0 ? endY - 5 : top, 'left', right.rightYScalevalue.style);
|
|
5840
|
-
|
|
5841
|
-
list.push(text); // 刻度横线
|
|
5842
|
-
|
|
5843
|
-
var spaceHVaule0 = (endY - top1) / spaceScaleNumber; // 第一个-每华氏度之间的间隔高度值
|
|
5844
|
-
|
|
5845
|
-
for (var k = 0; k < spaceScaleNumber; k++) {
|
|
5846
|
-
var scaleTop = i === 0 ? endY - k * spaceHVaule0 : top - k * spaceHVaule;
|
|
5847
|
-
var line = new _this2.fabric.Line([endX, scaleTop, k > 0 ? endX + subScaleWidth : endX + mainScaleWidth, scaleTop], Object(objectSpread2["a" /* default */])({}, defaultVaule.borderStyle));
|
|
5848
|
-
list.push(line);
|
|
5849
|
-
}
|
|
5850
|
-
}); // 单位
|
|
5851
|
-
|
|
5852
|
-
var width = canvasWidth - endX;
|
|
5853
|
-
var unit = right.rightYScalevalue.unit ? this.createText(right.rightYScalevalue.unit.split('').join('\n'), endX + width / 2, endTop / 2, 'center', right.rightYScalevalue.style) : null;
|
|
5854
|
-
unit && list.push(unit);
|
|
5855
|
-
var group = list.length > 0 ? new this.fabric.Group([].concat(list), Object(objectSpread2["a" /* default */])({}, defaultVaule.style)) : null;
|
|
5856
|
-
group && group.sendToBack(); // 向下跳底层
|
|
5857
|
-
|
|
5858
|
-
group && this.canvas.add(group);
|
|
5859
|
-
},
|
|
5860
|
-
createText: function createText(text, left, top, originX, style) {
|
|
5861
|
-
return new this.fabric.Text(String(text), Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, this.defaultTextStyle), {}, {
|
|
5862
|
-
left: left,
|
|
5863
|
-
top: top,
|
|
5864
|
-
originX: originX
|
|
5865
|
-
}, style));
|
|
5866
|
-
}
|
|
5867
|
-
},
|
|
5868
|
-
render: function render(h) {
|
|
5869
|
-
return this.$slots.default ? h('div', this.$slots.default) : undefined;
|
|
5870
|
-
}
|
|
5871
|
-
});
|
|
5872
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricRight.vue?vue&type=script&lang=js&
|
|
5873
|
-
/* harmony default export */ var fabric_chart2_FabricRightvue_type_script_lang_js_ = (FabricRightvue_type_script_lang_js_);
|
|
5874
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricRight.vue
|
|
5875
|
-
var FabricRight_render, FabricRight_staticRenderFns
|
|
5876
|
-
|
|
5877
|
-
|
|
5878
|
-
|
|
5879
|
-
|
|
5880
|
-
/* normalize component */
|
|
5881
|
-
|
|
5882
|
-
var FabricRight_component = Object(componentNormalizer["a" /* default */])(
|
|
5883
|
-
fabric_chart2_FabricRightvue_type_script_lang_js_,
|
|
5884
|
-
FabricRight_render,
|
|
5885
|
-
FabricRight_staticRenderFns,
|
|
5886
|
-
false,
|
|
5887
|
-
null,
|
|
5888
|
-
null,
|
|
5889
|
-
null
|
|
5890
|
-
|
|
5891
|
-
)
|
|
5892
|
-
|
|
5893
|
-
/* harmony default export */ var FabricRight = (FabricRight_component.exports);
|
|
5894
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart2/FabricBottom.vue?vue&type=script&lang=js&
|
|
5895
|
-
|
|
5896
|
-
|
|
5897
|
-
|
|
5898
|
-
|
|
5899
|
-
|
|
5900
|
-
|
|
5901
|
-
|
|
5902
|
-
/* harmony default export */ var FabricBottomvue_type_script_lang_js_ = ({
|
|
5903
|
-
name: 'fabric-bottom2',
|
|
5904
|
-
mixins: [fabricCommon, draw],
|
|
5905
|
-
props: {
|
|
5906
|
-
templateData: {
|
|
5907
|
-
type: Object,
|
|
5908
|
-
required: true
|
|
5909
|
-
}
|
|
5910
|
-
},
|
|
5911
|
-
data: function data() {
|
|
5912
|
-
return {};
|
|
5913
|
-
},
|
|
5914
|
-
mounted: function mounted() {
|
|
5915
|
-
var _this = this;
|
|
5916
|
-
|
|
5917
|
-
this.$nextTick(function () {
|
|
5918
|
-
_this.init();
|
|
5919
|
-
});
|
|
5920
|
-
},
|
|
5921
|
-
computed: {
|
|
5922
|
-
girdLineStyle: function girdLineStyle() {
|
|
5923
|
-
return Object.assign({}, defaultVaule.borderStyle, this.templateData.borderStyle || {});
|
|
5924
|
-
}
|
|
5925
|
-
},
|
|
5926
|
-
methods: {
|
|
5927
|
-
init: function init() {
|
|
5928
|
-
this.drawBottom(this.templateData.bottom || null);
|
|
5929
|
-
this.canvas.renderAll();
|
|
5930
|
-
},
|
|
5931
|
-
drawBottom: function drawBottom(bottom) {
|
|
5932
|
-
var _this2 = this;
|
|
5933
|
-
|
|
5934
|
-
var _this$propItems = this.propItems,
|
|
5935
|
-
xScaleList = _this$propItems.xScaleList,
|
|
5936
|
-
xScaleCell = _this$propItems.xScaleCell,
|
|
5937
|
-
originX = _this$propItems.originX,
|
|
5938
|
-
endX = _this$propItems.endX,
|
|
5939
|
-
endY = _this$propItems.endY,
|
|
5940
|
-
xCellWidth = _this$propItems.xCellWidth,
|
|
5941
|
-
canvasHeight = _this$propItems.canvasHeight;
|
|
5942
|
-
|
|
5943
|
-
if (!bottom) {
|
|
5944
|
-
this.canvas.add(new this.fabric.Line([0, canvasHeight - 1, endX, canvasHeight - 1], defaultVaule.borderStyle));
|
|
5945
|
-
return false;
|
|
5946
|
-
}
|
|
5947
|
-
|
|
5948
|
-
var height = canvasHeight - endY;
|
|
5949
|
-
var list = [];
|
|
5950
|
-
var flag = true; // 定义呼吸数值显示为靠上还是靠下
|
|
5951
|
-
// 数据列表
|
|
5952
|
-
|
|
5953
|
-
xScaleList.forEach(function (item, index) {
|
|
5954
|
-
var left = originX + index * xCellWidth;
|
|
5955
|
-
var text = '';
|
|
5956
|
-
bottom.list.forEach(function (v, i) {
|
|
5957
|
-
var time = new Date(v.time).getTime();
|
|
5958
|
-
if (time >= item && time < item + xScaleCell) text = v.value;
|
|
5959
|
-
});
|
|
5960
|
-
var style = flag ? {
|
|
5961
|
-
top: -(height / 2 - 10)
|
|
5962
|
-
} : {
|
|
5963
|
-
top: height / 2 - 10
|
|
5964
|
-
};
|
|
5965
|
-
if (text) flag = !flag;
|
|
5966
|
-
|
|
5967
|
-
var group = _this2.drawTextGroup(Object(objectSpread2["a" /* default */])({
|
|
5968
|
-
width: xCellWidth,
|
|
5969
|
-
height: height
|
|
5970
|
-
}, defaultVaule.rectStyle), Object.assign({}, Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({
|
|
5971
|
-
text: String(text)
|
|
5972
|
-
}, defaultVaule.textStyle), top.textGroupStyle), text ? style : {}), {
|
|
5973
|
-
left: left,
|
|
5974
|
-
top: endY
|
|
5975
|
-
});
|
|
5976
|
-
|
|
5977
|
-
list.push(group);
|
|
5978
|
-
}); // 底部外框和标题名称
|
|
5979
|
-
|
|
5980
|
-
var titleGroup = this.drawTextGroup(Object(objectSpread2["a" /* default */])({
|
|
5981
|
-
width: endX,
|
|
5982
|
-
height: height - 1
|
|
5983
|
-
}, defaultVaule.rectStyle), Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({
|
|
5984
|
-
text: String(bottom.name + bottom.unit)
|
|
5985
|
-
}, defaultVaule.textStyle), top.textGroupStyle), {}, {
|
|
5986
|
-
left: -((endX - originX) / 2)
|
|
5987
|
-
}), {
|
|
5988
|
-
left: 0,
|
|
5989
|
-
top: endY
|
|
5990
|
-
});
|
|
5991
|
-
list.push(titleGroup);
|
|
5992
|
-
var group = list.length > 0 ? new this.fabric.Group([].concat(list), Object(objectSpread2["a" /* default */])({}, defaultVaule.style)) : null;
|
|
5993
|
-
group && group.sendToBack(); // 向下跳底层
|
|
5994
|
-
|
|
5995
|
-
group && this.canvas.add(group);
|
|
5996
|
-
}
|
|
5997
|
-
},
|
|
5998
|
-
render: function render(h) {
|
|
5999
|
-
return this.$slots.default ? h('div', this.$slots.default) : undefined;
|
|
6000
|
-
}
|
|
6001
|
-
});
|
|
6002
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricBottom.vue?vue&type=script&lang=js&
|
|
6003
|
-
/* harmony default export */ var fabric_chart2_FabricBottomvue_type_script_lang_js_ = (FabricBottomvue_type_script_lang_js_);
|
|
6004
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricBottom.vue
|
|
6005
|
-
var FabricBottom_render, FabricBottom_staticRenderFns
|
|
6006
|
-
|
|
6007
|
-
|
|
6008
|
-
|
|
6009
|
-
|
|
6010
|
-
/* normalize component */
|
|
6011
|
-
|
|
6012
|
-
var FabricBottom_component = Object(componentNormalizer["a" /* default */])(
|
|
6013
|
-
fabric_chart2_FabricBottomvue_type_script_lang_js_,
|
|
6014
|
-
FabricBottom_render,
|
|
6015
|
-
FabricBottom_staticRenderFns,
|
|
6016
|
-
false,
|
|
6017
|
-
null,
|
|
6018
|
-
null,
|
|
6019
|
-
null
|
|
6020
|
-
|
|
6021
|
-
)
|
|
6022
|
-
|
|
6023
|
-
/* harmony default export */ var FabricBottom = (FabricBottom_component.exports);
|
|
6024
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"54b2b90d-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart2/FabricCenter.vue?vue&type=template&id=4d90e644&
|
|
6025
|
-
var FabricCentervue_type_template_id_4d90e644_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"poly-line"},[(_vm.isRightVisible)?_c('MouseRightClick',{attrs:{"getContainer":_vm.getContainer,"nodeList":_vm.rightClickNode,"rightPos":_vm.rightPos},on:{"nodeClick":_vm.handleRightClick,"closeRight":function($event){_vm.isRightVisible = false}}}):_vm._e(),(_vm.isDropVisible)?_c('DropPopup',{attrs:{"val":_vm.dropVal,"dropPos":_vm.dropPos}}):_vm._e()],1)}
|
|
6026
|
-
var FabricCentervue_type_template_id_4d90e644_staticRenderFns = []
|
|
6027
|
-
|
|
6028
|
-
|
|
6029
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart2/FabricCenter.vue?vue&type=template&id=4d90e644&
|
|
6030
|
-
|
|
6031
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/fabric-chart2/FabricCenter.vue?vue&type=script&lang=js&
|
|
6032
|
-
|
|
6033
|
-
|
|
6034
|
-
|
|
6035
|
-
|
|
6036
|
-
|
|
6037
|
-
|
|
6038
|
-
|
|
6039
|
-
|
|
6040
|
-
|
|
6041
|
-
|
|
6042
|
-
|
|
6043
|
-
|
|
6044
|
-
|
|
6045
|
-
|
|
6046
|
-
|
|
6047
|
-
|
|
6048
|
-
|
|
6049
|
-
|
|
6050
|
-
|
|
6051
|
-
|
|
6052
|
-
|
|
6053
|
-
//
|
|
6054
|
-
//
|
|
6055
|
-
//
|
|
6056
|
-
//
|
|
6057
|
-
//
|
|
6058
|
-
//
|
|
6059
|
-
//
|
|
6060
|
-
|
|
6061
|
-
|
|
6062
|
-
|
|
6063
|
-
|
|
6064
|
-
|
|
6065
|
-
|
|
6066
|
-
var FabricCentervue_type_script_lang_js_rightClickNode = [{
|
|
6067
|
-
name: '新增节点',
|
|
6068
|
-
type: 'add'
|
|
6069
|
-
}, {
|
|
6070
|
-
name: '删除节点',
|
|
6071
|
-
type: 'delete'
|
|
6072
|
-
}];
|
|
6073
|
-
/* harmony default export */ var FabricCentervue_type_script_lang_js_ = ({
|
|
6074
|
-
name: 'fabric-center2',
|
|
6075
|
-
mixins: [fabricCommon, draw, eventCommon],
|
|
6076
|
-
props: {
|
|
6077
|
-
other: {
|
|
6078
|
-
type: Object,
|
|
6079
|
-
default: function _default() {}
|
|
6080
|
-
},
|
|
6081
|
-
polyline: {
|
|
6082
|
-
type: Array,
|
|
6083
|
-
required: true
|
|
6084
|
-
}
|
|
6085
|
-
},
|
|
6086
|
-
components: {
|
|
6087
|
-
MouseRightClick: MouseRightClick,
|
|
6088
|
-
DropPopup: DropPopup
|
|
6089
|
-
},
|
|
6090
|
-
data: function data() {
|
|
6091
|
-
return {
|
|
6092
|
-
polylineList: [],
|
|
6093
|
-
isDropVisible: false,
|
|
6094
|
-
dropVal: {},
|
|
6095
|
-
dropPos: {
|
|
6096
|
-
clientX: 0,
|
|
6097
|
-
clientY: 0
|
|
6098
|
-
},
|
|
6099
|
-
isRightVisible: false,
|
|
6100
|
-
rightPos: {
|
|
6101
|
-
clientX: 0,
|
|
6102
|
-
clientY: 0
|
|
6103
|
-
},
|
|
6104
|
-
rightClickNode: [],
|
|
6105
|
-
activeEvent: null // 当前可右键活动的对象
|
|
6106
|
-
|
|
6107
|
-
};
|
|
6108
|
-
},
|
|
6109
|
-
watch: {
|
|
6110
|
-
polyline: {
|
|
6111
|
-
handler: function handler(value) {
|
|
6112
|
-
if (value) {
|
|
6113
|
-
this.repaintPolyline();
|
|
6114
|
-
}
|
|
6115
|
-
},
|
|
6116
|
-
deep: true
|
|
6117
|
-
},
|
|
6118
|
-
polylineList: function polylineList(value) {
|
|
6119
|
-
var _this = this;
|
|
6120
|
-
|
|
6121
|
-
if (value) {
|
|
6122
|
-
this.polylineList.forEach(function (polylineType, index) {
|
|
6123
|
-
_this.createPolyline(polylineType, polylineType.type);
|
|
6124
|
-
});
|
|
6125
|
-
}
|
|
6126
|
-
}
|
|
6127
|
-
},
|
|
6128
|
-
created: function created() {},
|
|
6129
|
-
mounted: function mounted() {
|
|
6130
|
-
var _this2 = this;
|
|
6131
|
-
|
|
6132
|
-
this.$nextTick(function () {
|
|
6133
|
-
_this2.init();
|
|
6134
|
-
});
|
|
6135
|
-
},
|
|
6136
|
-
computed: {
|
|
6137
|
-
eventStyle: function eventStyle() {
|
|
6138
|
-
return this.propItems.eventStyle;
|
|
6139
|
-
}
|
|
6140
|
-
},
|
|
6141
|
-
methods: {
|
|
6142
|
-
init: function init() {
|
|
6143
|
-
this.drawOther(this.other);
|
|
6144
|
-
this.eventStyle.evented && this.createEvent();
|
|
6145
|
-
this.polylineList = JSON.parse(JSON.stringify(this.polyline));
|
|
6146
|
-
},
|
|
6147
|
-
getContainer: function getContainer() {
|
|
6148
|
-
return this.$el;
|
|
6149
|
-
},
|
|
6150
|
-
createEvent: function createEvent() {
|
|
6151
|
-
var _this3 = this;
|
|
6152
|
-
|
|
6153
|
-
this.canvas.on('mouse:up', function (event) {
|
|
6154
|
-
if (event.button === 3) {
|
|
6155
|
-
var _event$pointer = event.pointer,
|
|
6156
|
-
x = _event$pointer.x,
|
|
6157
|
-
y = _event$pointer.y;
|
|
6158
|
-
|
|
6159
|
-
var _this3$$propItems = _this3.$propItems(),
|
|
6160
|
-
originX = _this3$$propItems.originX,
|
|
6161
|
-
originY = _this3$$propItems.originY,
|
|
6162
|
-
endX = _this3$$propItems.endX,
|
|
6163
|
-
endY = _this3$$propItems.endY;
|
|
6164
|
-
|
|
6165
|
-
if (!(x < originX || x > endX || y < originY || y > endY)) {
|
|
6166
|
-
_this3.activeEvent = event;
|
|
6167
|
-
document.querySelector('.upper-canvas').addEventListener('contextmenu', _this3.addEventListenerContextmenu, true);
|
|
6168
|
-
}
|
|
6169
|
-
}
|
|
6170
|
-
});
|
|
6171
|
-
},
|
|
6172
|
-
createPolyline: function createPolyline(polylineType, type) {
|
|
6173
|
-
var _this4 = this;
|
|
6174
|
-
|
|
6175
|
-
polylineType.dataList.forEach(function (item, index) {
|
|
6176
|
-
_this4.drawPolyline(item, index, polylineType, type);
|
|
6177
|
-
});
|
|
6178
|
-
var data = this.getShadowData(polylineType, type);
|
|
6179
|
-
(data === null || data === void 0 ? void 0 : data.length) && this.drawShadow(data, polylineType.shadowStyle);
|
|
6180
|
-
},
|
|
6181
|
-
// 画出阴影线段
|
|
6182
|
-
drawShadow: function drawShadow(data, shadowStyle) {
|
|
6183
|
-
var _this5 = this,
|
|
6184
|
-
_this$canvas;
|
|
6185
|
-
|
|
6186
|
-
var canvasHeight = this.propItems.canvasHeight;
|
|
6187
|
-
var lines = [];
|
|
6188
|
-
data.forEach(function (v) {
|
|
6189
|
-
var line1 = _this5.computeShadow(v.line1, shadowStyle.moveMode);
|
|
6190
|
-
|
|
6191
|
-
var line2 = _this5.computeShadow(v.line2, shadowStyle.moveMode);
|
|
6192
|
-
|
|
6193
|
-
var maxLine = line1.length >= line2.length ? line1 : line2;
|
|
6194
|
-
var minLine = line1.length < line2.length ? line1 : line2; // 如果存在两个数组长度不相等,则节点多的数组多余节点的阴影线段只存在节点多的线段组上,而没有与长度小的线段组相交
|
|
6195
|
-
|
|
6196
|
-
var i = 0;
|
|
6197
|
-
maxLine.forEach(function (k, j) {
|
|
6198
|
-
if (minLine[j]) {
|
|
6199
|
-
var line = _this5.drawLine([k.x, canvasHeight - k.y, minLine[j].x, canvasHeight - minLine[j].y], Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, defaultVaule.style), shadowStyle));
|
|
6200
|
-
|
|
6201
|
-
lines.push(line);
|
|
6202
|
-
} else {
|
|
6203
|
-
if (i % 2 === 0 && maxLine[j + 1]) {
|
|
6204
|
-
var _line = _this5.drawLine([k.x, canvasHeight - k.y, maxLine[j + 1].x, canvasHeight - maxLine[j + 1].y], Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, defaultVaule.style), shadowStyle));
|
|
6205
|
-
|
|
6206
|
-
lines.push(_line);
|
|
6207
|
-
}
|
|
6208
|
-
|
|
6209
|
-
i++;
|
|
6210
|
-
}
|
|
6211
|
-
});
|
|
6212
|
-
});
|
|
6213
|
-
|
|
6214
|
-
(_this$canvas = this.canvas).add.apply(_this$canvas, lines);
|
|
6215
|
-
|
|
6216
|
-
this.canvas.renderAll();
|
|
6217
|
-
},
|
|
6218
|
-
|
|
6219
|
-
/**
|
|
6220
|
-
* @description: 计算阴影线段坐标数组
|
|
6221
|
-
* @param {*} lineGroup
|
|
6222
|
-
* @param {*} moveMode
|
|
6223
|
-
* @return {*}
|
|
6224
|
-
*/
|
|
6225
|
-
computeShadow: function computeShadow(lineGroup, moveMode) {
|
|
6226
|
-
var canvasWidth = this.propItems.canvasWidth; // 结果坐标集合
|
|
6227
|
-
|
|
6228
|
-
var resultArr = [];
|
|
6229
|
-
if (lineGroup.length < 2) return;
|
|
6230
|
-
var beginPoint = lineGroup[0];
|
|
6231
|
-
var endPoint = lineGroup[lineGroup.length - 1];
|
|
6232
|
-
var b = beginPoint.y + beginPoint.x; // y = b - x;(斜率k的值为-1)
|
|
6233
|
-
// const count = Math.round((endPoint.x - beginPoint.x) / moveMode);
|
|
6234
|
-
|
|
6235
|
-
var count = Math.round(canvasWidth / moveMode);
|
|
6236
|
-
|
|
6237
|
-
for (var i = 0; i < count; i++) {
|
|
6238
|
-
for (var j = 0; j < lineGroup.length; j++) {
|
|
6239
|
-
if (lineGroup[j + 1]) {
|
|
6240
|
-
var point1 = lineGroup[j];
|
|
6241
|
-
var point2 = lineGroup[j + 1];
|
|
6242
|
-
var point11 = {
|
|
6243
|
-
x: 0,
|
|
6244
|
-
y: b + moveMode * i
|
|
6245
|
-
};
|
|
6246
|
-
var point22 = {
|
|
6247
|
-
x: endPoint.x,
|
|
6248
|
-
y: b + moveMode * i - endPoint.x
|
|
6249
|
-
};
|
|
6250
|
-
var intersectPoint = this.getIntersectPoint(point1, point2, point11, point22);
|
|
6251
|
-
intersectPoint && resultArr.push(intersectPoint);
|
|
6252
|
-
}
|
|
6253
|
-
}
|
|
6254
|
-
}
|
|
6255
|
-
|
|
6256
|
-
return resultArr;
|
|
6257
|
-
},
|
|
6258
|
-
// 获取两个线段相交的点的坐标,ab一个线段,cd一个线段
|
|
6259
|
-
getIntersectPoint: function getIntersectPoint(a, b, c, d) {
|
|
6260
|
-
// 三角形abc 面积的2倍
|
|
6261
|
-
var area_abc = (a.x - c.x) * (b.y - c.y) - (a.y - c.y) * (b.x - c.x); // 三角形abd 面积的2倍
|
|
6262
|
-
|
|
6263
|
-
var area_abd = (a.x - d.x) * (b.y - d.y) - (a.y - d.y) * (b.x - d.x); // 面积符号相同则两点在线段同侧,不相交 (对点在线段上的情况,本例当作不相交处理);
|
|
6264
|
-
|
|
6265
|
-
if (area_abc * area_abd >= 0) {
|
|
6266
|
-
return false;
|
|
6267
|
-
} // 三角形cda 面积的2倍
|
|
6268
|
-
|
|
6269
|
-
|
|
6270
|
-
var area_cda = (c.x - a.x) * (d.y - a.y) - (c.y - a.y) * (d.x - a.x); // 三角形cdb 面积的2倍
|
|
6271
|
-
// 注意: 这里有一个小优化.不需要再用公式计算面积,而是通过已知的三个面积加减得出.
|
|
6272
|
-
|
|
6273
|
-
var area_cdb = area_cda + area_abc - area_abd;
|
|
6274
|
-
|
|
6275
|
-
if (area_cda * area_cdb >= 0) {
|
|
6276
|
-
return false;
|
|
6277
|
-
} // 计算交点坐标
|
|
6278
|
-
|
|
6279
|
-
|
|
6280
|
-
var t = area_cda / (area_abd - area_abc);
|
|
6281
|
-
var dx = t * (b.x - a.x),
|
|
6282
|
-
dy = t * (b.y - a.y);
|
|
6283
|
-
return {
|
|
6284
|
-
x: a.x + dx,
|
|
6285
|
-
y: a.y + dy
|
|
6286
|
-
};
|
|
6287
|
-
},
|
|
6288
|
-
|
|
6289
|
-
/**
|
|
6290
|
-
* @description: 获取阴影部分所有点的数组
|
|
6291
|
-
* @param {*} polylineType 折线数据,leftYScalevalue
|
|
6292
|
-
* @param {*} type 类型,呼吸还是心率等
|
|
6293
|
-
* @return {*} 返回一个数组,数组中每一个对象{line1, line2}即表示一块阴影,eg: [{line1, line2}, {line1, line2}]
|
|
6294
|
-
*/
|
|
6295
|
-
getShadowData: function getShadowData(polylineType, type) {
|
|
6296
|
-
var _this6 = this;
|
|
6297
|
-
|
|
6298
|
-
// 说明,次方法待完善,存在阴影部分上下线段的节点个数不同的情况和时间不等值也不等的节点的情况(拖动节点后就会出现了。)
|
|
6299
|
-
var dataList = polylineType.dataList;
|
|
6300
|
-
var canvasHeight = this.propItems.canvasHeight;
|
|
6301
|
-
var data = [];
|
|
6302
|
-
|
|
6303
|
-
if (type === 'pulse' && dataList.length > 1) {
|
|
6304
|
-
dataList.forEach(function (v, i) {
|
|
6305
|
-
if (i === 0) {
|
|
6306
|
-
var line1 = [];
|
|
6307
|
-
var line2 = [];
|
|
6308
|
-
var list = v.list.flat();
|
|
6309
|
-
var list2 = dataList[1].list.flat();
|
|
6310
|
-
list.forEach(function (k, j) {
|
|
6311
|
-
if (k.time === list2[j].time && k.value !== list2[j].value) {
|
|
6312
|
-
line1.push({
|
|
6313
|
-
x: _this6.cumputedX(k.time),
|
|
6314
|
-
y: canvasHeight - _this6.cumputedY(polylineType, k.value, type)
|
|
6315
|
-
});
|
|
6316
|
-
line2.push({
|
|
6317
|
-
x: _this6.cumputedX(k.time),
|
|
6318
|
-
y: canvasHeight - _this6.cumputedY(polylineType, list2[j].value, type)
|
|
6319
|
-
});
|
|
6320
|
-
|
|
6321
|
-
if (list[j - 1] && line1.length === 1) {
|
|
6322
|
-
var obj = {
|
|
6323
|
-
x: _this6.cumputedX(list[j - 1].time),
|
|
6324
|
-
y: canvasHeight - _this6.cumputedY(polylineType, list[j - 1].value, type)
|
|
6325
|
-
};
|
|
6326
|
-
line1.unshift(obj);
|
|
6327
|
-
line2.unshift(obj);
|
|
6328
|
-
}
|
|
6329
|
-
|
|
6330
|
-
if (list[j + 1] && list[j + 1].time === list2[j + 1].time && list[j + 1].value === list2[j + 1].value) {
|
|
6331
|
-
var _obj = {
|
|
6332
|
-
x: _this6.cumputedX(list[j + 1].time),
|
|
6333
|
-
y: canvasHeight - _this6.cumputedY(polylineType, list[j + 1].value, type)
|
|
6334
|
-
};
|
|
6335
|
-
line1.push(_obj);
|
|
6336
|
-
line2.push(_obj);
|
|
6337
|
-
}
|
|
6338
|
-
} else {
|
|
6339
|
-
line1.length && line2.length && data.push({
|
|
6340
|
-
line1: line1,
|
|
6341
|
-
line2: line2
|
|
6342
|
-
});
|
|
6343
|
-
line1 = [];
|
|
6344
|
-
line2 = [];
|
|
6345
|
-
}
|
|
6346
|
-
});
|
|
6347
|
-
}
|
|
6348
|
-
});
|
|
6349
|
-
}
|
|
6350
|
-
|
|
6351
|
-
return data;
|
|
6352
|
-
},
|
|
6353
|
-
drawPolyline: function drawPolyline(polyline, polylineIndex, polylineType, type) {
|
|
6354
|
-
var _this7 = this;
|
|
6355
|
-
|
|
6356
|
-
var pointAttr = polyline.pointAttr;
|
|
6357
|
-
this._iconClassName = polyline.type === 'img' && pointAttr.iconClassName ? pointAttr.iconClassName : '';
|
|
6358
|
-
var list = polyline.list;
|
|
6359
|
-
var pointList = [];
|
|
6360
|
-
var lineList = [];
|
|
6361
|
-
var otherList = [];
|
|
6362
|
-
var otherAsyncList = [];
|
|
6363
|
-
var _this$propItems = this.propItems,
|
|
6364
|
-
xScaleList = _this$propItems.xScaleList,
|
|
6365
|
-
yCellHeight = _this$propItems.yCellHeight;
|
|
6366
|
-
var minTime = Math.min.apply(Math, Object(toConsumableArray["a" /* default */])(xScaleList));
|
|
6367
|
-
var maxTime = Math.max.apply(Math, Object(toConsumableArray["a" /* default */])(xScaleList));
|
|
6368
|
-
list.forEach(function (v, i) {
|
|
6369
|
-
// 当前点
|
|
6370
|
-
var points = null;
|
|
6371
|
-
|
|
6372
|
-
if (v.time && v.value) {
|
|
6373
|
-
var x = _this7.cumputedX(v.time);
|
|
6374
|
-
|
|
6375
|
-
var y = _this7.cumputedY(polylineType, v.value, type);
|
|
6376
|
-
|
|
6377
|
-
var time = new Date(v.time).getTime();
|
|
6378
|
-
if (time >= minTime && time <= maxTime) points = [x, y];
|
|
6379
|
-
} // 下一个点
|
|
6380
|
-
|
|
6381
|
-
|
|
6382
|
-
var nextPoints = list[i + 1];
|
|
6383
|
-
var nextPoint = null;
|
|
6384
|
-
|
|
6385
|
-
if (nextPoints !== null && nextPoints !== void 0 && nextPoints.time && nextPoints !== null && nextPoints !== void 0 && nextPoints.value) {
|
|
6386
|
-
var nextX = _this7.cumputedX(nextPoints.time);
|
|
6387
|
-
|
|
6388
|
-
var nextY = _this7.cumputedY(polylineType, nextPoints.value, type);
|
|
6389
|
-
|
|
6390
|
-
var nextTime = new Date(nextPoints.time).getTime();
|
|
6391
|
-
if (nextTime > minTime && nextTime <= maxTime) nextPoint = [nextX, nextY];
|
|
6392
|
-
}
|
|
6393
|
-
|
|
6394
|
-
var pointOthers = Object(objectSpread2["a" /* default */])({
|
|
6395
|
-
type: type,
|
|
6396
|
-
polylineIndex: polylineIndex,
|
|
6397
|
-
pointIndex: i
|
|
6398
|
-
}, pointAttr); // 其他标志
|
|
6399
|
-
|
|
6400
|
-
|
|
6401
|
-
var coolLine, coolPoint, noRiseText, arrowGroup, verifiedText;
|
|
6402
|
-
|
|
6403
|
-
if (points && type === 'centigrade') {
|
|
6404
|
-
// 体温不升
|
|
6405
|
-
if (v.noRise) {
|
|
6406
|
-
var noRiseStyle = polyline.noRiseStyle; // 文字形式
|
|
6407
|
-
|
|
6408
|
-
if (v.noRise.text) {
|
|
6409
|
-
noRiseText = _this7.drawText(v.noRise.text.split('').join('\n'), points[0], points[1] + 5, Object(objectSpread2["a" /* default */])({
|
|
6410
|
-
polylineIndex: polylineIndex,
|
|
6411
|
-
pointIndex: i,
|
|
6412
|
-
originX: 'center'
|
|
6413
|
-
}, noRiseStyle));
|
|
6414
|
-
otherList.push(noRiseText);
|
|
6415
|
-
} else {
|
|
6416
|
-
// 下箭头形式
|
|
6417
|
-
var top = points[1] + yCellHeight * 2;
|
|
6418
|
-
|
|
6419
|
-
var arrowLine = _this7.drawLine([].concat(Object(toConsumableArray["a" /* default */])(points), [points[0], top]), Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({
|
|
6420
|
-
polylineIndex: polylineIndex,
|
|
6421
|
-
lineIndex: i
|
|
6422
|
-
}, polyline.lineAttr), {}, {
|
|
6423
|
-
stroke: noRiseStyle.fill
|
|
6424
|
-
}));
|
|
6425
|
-
|
|
6426
|
-
var arrow = _this7.drawText('v', points[0] + 0.5, top + 3, Object(objectSpread2["a" /* default */])({
|
|
6427
|
-
polylineIndex: polylineIndex,
|
|
6428
|
-
pointIndex: i,
|
|
6429
|
-
originX: 'center',
|
|
6430
|
-
originY: 'bottom',
|
|
6431
|
-
fontSize: 16
|
|
6432
|
-
}, noRiseStyle)); // 加0.5会虚,不加箭头没有完全对称,top值同理
|
|
6433
|
-
|
|
6434
|
-
|
|
6435
|
-
arrowGroup = new _this7.fabric.Group([arrowLine, arrow], Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, defaultVaule.style), {}, {
|
|
6436
|
-
originX: 'center',
|
|
6437
|
-
originY: 'top'
|
|
6438
|
-
}));
|
|
6439
|
-
otherList.push(arrowGroup);
|
|
6440
|
-
}
|
|
6441
|
-
} // 体温已核实
|
|
6442
|
-
|
|
6443
|
-
|
|
6444
|
-
if (v.verified) {
|
|
6445
|
-
var verifiedStyle = polyline.verifiedStyle;
|
|
6446
|
-
verifiedText = _this7.drawText('v', points[0], points[1] - 5, Object(objectSpread2["a" /* default */])({
|
|
6447
|
-
polylineIndex: polylineIndex,
|
|
6448
|
-
pointIndex: i,
|
|
6449
|
-
originX: 'center',
|
|
6450
|
-
originY: 'bottom'
|
|
6451
|
-
}, verifiedStyle));
|
|
6452
|
-
otherList.push(verifiedText);
|
|
6453
|
-
} // 物理降温
|
|
6454
|
-
|
|
6455
|
-
|
|
6456
|
-
if (v.cooling) {
|
|
6457
|
-
var coolingStyle = polyline.coolingStyle;
|
|
6458
|
-
|
|
6459
|
-
var coolingLineStyle = Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({}, polyline.lineAttr), {}, {
|
|
6460
|
-
stroke: coolingStyle.stroke,
|
|
6461
|
-
strokeDashArray: [3, 3]
|
|
6462
|
-
});
|
|
6463
|
-
|
|
6464
|
-
var coolY = _this7.cumputedY(polylineType, v.cooling, type);
|
|
6465
|
-
|
|
6466
|
-
coolLine = _this7.drawLine([].concat(Object(toConsumableArray["a" /* default */])(points), [points[0], coolY]), Object(objectSpread2["a" /* default */])({
|
|
6467
|
-
polylineIndex: polylineIndex,
|
|
6468
|
-
lineIndex: i
|
|
6469
|
-
}, coolingLineStyle));
|
|
6470
|
-
var otherObj = Object.assign({}, pointOthers, coolingStyle, {
|
|
6471
|
-
isCooling: true
|
|
6472
|
-
});
|
|
6473
|
-
var lineObj = {
|
|
6474
|
-
line1: coolLine,
|
|
6475
|
-
line2: null,
|
|
6476
|
-
line3: null,
|
|
6477
|
-
noRiseText: noRiseText,
|
|
6478
|
-
arrowGroup: arrowGroup,
|
|
6479
|
-
verifiedText: verifiedText
|
|
6480
|
-
};
|
|
6481
|
-
coolPoint = _this7.drawPoint(points[0], coolY, lineObj, 'circle', otherObj);
|
|
6482
|
-
otherList.push(coolLine);
|
|
6483
|
-
otherAsyncList.push(coolPoint);
|
|
6484
|
-
}
|
|
6485
|
-
}
|
|
6486
|
-
|
|
6487
|
-
var line;
|
|
6488
|
-
var point;
|
|
6489
|
-
var previousLine;
|
|
6490
|
-
line = points && nextPoint ? _this7.drawLine([].concat(Object(toConsumableArray["a" /* default */])(points), Object(toConsumableArray["a" /* default */])(nextPoint)), Object(objectSpread2["a" /* default */])({
|
|
6491
|
-
polylineIndex: polylineIndex,
|
|
6492
|
-
lineIndex: i
|
|
6493
|
-
}, polyline.lineAttr)) : null;
|
|
6494
|
-
previousLine = lineList[i - 1];
|
|
6495
|
-
|
|
6496
|
-
if (previousLine) {
|
|
6497
|
-
var _lineObj = {
|
|
6498
|
-
line1: previousLine,
|
|
6499
|
-
line2: line,
|
|
6500
|
-
line3: coolLine,
|
|
6501
|
-
noRiseText: noRiseText,
|
|
6502
|
-
arrowGroup: arrowGroup,
|
|
6503
|
-
verifiedText: verifiedText
|
|
6504
|
-
};
|
|
6505
|
-
point = points && _this7.drawPoint(previousLine.get('x2'), previousLine.get('y2'), _lineObj, polyline.type, pointOthers);
|
|
6506
|
-
} else {
|
|
6507
|
-
if (points) {
|
|
6508
|
-
var _lineObj2 = {
|
|
6509
|
-
line1: null,
|
|
6510
|
-
line2: line,
|
|
6511
|
-
line3: coolLine,
|
|
6512
|
-
noRiseText: noRiseText,
|
|
6513
|
-
arrowGroup: arrowGroup,
|
|
6514
|
-
verifiedText: verifiedText
|
|
6515
|
-
};
|
|
6516
|
-
point = _this7.drawPoint.apply(_this7, Object(toConsumableArray["a" /* default */])(points).concat([_lineObj2, polyline.type, pointOthers]));
|
|
6517
|
-
}
|
|
6518
|
-
}
|
|
6519
|
-
|
|
6520
|
-
lineList.push(line);
|
|
6521
|
-
point && pointList.push(point);
|
|
6522
|
-
});
|
|
6523
|
-
Promise.all(pointList).then(function (res) {
|
|
6524
|
-
lineList = lineList.filter(function (v) {
|
|
6525
|
-
return v;
|
|
6526
|
-
});
|
|
6527
|
-
var prevPoint = null;
|
|
6528
|
-
res = res.filter(function (v) {
|
|
6529
|
-
if (v && prevPoint) {
|
|
6530
|
-
prevPoint.nextPoint = v; // 记录下一个点 id
|
|
6531
|
-
|
|
6532
|
-
v.prevPoint = prevPoint;
|
|
6533
|
-
}
|
|
6534
|
-
|
|
6535
|
-
prevPoint = v || prevPoint;
|
|
6536
|
-
return v;
|
|
6537
|
-
});
|
|
6538
|
-
Promise.all(otherAsyncList).then(function (r) {
|
|
6539
|
-
var _this7$canvas;
|
|
6540
|
-
|
|
6541
|
-
(_this7$canvas = _this7.canvas).add.apply(_this7$canvas, Object(toConsumableArray["a" /* default */])(lineList).concat(Object(toConsumableArray["a" /* default */])(res), otherList, Object(toConsumableArray["a" /* default */])(r)));
|
|
6542
|
-
|
|
6543
|
-
_this7.canvas.requestRenderAll();
|
|
6544
|
-
});
|
|
6545
|
-
});
|
|
6546
|
-
},
|
|
6547
|
-
|
|
6548
|
-
/**
|
|
6549
|
-
* 绘制折线点
|
|
6550
|
-
* @param {left, top} 折线点坐标
|
|
6551
|
-
* @param {lineObj} 与折线点关联的对象
|
|
6552
|
-
* @param {type} 折线点类型
|
|
6553
|
-
* @param {others} 参数 polylineIndex | pointIndex | ...polyline.pointAttr
|
|
6554
|
-
*/
|
|
6555
|
-
drawPoint: function drawPoint(left, top, lineObj, type, others) {
|
|
6556
|
-
var _this8 = this;
|
|
6557
|
-
|
|
6558
|
-
return Object(asyncToGenerator["a" /* default */])( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
|
|
6559
|
-
var pointId, ele, point;
|
|
6560
|
-
return regeneratorRuntime.wrap(function _callee$(_context) {
|
|
6561
|
-
while (1) {
|
|
6562
|
-
switch (_context.prev = _context.next) {
|
|
6563
|
-
case 0:
|
|
6564
|
-
pointId = "".concat(others.type, "_").concat(others.polylineIndex, "_").concat(others.pointIndex, "_polylinePoint_").concat(new Date().getTime());
|
|
6565
|
-
_context.t0 = _this8._iconClassName;
|
|
6566
|
-
|
|
6567
|
-
if (!_context.t0) {
|
|
6568
|
-
_context.next = 6;
|
|
6569
|
-
break;
|
|
6570
|
-
}
|
|
6571
|
-
|
|
6572
|
-
_context.next = 5;
|
|
6573
|
-
return _this8.createImage(_this8._iconClassName, others);
|
|
6574
|
-
|
|
6575
|
-
case 5:
|
|
6576
|
-
_context.t0 = _context.sent;
|
|
6577
|
-
|
|
6578
|
-
case 6:
|
|
6579
|
-
ele = _context.t0;
|
|
6580
|
-
_context.next = 9;
|
|
6581
|
-
return _this8.createPoint(type, Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({
|
|
6582
|
-
id: pointId,
|
|
6583
|
-
left: left,
|
|
6584
|
-
top: top,
|
|
6585
|
-
ele: ele || ''
|
|
6586
|
-
}, defaultVaule.pointStyle), others), _this8.propItems.eventStyle));
|
|
6587
|
-
|
|
6588
|
-
case 9:
|
|
6589
|
-
point = _context.sent;
|
|
6590
|
-
point.hasControls = point.hasBorders = false;
|
|
6591
|
-
lineObj.line1 && (point.line1 = lineObj.line1);
|
|
6592
|
-
lineObj.line2 && (point.line2 = lineObj.line2);
|
|
6593
|
-
lineObj.line3 && (point.line3 = lineObj.line3);
|
|
6594
|
-
lineObj.noRiseText && (point.noRiseText = lineObj.noRiseText);
|
|
6595
|
-
lineObj.arrowGroup && (point.arrowGroup = lineObj.arrowGroup);
|
|
6596
|
-
lineObj.verifiedText && (point.verifiedText = lineObj.verifiedText);
|
|
6597
|
-
point.on('mouseover', function () {
|
|
6598
|
-
_this8.showDrapPopup(point);
|
|
6599
|
-
});
|
|
6600
|
-
point.on('mouseout', function () {
|
|
6601
|
-
_this8.isDropVisible = false;
|
|
6602
|
-
}); // 折线点移动中 实时更新相关联的线的坐标
|
|
6603
|
-
|
|
6604
|
-
point.on('moving', function () {
|
|
6605
|
-
_this8.pointMoveLimit(point);
|
|
6606
|
-
|
|
6607
|
-
_this8.pointMoveUpdateLine(point);
|
|
6608
|
-
|
|
6609
|
-
_this8.canvas.renderAll();
|
|
6610
|
-
|
|
6611
|
-
_this8.showDrapPopup(point);
|
|
6612
|
-
}); // 折线点停止拖拽后 更新polylineList中对应的坐标
|
|
6613
|
-
|
|
6614
|
-
point.on('moved', function () {
|
|
6615
|
-
if (point && point.id.includes('_polylinePoint_')) {
|
|
6616
|
-
_this8.isDropVisible = false;
|
|
6617
|
-
|
|
6618
|
-
var data = _this8.getValue(point);
|
|
6619
|
-
|
|
6620
|
-
_this8.$emit('pointChange', data);
|
|
6621
|
-
}
|
|
6622
|
-
});
|
|
6623
|
-
return _context.abrupt("return", point);
|
|
6624
|
-
|
|
6625
|
-
case 22:
|
|
6626
|
-
case "end":
|
|
6627
|
-
return _context.stop();
|
|
6628
|
-
}
|
|
6629
|
-
}
|
|
6630
|
-
}, _callee);
|
|
6631
|
-
}))();
|
|
6632
|
-
},
|
|
6633
|
-
showDrapPopup: function showDrapPopup(point) {
|
|
6634
|
-
this.isDropVisible = true;
|
|
6635
|
-
this.dropPos = {
|
|
6636
|
-
left: point.left,
|
|
6637
|
-
top: point.top
|
|
6638
|
-
};
|
|
6639
|
-
|
|
6640
|
-
var _this$getValue = this.getValue(point),
|
|
6641
|
-
value = _this$getValue.value,
|
|
6642
|
-
title = _this$getValue.title;
|
|
6643
|
-
|
|
6644
|
-
this.dropVal = {
|
|
6645
|
-
title: title,
|
|
6646
|
-
list: [{
|
|
6647
|
-
id: '11',
|
|
6648
|
-
name: '时间',
|
|
6649
|
-
value: value.time
|
|
6650
|
-
}, {
|
|
6651
|
-
id: '22',
|
|
6652
|
-
name: '值',
|
|
6653
|
-
value: Math.round(value.value)
|
|
6654
|
-
}]
|
|
6655
|
-
};
|
|
6656
|
-
},
|
|
6657
|
-
// 折线点移动时 setCoords()方法手动更新相关联的线坐标
|
|
6658
|
-
pointMoveUpdateLine: function pointMoveUpdateLine(point) {
|
|
6659
|
-
if (point.line1) {
|
|
6660
|
-
point.line1.setCoords();
|
|
6661
|
-
point.line1.set({
|
|
6662
|
-
x2: point.left,
|
|
6663
|
-
y2: point.top
|
|
6664
|
-
});
|
|
6665
|
-
}
|
|
6666
|
-
|
|
6667
|
-
if (point.line2) {
|
|
6668
|
-
point.line2.setCoords();
|
|
6669
|
-
point.line2.set({
|
|
6670
|
-
x1: point.left,
|
|
6671
|
-
y1: point.top
|
|
6672
|
-
});
|
|
6673
|
-
}
|
|
6674
|
-
|
|
6675
|
-
if (point.line3) {
|
|
6676
|
-
point.line3.setCoords();
|
|
6677
|
-
point.line3.set({
|
|
6678
|
-
x1: point.left,
|
|
6679
|
-
y1: point.top
|
|
6680
|
-
});
|
|
6681
|
-
}
|
|
6682
|
-
|
|
6683
|
-
if (point.noRiseText) {
|
|
6684
|
-
point.noRiseText.setCoords();
|
|
6685
|
-
point.noRiseText.set({
|
|
6686
|
-
left: point.left,
|
|
6687
|
-
top: point.top + 5
|
|
6688
|
-
});
|
|
6689
|
-
}
|
|
5025
|
+
return {
|
|
5026
|
+
lineObj: {
|
|
5027
|
+
title: linesRow.title,
|
|
5028
|
+
obj: linesRow.lineList[colIndex],
|
|
5029
|
+
val: x
|
|
5030
|
+
},
|
|
5031
|
+
x: x
|
|
5032
|
+
};
|
|
5033
|
+
},
|
|
5034
|
+
// 直线数组更新后 移除旧的直线并绘制新的直线,处理拖动限制不能更新的问题
|
|
5035
|
+
updateLine: function updateLine(rowIndex) {
|
|
5036
|
+
var _this8 = this;
|
|
6690
5037
|
|
|
6691
|
-
|
|
6692
|
-
|
|
6693
|
-
|
|
6694
|
-
|
|
6695
|
-
|
|
6696
|
-
|
|
6697
|
-
|
|
5038
|
+
this.canvas.forEachObject(function (obj) {
|
|
5039
|
+
if (obj.rowIndex === rowIndex) {
|
|
5040
|
+
_this8.canvas.remove(obj);
|
|
5041
|
+
}
|
|
5042
|
+
});
|
|
5043
|
+
this.drawLineData(this.lines[rowIndex], rowIndex);
|
|
5044
|
+
},
|
|
5045
|
+
// 移除头部表格所有线条数字数据
|
|
5046
|
+
removeLines: function removeLines() {
|
|
5047
|
+
var _this9 = this;
|
|
6698
5048
|
|
|
6699
|
-
|
|
6700
|
-
|
|
6701
|
-
|
|
6702
|
-
|
|
6703
|
-
|
|
6704
|
-
|
|
6705
|
-
}
|
|
5049
|
+
this.canvas.forEachObject(function (obj) {
|
|
5050
|
+
if (obj.id && obj.id.includes('_lineGroup_')) {
|
|
5051
|
+
_this9.canvas.remove(obj);
|
|
5052
|
+
}
|
|
5053
|
+
});
|
|
5054
|
+
this.lines = [];
|
|
6706
5055
|
},
|
|
6707
5056
|
drawLine: function drawLine(lines, others) {
|
|
6708
|
-
var lineId = "".concat(others.polylineIndex, "_").concat(others.pointIndex, "_polylineLine_").concat(new Date().getTime());
|
|
6709
5057
|
var line = new this.fabric.Line(lines, Object(objectSpread2["a" /* default */])({
|
|
6710
|
-
|
|
6711
|
-
hoverCursor: 'pointer',
|
|
6712
|
-
objectCaching: false,
|
|
6713
|
-
selectable: false,
|
|
6714
|
-
evented: false
|
|
5058
|
+
objectCaching: false
|
|
6715
5059
|
}, others));
|
|
6716
5060
|
return line;
|
|
6717
5061
|
},
|
|
6718
|
-
|
|
6719
|
-
|
|
6720
|
-
var text = new this.fabric.Text(String(value), Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])(Object(objectSpread2["a" /* default */])({
|
|
6721
|
-
id: id,
|
|
6722
|
-
originX: others.originX || 'left',
|
|
6723
|
-
originY: others.originY || 'top',
|
|
6724
|
-
left: left,
|
|
6725
|
-
top: top
|
|
6726
|
-
}, defaultVaule.style), defaultVaule.textStyle), others));
|
|
6727
|
-
return text;
|
|
6728
|
-
},
|
|
6729
|
-
cumputedX: function cumputedX(value) {
|
|
6730
|
-
var _this$propItems2 = this.propItems,
|
|
6731
|
-
xScaleList = _this$propItems2.xScaleList,
|
|
6732
|
-
xScaleCell = _this$propItems2.xScaleCell,
|
|
6733
|
-
originX = _this$propItems2.originX,
|
|
6734
|
-
xCellWidth = _this$propItems2.xCellWidth;
|
|
6735
|
-
var time = new Date(value).getTime();
|
|
6736
|
-
var minScale = Math.min.apply(Math, Object(toConsumableArray["a" /* default */])(xScaleList));
|
|
6737
|
-
var i = Math.floor((time - minScale) / xScaleCell);
|
|
6738
|
-
return originX + xCellWidth * i + xCellWidth / 2;
|
|
6739
|
-
},
|
|
6740
|
-
cumputedY: function cumputedY(polylineType, value, type) {
|
|
6741
|
-
var yScaleCell = this.propItems["".concat(type, "YCell")];
|
|
6742
|
-
var yCellUnit = value - Math.min.apply(Math, Object(toConsumableArray["a" /* default */])(polylineType.list));
|
|
6743
|
-
return this.propItems.endY - yScaleCell * yCellUnit;
|
|
6744
|
-
},
|
|
6745
|
-
getXValue: function getXValue(left) {
|
|
6746
|
-
var _this$propItems3 = this.propItems,
|
|
6747
|
-
xScaleList = _this$propItems3.xScaleList,
|
|
6748
|
-
xScaleCell = _this$propItems3.xScaleCell,
|
|
6749
|
-
xCellWidth = _this$propItems3.xCellWidth,
|
|
6750
|
-
originX = _this$propItems3.originX;
|
|
6751
|
-
var minScale = Math.min.apply(Math, Object(toConsumableArray["a" /* default */])(xScaleList));
|
|
6752
|
-
var time = minScale + (left - originX) / xCellWidth * xScaleCell;
|
|
6753
|
-
var d = new Date(time);
|
|
6754
|
-
var month = "00".concat(d.getMonth() + 1).slice(-2);
|
|
6755
|
-
var day = "00".concat(d.getDate()).slice(-2);
|
|
6756
|
-
var date = "".concat(d.getFullYear(), "-").concat(month, "-").concat(day, " ").concat(d.getHours(), ":00");
|
|
6757
|
-
return date;
|
|
6758
|
-
},
|
|
6759
|
-
getYValue: function getYValue(type, top) {
|
|
6760
|
-
var _this$polyline$find;
|
|
5062
|
+
lineMoveLimit: function lineMoveLimit(line) {
|
|
5063
|
+
line.setCoords(); // 需调用setCoords()才能重新计算控制位置(改变Object状态)
|
|
6761
5064
|
|
|
6762
|
-
|
|
6763
|
-
|
|
6764
|
-
|
|
6765
|
-
})) === null || _this$polyline$find === void 0 ? void 0 : _this$polyline$find.list) || [];
|
|
6766
|
-
var minVal = list.length ? Math.min.apply(Math, Object(toConsumableArray["a" /* default */])(list)) : 0;
|
|
6767
|
-
var y = (this.propItems.endY - top) / yScaleCell + minVal;
|
|
6768
|
-
return y;
|
|
6769
|
-
},
|
|
6770
|
-
getValue: function getValue(point) {
|
|
6771
|
-
var _this9 = this;
|
|
5065
|
+
if (line.left < line.limitX.x1) {
|
|
5066
|
+
line.set('left', line.limitX.x1);
|
|
5067
|
+
}
|
|
6772
5068
|
|
|
6773
|
-
if (
|
|
6774
|
-
|
|
6775
|
-
|
|
6776
|
-
|
|
6777
|
-
|
|
6778
|
-
|
|
6779
|
-
|
|
6780
|
-
|
|
6781
|
-
|
|
6782
|
-
return v.type === type;
|
|
5069
|
+
if (line.left > line.limitX.x2) {
|
|
5070
|
+
line.set('left', line.limitX.x2);
|
|
5071
|
+
}
|
|
5072
|
+
},
|
|
5073
|
+
lineMoveUpdateLine: function lineMoveUpdateLine(line) {
|
|
5074
|
+
if (line.line1) {
|
|
5075
|
+
line.line1.setCoords();
|
|
5076
|
+
line.line1.set({
|
|
5077
|
+
x1: line.left
|
|
6783
5078
|
});
|
|
6784
|
-
|
|
5079
|
+
}
|
|
6785
5080
|
|
|
6786
|
-
|
|
6787
|
-
|
|
6788
|
-
|
|
6789
|
-
|
|
6790
|
-
obj.value.time = this.getXValue(left);
|
|
6791
|
-
obj.value.value = this.getYValue(type, top);
|
|
6792
|
-
return Object(objectSpread2["a" /* default */])({
|
|
6793
|
-
title: title,
|
|
6794
|
-
type: type,
|
|
6795
|
-
dataIndex: polylineIndex,
|
|
6796
|
-
pointIndex: pointIndex
|
|
6797
|
-
}, obj);
|
|
6798
|
-
} else {
|
|
6799
|
-
var x = this.getXValue(point.left);
|
|
6800
|
-
var valueList = this.polylineList.map(function (v) {
|
|
6801
|
-
return {
|
|
6802
|
-
type: v.type,
|
|
6803
|
-
value: _this9.getYValue(v.type, point.top)
|
|
6804
|
-
};
|
|
5081
|
+
if (line.line2) {
|
|
5082
|
+
line.line2.setCoords();
|
|
5083
|
+
line.line2.set({
|
|
5084
|
+
x2: line.left
|
|
6805
5085
|
});
|
|
6806
|
-
return {
|
|
6807
|
-
x: x,
|
|
6808
|
-
valueList: valueList
|
|
6809
|
-
};
|
|
6810
5086
|
}
|
|
6811
5087
|
},
|
|
6812
|
-
|
|
6813
|
-
var
|
|
6814
|
-
|
|
6815
|
-
var originY = this.propItems.originY;
|
|
6816
|
-
if (!other || !other.list) return false;
|
|
6817
|
-
var list = []; // 数据列表
|
|
5088
|
+
textUpdatePositionX: function textUpdatePositionX(line) {
|
|
5089
|
+
var text = line.text || null;
|
|
6818
5090
|
|
|
6819
|
-
|
|
6820
|
-
|
|
6821
|
-
|
|
6822
|
-
|
|
6823
|
-
top: originY,
|
|
6824
|
-
left: _this10.cumputedX(v[0]),
|
|
6825
|
-
textAlign: 'center'
|
|
6826
|
-
}, defaultVaule.style), arr.style));
|
|
6827
|
-
list.push(text);
|
|
6828
|
-
});
|
|
6829
|
-
});
|
|
6830
|
-
var group = list.length > 0 ? new this.fabric.Group([].concat(list), Object(objectSpread2["a" /* default */])({}, defaultVaule.style)) : null;
|
|
6831
|
-
group && group.sendToBack(); // 向下跳底层
|
|
5091
|
+
if (text) {
|
|
5092
|
+
// 如果line2存在说明当前拖动的是右边手柄,line1存在则是左边手柄,都不存在说明不存在中间线
|
|
5093
|
+
var centerLine = line.line1 || line.line2 || null;
|
|
5094
|
+
var left = line.left;
|
|
6832
5095
|
|
|
6833
|
-
|
|
6834
|
-
this.canvas.renderAll();
|
|
6835
|
-
},
|
|
6836
|
-
// 关闭右键菜单,打开添加节点弹窗表单
|
|
6837
|
-
handleRightClick: function handleRightClick(_ref) {
|
|
6838
|
-
var type = _ref.type;
|
|
6839
|
-
this.isRightVisible = false;
|
|
6840
|
-
var point = this._currentPoint;
|
|
6841
|
-
this._currentPoint = '';
|
|
6842
|
-
var _this$_active = this._active,
|
|
6843
|
-
left = _this$_active.left,
|
|
6844
|
-
top = _this$_active.top;
|
|
6845
|
-
var data = point ? this.getValue(point) : this.getValue({
|
|
6846
|
-
left: left,
|
|
6847
|
-
top: top
|
|
6848
|
-
});
|
|
6849
|
-
this.$emit('pointOperation', type, data);
|
|
6850
|
-
},
|
|
6851
|
-
// 打开右键菜单
|
|
6852
|
-
openRightModal: function openRightModal(event) {
|
|
6853
|
-
var _this11 = this;
|
|
5096
|
+
var _limitWidth = text.width + 2;
|
|
6854
5097
|
|
|
6855
|
-
|
|
6856
|
-
|
|
6857
|
-
}
|
|
5098
|
+
var originX = text.originX;
|
|
5099
|
+
var v;
|
|
6858
5100
|
|
|
6859
|
-
|
|
6860
|
-
|
|
6861
|
-
|
|
6862
|
-
};
|
|
6863
|
-
this.isRightVisible = false;
|
|
6864
|
-
var target = event.target;
|
|
6865
|
-
var id = target ? target.id : '';
|
|
6866
|
-
var nextId = target ? target.nextId : '';
|
|
6867
|
-
this.$nextTick(function () {
|
|
6868
|
-
if (id && id.includes('_polylinePoint_')) {
|
|
6869
|
-
_this11._currentPoint = target;
|
|
6870
|
-
_this11.rightClickNode = Object.freeze(FabricCentervue_type_script_lang_js_rightClickNode.slice());
|
|
5101
|
+
if ((centerLine === null || centerLine === void 0 ? void 0 : centerLine.x2) - (centerLine === null || centerLine === void 0 ? void 0 : centerLine.x1) > _limitWidth) {
|
|
5102
|
+
v = left + centerLine.width / 2 * (line.line2 ? -1 : 1);
|
|
5103
|
+
originX = 'center';
|
|
6871
5104
|
} else {
|
|
6872
|
-
|
|
6873
|
-
|
|
6874
|
-
}
|
|
5105
|
+
v = this.textMarginLeft + (centerLine ? centerLine.x2 : left);
|
|
5106
|
+
originX = 'left'; // 移动到最右边界时候文字超出当前线段可拖动的右边界的情况
|
|
6875
5107
|
|
|
6876
|
-
|
|
6877
|
-
|
|
6878
|
-
|
|
6879
|
-
|
|
6880
|
-
var _this12 = this;
|
|
5108
|
+
if (line.textLimitRight && v + _limitWidth > line.textLimitRight) {
|
|
5109
|
+
v = this.propItems.endX + 100; // 此值随便设置,只要达到隐藏效果即可
|
|
5110
|
+
}
|
|
5111
|
+
}
|
|
6881
5112
|
|
|
6882
|
-
|
|
6883
|
-
|
|
6884
|
-
|
|
5113
|
+
text.setCoords();
|
|
5114
|
+
text.set({
|
|
5115
|
+
left: v,
|
|
5116
|
+
originX: originX
|
|
6885
5117
|
});
|
|
5118
|
+
} // 拖动左侧竖线时需要更改上一线段文字的位置,以防止文字被遮挡
|
|
6886
5119
|
|
|
6887
|
-
if (point) {
|
|
6888
|
-
this.canvas.remove(point);
|
|
6889
|
-
point.line1 && this.canvas.remove(point.line1);
|
|
6890
|
-
point.line3 && this.canvas.remove(point.line3);
|
|
6891
|
-
point.noRiseText && this.canvas.remove(point.noRiseText);
|
|
6892
|
-
point.arrowGroup && this.canvas.remove(point.arrowGroup);
|
|
6893
|
-
point.verifiedText && this.canvas.remove(point.verifiedText);
|
|
6894
|
-
}
|
|
6895
5120
|
|
|
6896
|
-
|
|
6897
|
-
|
|
5121
|
+
var preText = line.preText || null;
|
|
5122
|
+
if (!preText) return;
|
|
5123
|
+
var limitWidth = preText.width + 2;
|
|
6898
5124
|
|
|
6899
|
-
|
|
6900
|
-
|
|
6901
|
-
|
|
6902
|
-
|
|
6903
|
-
|
|
5125
|
+
if (preText.originX === 'left' && preText.left + limitWidth > line.left) {
|
|
5126
|
+
var _v = this.propItems.endX + 100; // 此值随便设置,只要达到隐藏效果即可
|
|
5127
|
+
|
|
5128
|
+
|
|
5129
|
+
preText.setCoords();
|
|
5130
|
+
preText.set({
|
|
5131
|
+
left: _v
|
|
5132
|
+
});
|
|
5133
|
+
}
|
|
6904
5134
|
},
|
|
6905
|
-
|
|
6906
|
-
if (this.
|
|
6907
|
-
this.
|
|
5135
|
+
repaintLine: function repaintLine() {
|
|
5136
|
+
if (this.lines.length) {
|
|
5137
|
+
this.removeLines();
|
|
6908
5138
|
}
|
|
6909
5139
|
|
|
6910
|
-
this.
|
|
5140
|
+
this.getLineList(this.linesObj.list);
|
|
5141
|
+
this.createLine();
|
|
6911
5142
|
}
|
|
6912
|
-
}
|
|
5143
|
+
},
|
|
5144
|
+
beforeDestroy: function beforeDestroy() {}
|
|
6913
5145
|
});
|
|
6914
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-
|
|
6915
|
-
/* harmony default export */ var
|
|
6916
|
-
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-
|
|
5146
|
+
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricLines.vue?vue&type=script&lang=js&
|
|
5147
|
+
/* harmony default export */ var fabric_chart_FabricLinesvue_type_script_lang_js_ = (FabricLinesvue_type_script_lang_js_);
|
|
5148
|
+
// CONCATENATED MODULE: ./packages/fabric-chart/src/fabric-chart/FabricLines.vue
|
|
6917
5149
|
|
|
6918
5150
|
|
|
6919
5151
|
|
|
@@ -6921,10 +5153,10 @@ var FabricCentervue_type_script_lang_js_rightClickNode = [{
|
|
|
6921
5153
|
|
|
6922
5154
|
/* normalize component */
|
|
6923
5155
|
|
|
6924
|
-
var
|
|
6925
|
-
|
|
6926
|
-
|
|
6927
|
-
|
|
5156
|
+
var FabricLines_component = Object(componentNormalizer["a" /* default */])(
|
|
5157
|
+
fabric_chart_FabricLinesvue_type_script_lang_js_,
|
|
5158
|
+
FabricLinesvue_type_template_id_7d4d7ba0_render,
|
|
5159
|
+
FabricLinesvue_type_template_id_7d4d7ba0_staticRenderFns,
|
|
6928
5160
|
false,
|
|
6929
5161
|
null,
|
|
6930
5162
|
null,
|
|
@@ -6932,7 +5164,7 @@ var FabricCenter_component = Object(componentNormalizer["a" /* default */])(
|
|
|
6932
5164
|
|
|
6933
5165
|
)
|
|
6934
5166
|
|
|
6935
|
-
/* harmony default export */ var
|
|
5167
|
+
/* harmony default export */ var FabricLines = (FabricLines_component.exports);
|
|
6936
5168
|
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/fabric-chart/src/FabricChart.vue?vue&type=script&lang=js&
|
|
6937
5169
|
|
|
6938
5170
|
//
|
|
@@ -6953,11 +5185,6 @@ var FabricCenter_component = Object(componentNormalizer["a" /* default */])(
|
|
|
6953
5185
|
//
|
|
6954
5186
|
//
|
|
6955
5187
|
//
|
|
6956
|
-
//
|
|
6957
|
-
//
|
|
6958
|
-
//
|
|
6959
|
-
//
|
|
6960
|
-
//
|
|
6961
5188
|
|
|
6962
5189
|
/**
|
|
6963
5190
|
* @author lujiafu
|
|
@@ -6972,12 +5199,6 @@ var FabricCenter_component = Object(componentNormalizer["a" /* default */])(
|
|
|
6972
5199
|
|
|
6973
5200
|
|
|
6974
5201
|
|
|
6975
|
-
|
|
6976
|
-
|
|
6977
|
-
|
|
6978
|
-
|
|
6979
|
-
|
|
6980
|
-
|
|
6981
5202
|
/* harmony default export */ var FabricChartvue_type_script_lang_js_ = (Object(create["a" /* default */])({
|
|
6982
5203
|
name: 'fabric-chart',
|
|
6983
5204
|
props: {
|
|
@@ -6993,17 +5214,11 @@ var FabricCenter_component = Object(componentNormalizer["a" /* default */])(
|
|
|
6993
5214
|
},
|
|
6994
5215
|
components: {
|
|
6995
5216
|
FabricCanvas: FabricCanvas,
|
|
6996
|
-
FabricCanvas2: fabric_chart2_FabricCanvas,
|
|
6997
5217
|
FabricGrid: FabricGrid,
|
|
6998
5218
|
FabricTextGroup: FabricTextGroup,
|
|
6999
5219
|
FabricPolylines: FabricPolylines,
|
|
7000
5220
|
FabricScaleValue: FabricScaleValue,
|
|
7001
|
-
FabricLines: FabricLines
|
|
7002
|
-
FabricTop2: FabricTop,
|
|
7003
|
-
FabricLeft2: FabricLeft,
|
|
7004
|
-
FabricRight2: FabricRight,
|
|
7005
|
-
FabricBottom2: FabricBottom,
|
|
7006
|
-
FabricCenter2: FabricCenter
|
|
5221
|
+
FabricLines: FabricLines
|
|
7007
5222
|
},
|
|
7008
5223
|
computed: {
|
|
7009
5224
|
polylines: function polylines() {
|
|
@@ -7118,8 +5333,8 @@ var FabricCenter_component = Object(componentNormalizer["a" /* default */])(
|
|
|
7118
5333
|
}));
|
|
7119
5334
|
// CONCATENATED MODULE: ./packages/fabric-chart/src/FabricChart.vue?vue&type=script&lang=js&
|
|
7120
5335
|
/* harmony default export */ var src_FabricChartvue_type_script_lang_js_ = (FabricChartvue_type_script_lang_js_);
|
|
7121
|
-
// EXTERNAL MODULE: ./packages/fabric-chart/src/FabricChart.vue?vue&type=style&index=0&id=
|
|
7122
|
-
var
|
|
5336
|
+
// EXTERNAL MODULE: ./packages/fabric-chart/src/FabricChart.vue?vue&type=style&index=0&id=b556f068&lang=less&scoped=true&
|
|
5337
|
+
var FabricChartvue_type_style_index_0_id_b556f068_lang_less_scoped_true_ = __webpack_require__("d3f0");
|
|
7123
5338
|
|
|
7124
5339
|
// CONCATENATED MODULE: ./packages/fabric-chart/src/FabricChart.vue
|
|
7125
5340
|
|
|
@@ -7136,7 +5351,7 @@ var FabricChart_component = Object(componentNormalizer["a" /* default */])(
|
|
|
7136
5351
|
staticRenderFns,
|
|
7137
5352
|
false,
|
|
7138
5353
|
null,
|
|
7139
|
-
"
|
|
5354
|
+
"b556f068",
|
|
7140
5355
|
null
|
|
7141
5356
|
|
|
7142
5357
|
)
|
|
@@ -7492,17 +5707,6 @@ module.exports = function (CONSTRUCTOR_NAME) {
|
|
|
7492
5707
|
};
|
|
7493
5708
|
|
|
7494
5709
|
|
|
7495
|
-
/***/ }),
|
|
7496
|
-
|
|
7497
|
-
/***/ "26a0":
|
|
7498
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
7499
|
-
|
|
7500
|
-
"use strict";
|
|
7501
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_FabricChart_vue_vue_type_style_index_0_id_cb500674_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("bb2d");
|
|
7502
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_FabricChart_vue_vue_type_style_index_0_id_cb500674_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_FabricChart_vue_vue_type_style_index_0_id_cb500674_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0__);
|
|
7503
|
-
/* unused harmony reexport * */
|
|
7504
|
-
|
|
7505
|
-
|
|
7506
5710
|
/***/ }),
|
|
7507
5711
|
|
|
7508
5712
|
/***/ "2871":
|
|
@@ -9025,13 +7229,6 @@ module.exports = require("core-js/modules/es.object.to-string.js");
|
|
|
9025
7229
|
|
|
9026
7230
|
/***/ }),
|
|
9027
7231
|
|
|
9028
|
-
/***/ "98a5":
|
|
9029
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
9030
|
-
|
|
9031
|
-
// extracted by mini-css-extract-plugin
|
|
9032
|
-
|
|
9033
|
-
/***/ }),
|
|
9034
|
-
|
|
9035
7232
|
/***/ "9b22":
|
|
9036
7233
|
/***/ (function(module, exports) {
|
|
9037
7234
|
|
|
@@ -9267,6 +7464,13 @@ module.exports = {
|
|
|
9267
7464
|
};
|
|
9268
7465
|
|
|
9269
7466
|
|
|
7467
|
+
/***/ }),
|
|
7468
|
+
|
|
7469
|
+
/***/ "b4ea":
|
|
7470
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
7471
|
+
|
|
7472
|
+
// extracted by mini-css-extract-plugin
|
|
7473
|
+
|
|
9270
7474
|
/***/ }),
|
|
9271
7475
|
|
|
9272
7476
|
/***/ "b575":
|
|
@@ -9384,13 +7588,6 @@ module.exports = function (name) {
|
|
|
9384
7588
|
};
|
|
9385
7589
|
|
|
9386
7590
|
|
|
9387
|
-
/***/ }),
|
|
9388
|
-
|
|
9389
|
-
/***/ "bb2d":
|
|
9390
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
9391
|
-
|
|
9392
|
-
// extracted by mini-css-extract-plugin
|
|
9393
|
-
|
|
9394
7591
|
/***/ }),
|
|
9395
7592
|
|
|
9396
7593
|
/***/ "be94":
|
|
@@ -9702,6 +7899,17 @@ module.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {
|
|
|
9702
7899
|
}() : undefined);
|
|
9703
7900
|
|
|
9704
7901
|
|
|
7902
|
+
/***/ }),
|
|
7903
|
+
|
|
7904
|
+
/***/ "d3f0":
|
|
7905
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
7906
|
+
|
|
7907
|
+
"use strict";
|
|
7908
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_FabricChart_vue_vue_type_style_index_0_id_b556f068_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("fe76");
|
|
7909
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_FabricChart_vue_vue_type_style_index_0_id_b556f068_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_FabricChart_vue_vue_type_style_index_0_id_b556f068_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0__);
|
|
7910
|
+
/* unused harmony reexport * */
|
|
7911
|
+
|
|
7912
|
+
|
|
9705
7913
|
/***/ }),
|
|
9706
7914
|
|
|
9707
7915
|
/***/ "d44e":
|
|
@@ -9754,13 +7962,6 @@ module.exports = USE_SYMBOL_AS_UID ? function (it) {
|
|
|
9754
7962
|
};
|
|
9755
7963
|
|
|
9756
7964
|
|
|
9757
|
-
/***/ }),
|
|
9758
|
-
|
|
9759
|
-
/***/ "da6e":
|
|
9760
|
-
/***/ (function(module, exports) {
|
|
9761
|
-
|
|
9762
|
-
module.exports = require("core-js/modules/es.array.flat.js");
|
|
9763
|
-
|
|
9764
7965
|
/***/ }),
|
|
9765
7966
|
|
|
9766
7967
|
/***/ "da84":
|
|
@@ -9920,17 +8121,6 @@ module.exports = function (target, src, options) {
|
|
|
9920
8121
|
};
|
|
9921
8122
|
|
|
9922
8123
|
|
|
9923
|
-
/***/ }),
|
|
9924
|
-
|
|
9925
|
-
/***/ "e350":
|
|
9926
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
9927
|
-
|
|
9928
|
-
"use strict";
|
|
9929
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_TimeScaleValue_vue_vue_type_style_index_0_id_a10b6e3e_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("98a5");
|
|
9930
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_TimeScaleValue_vue_vue_type_style_index_0_id_a10b6e3e_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_10_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_10_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_10_oneOf_1_2_node_modules_less_loader_dist_cjs_js_ref_10_oneOf_1_3_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_TimeScaleValue_vue_vue_type_style_index_0_id_a10b6e3e_lang_less_scoped_true___WEBPACK_IMPORTED_MODULE_0__);
|
|
9931
|
-
/* unused harmony reexport * */
|
|
9932
|
-
|
|
9933
|
-
|
|
9934
8124
|
/***/ }),
|
|
9935
8125
|
|
|
9936
8126
|
/***/ "e667":
|
|
@@ -10480,13 +8670,6 @@ module.exports = function (key) {
|
|
|
10480
8670
|
};
|
|
10481
8671
|
|
|
10482
8672
|
|
|
10483
|
-
/***/ }),
|
|
10484
|
-
|
|
10485
|
-
/***/ "f906":
|
|
10486
|
-
/***/ (function(module, exports) {
|
|
10487
|
-
|
|
10488
|
-
module.exports = require("vxe-table");
|
|
10489
|
-
|
|
10490
8673
|
/***/ }),
|
|
10491
8674
|
|
|
10492
8675
|
/***/ "f989":
|
|
@@ -10528,6 +8711,13 @@ module.exports = NATIVE_SYMBOL
|
|
|
10528
8711
|
&& typeof Symbol.iterator == 'symbol';
|
|
10529
8712
|
|
|
10530
8713
|
|
|
8714
|
+
/***/ }),
|
|
8715
|
+
|
|
8716
|
+
/***/ "fe76":
|
|
8717
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
8718
|
+
|
|
8719
|
+
// extracted by mini-css-extract-plugin
|
|
8720
|
+
|
|
10531
8721
|
/***/ }),
|
|
10532
8722
|
|
|
10533
8723
|
/***/ "fea9":
|