wargerm 0.5.33 → 0.5.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/dist/components/Modal/index.d.ts +1 -0
- package/dist/components/ModalTips/index.d.ts +1 -0
- package/dist/index.esm.js +24 -8
- package/dist/index.js +24 -8
- package/package.json +88 -88
package/dist/index.esm.js
CHANGED
@@ -9919,19 +9919,20 @@ var Modal = /*#__PURE__*/function (_React$PureComponent) {
|
|
9919
9919
|
title = _this$props2.title,
|
9920
9920
|
onClose = _this$props2.onClose,
|
9921
9921
|
closeCb = _this$props2.closeCb,
|
9922
|
+
renderClose = _this$props2.renderClose,
|
9922
9923
|
isDrag = _this$props2.isDrag;
|
9923
9924
|
return /*#__PURE__*/React.createElement("div", {
|
9924
9925
|
className: "model-header"
|
9925
9926
|
}, /*#__PURE__*/React.createElement("div", {
|
9926
9927
|
ref: _this.titleRef,
|
9927
9928
|
className: "model-title ".concat(isDrag ? 'move' : '')
|
9928
|
-
}, title), /*#__PURE__*/React.createElement(
|
9929
|
+
}, title), /*#__PURE__*/React.createElement("div", {
|
9929
9930
|
className: "model-closeIcon",
|
9930
9931
|
onClick: function onClick() {
|
9931
9932
|
onClose && onClose();
|
9932
9933
|
closeCb && closeCb();
|
9933
9934
|
}
|
9934
|
-
}));
|
9935
|
+
}, renderClose ? renderClose : /*#__PURE__*/React.createElement(CloseCircleOutlined, null)));
|
9935
9936
|
};
|
9936
9937
|
|
9937
9938
|
_this.renderContent = function () {
|
@@ -10221,17 +10222,18 @@ var Modal$1 = /*#__PURE__*/function (_React$PureComponent) {
|
|
10221
10222
|
_this.renderTop = function () {
|
10222
10223
|
var _this$props2 = _this.props,
|
10223
10224
|
title = _this$props2.title,
|
10224
|
-
onClose = _this$props2.onClose
|
10225
|
+
onClose = _this$props2.onClose,
|
10226
|
+
renderClose = _this$props2.renderClose;
|
10225
10227
|
return /*#__PURE__*/React.createElement("div", {
|
10226
10228
|
className: "model-header-tips"
|
10227
10229
|
}, /*#__PURE__*/React.createElement("div", {
|
10228
10230
|
className: "model-title-tips"
|
10229
|
-
}, title), /*#__PURE__*/React.createElement(
|
10231
|
+
}, title), /*#__PURE__*/React.createElement("div", {
|
10230
10232
|
className: "model-closeIcon-tips",
|
10231
10233
|
onClick: function onClick() {
|
10232
10234
|
return onClose && onClose();
|
10233
10235
|
}
|
10234
|
-
}));
|
10236
|
+
}, renderClose ? renderClose : /*#__PURE__*/React.createElement(CloseCircleOutlined, null)));
|
10235
10237
|
};
|
10236
10238
|
|
10237
10239
|
_this.renderContent = function () {
|
@@ -11459,6 +11461,7 @@ function Calendar(_ref, ref) {
|
|
11459
11461
|
type = _ref.type,
|
11460
11462
|
toolBarSolt = _ref.toolBarSolt,
|
11461
11463
|
dateCellRender = _ref.dateCellRender,
|
11464
|
+
onCell = _ref.onCell,
|
11462
11465
|
calendarBodyClassName = _ref.calendarBodyClassName;
|
11463
11466
|
|
11464
11467
|
var _useState = useState(initCalendar()),
|
@@ -11569,6 +11572,7 @@ function Calendar(_ref, ref) {
|
|
11569
11572
|
type: "text",
|
11570
11573
|
onClick: handleUp
|
11571
11574
|
}), type == 'day' ? /*#__PURE__*/React.createElement(_DatePicker, {
|
11575
|
+
allowClear: false,
|
11572
11576
|
value: datevalue,
|
11573
11577
|
onChange: function onChange(date) {
|
11574
11578
|
setOneWeekDays(['时间'].concat(_toConsumableArray(getweekDay(date))));
|
@@ -11579,6 +11583,7 @@ function Calendar(_ref, ref) {
|
|
11579
11583
|
width: '250px'
|
11580
11584
|
}
|
11581
11585
|
}) : type == 'week' ? /*#__PURE__*/React.createElement(_DatePicker, {
|
11586
|
+
allowClear: false,
|
11582
11587
|
value: datevalue,
|
11583
11588
|
style: {
|
11584
11589
|
width: '250px'
|
@@ -11591,6 +11596,7 @@ function Calendar(_ref, ref) {
|
|
11591
11596
|
setDatevalue(date);
|
11592
11597
|
}
|
11593
11598
|
}) : /*#__PURE__*/React.createElement(_DatePicker, {
|
11599
|
+
allowClear: false,
|
11594
11600
|
value: datevalue,
|
11595
11601
|
picker: "month",
|
11596
11602
|
onChange: function onChange(date) {
|
@@ -11625,13 +11631,20 @@ function Calendar(_ref, ref) {
|
|
11625
11631
|
gridTemplateColumns: type == 'week' ? 'repeat(8, 1fr)' : '1fr 7fr'
|
11626
11632
|
}
|
11627
11633
|
}, days === null || days === void 0 ? void 0 : days.map(function (day, index) {
|
11628
|
-
|
11634
|
+
var _onCell;
|
11635
|
+
|
11636
|
+
var number = onCell && ((_onCell = onCell(days, day)) === null || _onCell === void 0 ? void 0 : _onCell.rowSpan) || 1;
|
11637
|
+
return number ? /*#__PURE__*/React.createElement("div", {
|
11629
11638
|
onClick: function onClick() {
|
11630
11639
|
return cellClick(day);
|
11631
11640
|
},
|
11641
|
+
style: {
|
11642
|
+
gridRowStart: "span ".concat(number),
|
11643
|
+
height: number * 100
|
11644
|
+
},
|
11632
11645
|
className: "day_container ".concat(day.isCurrentDay ? 'isCurrentDay' : '', " ").concat(day.isCurrentMonth ? 'isCurrentMonth' : ''),
|
11633
11646
|
key: index
|
11634
|
-
}, dateCellRender ? dateCellRender(day) : day.text);
|
11647
|
+
}, dateCellRender ? dateCellRender(day) : day.text) : null;
|
11635
11648
|
}))) : /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
11636
11649
|
className: "calendar_header_wrapper"
|
11637
11650
|
}, weekLabelArray.map(function (weekLabel) {
|
@@ -11965,11 +11978,14 @@ function VideoPlayer(_ref, ref) {
|
|
11965
11978
|
currentLayoutIndex = _useState2[0],
|
11966
11979
|
setCurrentLayoutIndex = _useState2[1];
|
11967
11980
|
|
11968
|
-
var _useState3 = useState(
|
11981
|
+
var _useState3 = useState([]),
|
11969
11982
|
_useState4 = _slicedToArray(_useState3, 2),
|
11970
11983
|
urls = _useState4[0],
|
11971
11984
|
setUrls = _useState4[1];
|
11972
11985
|
|
11986
|
+
useEffect(function () {
|
11987
|
+
setUrls(url);
|
11988
|
+
}, [url]);
|
11973
11989
|
var initPlayerIndex = allLayouts[layoutIndex || 0].span >= url.length ? url.length - 1 >= 0 ? url.length - 1 : 0 : allLayouts[layoutIndex || 0].span - 1;
|
11974
11990
|
|
11975
11991
|
var _useState5 = useState(initPlayerIndex),
|
package/dist/index.js
CHANGED
@@ -9981,19 +9981,20 @@ var Modal = /*#__PURE__*/function (_React$PureComponent) {
|
|
9981
9981
|
title = _this$props2.title,
|
9982
9982
|
onClose = _this$props2.onClose,
|
9983
9983
|
closeCb = _this$props2.closeCb,
|
9984
|
+
renderClose = _this$props2.renderClose,
|
9984
9985
|
isDrag = _this$props2.isDrag;
|
9985
9986
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
9986
9987
|
className: "model-header"
|
9987
9988
|
}, /*#__PURE__*/React__default['default'].createElement("div", {
|
9988
9989
|
ref: _this.titleRef,
|
9989
9990
|
className: "model-title ".concat(isDrag ? 'move' : '')
|
9990
|
-
}, title), /*#__PURE__*/React__default['default'].createElement(
|
9991
|
+
}, title), /*#__PURE__*/React__default['default'].createElement("div", {
|
9991
9992
|
className: "model-closeIcon",
|
9992
9993
|
onClick: function onClick() {
|
9993
9994
|
onClose && onClose();
|
9994
9995
|
closeCb && closeCb();
|
9995
9996
|
}
|
9996
|
-
}));
|
9997
|
+
}, renderClose ? renderClose : /*#__PURE__*/React__default['default'].createElement(icons.CloseCircleOutlined, null)));
|
9997
9998
|
};
|
9998
9999
|
|
9999
10000
|
_this.renderContent = function () {
|
@@ -10283,17 +10284,18 @@ var Modal$1 = /*#__PURE__*/function (_React$PureComponent) {
|
|
10283
10284
|
_this.renderTop = function () {
|
10284
10285
|
var _this$props2 = _this.props,
|
10285
10286
|
title = _this$props2.title,
|
10286
|
-
onClose = _this$props2.onClose
|
10287
|
+
onClose = _this$props2.onClose,
|
10288
|
+
renderClose = _this$props2.renderClose;
|
10287
10289
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
10288
10290
|
className: "model-header-tips"
|
10289
10291
|
}, /*#__PURE__*/React__default['default'].createElement("div", {
|
10290
10292
|
className: "model-title-tips"
|
10291
|
-
}, title), /*#__PURE__*/React__default['default'].createElement(
|
10293
|
+
}, title), /*#__PURE__*/React__default['default'].createElement("div", {
|
10292
10294
|
className: "model-closeIcon-tips",
|
10293
10295
|
onClick: function onClick() {
|
10294
10296
|
return onClose && onClose();
|
10295
10297
|
}
|
10296
|
-
}));
|
10298
|
+
}, renderClose ? renderClose : /*#__PURE__*/React__default['default'].createElement(icons.CloseCircleOutlined, null)));
|
10297
10299
|
};
|
10298
10300
|
|
10299
10301
|
_this.renderContent = function () {
|
@@ -11521,6 +11523,7 @@ function Calendar(_ref, ref) {
|
|
11521
11523
|
type = _ref.type,
|
11522
11524
|
toolBarSolt = _ref.toolBarSolt,
|
11523
11525
|
dateCellRender = _ref.dateCellRender,
|
11526
|
+
onCell = _ref.onCell,
|
11524
11527
|
calendarBodyClassName = _ref.calendarBodyClassName;
|
11525
11528
|
|
11526
11529
|
var _useState = React.useState(initCalendar()),
|
@@ -11631,6 +11634,7 @@ function Calendar(_ref, ref) {
|
|
11631
11634
|
type: "text",
|
11632
11635
|
onClick: handleUp
|
11633
11636
|
}), type == 'day' ? /*#__PURE__*/React__default['default'].createElement(_DatePicker__default['default'], {
|
11637
|
+
allowClear: false,
|
11634
11638
|
value: datevalue,
|
11635
11639
|
onChange: function onChange(date) {
|
11636
11640
|
setOneWeekDays(['时间'].concat(_toConsumableArray(getweekDay(date))));
|
@@ -11641,6 +11645,7 @@ function Calendar(_ref, ref) {
|
|
11641
11645
|
width: '250px'
|
11642
11646
|
}
|
11643
11647
|
}) : type == 'week' ? /*#__PURE__*/React__default['default'].createElement(_DatePicker__default['default'], {
|
11648
|
+
allowClear: false,
|
11644
11649
|
value: datevalue,
|
11645
11650
|
style: {
|
11646
11651
|
width: '250px'
|
@@ -11653,6 +11658,7 @@ function Calendar(_ref, ref) {
|
|
11653
11658
|
setDatevalue(date);
|
11654
11659
|
}
|
11655
11660
|
}) : /*#__PURE__*/React__default['default'].createElement(_DatePicker__default['default'], {
|
11661
|
+
allowClear: false,
|
11656
11662
|
value: datevalue,
|
11657
11663
|
picker: "month",
|
11658
11664
|
onChange: function onChange(date) {
|
@@ -11687,13 +11693,20 @@ function Calendar(_ref, ref) {
|
|
11687
11693
|
gridTemplateColumns: type == 'week' ? 'repeat(8, 1fr)' : '1fr 7fr'
|
11688
11694
|
}
|
11689
11695
|
}, days === null || days === void 0 ? void 0 : days.map(function (day, index) {
|
11690
|
-
|
11696
|
+
var _onCell;
|
11697
|
+
|
11698
|
+
var number = onCell && ((_onCell = onCell(days, day)) === null || _onCell === void 0 ? void 0 : _onCell.rowSpan) || 1;
|
11699
|
+
return number ? /*#__PURE__*/React__default['default'].createElement("div", {
|
11691
11700
|
onClick: function onClick() {
|
11692
11701
|
return cellClick(day);
|
11693
11702
|
},
|
11703
|
+
style: {
|
11704
|
+
gridRowStart: "span ".concat(number),
|
11705
|
+
height: number * 100
|
11706
|
+
},
|
11694
11707
|
className: "day_container ".concat(day.isCurrentDay ? 'isCurrentDay' : '', " ").concat(day.isCurrentMonth ? 'isCurrentMonth' : ''),
|
11695
11708
|
key: index
|
11696
|
-
}, dateCellRender ? dateCellRender(day) : day.text);
|
11709
|
+
}, dateCellRender ? dateCellRender(day) : day.text) : null;
|
11697
11710
|
}))) : /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, /*#__PURE__*/React__default['default'].createElement("div", {
|
11698
11711
|
className: "calendar_header_wrapper"
|
11699
11712
|
}, weekLabelArray.map(function (weekLabel) {
|
@@ -12027,11 +12040,14 @@ function VideoPlayer(_ref, ref) {
|
|
12027
12040
|
currentLayoutIndex = _useState2[0],
|
12028
12041
|
setCurrentLayoutIndex = _useState2[1];
|
12029
12042
|
|
12030
|
-
var _useState3 = React.useState(
|
12043
|
+
var _useState3 = React.useState([]),
|
12031
12044
|
_useState4 = _slicedToArray(_useState3, 2),
|
12032
12045
|
urls = _useState4[0],
|
12033
12046
|
setUrls = _useState4[1];
|
12034
12047
|
|
12048
|
+
React.useEffect(function () {
|
12049
|
+
setUrls(url);
|
12050
|
+
}, [url]);
|
12035
12051
|
var initPlayerIndex = allLayouts[layoutIndex || 0].span >= url.length ? url.length - 1 >= 0 ? url.length - 1 : 0 : allLayouts[layoutIndex || 0].span - 1;
|
12036
12052
|
|
12037
12053
|
var _useState5 = React.useState(initPlayerIndex),
|
package/package.json
CHANGED
@@ -1,88 +1,88 @@
|
|
1
|
-
{
|
2
|
-
"private": false,
|
3
|
-
"name": "wargerm",
|
4
|
-
"version": "0.5.
|
5
|
-
"scripts": {
|
6
|
-
"dev": "dumi dev",
|
7
|
-
"docs:build": "dumi build",
|
8
|
-
"docs:deploy": "gh-pages -d docs-dist",
|
9
|
-
"build": "father-build",
|
10
|
-
"deploy": "npm run docs:build && npm run docs:deploy",
|
11
|
-
"release": "npm run build && npm publish",
|
12
|
-
"prettier": "prettier --write \"**/*.{js,jsx,tsx,ts,less,md,json}\"",
|
13
|
-
"test": "umi-test",
|
14
|
-
"test:coverage": "umi-test --coverage"
|
15
|
-
},
|
16
|
-
"main": "dist/index.js",
|
17
|
-
"module": "dist/index.esm.js",
|
18
|
-
"unpkg": "dist/index.umd.min.js",
|
19
|
-
"typings": "dist/index.d.ts",
|
20
|
-
"author": "jinly2",
|
21
|
-
"license": "MIT",
|
22
|
-
"keywords": [
|
23
|
-
"React",
|
24
|
-
"Component"
|
25
|
-
],
|
26
|
-
"gitHooks": {
|
27
|
-
"pre-commit": "lint-staged"
|
28
|
-
},
|
29
|
-
"repository": {
|
30
|
-
"type": "git",
|
31
|
-
"url": "http://code.eblssmart.com/platform/web/wargerm-components.git",
|
32
|
-
"branch": "main"
|
33
|
-
},
|
34
|
-
"files": [
|
35
|
-
"dist",
|
36
|
-
"es",
|
37
|
-
"lib",
|
38
|
-
"index.css"
|
39
|
-
],
|
40
|
-
"lint-staged": {
|
41
|
-
"*.{js,jsx,less,md,json}": [
|
42
|
-
"prettier --write"
|
43
|
-
],
|
44
|
-
"*.ts?(x)": [
|
45
|
-
"prettier --parser=typescript --write"
|
46
|
-
]
|
47
|
-
},
|
48
|
-
"dependencies": {
|
49
|
-
"@ant-design/pro-table": "^2.79.0",
|
50
|
-
"animate.css": "^4.1.1",
|
51
|
-
"echarts": "^5.2.2",
|
52
|
-
"echarts-for-react": "^3.0.2",
|
53
|
-
"react-countup": "^6.0.0",
|
54
|
-
"react-dom": "^17.0.2",
|
55
|
-
"react-file-viewer": "^1.2.1",
|
56
|
-
"swiper": "^6.7.0",
|
57
|
-
"xgplayer": "^2.31.6",
|
58
|
-
"xgplayer-flv": "^2.5.1",
|
59
|
-
"xgplayer-flv.js": "^2.3.0",
|
60
|
-
"xgplayer-hls": "^2.5.2",
|
61
|
-
"xgplayer-hls.js": "^2.6.1"
|
62
|
-
},
|
63
|
-
"peerDependencies": {
|
64
|
-
"@ant-design/icons": ">=4.2.0",
|
65
|
-
"antd": ">=4.7.0",
|
66
|
-
"classnames": ">=2.2.0",
|
67
|
-
"echarts": "^5.2.2",
|
68
|
-
"echarts-for-react": "^3.0.2",
|
69
|
-
"lodash": ">=4.0.0",
|
70
|
-
"react": ">=17.0.0"
|
71
|
-
},
|
72
|
-
"devDependencies": {
|
73
|
-
"@ant-design/icons": "^4.6.4",
|
74
|
-
"@types/lodash": "^4.14.173",
|
75
|
-
"@types/react-dom": "^17.0.11",
|
76
|
-
"@umijs/test": "^3.0.5",
|
77
|
-
"antd": "^4.16.13",
|
78
|
-
"babel-plugin-import": "^1.13.3",
|
79
|
-
"classnames": "^2.3.1",
|
80
|
-
"dumi": "^1.1.31",
|
81
|
-
"father-build": "^1.19.1",
|
82
|
-
"gh-pages": "^3.0.0",
|
83
|
-
"lint-staged": "^10.0.7",
|
84
|
-
"prettier": "^1.19.1",
|
85
|
-
"react": "^16.12.0",
|
86
|
-
"yorkie": "^2.0.0"
|
87
|
-
}
|
88
|
-
}
|
1
|
+
{
|
2
|
+
"private": false,
|
3
|
+
"name": "wargerm",
|
4
|
+
"version": "0.5.35",
|
5
|
+
"scripts": {
|
6
|
+
"dev": "dumi dev",
|
7
|
+
"docs:build": "dumi build",
|
8
|
+
"docs:deploy": "gh-pages -d docs-dist",
|
9
|
+
"build": "father-build",
|
10
|
+
"deploy": "npm run docs:build && npm run docs:deploy",
|
11
|
+
"release": "npm run build && npm publish",
|
12
|
+
"prettier": "prettier --write \"**/*.{js,jsx,tsx,ts,less,md,json}\"",
|
13
|
+
"test": "umi-test",
|
14
|
+
"test:coverage": "umi-test --coverage"
|
15
|
+
},
|
16
|
+
"main": "dist/index.js",
|
17
|
+
"module": "dist/index.esm.js",
|
18
|
+
"unpkg": "dist/index.umd.min.js",
|
19
|
+
"typings": "dist/index.d.ts",
|
20
|
+
"author": "jinly2",
|
21
|
+
"license": "MIT",
|
22
|
+
"keywords": [
|
23
|
+
"React",
|
24
|
+
"Component"
|
25
|
+
],
|
26
|
+
"gitHooks": {
|
27
|
+
"pre-commit": "lint-staged"
|
28
|
+
},
|
29
|
+
"repository": {
|
30
|
+
"type": "git",
|
31
|
+
"url": "http://code.eblssmart.com/platform/web/wargerm-components.git",
|
32
|
+
"branch": "main"
|
33
|
+
},
|
34
|
+
"files": [
|
35
|
+
"dist",
|
36
|
+
"es",
|
37
|
+
"lib",
|
38
|
+
"index.css"
|
39
|
+
],
|
40
|
+
"lint-staged": {
|
41
|
+
"*.{js,jsx,less,md,json}": [
|
42
|
+
"prettier --write"
|
43
|
+
],
|
44
|
+
"*.ts?(x)": [
|
45
|
+
"prettier --parser=typescript --write"
|
46
|
+
]
|
47
|
+
},
|
48
|
+
"dependencies": {
|
49
|
+
"@ant-design/pro-table": "^2.79.0",
|
50
|
+
"animate.css": "^4.1.1",
|
51
|
+
"echarts": "^5.2.2",
|
52
|
+
"echarts-for-react": "^3.0.2",
|
53
|
+
"react-countup": "^6.0.0",
|
54
|
+
"react-dom": "^17.0.2",
|
55
|
+
"react-file-viewer": "^1.2.1",
|
56
|
+
"swiper": "^6.7.0",
|
57
|
+
"xgplayer": "^2.31.6",
|
58
|
+
"xgplayer-flv": "^2.5.1",
|
59
|
+
"xgplayer-flv.js": "^2.3.0",
|
60
|
+
"xgplayer-hls": "^2.5.2",
|
61
|
+
"xgplayer-hls.js": "^2.6.1"
|
62
|
+
},
|
63
|
+
"peerDependencies": {
|
64
|
+
"@ant-design/icons": ">=4.2.0",
|
65
|
+
"antd": ">=4.7.0",
|
66
|
+
"classnames": ">=2.2.0",
|
67
|
+
"echarts": "^5.2.2",
|
68
|
+
"echarts-for-react": "^3.0.2",
|
69
|
+
"lodash": ">=4.0.0",
|
70
|
+
"react": ">=17.0.0"
|
71
|
+
},
|
72
|
+
"devDependencies": {
|
73
|
+
"@ant-design/icons": "^4.6.4",
|
74
|
+
"@types/lodash": "^4.14.173",
|
75
|
+
"@types/react-dom": "^17.0.11",
|
76
|
+
"@umijs/test": "^3.0.5",
|
77
|
+
"antd": "^4.16.13",
|
78
|
+
"babel-plugin-import": "^1.13.3",
|
79
|
+
"classnames": "^2.3.1",
|
80
|
+
"dumi": "^1.1.31",
|
81
|
+
"father-build": "^1.19.1",
|
82
|
+
"gh-pages": "^3.0.0",
|
83
|
+
"lint-staged": "^10.0.7",
|
84
|
+
"prettier": "^1.19.1",
|
85
|
+
"react": "^16.12.0",
|
86
|
+
"yorkie": "^2.0.0"
|
87
|
+
}
|
88
|
+
}
|