wargerm 0.7.30 → 0.7.31
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.
@@ -30,6 +30,10 @@ export declare function initCalendar(date?: Dayjs): {
|
|
30
30
|
isCurrentMonth: boolean;
|
31
31
|
isCurrentDay: boolean;
|
32
32
|
}[];
|
33
|
+
/**
|
34
|
+
* 初始化日历 自定义前缀
|
35
|
+
*/
|
36
|
+
export declare function initCustomPrefixCalendar(date?: Dayjs, content?: any): any[];
|
33
37
|
/**
|
34
38
|
* 初始化日历
|
35
39
|
*/
|
package/dist/index.esm.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import 'antd/dist/reset.css';
|
2
2
|
import React, { useRef, useEffect, useMemo, useState, useCallback, useImperativeHandle, memo, forwardRef, createRef } from 'react';
|
3
|
-
import { cloneDeep, uniqBy, isEmpty } from 'lodash-es';
|
3
|
+
import { cloneDeep, uniqBy, chunk, isEmpty } from 'lodash-es';
|
4
4
|
import { useSyncExternalStore } from 'use-sync-external-store/shim';
|
5
5
|
import { Menu, Dropdown, Button, Input, Upload as Upload$1, Modal as Modal$2, message, InputNumber, DatePicker, Radio, Space, Checkbox, Select, Switch, Tooltip, TreeSelect as TreeSelect$1, Cascader, Form, Row, Col, Spin, Pagination, Breadcrumb, ConfigProvider, notification } from 'antd';
|
6
6
|
import { createFromIconfontCN, PlusOutlined, CloseCircleOutlined, SearchOutlined, ReloadOutlined, EllipsisOutlined, ExclamationCircleOutlined, EyeOutlined, EditOutlined, DeleteOutlined, LeftOutlined, RightOutlined, CloseOutlined } from '@ant-design/icons';
|
@@ -7945,6 +7945,73 @@ function initCalendar(date) {
|
|
7945
7945
|
|
7946
7946
|
return [].concat(_toConsumableArray(lastDays.reverse()), currentDays, nextDays);
|
7947
7947
|
}
|
7948
|
+
/**
|
7949
|
+
* 初始化日历 自定义前缀
|
7950
|
+
*/
|
7951
|
+
|
7952
|
+
function initCustomPrefixCalendar(date, content) {
|
7953
|
+
// 当前月天数
|
7954
|
+
var totalDaysInMonth = getMonthDays(date); // 上个月天数
|
7955
|
+
|
7956
|
+
var totalDaysInLastMonth = getMonthDays(getLastMonth(date)); // 下个月开始日期
|
7957
|
+
|
7958
|
+
var nextFirstDate = 1;
|
7959
|
+
var lastDays = [],
|
7960
|
+
currentDays = [],
|
7961
|
+
nextDays = []; // 当前月第一天是星期几(索引值)
|
7962
|
+
|
7963
|
+
/**
|
7964
|
+
* 这里的索引值刚刚好是需要填充的上月的天数
|
7965
|
+
*/
|
7966
|
+
|
7967
|
+
var currentWeekDay = getWeekDays(date);
|
7968
|
+
|
7969
|
+
for (var i = 0, len = 42; i < len; i++) {
|
7970
|
+
// 填充上个月的天数
|
7971
|
+
if (i < currentWeekDay) {
|
7972
|
+
// lastDays.push(totalDaysInLastMonth);
|
7973
|
+
var daySting = dayjs(dayjs(date).subtract(1, 'month').format(YEAER_MONTH_FORMAT_EN) + '-' + totalDaysInLastMonth).format('YYYY-MM-DD');
|
7974
|
+
lastDays.push({
|
7975
|
+
date: daySting,
|
7976
|
+
text: formatDayWithTwoWords(totalDaysInLastMonth),
|
7977
|
+
isCurrentMonth: false,
|
7978
|
+
isCurrentDay: dayjs().format('YYYY-MM-DD') == daySting
|
7979
|
+
});
|
7980
|
+
totalDaysInLastMonth--;
|
7981
|
+
} // 填充下个月的天数
|
7982
|
+
else if (i >= totalDaysInMonth + currentWeekDay) {
|
7983
|
+
// nextDays.push(nextFirstDate);
|
7984
|
+
var _daySting3 = dayjs(dayjs(date).add(1, 'month').format(YEAER_MONTH_FORMAT_EN) + '-' + nextFirstDate).format('YYYY-MM-DD');
|
7985
|
+
|
7986
|
+
nextDays.push({
|
7987
|
+
date: _daySting3,
|
7988
|
+
text: formatDayWithTwoWords(nextFirstDate),
|
7989
|
+
isCurrentMonth: false,
|
7990
|
+
isCurrentDay: dayjs().format('YYYY-MM-DD') == _daySting3
|
7991
|
+
});
|
7992
|
+
nextFirstDate++;
|
7993
|
+
} // 填充当前月天数
|
7994
|
+
else {
|
7995
|
+
// currentDays.push(i - currentWeekDay + 1);
|
7996
|
+
var _daySting4 = dayjs(dayjs(date).format(YEAER_MONTH_FORMAT_EN) + '-' + (i - currentWeekDay + 1)).format('YYYY-MM-DD');
|
7997
|
+
|
7998
|
+
currentDays.push({
|
7999
|
+
date: _daySting4,
|
8000
|
+
text: formatDayWithTwoWords(i - currentWeekDay + 1),
|
8001
|
+
isCurrentMonth: true,
|
8002
|
+
isCurrentDay: dayjs().format('YYYY-MM-DD') == _daySting4
|
8003
|
+
});
|
8004
|
+
}
|
8005
|
+
} // 上个月需要倒序显示
|
8006
|
+
|
8007
|
+
|
8008
|
+
var dayArr = [].concat(_toConsumableArray(lastDays.reverse()), currentDays, nextDays);
|
8009
|
+
return chunk(dayArr, 7).map(function (day) {
|
8010
|
+
return [{
|
8011
|
+
content: content
|
8012
|
+
}].concat(_toConsumableArray(day));
|
8013
|
+
}).flat();
|
8014
|
+
}
|
7948
8015
|
/**
|
7949
8016
|
* 初始化日历
|
7950
8017
|
*/
|
@@ -7986,7 +8053,8 @@ function Calendar(_ref, ref) {
|
|
7986
8053
|
onCell = _ref.onCell,
|
7987
8054
|
calendarBodyClassName = _ref.calendarBodyClassName,
|
7988
8055
|
hiddenWeekLabel = _ref.hiddenWeekLabel,
|
7989
|
-
dateString = _ref.dateString
|
8056
|
+
dateString = _ref.dateString,
|
8057
|
+
customPrefix = _ref.customPrefix;
|
7990
8058
|
|
7991
8059
|
var _useState = useState(initCalendar()),
|
7992
8060
|
_useState2 = _slicedToArray(_useState, 2),
|
@@ -8003,7 +8071,8 @@ function Calendar(_ref, ref) {
|
|
8003
8071
|
oneWeekDays = _useState6[0],
|
8004
8072
|
setOneWeekDays = _useState6[1];
|
8005
8073
|
|
8006
|
-
var
|
8074
|
+
var customHeader = customPrefix ? [customPrefix.header] : [];
|
8075
|
+
var weekLabelArray = [].concat(customHeader, ['周一', '周二', '周三', '周四', '周五', '周六', '周日']);
|
8007
8076
|
|
8008
8077
|
var getweekDay = function getweekDay(date) {
|
8009
8078
|
var index = dayjs(date).day();
|
@@ -8020,14 +8089,14 @@ function Calendar(_ref, ref) {
|
|
8020
8089
|
if (type == 'day') {
|
8021
8090
|
setOneWeekDays(['时间'].concat(_toConsumableArray(getweekDay(datevalue))));
|
8022
8091
|
} else {
|
8023
|
-
setOneWeekDays(getWeekList(datevalue));
|
8092
|
+
setOneWeekDays(_toConsumableArray(getWeekList(datevalue)));
|
8024
8093
|
}
|
8025
8094
|
|
8026
8095
|
setDays(initWeekCalendar(type, datevalue));
|
8027
8096
|
} else {
|
8028
|
-
setDays(initCalendar(dateString || datevalue));
|
8097
|
+
setDays((customPrefix === null || customPrefix === void 0 ? void 0 : customPrefix.content) ? initCustomPrefixCalendar(dateString || datevalue, customPrefix === null || customPrefix === void 0 ? void 0 : customPrefix.content) : initCalendar(dateString || datevalue));
|
8029
8098
|
}
|
8030
|
-
}, [type, datevalue, dateString]);
|
8099
|
+
}, [type, datevalue, dateString, customPrefix]);
|
8031
8100
|
useEffect(function () {
|
8032
8101
|
setDatevalue(value || dayjs());
|
8033
8102
|
}, [value]);
|
@@ -8172,14 +8241,20 @@ function Calendar(_ref, ref) {
|
|
8172
8241
|
key: index
|
8173
8242
|
}, dateCellRender ? dateCellRender(day) : day.text) : null;
|
8174
8243
|
}))) : /*#__PURE__*/React.createElement(React.Fragment, null, !hiddenWeekLabel && /*#__PURE__*/React.createElement("div", {
|
8175
|
-
className: "calendar_header_wrapper"
|
8244
|
+
className: "calendar_header_wrapper",
|
8245
|
+
style: {
|
8246
|
+
gridTemplateColumns: "repeat(".concat(weekLabelArray.length, ", 1fr)")
|
8247
|
+
}
|
8176
8248
|
}, weekLabelArray.map(function (weekLabel) {
|
8177
8249
|
return /*#__PURE__*/React.createElement("div", {
|
8178
8250
|
key: weekLabel,
|
8179
8251
|
className: "flex ai-c jc-c"
|
8180
8252
|
}, weekLabel);
|
8181
8253
|
})), /*#__PURE__*/React.createElement("div", {
|
8182
|
-
className: "content_wrapper ".concat(calendarBodyClassName)
|
8254
|
+
className: "content_wrapper ".concat(calendarBodyClassName),
|
8255
|
+
style: {
|
8256
|
+
gridTemplateColumns: "repeat(".concat(weekLabelArray.length, ", 1fr)")
|
8257
|
+
}
|
8183
8258
|
}, days === null || days === void 0 ? void 0 : days.map(function (day, index) {
|
8184
8259
|
return /*#__PURE__*/React.createElement("div", {
|
8185
8260
|
onClick: function onClick() {
|
@@ -8187,7 +8262,7 @@ function Calendar(_ref, ref) {
|
|
8187
8262
|
},
|
8188
8263
|
className: "day_container ".concat(day.isCurrentDay ? 'isCurrentDay' : '', " ").concat(day.isCurrentMonth ? 'isCurrentMonth' : ''),
|
8189
8264
|
key: index
|
8190
|
-
}, dateCellRender ? dateCellRender(day) : day.text);
|
8265
|
+
}, (day === null || day === void 0 ? void 0 : day.content) ? day.content : dateCellRender ? dateCellRender(day) : day.text);
|
8191
8266
|
})))));
|
8192
8267
|
}
|
8193
8268
|
|
package/dist/index.js
CHANGED
@@ -7989,6 +7989,73 @@ function initCalendar(date) {
|
|
7989
7989
|
|
7990
7990
|
return [].concat(_toConsumableArray(lastDays.reverse()), currentDays, nextDays);
|
7991
7991
|
}
|
7992
|
+
/**
|
7993
|
+
* 初始化日历 自定义前缀
|
7994
|
+
*/
|
7995
|
+
|
7996
|
+
function initCustomPrefixCalendar(date, content) {
|
7997
|
+
// 当前月天数
|
7998
|
+
var totalDaysInMonth = getMonthDays(date); // 上个月天数
|
7999
|
+
|
8000
|
+
var totalDaysInLastMonth = getMonthDays(getLastMonth(date)); // 下个月开始日期
|
8001
|
+
|
8002
|
+
var nextFirstDate = 1;
|
8003
|
+
var lastDays = [],
|
8004
|
+
currentDays = [],
|
8005
|
+
nextDays = []; // 当前月第一天是星期几(索引值)
|
8006
|
+
|
8007
|
+
/**
|
8008
|
+
* 这里的索引值刚刚好是需要填充的上月的天数
|
8009
|
+
*/
|
8010
|
+
|
8011
|
+
var currentWeekDay = getWeekDays(date);
|
8012
|
+
|
8013
|
+
for (var i = 0, len = 42; i < len; i++) {
|
8014
|
+
// 填充上个月的天数
|
8015
|
+
if (i < currentWeekDay) {
|
8016
|
+
// lastDays.push(totalDaysInLastMonth);
|
8017
|
+
var daySting = dayjs__default['default'](dayjs__default['default'](date).subtract(1, 'month').format(YEAER_MONTH_FORMAT_EN) + '-' + totalDaysInLastMonth).format('YYYY-MM-DD');
|
8018
|
+
lastDays.push({
|
8019
|
+
date: daySting,
|
8020
|
+
text: formatDayWithTwoWords(totalDaysInLastMonth),
|
8021
|
+
isCurrentMonth: false,
|
8022
|
+
isCurrentDay: dayjs__default['default']().format('YYYY-MM-DD') == daySting
|
8023
|
+
});
|
8024
|
+
totalDaysInLastMonth--;
|
8025
|
+
} // 填充下个月的天数
|
8026
|
+
else if (i >= totalDaysInMonth + currentWeekDay) {
|
8027
|
+
// nextDays.push(nextFirstDate);
|
8028
|
+
var _daySting3 = dayjs__default['default'](dayjs__default['default'](date).add(1, 'month').format(YEAER_MONTH_FORMAT_EN) + '-' + nextFirstDate).format('YYYY-MM-DD');
|
8029
|
+
|
8030
|
+
nextDays.push({
|
8031
|
+
date: _daySting3,
|
8032
|
+
text: formatDayWithTwoWords(nextFirstDate),
|
8033
|
+
isCurrentMonth: false,
|
8034
|
+
isCurrentDay: dayjs__default['default']().format('YYYY-MM-DD') == _daySting3
|
8035
|
+
});
|
8036
|
+
nextFirstDate++;
|
8037
|
+
} // 填充当前月天数
|
8038
|
+
else {
|
8039
|
+
// currentDays.push(i - currentWeekDay + 1);
|
8040
|
+
var _daySting4 = dayjs__default['default'](dayjs__default['default'](date).format(YEAER_MONTH_FORMAT_EN) + '-' + (i - currentWeekDay + 1)).format('YYYY-MM-DD');
|
8041
|
+
|
8042
|
+
currentDays.push({
|
8043
|
+
date: _daySting4,
|
8044
|
+
text: formatDayWithTwoWords(i - currentWeekDay + 1),
|
8045
|
+
isCurrentMonth: true,
|
8046
|
+
isCurrentDay: dayjs__default['default']().format('YYYY-MM-DD') == _daySting4
|
8047
|
+
});
|
8048
|
+
}
|
8049
|
+
} // 上个月需要倒序显示
|
8050
|
+
|
8051
|
+
|
8052
|
+
var dayArr = [].concat(_toConsumableArray(lastDays.reverse()), currentDays, nextDays);
|
8053
|
+
return lodashEs.chunk(dayArr, 7).map(function (day) {
|
8054
|
+
return [{
|
8055
|
+
content: content
|
8056
|
+
}].concat(_toConsumableArray(day));
|
8057
|
+
}).flat();
|
8058
|
+
}
|
7992
8059
|
/**
|
7993
8060
|
* 初始化日历
|
7994
8061
|
*/
|
@@ -8030,7 +8097,8 @@ function Calendar(_ref, ref) {
|
|
8030
8097
|
onCell = _ref.onCell,
|
8031
8098
|
calendarBodyClassName = _ref.calendarBodyClassName,
|
8032
8099
|
hiddenWeekLabel = _ref.hiddenWeekLabel,
|
8033
|
-
dateString = _ref.dateString
|
8100
|
+
dateString = _ref.dateString,
|
8101
|
+
customPrefix = _ref.customPrefix;
|
8034
8102
|
|
8035
8103
|
var _useState = React.useState(initCalendar()),
|
8036
8104
|
_useState2 = _slicedToArray(_useState, 2),
|
@@ -8047,7 +8115,8 @@ function Calendar(_ref, ref) {
|
|
8047
8115
|
oneWeekDays = _useState6[0],
|
8048
8116
|
setOneWeekDays = _useState6[1];
|
8049
8117
|
|
8050
|
-
var
|
8118
|
+
var customHeader = customPrefix ? [customPrefix.header] : [];
|
8119
|
+
var weekLabelArray = [].concat(customHeader, ['周一', '周二', '周三', '周四', '周五', '周六', '周日']);
|
8051
8120
|
|
8052
8121
|
var getweekDay = function getweekDay(date) {
|
8053
8122
|
var index = dayjs__default['default'](date).day();
|
@@ -8064,14 +8133,14 @@ function Calendar(_ref, ref) {
|
|
8064
8133
|
if (type == 'day') {
|
8065
8134
|
setOneWeekDays(['时间'].concat(_toConsumableArray(getweekDay(datevalue))));
|
8066
8135
|
} else {
|
8067
|
-
setOneWeekDays(getWeekList(datevalue));
|
8136
|
+
setOneWeekDays(_toConsumableArray(getWeekList(datevalue)));
|
8068
8137
|
}
|
8069
8138
|
|
8070
8139
|
setDays(initWeekCalendar(type, datevalue));
|
8071
8140
|
} else {
|
8072
|
-
setDays(initCalendar(dateString || datevalue));
|
8141
|
+
setDays((customPrefix === null || customPrefix === void 0 ? void 0 : customPrefix.content) ? initCustomPrefixCalendar(dateString || datevalue, customPrefix === null || customPrefix === void 0 ? void 0 : customPrefix.content) : initCalendar(dateString || datevalue));
|
8073
8142
|
}
|
8074
|
-
}, [type, datevalue, dateString]);
|
8143
|
+
}, [type, datevalue, dateString, customPrefix]);
|
8075
8144
|
React.useEffect(function () {
|
8076
8145
|
setDatevalue(value || dayjs__default['default']());
|
8077
8146
|
}, [value]);
|
@@ -8216,14 +8285,20 @@ function Calendar(_ref, ref) {
|
|
8216
8285
|
key: index
|
8217
8286
|
}, dateCellRender ? dateCellRender(day) : day.text) : null;
|
8218
8287
|
}))) : /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, !hiddenWeekLabel && /*#__PURE__*/React__default['default'].createElement("div", {
|
8219
|
-
className: "calendar_header_wrapper"
|
8288
|
+
className: "calendar_header_wrapper",
|
8289
|
+
style: {
|
8290
|
+
gridTemplateColumns: "repeat(".concat(weekLabelArray.length, ", 1fr)")
|
8291
|
+
}
|
8220
8292
|
}, weekLabelArray.map(function (weekLabel) {
|
8221
8293
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
8222
8294
|
key: weekLabel,
|
8223
8295
|
className: "flex ai-c jc-c"
|
8224
8296
|
}, weekLabel);
|
8225
8297
|
})), /*#__PURE__*/React__default['default'].createElement("div", {
|
8226
|
-
className: "content_wrapper ".concat(calendarBodyClassName)
|
8298
|
+
className: "content_wrapper ".concat(calendarBodyClassName),
|
8299
|
+
style: {
|
8300
|
+
gridTemplateColumns: "repeat(".concat(weekLabelArray.length, ", 1fr)")
|
8301
|
+
}
|
8227
8302
|
}, days === null || days === void 0 ? void 0 : days.map(function (day, index) {
|
8228
8303
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
8229
8304
|
onClick: function onClick() {
|
@@ -8231,7 +8306,7 @@ function Calendar(_ref, ref) {
|
|
8231
8306
|
},
|
8232
8307
|
className: "day_container ".concat(day.isCurrentDay ? 'isCurrentDay' : '', " ").concat(day.isCurrentMonth ? 'isCurrentMonth' : ''),
|
8233
8308
|
key: index
|
8234
|
-
}, dateCellRender ? dateCellRender(day) : day.text);
|
8309
|
+
}, (day === null || day === void 0 ? void 0 : day.content) ? day.content : dateCellRender ? dateCellRender(day) : day.text);
|
8235
8310
|
})))));
|
8236
8311
|
}
|
8237
8312
|
|
package/package.json
CHANGED
@@ -1,93 +1,93 @@
|
|
1
|
-
{
|
2
|
-
"private": false,
|
3
|
-
"name": "wargerm",
|
4
|
-
"version": "0.7.
|
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": "^3.3.1",
|
50
|
-
"animate.css": "^4.1.1",
|
51
|
-
"dayjs": "^1.11.7",
|
52
|
-
"echarts": "^5.2.2",
|
53
|
-
"echarts-for-react": "^3.0.2",
|
54
|
-
"lodash-es": "^4.17.21",
|
55
|
-
"react-countup": "^6.0.0",
|
56
|
-
"react-dom": "^17.0.2",
|
57
|
-
"react-file-viewer": "^1.2.1",
|
58
|
-
"swiper": "^6.7.0",
|
59
|
-
"use-sync-external-store": "^1.2.0",
|
60
|
-
"xgplayer": "^2.31.6",
|
61
|
-
"xgplayer-flv": "^2.5.1",
|
62
|
-
"xgplayer-flv.js": "^2.3.0",
|
63
|
-
"xgplayer-hls": "^2.5.2",
|
64
|
-
"xgplayer-hls.js": "^2.6.1"
|
65
|
-
},
|
66
|
-
"peerDependencies": {
|
67
|
-
"@ant-design/icons": ">=4.2.0",
|
68
|
-
"antd": ">=4.7.0",
|
69
|
-
"classnames": ">=2.2.0",
|
70
|
-
"echarts": "^5.2.2",
|
71
|
-
"echarts-for-react": "^3.0.2",
|
72
|
-
"lodash-es": ">=4.17.21",
|
73
|
-
"react": ">=17.0.0"
|
74
|
-
},
|
75
|
-
"devDependencies": {
|
76
|
-
"@ant-design/icons": "^4.6.4",
|
77
|
-
"@types/lodash-es": "^4.17.6",
|
78
|
-
"@types/react-dom": "^17.0.11",
|
79
|
-
"@types/use-sync-external-store": "^0.0.3",
|
80
|
-
"@umijs/test": "^3.0.5",
|
81
|
-
"antd": "^5.2.2",
|
82
|
-
"classnames": "^2.3.1",
|
83
|
-
"dumi": "^1.1.31",
|
84
|
-
"father-build": "^1.19.1",
|
85
|
-
"gh-pages": "^3.0.0",
|
86
|
-
"lint-staged": "^10.0.7",
|
87
|
-
"prettier": "^1.19.1",
|
88
|
-
"react": "^16.12.0",
|
89
|
-
"react-dnd": "^16.0.1",
|
90
|
-
"react-dnd-html5-backend": "^16.0.1",
|
91
|
-
"yorkie": "^2.0.0"
|
92
|
-
}
|
1
|
+
{
|
2
|
+
"private": false,
|
3
|
+
"name": "wargerm",
|
4
|
+
"version": "0.7.31",
|
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": "^3.3.1",
|
50
|
+
"animate.css": "^4.1.1",
|
51
|
+
"dayjs": "^1.11.7",
|
52
|
+
"echarts": "^5.2.2",
|
53
|
+
"echarts-for-react": "^3.0.2",
|
54
|
+
"lodash-es": "^4.17.21",
|
55
|
+
"react-countup": "^6.0.0",
|
56
|
+
"react-dom": "^17.0.2",
|
57
|
+
"react-file-viewer": "^1.2.1",
|
58
|
+
"swiper": "^6.7.0",
|
59
|
+
"use-sync-external-store": "^1.2.0",
|
60
|
+
"xgplayer": "^2.31.6",
|
61
|
+
"xgplayer-flv": "^2.5.1",
|
62
|
+
"xgplayer-flv.js": "^2.3.0",
|
63
|
+
"xgplayer-hls": "^2.5.2",
|
64
|
+
"xgplayer-hls.js": "^2.6.1"
|
65
|
+
},
|
66
|
+
"peerDependencies": {
|
67
|
+
"@ant-design/icons": ">=4.2.0",
|
68
|
+
"antd": ">=4.7.0",
|
69
|
+
"classnames": ">=2.2.0",
|
70
|
+
"echarts": "^5.2.2",
|
71
|
+
"echarts-for-react": "^3.0.2",
|
72
|
+
"lodash-es": ">=4.17.21",
|
73
|
+
"react": ">=17.0.0"
|
74
|
+
},
|
75
|
+
"devDependencies": {
|
76
|
+
"@ant-design/icons": "^4.6.4",
|
77
|
+
"@types/lodash-es": "^4.17.6",
|
78
|
+
"@types/react-dom": "^17.0.11",
|
79
|
+
"@types/use-sync-external-store": "^0.0.3",
|
80
|
+
"@umijs/test": "^3.0.5",
|
81
|
+
"antd": "^5.2.2",
|
82
|
+
"classnames": "^2.3.1",
|
83
|
+
"dumi": "^1.1.31",
|
84
|
+
"father-build": "^1.19.1",
|
85
|
+
"gh-pages": "^3.0.0",
|
86
|
+
"lint-staged": "^10.0.7",
|
87
|
+
"prettier": "^1.19.1",
|
88
|
+
"react": "^16.12.0",
|
89
|
+
"react-dnd": "^16.0.1",
|
90
|
+
"react-dnd-html5-backend": "^16.0.1",
|
91
|
+
"yorkie": "^2.0.0"
|
92
|
+
}
|
93
93
|
}
|