@para-ui/core 4.0.0-rc → 4.0.0-rc.1
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/AutoBox/index.d.ts +1 -1
- package/AutoBox/index.js +12 -12
- package/AutoTips/autoTipsMultiline/index.d.ts +1 -1
- package/AutoTips/index.d.ts +2 -2
- package/AutoTips/index.js +12 -12
- package/Badge/index.d.ts +23 -0
- package/Badge/index.js +54 -0
- package/Breadcrumbs/index.js +8 -8
- package/Button/SplitButton.d.ts +1 -1
- package/Button/index.d.ts +1 -1
- package/Button/index.js +3 -3
- package/Carousel/index.d.ts +6 -6
- package/Carousel/index.js +5 -5
- package/Cascader/Cascader.d.ts +10 -10
- package/Cascader/OptionList/Column.d.ts +3 -3
- package/Cascader/OptionList/index.d.ts +2 -2
- package/Cascader/index.d.ts +1 -1
- package/Cascader/index.js +4 -2
- package/Cascader/lang/en_US.d.ts +5 -0
- package/Cascader/lang/index.d.ts +11 -0
- package/Cascader/lang/zh_CN.d.ts +5 -0
- package/Cascader/utils/treeUtil.d.ts +1 -1
- package/Checkbox/index.d.ts +1 -1
- package/Checkbox/index.js +4 -4
- package/CheckboxGroup/index.d.ts +2 -2
- package/CheckboxGroup/index.js +3 -3
- package/Collapse/index.js +4 -4
- package/CollapseBox/index.js +12 -20
- package/CollapseLayout/index.js +20 -20
- package/ColorPicker/index.js +2 -2
- package/ComboSelect/index.js +43 -52
- package/ComboSelect/interface.d.ts +3 -3
- package/Container/index.d.ts +3 -3
- package/Container/index.js +56 -56
- package/CopyText/index.d.ts +2 -2
- package/DatePicker/generatePicker/index.d.ts +22 -22
- package/DatePicker/index.js +8 -7
- package/DatePicker/util.d.ts +1 -1
- package/Desktop/index.d.ts +1 -1
- package/Desktop/index.js +18 -13
- package/DragVerify/index.d.ts +1 -1
- package/DragVerify/index.js +13 -13
- package/Drawer/index.js +29 -33
- package/Drawer/interface.d.ts +2 -2
- package/Dropdown/index.d.ts +1 -1
- package/DynamicMultiBox/formItem.d.ts +1 -1
- package/DynamicMultiBox/index.d.ts +1 -1
- package/DynamicMultiBox/index.js +38 -35
- package/DynamicMultiBox/interface.d.ts +8 -8
- package/DynamicMultiBox/rowForm.d.ts +3 -1
- package/Empty/index.d.ts +1 -1
- package/Empty/index.js +2 -2
- package/Form/index.d.ts +12 -13
- package/Form/index.js +10 -8
- package/FormItem/compoments/defaultCompoments/index.d.ts +4 -4
- package/FormItem/compoments/formCheckboxGroup/index.d.ts +1 -1
- package/FormItem/compoments/formFile/index.d.ts +2 -2
- package/FormItem/compoments/formRadioGroup/index.d.ts +1 -1
- package/FormItem/compoments/formSelect/index.d.ts +7 -7
- package/FormItem/errorTips.d.ts +3 -3
- package/FormItem/index.d.ts +5 -5
- package/FormItem/index.js +3 -2
- package/FormItem/lang/en_US.d.ts +10 -0
- package/FormItem/lang/index.d.ts +21 -0
- package/FormItem/lang/zh_CN.d.ts +10 -0
- package/FormItem/validateFunction.d.ts +1 -1
- package/FunctionModal/dialog.d.ts +26 -26
- package/FunctionModal/index.d.ts +6 -6
- package/FunctionModal/index.js +6 -6
- package/FunctionModal/modalContext.d.ts +3 -3
- package/GlobalContext/componentsProps.d.ts +7 -7
- package/GlobalContext/index.d.ts +2 -2
- package/GlobalContext/useFormatMessage.d.ts +1 -1
- package/Help/index.js +1 -1
- package/HelperText/index.js +1 -1
- package/InputLang/index.d.ts +2 -2
- package/InputLang/index.js +8 -8
- package/InputNumber/index.d.ts +2 -2
- package/InputNumber/index.js +3 -3
- package/Label/index.js +2 -2
- package/Loading/index.js +1 -1
- package/Menu/index.js +14 -14
- package/Menu/interface.d.ts +1 -1
- package/Message/index.js +12 -12
- package/Modal/Confirm/index.d.ts +3 -3
- package/Modal/index.d.ts +1 -1
- package/Modal/index.js +5 -5
- package/MultiBox/index.d.ts +2 -2
- package/MultiBox/index.js +3 -3
- package/Notification/index.js +1 -1
- package/OperateBtn/index.d.ts +2 -2
- package/OperateBtn/index.js +40 -36
- package/PageHeader/index.js +30 -30
- package/PageHeader/interface.d.ts +1 -1
- package/Pagination/index.d.ts +1 -1
- package/Pagination/index.js +17 -17
- package/PasswordRules/index.js +7 -7
- package/PopConfirm/index.js +3 -3
- package/Progress/Line.d.ts +10 -10
- package/Progress/Steps.d.ts +2 -2
- package/Progress/index.d.ts +12 -12
- package/Progress/index.js +40 -40
- package/Progress/utils.d.ts +4 -4
- package/Querying/index.d.ts +1 -1
- package/Querying/index.js +2 -2
- package/README.md +3 -0
- package/Radio/index.d.ts +1 -1
- package/Radio/index.js +4 -4
- package/RadioGroup/index.d.ts +2 -2
- package/RadioGroup/index.js +3 -3
- package/Search/index.js +1 -1
- package/Select/index.d.ts +3 -3
- package/Select/index.js +42 -42
- package/SelectInput/index.js +2 -2
- package/Selector/index.js +15 -15
- package/Selector/interface.d.ts +6 -6
- package/SelectorPicker/index.d.ts +4 -4
- package/SelectorPicker/index.js +9 -9
- package/SingleBox/index.d.ts +2 -2
- package/SingleBox/index.js +3 -3
- package/Slider/interface.d.ts +1 -1
- package/Status/index.d.ts +4 -4
- package/Status/index.js +4 -4
- package/Stepper/index.d.ts +5 -5
- package/Stepper/index.js +23 -23
- package/Switch/index.d.ts +7 -7
- package/Switch/index.js +23 -5
- package/Switch/lang/en_US.d.ts +4 -0
- package/Switch/lang/index.d.ts +9 -0
- package/Switch/lang/zh_CN.d.ts +4 -0
- package/Table/index.js +34 -34
- package/Table/interface.d.ts +4 -4
- package/Table/tableBodyElement/index.d.ts +1 -1
- package/Table/tableBodyInterface.d.ts +2 -2
- package/Table/tableContainer/index.d.ts +1 -1
- package/Table/tableElement/index.d.ts +1 -1
- package/Table/tableHeadElement/index.d.ts +1 -1
- package/Table/tableHeadInterface.d.ts +1 -1
- package/Table/tablePaginationInterface.d.ts +6 -6
- package/Table/tdElement/index.d.ts +1 -1
- package/Table/thElement/index.d.ts +2 -2
- package/Table/trElement/index.d.ts +1 -1
- package/Table/util.d.ts +1 -1
- package/Tabs/index.d.ts +1 -1
- package/Tabs/index.js +25 -17
- package/Tag/TagGroup.d.ts +5 -5
- package/Tag/index.d.ts +7 -7
- package/Tag/index.js +25 -25
- package/TextEditor/index.d.ts +2 -2
- package/TextEditor/index.js +45 -27
- package/TextEditor/lang/en_US.d.ts +4 -0
- package/TextEditor/lang/index.d.ts +9 -0
- package/TextEditor/lang/zh_CN.d.ts +4 -0
- package/TextField/index.d.ts +1 -1
- package/TextField/index.js +13 -13
- package/TimePicker/index.d.ts +1 -1
- package/TimePicker/index.js +1 -1
- package/Timeline/TimelineItem.d.ts +1 -1
- package/Timeline/index.d.ts +5 -5
- package/Timeline/index.js +14 -14
- package/Title/index.d.ts +4 -4
- package/Title/index.js +3 -3
- package/ToggleButton/ToggleButtonGroup.d.ts +1 -1
- package/ToggleButton/index.d.ts +5 -1
- package/ToggleButton/index.js +17 -10
- package/Transfer/box.d.ts +6 -6
- package/Transfer/index.js +21 -21
- package/Tree/OperateBar/index.d.ts +4 -4
- package/Tree/Tree.d.ts +2 -2
- package/Tree/index.js +2 -2
- package/Tree/interface.d.ts +4 -4
- package/Tree/utils/tools.d.ts +1 -1
- package/Upload/Dragger/index.d.ts +2 -2
- package/Upload/ErroTip/index.d.ts +1 -1
- package/Upload/index.d.ts +2 -2
- package/Upload/index.js +7 -7
- package/Upload/interface.d.ts +1 -1
- package/_verture/{index-8469865e.js → index-0f315bca.js} +2 -2
- package/_verture/{index-e1b800aa.js → index-92e406f4.js} +48 -24
- package/_verture/{index-47297a40.js → index-bc461491.js} +45 -45
- package/_verture/{index-1c8d3e94.js → index-d251967e.js} +101 -47
- package/_verture/{modalContext-670eab09.js → modalContext-9299acc9.js} +25 -25
- package/index.d.ts +2 -0
- package/index.js +8 -7
- package/locale/en-US.d.ts +19 -0
- package/locale/index.d.ts +38 -0
- package/locale/index.js +39 -1
- package/locale/zh-CN.d.ts +19 -0
- package/package.json +3 -1
- package/umd/AutoBox.js +1 -1
- package/umd/AutoTips.js +1 -1
- package/umd/Badge.js +1 -0
- package/umd/Breadcrumbs.js +1 -1
- package/umd/Button.js +2 -2
- package/umd/ButtonGroup.js +2 -2
- package/umd/Cascader.js +5 -5
- package/umd/Checkbox.js +1 -1
- package/umd/CheckboxGroup.js +1 -1
- package/umd/Collapse.js +1 -1
- package/umd/CollapseBox.js +1 -1
- package/umd/CollapseLayout.js +4 -4
- package/umd/ComboSelect.js +4 -4
- package/umd/CopyText.js +1 -1
- package/umd/DatePicker.js +2 -2
- package/umd/Desktop.js +2 -2
- package/umd/DragVerify.js +4 -4
- package/umd/Drawer.js +2 -2
- package/umd/DynamicMultiBox.js +4 -4
- package/umd/Form.js +4 -4
- package/umd/FormItem.js +4 -4
- package/umd/FunctionModal.js +2 -2
- package/umd/Help.js +1 -1
- package/umd/HelperText.js +1 -1
- package/umd/InputLang.js +1 -1
- package/umd/InputNumber.js +1 -1
- package/umd/Label.js +1 -1
- package/umd/Loading.js +1 -1
- package/umd/Menu.js +2 -2
- package/umd/Message.js +1 -1
- package/umd/Modal.js +2 -2
- package/umd/MultiBox.js +7 -7
- package/umd/Notification.js +1 -1
- package/umd/OperateBtn.js +2 -2
- package/umd/PageHeader.js +2 -2
- package/umd/Pagination.js +4 -4
- package/umd/PasswordRules.js +4 -4
- package/umd/PopConfirm.js +2 -2
- package/umd/Progress.js +1 -1
- package/umd/Radio.js +1 -1
- package/umd/RadioGroup.js +1 -1
- package/umd/Search.js +7 -7
- package/umd/Select.js +1 -1
- package/umd/SelectInput.js +1 -1
- package/umd/Selector.js +1 -1
- package/umd/SelectorPicker.js +1 -1
- package/umd/SingleBox.js +1 -1
- package/umd/Stepper.js +1 -1
- package/umd/Switch.js +4 -4
- package/umd/Table.js +2 -2
- package/umd/Tabs.js +4 -4
- package/umd/Tag.js +1 -1
- package/umd/TextEditor.js +2 -2
- package/umd/TextField.js +7 -7
- package/umd/TimePicker.js +2 -2
- package/umd/Title.js +1 -1
- package/umd/ToggleButton.js +4 -4
- package/umd/Transfer.js +2 -2
- package/umd/Tree.js +1 -1
- package/umd/Upload.js +2 -2
- package/umd/locale.js +1 -1
package/PageHeader/index.js
CHANGED
|
@@ -50,7 +50,7 @@ var handHref = function handHref() {
|
|
|
50
50
|
var lastOne = !children || children.length === 0;
|
|
51
51
|
if (lastOne) {
|
|
52
52
|
return {
|
|
53
|
-
href: href ? href :
|
|
53
|
+
href: href ? href : "#".concat(path)
|
|
54
54
|
};
|
|
55
55
|
}
|
|
56
56
|
return {};
|
|
@@ -185,7 +185,7 @@ var MenuItemPopper = function MenuItemPopper(props) {
|
|
|
185
185
|
var handPopoverClass = function handPopoverClass() {
|
|
186
186
|
var str = 'menu-item-popper';
|
|
187
187
|
if (level !== 1) str += ' menu-item-popper-child';
|
|
188
|
-
if (className) str +=
|
|
188
|
+
if (className) str += " ".concat(className);
|
|
189
189
|
return str;
|
|
190
190
|
};
|
|
191
191
|
/**
|
|
@@ -274,7 +274,7 @@ var HorizontalMenu = function HorizontalMenu(props) {
|
|
|
274
274
|
_useState16 = _slicedToArray(_useState15, 2),
|
|
275
275
|
childList = _useState16[0],
|
|
276
276
|
setChildList = _useState16[1]; // 侧边子菜单数据
|
|
277
|
-
var _useState17 = useState(
|
|
277
|
+
var _useState17 = useState(''),
|
|
278
278
|
_useState18 = _slicedToArray(_useState17, 2),
|
|
279
279
|
selectMenuCom = _useState18[0],
|
|
280
280
|
setSelectMenuCom = _useState18[1]; // 当前选中菜单id
|
|
@@ -300,9 +300,9 @@ var HorizontalMenu = function HorizontalMenu(props) {
|
|
|
300
300
|
useEffect(function () {
|
|
301
301
|
handList(list || []);
|
|
302
302
|
changeSize();
|
|
303
|
-
window.addEventListener(
|
|
303
|
+
window.addEventListener('resize', changeSize);
|
|
304
304
|
return function () {
|
|
305
|
-
window.removeEventListener(
|
|
305
|
+
window.removeEventListener('resize', changeSize);
|
|
306
306
|
clearTimeout(timerJson.timerResize);
|
|
307
307
|
};
|
|
308
308
|
}, [list]);
|
|
@@ -464,7 +464,7 @@ var HorizontalMenu = function HorizontalMenu(props) {
|
|
|
464
464
|
*/
|
|
465
465
|
var handClass = function handClass() {
|
|
466
466
|
var str = 'horizontal-menu-list';
|
|
467
|
-
if (className) str +=
|
|
467
|
+
if (className) str += " ".concat(className);
|
|
468
468
|
return str;
|
|
469
469
|
};
|
|
470
470
|
/**
|
|
@@ -509,9 +509,9 @@ var HorizontalMenu = function HorizontalMenu(props) {
|
|
|
509
509
|
return jsx(Popover, Object.assign({
|
|
510
510
|
visible: openChildIndex === index,
|
|
511
511
|
trigger: 'hover',
|
|
512
|
-
placement:
|
|
512
|
+
placement: 'bottom-start',
|
|
513
513
|
content: MenuItemPopperMemo,
|
|
514
|
-
overlayClassName: $prefixCls
|
|
514
|
+
overlayClassName: "".concat($prefixCls, "-horizontal-menu-popper"),
|
|
515
515
|
onVisibleChange: onVisibleChange
|
|
516
516
|
}, {
|
|
517
517
|
children: jsxs(Ele, Object.assign({
|
|
@@ -544,9 +544,9 @@ var HorizontalMenu = function HorizontalMenu(props) {
|
|
|
544
544
|
return jsx(Popover, Object.assign({
|
|
545
545
|
visible: openChildIndex === morePos,
|
|
546
546
|
trigger: 'hover',
|
|
547
|
-
placement:
|
|
547
|
+
placement: 'bottom-start',
|
|
548
548
|
content: MenuItemPopperMemo,
|
|
549
|
-
overlayClassName: $prefixCls
|
|
549
|
+
overlayClassName: "".concat($prefixCls, "-horizontal-menu-popper"),
|
|
550
550
|
onVisibleChange: onVisibleChange
|
|
551
551
|
}, {
|
|
552
552
|
children: jsx("div", Object.assign({
|
|
@@ -586,9 +586,9 @@ var BackSelfcare = function BackSelfcare(props) {
|
|
|
586
586
|
var handContent = function handContent() {
|
|
587
587
|
return jsx(Button, Object.assign({
|
|
588
588
|
startIcon: icon,
|
|
589
|
-
variant:
|
|
589
|
+
variant: 'contained',
|
|
590
590
|
onClick: onClickCom,
|
|
591
|
-
size:
|
|
591
|
+
size: 'small'
|
|
592
592
|
}, {
|
|
593
593
|
children: label
|
|
594
594
|
}));
|
|
@@ -599,7 +599,7 @@ var BackSelfcare = function BackSelfcare(props) {
|
|
|
599
599
|
*/
|
|
600
600
|
var handClass = function handClass() {
|
|
601
601
|
var str = 'back-btn';
|
|
602
|
-
if (className) str +=
|
|
602
|
+
if (className) str += " ".concat(className);
|
|
603
603
|
return str;
|
|
604
604
|
};
|
|
605
605
|
return jsx(Fragment, {
|
|
@@ -623,7 +623,7 @@ var Help = function Help(props) {
|
|
|
623
623
|
*/
|
|
624
624
|
var handClass = function handClass() {
|
|
625
625
|
var str = 'help-btn';
|
|
626
|
-
if (className) str +=
|
|
626
|
+
if (className) str += " ".concat(className);
|
|
627
627
|
return str;
|
|
628
628
|
};
|
|
629
629
|
return jsx(Fragment, {
|
|
@@ -692,7 +692,7 @@ var Language = function Language(props) {
|
|
|
692
692
|
*/
|
|
693
693
|
var handClass = function handClass() {
|
|
694
694
|
var str = 'language';
|
|
695
|
-
if (className) str +=
|
|
695
|
+
if (className) str += " ".concat(className);
|
|
696
696
|
if (showDialog) str += ' language-select';
|
|
697
697
|
return str;
|
|
698
698
|
};
|
|
@@ -760,9 +760,9 @@ var Language = function Language(props) {
|
|
|
760
760
|
return jsx(Popover, Object.assign({
|
|
761
761
|
trigger: 'hover',
|
|
762
762
|
visible: showDialog,
|
|
763
|
-
placement:
|
|
763
|
+
placement: 'bottom-start',
|
|
764
764
|
content: selectPopover(),
|
|
765
|
-
overlayClassName: $prefixCls
|
|
765
|
+
overlayClassName: "".concat($prefixCls, "-horizontal-meun-right-popover"),
|
|
766
766
|
onVisibleChange: onVisibleChange
|
|
767
767
|
}, {
|
|
768
768
|
children: jsx("div", Object.assign({
|
|
@@ -793,7 +793,7 @@ var BtnList = function BtnList(props) {
|
|
|
793
793
|
*/
|
|
794
794
|
var handClass = function handClass() {
|
|
795
795
|
var str = 'btn-list';
|
|
796
|
-
if (className) str +=
|
|
796
|
+
if (className) str += " ".concat(className);
|
|
797
797
|
return str;
|
|
798
798
|
};
|
|
799
799
|
/**
|
|
@@ -920,10 +920,10 @@ var UserMenuChildren = function UserMenuChildren(props) {
|
|
|
920
920
|
return jsx(Popover, Object.assign({
|
|
921
921
|
visible: showDialogCom,
|
|
922
922
|
trigger: 'hover',
|
|
923
|
-
placement:
|
|
923
|
+
placement: 'left-start',
|
|
924
924
|
content: handPopoverContent(),
|
|
925
925
|
onVisibleChange: onVisibleChange,
|
|
926
|
-
overlayClassName: $prefixCls
|
|
926
|
+
overlayClassName: "".concat($prefixCls, "-horizontal-meun-right-popover ").concat($prefixCls, "-horizontal-meun-right-popover-children")
|
|
927
927
|
}, {
|
|
928
928
|
children: jsxs("div", Object.assign({
|
|
929
929
|
className: handMenuClassItem(),
|
|
@@ -1014,7 +1014,7 @@ var User = function User(props) {
|
|
|
1014
1014
|
var recurrenceFunc = function recurrenceFunc(daraChildArr, parent) {
|
|
1015
1015
|
for (var i = 0, l = daraChildArr.length; i < l; i++) {
|
|
1016
1016
|
var item = daraChildArr[i];
|
|
1017
|
-
item._paraui_menu_id =
|
|
1017
|
+
item._paraui_menu_id = "_paraui_menu_id_".concat(UUID()); // 设置唯一id
|
|
1018
1018
|
json[item._paraui_menu_id] = item;
|
|
1019
1019
|
if (parent) {
|
|
1020
1020
|
var idList = DeepClone(idMap[parent._paraui_menu_id] || []);
|
|
@@ -1075,7 +1075,7 @@ var User = function User(props) {
|
|
|
1075
1075
|
var handStyleWidth = function handStyleWidth() {
|
|
1076
1076
|
var styleJson = {};
|
|
1077
1077
|
if (posDom && posDom.current) {
|
|
1078
|
-
styleJson.width = posDom.current.getBoundingClientRect().width
|
|
1078
|
+
styleJson.width = "".concat(posDom.current.getBoundingClientRect().width, "px");
|
|
1079
1079
|
}
|
|
1080
1080
|
return styleJson;
|
|
1081
1081
|
};
|
|
@@ -1126,7 +1126,7 @@ var User = function User(props) {
|
|
|
1126
1126
|
*/
|
|
1127
1127
|
var handClass = function handClass() {
|
|
1128
1128
|
var str = 'logo';
|
|
1129
|
-
if (className) str +=
|
|
1129
|
+
if (className) str += " ".concat(className);
|
|
1130
1130
|
if (showDialog) str += ' logo-show-dialog';
|
|
1131
1131
|
return str;
|
|
1132
1132
|
};
|
|
@@ -1134,9 +1134,9 @@ var User = function User(props) {
|
|
|
1134
1134
|
children: render ? render : jsx(Popover, Object.assign({
|
|
1135
1135
|
trigger: 'hover',
|
|
1136
1136
|
visible: showDialog,
|
|
1137
|
-
placement:
|
|
1137
|
+
placement: 'bottom-start',
|
|
1138
1138
|
content: selectPopover(),
|
|
1139
|
-
overlayClassName: $prefixCls
|
|
1139
|
+
overlayClassName: "".concat($prefixCls, "-horizontal-meun-right-popover"),
|
|
1140
1140
|
onVisibleChange: onVisibleChange
|
|
1141
1141
|
}, {
|
|
1142
1142
|
children: jsx("div", Object.assign({
|
|
@@ -1164,7 +1164,7 @@ var HorizontalMeunRight = function HorizontalMeunRight(props) {
|
|
|
1164
1164
|
*/
|
|
1165
1165
|
var handClass = function handClass() {
|
|
1166
1166
|
var str = 'horizontal-meun-right';
|
|
1167
|
-
if (className) str +=
|
|
1167
|
+
if (className) str += " ".concat(className);
|
|
1168
1168
|
return str;
|
|
1169
1169
|
};
|
|
1170
1170
|
/** 返回自助服务 */
|
|
@@ -1209,14 +1209,14 @@ var PageHeader = function PageHeader(props) {
|
|
|
1209
1209
|
style = props.style;
|
|
1210
1210
|
var LeftMemo = useMemo(function () {
|
|
1211
1211
|
return leftRender && jsx("div", Object.assign({
|
|
1212
|
-
className:
|
|
1212
|
+
className: "page-header-left"
|
|
1213
1213
|
}, {
|
|
1214
1214
|
children: leftRender
|
|
1215
1215
|
}));
|
|
1216
1216
|
}, [leftRender]);
|
|
1217
1217
|
var MenuMemo = useMemo(function () {
|
|
1218
1218
|
return props.menuListProps && jsx("div", Object.assign({
|
|
1219
|
-
className:
|
|
1219
|
+
className: "menu-box"
|
|
1220
1220
|
}, {
|
|
1221
1221
|
children: jsx(HorizontalMenu, Object.assign({}, menuListProps, {
|
|
1222
1222
|
selectMenu: selectMenu,
|
|
@@ -1231,8 +1231,8 @@ var PageHeader = function PageHeader(props) {
|
|
|
1231
1231
|
* 处理class
|
|
1232
1232
|
*/
|
|
1233
1233
|
var handClass = function handClass() {
|
|
1234
|
-
var str = $prefixCls
|
|
1235
|
-
if (className) str +=
|
|
1234
|
+
var str = "".concat($prefixCls, "-page-header");
|
|
1235
|
+
if (className) str += " ".concat(className);
|
|
1236
1236
|
return str;
|
|
1237
1237
|
};
|
|
1238
1238
|
return jsxs("div", Object.assign({
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import React, { ReactNode } from 'react';
|
|
7
7
|
/** 菜单类型 */
|
|
8
|
-
export type MenuListTypeType = 'redirect' | 'router' |
|
|
8
|
+
export type MenuListTypeType = 'redirect' | 'router' | 'iframe' | 'snack' | 'snackPage';
|
|
9
9
|
/** 菜单列表项参数 */
|
|
10
10
|
export interface MenuChildrenProps {
|
|
11
11
|
/** 样式class */
|
package/Pagination/index.d.ts
CHANGED
package/Pagination/index.js
CHANGED
|
@@ -48,7 +48,7 @@ import '../Popover/index.js';
|
|
|
48
48
|
|
|
49
49
|
var en = {
|
|
50
50
|
total: 'Total {total}',
|
|
51
|
-
barPage: '
|
|
51
|
+
barPage: ' / page',
|
|
52
52
|
prevPage: 'Prev',
|
|
53
53
|
nextPage: 'Next',
|
|
54
54
|
jumpTo: 'Go to',
|
|
@@ -129,7 +129,7 @@ var Pagination = function Pagination(props) {
|
|
|
129
129
|
constData.current.autoType = autoType;
|
|
130
130
|
useEffect(function () {
|
|
131
131
|
return function () {
|
|
132
|
-
window.removeEventListener(
|
|
132
|
+
window.removeEventListener('resize', changeSize);
|
|
133
133
|
clearTimeout(constData.current.timer);
|
|
134
134
|
clearTimeout(constData.current.timerClass);
|
|
135
135
|
clearTimeout(constData.current.changePagination);
|
|
@@ -175,9 +175,9 @@ var Pagination = function Pagination(props) {
|
|
|
175
175
|
if (type === 'complex' && autoType) {
|
|
176
176
|
changeSize();
|
|
177
177
|
// 复杂模式,且开启自适应模式
|
|
178
|
-
window.addEventListener(
|
|
178
|
+
window.addEventListener('resize', changeSize);
|
|
179
179
|
} else {
|
|
180
|
-
window.removeEventListener(
|
|
180
|
+
window.removeEventListener('resize', changeSize);
|
|
181
181
|
setTypeCom(type);
|
|
182
182
|
}
|
|
183
183
|
}, [type, autoType]);
|
|
@@ -213,7 +213,7 @@ var Pagination = function Pagination(props) {
|
|
|
213
213
|
clearTimeout(constData.current.timerClass);
|
|
214
214
|
var current = refDom.current;
|
|
215
215
|
if (!current) return;
|
|
216
|
-
current.classList.add($prefixCls
|
|
216
|
+
current.classList.add("".concat($prefixCls, "-pagination-over"));
|
|
217
217
|
constData.current.timer = setTimeout(function () {
|
|
218
218
|
if (!current) return;
|
|
219
219
|
var skipDom = current.querySelector('.skip-page-memo');
|
|
@@ -229,7 +229,7 @@ var Pagination = function Pagination(props) {
|
|
|
229
229
|
changeSize();
|
|
230
230
|
}
|
|
231
231
|
constData.current.timerClass = setTimeout(function () {
|
|
232
|
-
current.classList.remove($prefixCls
|
|
232
|
+
current.classList.remove("".concat($prefixCls, "-pagination-over"));
|
|
233
233
|
}, 200);
|
|
234
234
|
}, 200);
|
|
235
235
|
};
|
|
@@ -248,7 +248,7 @@ var Pagination = function Pagination(props) {
|
|
|
248
248
|
if (pageCom === 1) return;
|
|
249
249
|
num = 1;
|
|
250
250
|
break;*/
|
|
251
|
-
case
|
|
251
|
+
case 'prev':
|
|
252
252
|
if (pageCom === 1) return;
|
|
253
253
|
num--;
|
|
254
254
|
break;
|
|
@@ -256,11 +256,11 @@ var Pagination = function Pagination(props) {
|
|
|
256
256
|
if (pageCom === totalPage) return;
|
|
257
257
|
num = totalPage;
|
|
258
258
|
break;*/
|
|
259
|
-
case
|
|
259
|
+
case 'next':
|
|
260
260
|
if (pageCom === totalPage) return;
|
|
261
261
|
num++;
|
|
262
262
|
break;
|
|
263
|
-
case
|
|
263
|
+
case 'pagination':
|
|
264
264
|
num = value;
|
|
265
265
|
break;
|
|
266
266
|
}
|
|
@@ -305,7 +305,7 @@ var Pagination = function Pagination(props) {
|
|
|
305
305
|
};
|
|
306
306
|
var formatNumber = function formatNumber(num) {
|
|
307
307
|
var reg = /(?=(\B)(\d{3})+$)/g;
|
|
308
|
-
return num.toString().replace(reg,
|
|
308
|
+
return num.toString().replace(reg, ',');
|
|
309
309
|
};
|
|
310
310
|
/* 总数量 */
|
|
311
311
|
var TotalMemo = useMemo(function () {
|
|
@@ -334,7 +334,7 @@ var Pagination = function Pagination(props) {
|
|
|
334
334
|
}, {
|
|
335
335
|
children: jsx(Select, {
|
|
336
336
|
className: 'page-line-select',
|
|
337
|
-
size:
|
|
337
|
+
size: 'large',
|
|
338
338
|
value: currentRowsPerPageCom,
|
|
339
339
|
list: rowsPerPageCom,
|
|
340
340
|
hideErrorDom: true,
|
|
@@ -382,7 +382,7 @@ var Pagination = function Pagination(props) {
|
|
|
382
382
|
children: jsx(NavigateBefore, {})
|
|
383
383
|
}))
|
|
384
384
|
})), jsx(PaginationCom, {
|
|
385
|
-
prefixCls: $rcPrefixCls
|
|
385
|
+
prefixCls: "".concat($rcPrefixCls, "-pagination"),
|
|
386
386
|
current: pageCom,
|
|
387
387
|
pageSize: currentRowsPerPageCom,
|
|
388
388
|
total: total,
|
|
@@ -412,7 +412,7 @@ var Pagination = function Pagination(props) {
|
|
|
412
412
|
}, {
|
|
413
413
|
children: [jsx(Button, Object.assign({
|
|
414
414
|
variant: "outlined",
|
|
415
|
-
size:
|
|
415
|
+
size: 'large',
|
|
416
416
|
startIcon: jsx(NavigateBefore, {}),
|
|
417
417
|
onClick: clickPage('prev'),
|
|
418
418
|
disabled: pageCom === 1
|
|
@@ -422,7 +422,7 @@ var Pagination = function Pagination(props) {
|
|
|
422
422
|
})
|
|
423
423
|
})), jsx(Button, Object.assign({
|
|
424
424
|
variant: "outlined",
|
|
425
|
-
size:
|
|
425
|
+
size: 'large',
|
|
426
426
|
endIcon: jsx(Right, {}),
|
|
427
427
|
onClick: clickPage('next'),
|
|
428
428
|
disabled: pageCom === totalPage
|
|
@@ -447,7 +447,7 @@ var Pagination = function Pagination(props) {
|
|
|
447
447
|
})
|
|
448
448
|
}), jsx(TextField, {
|
|
449
449
|
className: 'skip-page-text-field',
|
|
450
|
-
size:
|
|
450
|
+
size: 'large',
|
|
451
451
|
type: "number",
|
|
452
452
|
value: skipValue || '',
|
|
453
453
|
onChange: changeSkipValue,
|
|
@@ -463,12 +463,12 @@ var Pagination = function Pagination(props) {
|
|
|
463
463
|
}, [skipValue, totalPage, language, locale, typeCom]);
|
|
464
464
|
// 处理class
|
|
465
465
|
var handClass = function handClass() {
|
|
466
|
-
var str = $prefixCls
|
|
466
|
+
var str = "".concat($prefixCls, "-pagination");
|
|
467
467
|
/*if (flippingArrow.indexOf('first') === -1 && flippingArrow.indexOf('prev') === -1)
|
|
468
468
|
str += ' ' + $prefixCls + '-pagination-no-left-arrow';
|
|
469
469
|
if (flippingArrow.indexOf('next') === -1 && flippingArrow.indexOf('last') === -1)
|
|
470
470
|
str += ' ' + $prefixCls + '-pagination-no-right-arrow';*/
|
|
471
|
-
if (className) str +=
|
|
471
|
+
if (className) str += " ".concat(className);
|
|
472
472
|
return str;
|
|
473
473
|
};
|
|
474
474
|
return jsxs("div", Object.assign({
|
package/PasswordRules/index.js
CHANGED
|
@@ -73,21 +73,21 @@ var PasswordRules = function PasswordRules(props) {
|
|
|
73
73
|
// 处理标志
|
|
74
74
|
var handFlag = function handFlag() {
|
|
75
75
|
if (type === 'order') {
|
|
76
|
-
return inx + 1
|
|
76
|
+
return "".concat(inx + 1, "\u3001");
|
|
77
77
|
}
|
|
78
78
|
if (result === true) return jsx(CompleteIcon, {}); // 成功
|
|
79
79
|
return jsx(CloseCircleF, {});
|
|
80
80
|
};
|
|
81
81
|
// 处理内容
|
|
82
82
|
var handLabel = function handLabel() {
|
|
83
|
-
if (typeof result !==
|
|
83
|
+
if (typeof result !== 'boolean' && result) return result;
|
|
84
84
|
return listItem.label;
|
|
85
85
|
};
|
|
86
86
|
// 处理样式
|
|
87
87
|
var handClassRulesItem = function handClassRulesItem() {
|
|
88
88
|
var str = 'rules-item-detail';
|
|
89
|
-
str +=
|
|
90
|
-
if (typeof result ===
|
|
89
|
+
str += " rules-item-detail-".concat(type);
|
|
90
|
+
if (typeof result === 'boolean' && result) {
|
|
91
91
|
str += ' rules-item-detail-success';
|
|
92
92
|
} else {
|
|
93
93
|
if (result !== undefined) str += ' rules-item-detail-error';
|
|
@@ -118,9 +118,9 @@ var PasswordRules = function PasswordRules(props) {
|
|
|
118
118
|
};
|
|
119
119
|
/** 处理className */
|
|
120
120
|
var handClass = function handClass() {
|
|
121
|
-
var str = $prefixCls
|
|
122
|
-
if (className) str +=
|
|
123
|
-
if (boxShadow) str +=
|
|
121
|
+
var str = "".concat($prefixCls, "-password-rules");
|
|
122
|
+
if (className) str += " ".concat(className);
|
|
123
|
+
if (boxShadow) str += " ".concat($prefixCls, "-password-rules-box-shadow");
|
|
124
124
|
return str;
|
|
125
125
|
};
|
|
126
126
|
return jsx("div", Object.assign({
|
package/PopConfirm/index.js
CHANGED
|
@@ -202,15 +202,15 @@ var PopConfirm = function PopConfirm(props) {
|
|
|
202
202
|
className: 'popconfirm-message-body'
|
|
203
203
|
}, {
|
|
204
204
|
children: [title && jsx("div", Object.assign({
|
|
205
|
-
className:
|
|
205
|
+
className: "popconfirm-message-title"
|
|
206
206
|
}, {
|
|
207
207
|
children: title
|
|
208
208
|
})), content && jsx("div", Object.assign({
|
|
209
|
-
className:
|
|
209
|
+
className: "popconfirm-message-content"
|
|
210
210
|
}, {
|
|
211
211
|
children: content
|
|
212
212
|
})), description && jsx("div", Object.assign({
|
|
213
|
-
className:
|
|
213
|
+
className: "popconfirm-message-description"
|
|
214
214
|
}, {
|
|
215
215
|
children: description
|
|
216
216
|
}))]
|
package/Progress/Line.d.ts
CHANGED
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
* @date 2022/3/10 18:25
|
|
4
4
|
* @description 线性进度条
|
|
5
5
|
*/
|
|
6
|
-
import * as React from
|
|
7
|
-
import { ProgressProps, StringGradients, DirectionType } from
|
|
6
|
+
import * as React from 'react';
|
|
7
|
+
import { ProgressProps, StringGradients, DirectionType } from './index';
|
|
8
8
|
interface LineProps extends ProgressProps {
|
|
9
9
|
direction?: DirectionType;
|
|
10
10
|
children: React.ReactNode;
|
|
11
11
|
}
|
|
12
12
|
/**
|
|
13
|
-
* 转换 百分比 到 样式格式
|
|
13
|
+
* 转换 百分比 到 样式格式
|
|
14
14
|
* {
|
|
15
15
|
* "0%": "#afc163",
|
|
16
16
|
* "75%": "#009900",
|
|
@@ -18,12 +18,12 @@ interface LineProps extends ProgressProps {
|
|
|
18
18
|
* "25%": "#66FF00",
|
|
19
19
|
* "100%": "#ffffff"
|
|
20
20
|
* }
|
|
21
|
-
* @param gradients 渐变的参数
|
|
22
|
-
* @return {string} 样式值
|
|
23
|
-
*/
|
|
21
|
+
* @param gradients 渐变的参数
|
|
22
|
+
* @return {string} 样式值
|
|
23
|
+
*/
|
|
24
24
|
export declare const sortGradient: (gradients: StringGradients) => string;
|
|
25
25
|
/**
|
|
26
|
-
* 转换传进来 渐变的参数 为css样式
|
|
26
|
+
* 转换传进来 渐变的参数 为css样式
|
|
27
27
|
* {
|
|
28
28
|
* "0%": "#afc163",
|
|
29
29
|
* "25%": "#66FF00",
|
|
@@ -37,9 +37,9 @@ export declare const sortGradient: (gradients: StringGradients) => string;
|
|
|
37
37
|
* "to": "#66FF00",// ====> linear-gradient(to right, #afc163, #66FF00)
|
|
38
38
|
* }
|
|
39
39
|
*
|
|
40
|
-
* @param {string} strokeColor 颜色值
|
|
41
|
-
* @return 返回 backgroundImage 的样式值
|
|
42
|
-
*/
|
|
40
|
+
* @param {string} strokeColor 颜色值
|
|
41
|
+
* @return 返回 backgroundImage 的样式值
|
|
42
|
+
*/
|
|
43
43
|
export declare const handleGradient: (strokeColor: any, directionConfig: DirectionType) => {
|
|
44
44
|
backgroundImage: string;
|
|
45
45
|
};
|
package/Progress/Steps.d.ts
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
* @date 2022/3/10 18:25
|
|
4
4
|
* @description 进度条的步骤条
|
|
5
5
|
*/
|
|
6
|
-
import * as React from
|
|
7
|
-
import { ProgressProps } from
|
|
6
|
+
import * as React from 'react';
|
|
7
|
+
import { ProgressProps } from './index';
|
|
8
8
|
interface StepsProps extends ProgressProps {
|
|
9
9
|
/** 一共有多少步 **/
|
|
10
10
|
steps: number;
|
package/Progress/index.d.ts
CHANGED
|
@@ -3,21 +3,21 @@
|
|
|
3
3
|
* @date 2022/3/10 18:25
|
|
4
4
|
* @description 进度条
|
|
5
5
|
*/
|
|
6
|
-
import React, { FunctionComponent } from
|
|
7
|
-
import
|
|
6
|
+
import React, { FunctionComponent } from 'react';
|
|
7
|
+
import './index.scss';
|
|
8
8
|
/** 进度条类型 **/
|
|
9
9
|
declare enum ProgressTypes {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
'line' = 0,
|
|
11
|
+
'circle' = 1,
|
|
12
|
+
'dashboard' = 2
|
|
13
13
|
}
|
|
14
14
|
export type ProgressType = typeof ProgressTypes[number];
|
|
15
15
|
/** 进度条状态 **/
|
|
16
16
|
declare enum ProgressStatuses {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
17
|
+
'normal' = 0,
|
|
18
|
+
'exception' = 1,
|
|
19
|
+
'active' = 2,
|
|
20
|
+
'success' = 3
|
|
21
21
|
}
|
|
22
22
|
/** 渐变进度条入参格式 两种 **/
|
|
23
23
|
export type StringGradients = {
|
|
@@ -32,7 +32,7 @@ export type ProgressGradient = {
|
|
|
32
32
|
direction?: string;
|
|
33
33
|
} & (StringGradients | FromToGradients);
|
|
34
34
|
/** 进度条渐变方向 **/
|
|
35
|
-
export type DirectionType =
|
|
35
|
+
export type DirectionType = 'ltr' | 'rtl' | undefined;
|
|
36
36
|
/** 成功的进度条的配置 **/
|
|
37
37
|
export interface SuccessProps {
|
|
38
38
|
/** 进度条值 **/
|
|
@@ -58,7 +58,7 @@ export interface ProgressProps {
|
|
|
58
58
|
/** 进度条线的宽度,单位 px **/
|
|
59
59
|
strokeWidth?: number;
|
|
60
60
|
/** 进度条的样式 **/
|
|
61
|
-
strokeLinecap?:
|
|
61
|
+
strokeLinecap?: 'butt' | 'square' | 'round';
|
|
62
62
|
/** 进度条的色彩 **/
|
|
63
63
|
strokeColor?: string | ({
|
|
64
64
|
direction?: string;
|
|
@@ -72,7 +72,7 @@ export interface ProgressProps {
|
|
|
72
72
|
/** 仪表盘进度条缺口角度,可取值 0 ~ 295 **/
|
|
73
73
|
gapDegree?: number;
|
|
74
74
|
/** 仪表盘进度条缺口位置 **/
|
|
75
|
-
gapPosition?:
|
|
75
|
+
gapPosition?: 'top' | 'bottom' | 'left' | 'right';
|
|
76
76
|
/** 进度条总共步数 **/
|
|
77
77
|
steps?: number;
|
|
78
78
|
/** 渐变颜色的方向 **/
|