@para-ui/core 3.0.2 → 3.0.5

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.
Files changed (58) hide show
  1. package/Breadcrumbs/index.d.ts +14 -0
  2. package/Breadcrumbs/index.js +209 -156
  3. package/Breadcrumbs/lang/en_US.d.ts +4 -0
  4. package/Breadcrumbs/lang/index.d.ts +9 -0
  5. package/Breadcrumbs/lang/zh_CN.d.ts +4 -0
  6. package/Button/index.js +9 -3
  7. package/ButtonGroup/index.js +1 -1
  8. package/Cascader/index.js +1 -1
  9. package/Checkbox/index.js +1 -1
  10. package/CollapseBox/index.js +1 -18
  11. package/CollapseLayout/index.d.ts +51 -0
  12. package/CollapseLayout/index.js +190 -0
  13. package/ComboSelect/index.js +16 -10
  14. package/DatePicker/generatePicker/index.d.ts +11 -2
  15. package/DatePicker/index.js +46 -34
  16. package/Desktop/index.js +1 -1
  17. package/Drawer/index.js +1 -1
  18. package/Empty/index.js +1 -1
  19. package/Form/index.js +3 -3
  20. package/FormItem/index.js +3 -3
  21. package/FunctionModal/index.js +3 -3
  22. package/Menu/index.js +1 -0
  23. package/Modal/index.js +1 -1
  24. package/OperateBtn/index.js +1 -1
  25. package/PageHeader/index.js +1 -1
  26. package/Pagination/index.js +5 -5
  27. package/PopConfirm/index.js +1 -1
  28. package/Popover/index.js +2 -16
  29. package/Querying/index.js +1 -1
  30. package/README.md +25 -0
  31. package/Search/index.js +1 -1
  32. package/Select/index.js +1 -1
  33. package/SelectInput/index.js +1 -1
  34. package/Selector/index.js +2 -1
  35. package/Selector/lang/index.d.ts +2 -0
  36. package/SelectorPicker/index.js +2 -1
  37. package/Table/index.js +11 -9
  38. package/Table/interface.d.ts +2 -0
  39. package/Tabs/index.js +1 -1
  40. package/TimePicker/index.js +1 -1
  41. package/Title/index.js +6 -6
  42. package/ToggleButton/index.js +1 -1
  43. package/Tooltip/index.js +12 -6
  44. package/Transfer/index.d.ts +19 -4
  45. package/Transfer/index.js +183 -102
  46. package/Transfer/lang/en_US.d.ts +2 -0
  47. package/Transfer/lang/index.d.ts +4 -0
  48. package/Transfer/lang/zh_CN.d.ts +2 -0
  49. package/Tree/index.js +3 -3
  50. package/Upload/index.js +1 -1
  51. package/_verture/{index-cc4c83b8.js → index-9d9fefc1.js} +0 -0
  52. package/_verture/{index-cf5bf211.js → index-e0508c99.js} +1 -1
  53. package/_verture/{modalContext-95c3fc87.js → modalContext-4bce2dae.js} +0 -0
  54. package/_verture/{useFormatMessage-ac9d6acf.js → useFormatMessage-f4452258.js} +6 -4
  55. package/_verture/util-a77b261e.js +19 -0
  56. package/index.d.ts +2 -0
  57. package/index.js +10 -7
  58. package/package.json +1 -1
@@ -29,11 +29,25 @@ export interface BreadcrumbsProps {
29
29
  popoverClassName?: string;
30
30
  /** 是否收缩 */
31
31
  isShrink?: boolean;
32
+ /** 最后最少显示数 */
33
+ minNum?: number;
34
+ /** 是否显示返回 */
35
+ isBack?: boolean;
36
+ /** 自定义返回内容 */
37
+ backRender?: ReactNode;
38
+ /** 弹窗方式 */
39
+ trigger?: 'hover' | 'click';
40
+ /** 弹窗方向 */
41
+ placement?: 'top' | 'left' | 'right' | 'bottom' | 'topLeft' | 'topRight' | 'bottomLeft' | 'bottomRight' | 'leftTop' | 'leftBottom' | 'rightTop' | 'rightBottom';
32
42
  /**
33
43
  * 点击菜单
34
44
  * @param ops 当前点击菜单数据
35
45
  */
36
46
  onClickItem?: (ops: listOptions) => void;
47
+ /**
48
+ * 点击返回
49
+ * */
50
+ onBack?: () => void;
37
51
  }
38
52
  export declare const Breadcrumbs: FunctionComponent<BreadcrumbsProps>;
39
53
  export default Breadcrumbs;
@@ -1,25 +1,40 @@
1
1
  import { _ as _toConsumableArray } from '../_verture/toConsumableArray-f8047a75.js';
2
2
  import { _ as _slicedToArray } from '../_verture/slicedToArray-d7722f4b.js';
3
- import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
4
- import { useState, useRef, useEffect, Fragment as Fragment$1 } from 'react';
3
+ import { jsxs, jsx, Fragment as Fragment$1 } from 'react/jsx-runtime';
4
+ import { useState, useRef, useEffect, Fragment } from 'react';
5
5
  import { Popover } from '../Popover/index.js';
6
6
  import AutoTips from '../AutoTips/index.js';
7
7
  import More from '@para-ui/icons/More';
8
- import { UUID } from '@paraview/lib';
8
+ import Return from '@para-ui/icons/Return';
9
9
  import { $ as $prefixCls } from '../_verture/constant-bf34e6fa.js';
10
+ import { u as useFormatMessage } from '../_verture/useFormatMessage-f4452258.js';
10
11
  import { s as styleInject } from '../_verture/style-inject.es-300983ab.js';
11
12
  import '../_verture/tslib.es6-55ed4bd2.js';
12
13
  import '../Tooltip/index.js';
13
14
  import 'rc-tooltip';
14
15
  import 'rc-tooltip/lib/placements';
15
16
  import 'clsx';
17
+ import '@para-ui/core/GlobalContext';
16
18
 
17
- var css_248z = "@charset \"UTF-8\";\n/**\n * @author linhd\n * @date 2021年10月25日 14:58:12\n * @description 面包屑\n */\n/**\n* @author Hanz\n* @date 2021/10/20 下午2:08\n* @description color\n*/\n/**\n* @author linhd\n* @date 2022/8/12 5:28 PM\n* @description 全局css前缀\n*/\n.paraui-v3-breadcrumbs {\n display: inline-block;\n font-family: -apple-system, BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;\n font-size: 14px;\n font-weight: 400;\n line-height: 0;\n height: 17px;\n}\n.paraui-v3-breadcrumbs.paraui-v3-breadcrumbs-shrink {\n white-space: nowrap;\n}\n.paraui-v3-breadcrumbs > div {\n display: inline-block;\n line-height: 17px;\n vertical-align: middle;\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-v3-breadcrumbs > div svg {\n font-size: 14px;\n vertical-align: middle;\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-v3-breadcrumbs > div span {\n display: inline-block;\n line-height: 0;\n vertical-align: middle;\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-v3-breadcrumbs > div .breadcrumbs-auto-tips {\n line-height: 0;\n}\n.paraui-v3-breadcrumbs > div .breadcrumbs-auto-tips .auto-tips-content {\n line-height: 17px;\n}\n.paraui-v3-breadcrumbs > div .breadcrumbs-auto-tips span {\n line-height: 17px;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-separator {\n user-select: none;\n margin: 0 8px;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-item-click {\n cursor: pointer;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-item-click:hover {\n color: rgb(54, 102, 214);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-item-click:hover svg {\n color: rgb(54, 102, 214);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-item-click:hover span {\n color: rgb(54, 102, 214);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-item-disabled {\n color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-breadcrumbs > .more-breadcrumbs {\n cursor: pointer;\n}\n.paraui-v3-breadcrumbs > .current-breadcrumbs {\n color: rgba(46, 55, 67, 0.7);\n font-weight: 700;\n}\n\n.paraui-v3-breadcrumbs-popover > .component-popover-content > .component-popover-inner {\n display: flex;\n align-items: center;\n height: 36px;\n line-height: 0;\n padding: 0 12px;\n}";
19
+ var en = {
20
+ back: 'Back'
21
+ };
22
+
23
+ var zh = {
24
+ back: '返回'
25
+ };
26
+
27
+ var localeJson = {
28
+ zh: zh,
29
+ en: en
30
+ };
31
+
32
+ var css_248z = "@charset \"UTF-8\";\n/**\n * @author linhd\n * @date 2021年10月25日 14:58:12\n * @description 面包屑\n */\n/**\n* @author Hanz\n* @date 2021/10/20 下午2:08\n* @description color\n*/\n/**\n* @author linhd\n* @date 2022/8/12 5:28 PM\n* @description 全局css前缀\n*/\n.paraui-v3-breadcrumbs {\n font-family: -apple-system, BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;\n font-size: 14px;\n font-weight: 400;\n display: flex;\n height: 24px;\n line-height: 24px;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list {\n display: flex;\n align-items: center;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item {\n padding: 0 4px;\n border-radius: 2px;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item .breadcrumbs-item-content {\n white-space: nowrap;\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item .breadcrumbs-item-content svg {\n color: rgba(46, 55, 67, 0.7);\n font-size: 14px;\n margin-right: 4px;\n vertical-align: -2px;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item.breadcrumbs-item-click .breadcrumbs-item-content {\n cursor: pointer;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item.breadcrumbs-item-click:hover {\n background-color: rgba(171, 176, 185, 0.12);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item.breadcrumbs-item-click:hover .breadcrumbs-item-content {\n color: rgb(54, 102, 214);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item.breadcrumbs-item-click:hover .breadcrumbs-item-content svg {\n color: rgb(54, 102, 214);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item.breadcrumbs-item-current .breadcrumbs-item-content {\n color: rgb(46, 55, 67);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item.breadcrumbs-item-current .breadcrumbs-item-content svg {\n color: rgb(46, 55, 67);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item.breadcrumbs-item-disabled {\n cursor: not-allowed;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item.breadcrumbs-item-disabled .breadcrumbs-item-content {\n color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item.breadcrumbs-item-disabled .breadcrumbs-item-content svg {\n color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item-more {\n display: flex;\n align-items: center;\n height: 100%;\n padding: 0 4px;\n cursor: pointer;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item-more svg {\n color: rgba(46, 55, 67, 0.7);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item-more:hover {\n background-color: rgba(171, 176, 185, 0.12);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .breadcrumbs-item-more:hover svg {\n color: rgb(54, 102, 214);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-list > .separator {\n color: rgba(171, 176, 185, 0.4);\n margin: 0 4px;\n position: relative;\n top: -1px;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-back {\n display: flex;\n align-items: center;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-back > .line {\n display: inline-block;\n width: 1px;\n height: 14px;\n background-color: rgba(171, 176, 185, 0.2);\n margin: 0 8px;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-back > .breadcrumbs-back-content {\n display: flex;\n align-items: center;\n flex-wrap: nowrap;\n height: 100%;\n color: rgba(46, 55, 67, 0.7);\n padding: 0 4px;\n border-radius: 2px;\n cursor: pointer;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-back > .breadcrumbs-back-content:hover {\n background-color: rgba(171, 176, 185, 0.12);\n color: rgb(54, 102, 214);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-back > .breadcrumbs-back-content:hover svg {\n color: rgb(54, 102, 214);\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-back > .breadcrumbs-back-content svg {\n color: rgba(46, 55, 67, 0.7);\n font-size: 14px;\n margin-right: 4px;\n}\n.paraui-v3-breadcrumbs > .breadcrumbs-back > .breadcrumbs-back-content span {\n white-space: nowrap;\n}\n.paraui-v3-breadcrumbs.paraui-v3-breadcrumbs-calculation {\n overflow: hidden;\n opacity: 0;\n}\n\n.paraui-v3-breadcrumbs-popover .breadcrumbs-popover-content {\n padding: 8px 0;\n}\n.paraui-v3-breadcrumbs-popover .breadcrumbs-popover-content .breadcrumbs-popover-content-item {\n font-family: -apple-system, BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;\n font-size: 14px;\n font-weight: 400;\n height: 36px;\n line-height: 36px;\n padding: 0 12px;\n color: rgb(46, 55, 67);\n display: flex;\n align-items: center;\n}\n.paraui-v3-breadcrumbs-popover .breadcrumbs-popover-content .breadcrumbs-popover-content-item svg {\n color: rgb(46, 55, 67);\n margin-right: 4px;\n}\n.paraui-v3-breadcrumbs-popover .breadcrumbs-popover-content .breadcrumbs-popover-content-item.breadcrumbs-popover-content-item-click {\n cursor: pointer;\n}\n.paraui-v3-breadcrumbs-popover .breadcrumbs-popover-content .breadcrumbs-popover-content-item.breadcrumbs-popover-content-item-click:hover {\n background-color: rgba(171, 176, 185, 0.12);\n}\n.paraui-v3-breadcrumbs-popover .breadcrumbs-popover-content .breadcrumbs-popover-content-item.breadcrumbs-popover-content-item-disabled {\n cursor: not-allowed;\n color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-breadcrumbs-popover .breadcrumbs-popover-content .breadcrumbs-popover-content-item.breadcrumbs-popover-content-item-disabled svg {\n color: rgba(46, 55, 67, 0.4);\n}";
18
33
  styleInject(css_248z);
19
34
 
20
35
  var Breadcrumbs = function Breadcrumbs(props) {
21
36
  var _props$maxWidth = props.maxWidth,
22
- maxWidth = _props$maxWidth === void 0 ? '' : _props$maxWidth,
37
+ maxWidth = _props$maxWidth === void 0 ? '160px' : _props$maxWidth,
23
38
  className = props.className,
24
39
  list = props.list,
25
40
  _props$separator = props.separator,
@@ -27,89 +42,152 @@ var Breadcrumbs = function Breadcrumbs(props) {
27
42
  popoverClassName = props.popoverClassName,
28
43
  _props$isShrink = props.isShrink,
29
44
  isShrink = _props$isShrink === void 0 ? true : _props$isShrink,
45
+ _props$isBack = props.isBack,
46
+ isBack = _props$isBack === void 0 ? false : _props$isBack,
47
+ _props$minNum = props.minNum,
48
+ minNum = _props$minNum === void 0 ? 2 : _props$minNum,
49
+ _props$trigger = props.trigger,
50
+ trigger = _props$trigger === void 0 ? 'hover' : _props$trigger,
51
+ _props$placement = props.placement,
52
+ placement = _props$placement === void 0 ? 'bottomLeft' : _props$placement,
53
+ backRender = props.backRender,
30
54
  onClickItem = props.onClickItem,
55
+ onBack = props.onBack,
31
56
  style = props.style;
57
+ var intl = useFormatMessage('Breadcrumbs', localeJson);
58
+
59
+ var _useState = useState(false),
60
+ _useState2 = _slicedToArray(_useState, 2),
61
+ showMore = _useState2[0],
62
+ setShowMore = _useState2[1]; // 是否显示更多按钮
32
63
 
33
- var _useState = useState($prefixCls + '-breadcrumbs-' + UUID()),
34
- _useState2 = _slicedToArray(_useState, 1),
35
- classStr = _useState2[0];
36
64
 
37
65
  var _useState3 = useState([]),
38
66
  _useState4 = _slicedToArray(_useState3, 2),
39
- listCom = _useState4[0],
40
- setListCom = _useState4[1];
41
-
42
- var _useState5 = useState(0),
43
- _useState6 = _slicedToArray(_useState5, 2),
44
- oneNum = _useState6[0],
45
- setOneNum = _useState6[1];
46
-
47
- var _useState7 = useState(false),
48
- _useState8 = _slicedToArray(_useState7, 2),
49
- open = _useState8[0],
50
- setOpen = _useState8[1];
67
+ hideArr = _useState4[0],
68
+ setHideArr = _useState4[1]; // 是否隐藏面包屑
51
69
 
52
- var _useState9 = useState({}),
53
- _useState10 = _slicedToArray(_useState9, 1),
54
- constData = _useState10[0];
55
70
 
56
- var ref = useRef();
71
+ var boxRef = useRef();
72
+ var constData = useRef({
73
+ minNum: minNum,
74
+ isBack: isBack,
75
+ isShrink: isShrink,
76
+ timer: null,
77
+ showMore: false,
78
+ hideArr: [],
79
+ hidePos: 0
80
+ });
81
+ constData.current.isBack = isBack;
82
+ constData.current.showMore = showMore;
83
+ constData.current.isShrink = isShrink;
84
+ constData.current.minNum = minNum;
57
85
  useEffect(function () {
58
- setTimeout(function () {
59
- var dom = document.querySelector('.' + classStr);
60
- if (dom) setOneNum(dom.offsetWidth);
61
- });
62
- setListCom(_toConsumableArray(list));
63
- }, [list]);
86
+ window.addEventListener("resize", winResize);
87
+ return function () {
88
+ clearTimeout(constData.current.timer);
89
+ window.removeEventListener("resize", winResize);
90
+ };
91
+ }, []);
64
92
  useEffect(function () {
65
- if (isShrink) {
66
- setTimeout(function () {
67
- changeSize();
68
- });
69
- window.addEventListener("resize", changeSize);
70
- } else window.removeEventListener("resize", changeSize);
93
+ var arr = new Array(props.list.length).fill(false);
94
+ constData.current.hideArr = arr;
95
+ setHideArr(arr);
96
+ changeSize();
97
+ }, [list]);
98
+ /** 点击面包屑 */
71
99
 
100
+ var clickItem = function clickItem(item, index) {
72
101
  return function () {
73
- window.removeEventListener("resize", changeSize);
102
+ if (props.list.length - 1 === index || item.disabled) return;
103
+ onClickItem && onClickItem(item);
74
104
  };
75
- }, [listCom, oneNum, isShrink]);
76
-
77
- var changeSize = function changeSize() {
78
- if (list.length <= 2 || oneNum === 0) return;
79
- var refDom = document.querySelector('.' + classStr);
80
-
81
- if (refDom && oneNum) {
82
- if (refDom.parentNode && refDom.parentNode.offsetWidth >= oneNum) {
83
- if (!constData.scroll) return;
84
- constData.scroll = false;
85
- setListCom(_toConsumableArray(list));
86
- setOpen(false);
87
- } else {
88
- if (constData.scroll) return;
89
- constData.scroll = true; // 滚动
90
-
91
- var arr = [];
92
- arr.push(list[0]);
93
- arr.push({
94
- more: 'more-breadcrumbs'
95
- });
96
- arr.push(list[list.length - 1]);
97
- setListCom([].concat(arr));
98
- }
105
+ };
106
+ /** 点击返回, 又返回执行返回事件,否则默认返回上级 */
107
+
108
+
109
+ var clickBack = function clickBack() {
110
+ if (onBack) return onBack();
111
+ if (props.list.length < 2) return;
112
+ var item = props.list[props.list.length - 2];
113
+ clickItem(item, props.list.length - 2)();
114
+ };
115
+ /** 改变屏幕 */
116
+
117
+
118
+ var winResize = function winResize() {
119
+ changeSize();
120
+ };
121
+ /** 去除遮罩 */
122
+
123
+
124
+ var hideMask = function hideMask() {
125
+ boxRef.current.classList.remove($prefixCls + '-breadcrumbs-calculation');
126
+ };
127
+
128
+ var changeSize = function changeSize(bol) {
129
+ if (!constData.current.isShrink) return hideMask(); // 不自动计算
130
+
131
+ clearTimeout(constData.current.timer); // 恢复初始状态
132
+
133
+ if (!bol) {
134
+ constData.current.hidePos = 0;
135
+ constData.current.showMore = false;
136
+ var arr = new Array(props.list.length).fill(false);
137
+ constData.current.hideArr = arr;
138
+ setHideArr(arr);
139
+ setShowMore(false);
99
140
  }
100
- }; // 点击菜单
101
141
 
142
+ if (props.list.length <= constData.current.minNum + 1) return hideMask(); // 面包屑数组长度必须大于最少显示数
102
143
 
103
- var handleClick = function handleClick(item) {
104
- return function () {
105
- if (item.disabled) return;
144
+ if (constData.current.hidePos === props.list.length - constData.current.minNum - 1) return hideMask(); // 隐藏到最小显示数,停止
145
+
146
+ boxRef.current.classList.add($prefixCls + '-breadcrumbs-calculation');
147
+ constData.current.timer = setTimeout(function () {
148
+ var boxWidth = boxRef.current.clientWidth;
149
+ var listWidth = boxRef.current.querySelector('.breadcrumbs-list').clientWidth;
150
+ var backWidth = constData.current.isBack ? boxRef.current.querySelector('.breadcrumbs-back').clientWidth : 0;
106
151
 
107
- if (item.more === 'more-breadcrumbs') {
108
- setOpen(true);
152
+ if (boxWidth > listWidth + backWidth) {
153
+ // 没有超出
154
+ hideMask();
109
155
  } else {
110
- if (onClickItem) onClickItem(item);
156
+ constData.current.hidePos += 1;
157
+ constData.current.hideArr[constData.current.hidePos] = true;
158
+ setHideArr(_toConsumableArray(constData.current.hideArr));
159
+ setShowMore(true);
160
+ changeSize(true);
161
+ /*// 超出
162
+ if (constData.current.showMore) {
163
+ // 超出情况下,在超出,继续减一个面包屑
164
+ } else {
165
+ // 没有超出-> 变超出
166
+ }*/
111
167
  }
112
- };
168
+ }, 50);
169
+ };
170
+ /** 处理弹窗内容 */
171
+
172
+
173
+ var handContent = function handContent() {
174
+ return jsx("div", Object.assign({
175
+ className: "breadcrumbs-popover-content"
176
+ }, {
177
+ children: list.map(function (item, index) {
178
+ if (!hideArr[index]) return null;
179
+ var str = 'breadcrumbs-popover-content-item';
180
+ if (index !== list.length - 1 && !item.disabled) str += ' breadcrumbs-popover-content-item-click';
181
+ if (index === list.length - 1) str += ' breadcrumbs-popover-content-item-current';
182
+ if (item.disabled) str += ' breadcrumbs-popover-content-item-disabled';
183
+ return jsx("div", Object.assign({
184
+ className: str,
185
+ onClick: clickItem(item, index)
186
+ }, {
187
+ children: item.label
188
+ }), index);
189
+ })
190
+ }));
113
191
  }; // 处理弹出框className
114
192
 
115
193
 
@@ -117,114 +195,89 @@ var Breadcrumbs = function Breadcrumbs(props) {
117
195
  var str = $prefixCls + '-breadcrumbs-popover';
118
196
  if (popoverClassName) str += ' ' + popoverClassName;
119
197
  return str;
120
- }; // 关闭弹出菜单
121
-
122
-
123
- var handleClose = function handleClose(bol) {
124
- if (!bol) setOpen(false);
125
198
  }; // 处理className
126
199
 
127
200
 
128
201
  var handClass = function handClass() {
129
- var str = $prefixCls + '-breadcrumbs ' + classStr;
202
+ var str = $prefixCls + '-breadcrumbs';
130
203
  if (isShrink) str += " ".concat($prefixCls, "-breadcrumbs-shrink");
131
204
  if (className) str += ' ' + className;
132
205
  return str;
133
206
  };
134
207
 
135
- var handClassItem = function handClassItem(item, index, arr) {
136
- var str = ' breadcrumbs-item';
137
- if (index === arr.length - 1) str += ' current-breadcrumbs';
138
- if (!item.disabled) str += ' breadcrumbs-item-click';else str += ' breadcrumbs-item-disabled';
139
- return str;
140
- };
141
-
142
- var popoverContent = function popoverContent() {
143
- return jsx("div", Object.assign({
144
- className: handClass()
208
+ return jsxs("div", Object.assign({
209
+ className: handClass(),
210
+ style: style,
211
+ ref: boxRef
212
+ }, {
213
+ children: [jsx("ul", Object.assign({
214
+ className: "breadcrumbs-list"
145
215
  }, {
146
216
  children: list.map(function (item, index) {
147
- var showSeparator = list.length - 1 !== index;
148
- return jsxs(Fragment$1, {
149
- children: [jsx("div", Object.assign({
150
- onClick: handleClick(item),
151
- className: handClassItem(item, index, list)
217
+ if (hideArr[index]) return;
218
+ var str = 'breadcrumbs-item';
219
+ if (index === list.length - 1) str += ' breadcrumbs-item-current';
220
+ if (index !== list.length - 1 && !item.disabled) str += ' breadcrumbs-item-click';
221
+ if (item.disabled) str += ' breadcrumbs-item-disabled';
222
+ return jsxs(Fragment, {
223
+ children: [jsx("li", Object.assign({
224
+ className: str,
225
+ style: {
226
+ maxWidth: item.maxWidth || maxWidth
227
+ },
228
+ onClick: clickItem(item, index)
152
229
  }, {
153
- children: item.label
154
- })), showSeparator && jsx("div", Object.assign({
155
- className: "breadcrumbs-separator"
230
+ children: jsx(AutoTips, {
231
+ children: jsx("span", Object.assign({
232
+ className: 'breadcrumbs-item-content'
233
+ }, {
234
+ children: item.label
235
+ }))
236
+ })
237
+ })), index !== list.length - 1 && jsx("li", Object.assign({
238
+ className: 'separator'
156
239
  }, {
157
240
  children: separator
158
- }))]
159
- }, index);
160
- })
161
- }));
162
- };
163
-
164
- var handStyle = function handStyle(item) {
165
- var obj = {};
166
- if (maxWidth) obj.maxWidth = maxWidth;
167
- if (item.maxWidth) obj.maxWidth = item.maxWidth;
168
- return obj;
169
- };
170
-
171
- var handContent = function handContent() {
172
- return jsx("div", Object.assign({
173
- className: handClass(),
174
- style: style,
175
- ref: ref
176
- }, {
177
- children: listCom.map(function (item, index) {
178
- var showSeparator = listCom.length - 1 !== index;
179
-
180
- if (item.more === 'more-breadcrumbs') {
181
- // 更多
182
- return jsxs(Fragment$1, {
183
- children: [jsx("div", Object.assign({
184
- onClick: handleClick(item),
185
- className: "more-breadcrumbs"
241
+ })), showMore && index === 0 && jsxs(Fragment$1, {
242
+ children: [jsx(Popover, Object.assign({
243
+ content: handContent(),
244
+ overlayClassName: popoverHandClass(),
245
+ trigger: trigger,
246
+ placement: placement,
247
+ destroyTooltipOnHide: true
186
248
  }, {
187
- children: jsx(More, {})
188
- })), showSeparator && jsx("div", Object.assign({
189
- className: "breadcrumbs-separator"
249
+ children: jsx("li", Object.assign({
250
+ className: 'breadcrumbs-item-more'
251
+ }, {
252
+ children: jsx(More, {})
253
+ }))
254
+ })), !hideArr[list.length - 1] && jsx("li", Object.assign({
255
+ className: 'separator'
190
256
  }, {
191
257
  children: separator
192
258
  }))]
193
- }, index);
194
- }
195
-
196
- return jsxs(Fragment$1, {
197
- children: [jsx("div", Object.assign({
198
- style: handStyle(item),
199
- onClick: handleClick(item),
200
- className: handClassItem(item, index, listCom)
201
- }, {
202
- children: jsx(AutoTips, Object.assign({
203
- className: 'breadcrumbs-auto-tips'
204
- }, {
205
- children: item.label
206
- }))
207
- })), showSeparator && jsx("div", Object.assign({
208
- className: "breadcrumbs-separator"
209
- }, {
210
- children: separator
211
- }))]
259
+ })]
212
260
  }, index);
213
261
  })
214
- }));
215
- };
216
-
217
- return jsx(Fragment, {
218
- children: isShrink ? jsx(Popover, Object.assign({
219
- placement: 'bottom-start',
220
- visible: open,
221
- content: popoverContent(),
222
- onVisibleChange: handleClose,
223
- overlayClassName: popoverHandClass()
262
+ })), isBack && jsxs("div", Object.assign({
263
+ className: 'breadcrumbs-back'
224
264
  }, {
225
- children: handContent()
226
- })) : handContent()
227
- });
265
+ children: [jsx("span", {
266
+ className: 'line'
267
+ }), jsx("div", Object.assign({
268
+ className: 'breadcrumbs-back-content',
269
+ onClick: clickBack
270
+ }, {
271
+ children: backRender ? backRender : jsxs(Fragment$1, {
272
+ children: [jsx(Return, {}), jsx("span", {
273
+ children: intl({
274
+ id: 'back'
275
+ })
276
+ })]
277
+ })
278
+ }))]
279
+ }))]
280
+ }));
228
281
  };
229
282
 
230
283
  export { Breadcrumbs, Breadcrumbs as default };
@@ -0,0 +1,4 @@
1
+ declare const _default: {
2
+ back: string;
3
+ };
4
+ export default _default;
@@ -0,0 +1,9 @@
1
+ declare const _default: {
2
+ zh: {
3
+ back: string;
4
+ };
5
+ en: {
6
+ back: string;
7
+ };
8
+ };
9
+ export default _default;
@@ -0,0 +1,4 @@
1
+ declare const _default: {
2
+ back: string;
3
+ };
4
+ export default _default;
package/Button/index.js CHANGED
@@ -11,7 +11,7 @@ import Down from '@para-ui/icons/Down';
11
11
  import { $ as $prefixCls } from '../_verture/constant-bf34e6fa.js';
12
12
  import { s as styleInject } from '../_verture/style-inject.es-300983ab.js';
13
13
  import { Dropdown } from '../Dropdown/index.js';
14
- import { u as useFormatMessage } from '../_verture/useFormatMessage-ac9d6acf.js';
14
+ import { u as useFormatMessage } from '../_verture/useFormatMessage-f4452258.js';
15
15
  import 'rc-tooltip';
16
16
  import 'rc-tooltip/lib/placements';
17
17
  import 'rc-dropdown';
@@ -267,7 +267,10 @@ var InternalButton = function InternalButton(props) {
267
267
  useEffect(function () {
268
268
  setHasLoading(!!loading);
269
269
  }, [loading]);
270
- return disabled && toolTipTitle ? jsx(Tooltip, Object.assign({}, TooltipProps, {
270
+ return disabled && toolTipTitle ? jsx(Tooltip, Object.assign({
271
+ arrow: false,
272
+ placement: 'bottom'
273
+ }, TooltipProps, {
271
274
  title: generateTooltipTitle()
272
275
  }, {
273
276
  children: jsx("span", Object.assign({
@@ -370,7 +373,10 @@ var IconButton = function IconButton(props) {
370
373
  useEffect(function () {
371
374
  setHasLoading(!!loading);
372
375
  }, [loading]);
373
- return !!toolTipTitle ? jsx(Tooltip, Object.assign({}, TooltipProps, {
376
+ return !!toolTipTitle ? jsx(Tooltip, Object.assign({
377
+ arrow: false,
378
+ placement: 'bottom'
379
+ }, TooltipProps, {
374
380
  title: generateTooltipTitle()
375
381
  }, {
376
382
  children: disabled ? jsx("span", Object.assign({
@@ -13,7 +13,7 @@ import '@para-ui/icons/LoadingF';
13
13
  import '@para-ui/icons/Down';
14
14
  import '../Dropdown/index.js';
15
15
  import 'rc-dropdown';
16
- import '../_verture/useFormatMessage-ac9d6acf.js';
16
+ import '../_verture/useFormatMessage-f4452258.js';
17
17
  import '@para-ui/core/GlobalContext';
18
18
  import 'rc-tooltip';
19
19
  import 'rc-tooltip/lib/placements';
package/Cascader/index.js CHANGED
@@ -7,7 +7,7 @@ import { useState, useCallback } from 'react';
7
7
  import RcCascader from 'rc-cascader';
8
8
  import Right from '@para-ui/icons/Right';
9
9
  import LoadingIcon from '@para-ui/icons/Loading';
10
- import { u as useFormatMessage } from '../_verture/useFormatMessage-ac9d6acf.js';
10
+ import { u as useFormatMessage } from '../_verture/useFormatMessage-f4452258.js';
11
11
  import { $ as $prefixCls, a as $rcPrefixCls } from '../_verture/constant-bf34e6fa.js';
12
12
  import { s as styleInject } from '../_verture/style-inject.es-300983ab.js';
13
13
  import '@para-ui/core/GlobalContext';
package/Checkbox/index.js CHANGED
@@ -12,7 +12,7 @@ import 'rc-tooltip/lib/placements';
12
12
  import 'clsx';
13
13
  import '@para-ui/icons/Help';
14
14
 
15
- var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2021/10/20 下午2:08\n* @description color\n*/\n/**\n* @author linhd\n* @date 2022/8/12 5:28 PM\n* @description 全局css前缀\n*/\n.paraui-v3-checkbox {\n font-family: -apple-system, BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;\n font-size: 14px;\n font-weight: 400;\n cursor: pointer;\n display: inline-flex;\n align-items: flex-start;\n line-height: 16px;\n}\n.paraui-v3-checkbox:hover > .checkbox-label {\n color: rgba(54, 102, 214, 0.8);\n cursor: pointer;\n}\n.paraui-v3-checkbox:hover > .checkbox-label svg {\n color: rgba(54, 102, 214, 0.8);\n}\n.paraui-v3-checkbox:hover > .checkbox-help {\n padding: 0 8px;\n}\n.paraui-v3-checkbox:hover > .checkbox-help > .checkbox-label {\n color: rgba(54, 102, 214, 0.8);\n cursor: pointer;\n}\n.paraui-v3-checkbox:hover > .checkbox-help > .checkbox-label svg {\n color: rgba(54, 102, 214, 0.8);\n}\n.paraui-v3-checkbox:hover > .checkbox-box > .checkbox-box-inner {\n border-color: rgba(54, 102, 214, 0.8);\n}\n.paraui-v3-checkbox > .checkbox-box {\n position: relative;\n}\n.paraui-v3-checkbox > .checkbox-box > input {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1;\n width: 100%;\n height: 100%;\n opacity: 0;\n cursor: pointer;\n}\n.paraui-v3-checkbox > .checkbox-box > .checkbox-box-inner {\n position: relative;\n top: 0;\n left: 0;\n display: block;\n border-radius: 2px;\n background-color: white;\n border: 1px solid rgba(171, 176, 185, 0.4);\n}\n.paraui-v3-checkbox > .checkbox-box > .checkbox-box-inner:after {\n position: absolute;\n display: table;\n content: \" \";\n}\n.paraui-v3-checkbox > .checkbox-label {\n color: rgb(46, 55, 67);\n padding: 0 8px;\n margin: 0;\n display: inline-flex;\n align-items: flex-start;\n}\n.paraui-v3-checkbox > .checkbox-label > .checkbox-help > svg {\n top: 0;\n}\n.paraui-v3-checkbox .checkbox-label {\n line-height: 16px;\n}\n.paraui-v3-checkbox > .checkbox-help {\n padding: 0 8px;\n position: relative;\n top: -1px;\n}\n.paraui-v3-checkbox > .checkbox-help > .checkbox-label {\n color: rgb(46, 55, 67);\n margin: 0;\n display: inline-flex;\n align-items: center;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-checked:hover > .checkbox-box > .checkbox-box-inner {\n background-color: rgba(54, 102, 214, 0.8);\n border-color: transparent;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-checked > .checkbox-box > .checkbox-box-inner {\n background-color: rgb(54, 102, 214);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-checked > .checkbox-box > .checkbox-box-inner:after {\n border: 1px solid white;\n border-top: 0;\n border-left: 0;\n transform: rotate(45deg) scale(1) translate(-50%, -50%);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-indeterminate:hover > .checkbox-box > .checkbox-box-inner {\n background-color: rgba(54, 102, 214, 0.8);\n border-color: transparent;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-indeterminate > .checkbox-box > .checkbox-box-inner {\n background-color: rgb(54, 102, 214);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-indeterminate > .checkbox-box > .checkbox-box-inner:after {\n background-color: white;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%) scale(1);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled {\n cursor: not-allowed;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-label {\n color: rgba(46, 55, 67, 0.4);\n cursor: not-allowed;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-label svg {\n color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-help > .checkbox-label {\n color: rgba(46, 55, 67, 0.4);\n cursor: not-allowed;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-help > .checkbox-label svg {\n color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-box > input {\n cursor: not-allowed;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-box > .checkbox-box-inner {\n background-color: rgba(171, 176, 185, 0.12);\n border-color: rgba(171, 176, 185, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled.paraui-v3-check-box-checked:hover > .checkbox-box > .checkbox-box-inner {\n background-color: rgba(171, 176, 185, 0.12);\n border-color: rgba(171, 176, 185, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled.paraui-v3-check-box-checked > .checkbox-box > .checkbox-box-inner:after {\n border-color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled.paraui-v3-check-box-indeterminate:hover > .checkbox-box > .checkbox-box-inner {\n background-color: rgba(171, 176, 185, 0.12);\n border-color: rgba(171, 176, 185, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled.paraui-v3-check-box-indeterminate > .checkbox-box > .checkbox-box-inner:after {\n background-color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-small > .checkbox-box {\n top: 1px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-small > .checkbox-box > .checkbox-box-inner {\n width: 14px;\n height: 14px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-small.paraui-v3-checkbox-checked > .checkbox-box > .checkbox-box-inner:after {\n top: 45%;\n left: 21%;\n width: 4px;\n height: 7px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-small.paraui-v3-checkbox-indeterminate > .checkbox-box > .checkbox-box-inner:after {\n width: 8px;\n height: 1px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-medium > .checkbox-box > .checkbox-box-inner {\n width: 16px;\n height: 16px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-medium.paraui-v3-checkbox-checked > .checkbox-box > .checkbox-box-inner:after {\n top: 45%;\n left: 21%;\n width: 5px;\n height: 8px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-medium.paraui-v3-checkbox-indeterminate > .checkbox-box > .checkbox-box-inner:after {\n width: 8px;\n height: 1px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-large > .checkbox-box > .checkbox-box-inner {\n width: 16px;\n height: 16px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-large.paraui-v3-checkbox-checked > .checkbox-box > .checkbox-box-inner:after {\n top: 45%;\n left: 21%;\n width: 5px;\n height: 8px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-large.paraui-v3-checkbox-indeterminate > .checkbox-box > .checkbox-box-inner:after {\n width: 8px;\n height: 1px;\n}";
15
+ var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2021/10/20 下午2:08\n* @description color\n*/\n/**\n* @author linhd\n* @date 2022/8/12 5:28 PM\n* @description 全局css前缀\n*/\n.paraui-v3-checkbox {\n font-family: -apple-system, BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;\n font-size: 14px;\n font-weight: 400;\n cursor: pointer;\n display: inline-flex;\n align-items: flex-start;\n line-height: 16px;\n}\n.paraui-v3-checkbox:hover > .checkbox-label {\n color: rgba(54, 102, 214, 0.8);\n cursor: pointer;\n}\n.paraui-v3-checkbox:hover > .checkbox-label svg {\n color: rgba(54, 102, 214, 0.8);\n}\n.paraui-v3-checkbox:hover > .checkbox-help {\n padding: 0 8px;\n}\n.paraui-v3-checkbox:hover > .checkbox-help > .checkbox-label {\n color: rgba(54, 102, 214, 0.8);\n cursor: pointer;\n}\n.paraui-v3-checkbox:hover > .checkbox-help > .checkbox-label svg {\n color: rgba(54, 102, 214, 0.8);\n}\n.paraui-v3-checkbox:hover > .checkbox-box > .checkbox-box-inner {\n border-color: rgba(54, 102, 214, 0.8);\n}\n.paraui-v3-checkbox > .checkbox-box {\n position: relative;\n}\n.paraui-v3-checkbox > .checkbox-box > input {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 1;\n width: 100%;\n height: 100%;\n opacity: 0;\n cursor: pointer;\n}\n.paraui-v3-checkbox > .checkbox-box > .checkbox-box-inner {\n position: relative;\n top: 0;\n left: 0;\n display: block;\n border-radius: 2px;\n background-color: white;\n border: 1px solid rgba(171, 176, 185, 0.4);\n}\n.paraui-v3-checkbox > .checkbox-box > .checkbox-box-inner:after {\n position: absolute;\n display: table;\n content: \" \";\n}\n.paraui-v3-checkbox > .checkbox-label {\n color: rgb(46, 55, 67);\n padding: 0 8px;\n margin: 0;\n display: inline-flex;\n align-items: flex-start;\n}\n.paraui-v3-checkbox > .checkbox-label > .checkbox-help > svg {\n top: 0;\n}\n.paraui-v3-checkbox .checkbox-label {\n line-height: 16px;\n}\n.paraui-v3-checkbox > .checkbox-help {\n padding: 0 8px;\n position: relative;\n top: -1px;\n}\n.paraui-v3-checkbox > .checkbox-help > .checkbox-label {\n color: rgb(46, 55, 67);\n margin: 0;\n display: inline-flex;\n align-items: center;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-checked:hover > .checkbox-box > .checkbox-box-inner {\n background-color: rgba(54, 102, 214, 0.8);\n border-color: transparent;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-checked > .checkbox-box > .checkbox-box-inner {\n background-color: rgb(54, 102, 214);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-checked > .checkbox-box > .checkbox-box-inner:after {\n border: 1px solid white;\n border-top: 0;\n border-left: 0;\n transform: rotate(45deg) scale(1) translate(-50%, -50%);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-indeterminate:hover > .checkbox-box > .checkbox-box-inner {\n background-color: rgba(54, 102, 214, 0.8);\n border-color: transparent;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-indeterminate > .checkbox-box > .checkbox-box-inner {\n background-color: rgb(54, 102, 214);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-indeterminate > .checkbox-box > .checkbox-box-inner:after {\n background-color: white;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%) scale(1);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled {\n cursor: not-allowed;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-label {\n color: rgba(46, 55, 67, 0.4);\n cursor: not-allowed;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-label svg {\n color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-help > .checkbox-label {\n color: rgba(46, 55, 67, 0.4);\n cursor: not-allowed;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-help > .checkbox-label svg {\n color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-box > input {\n cursor: not-allowed;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled > .checkbox-box > .checkbox-box-inner {\n background-color: rgba(171, 176, 185, 0.12);\n border-color: rgba(171, 176, 185, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled.paraui-v3-checkbox-checked:hover > .checkbox-box > .checkbox-box-inner {\n background-color: rgba(171, 176, 185, 0.12);\n border-color: rgba(171, 176, 185, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled.paraui-v3-checkbox-checked > .checkbox-box > .checkbox-box-inner:after {\n border-color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled.paraui-v3-checkbox-indeterminate:hover > .checkbox-box > .checkbox-box-inner {\n background-color: rgba(171, 176, 185, 0.12);\n border-color: rgba(171, 176, 185, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-disabled.paraui-v3-checkbox-indeterminate > .checkbox-box > .checkbox-box-inner:after {\n background-color: rgba(46, 55, 67, 0.4);\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-small > .checkbox-box {\n top: 1px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-small > .checkbox-box > .checkbox-box-inner {\n width: 14px;\n height: 14px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-small.paraui-v3-checkbox-checked > .checkbox-box > .checkbox-box-inner:after {\n top: 45%;\n left: 21%;\n width: 4px;\n height: 7px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-small.paraui-v3-checkbox-indeterminate > .checkbox-box > .checkbox-box-inner:after {\n width: 8px;\n height: 1px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-medium > .checkbox-box > .checkbox-box-inner {\n width: 16px;\n height: 16px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-medium.paraui-v3-checkbox-checked > .checkbox-box > .checkbox-box-inner:after {\n top: 45%;\n left: 21%;\n width: 5px;\n height: 8px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-medium.paraui-v3-checkbox-indeterminate > .checkbox-box > .checkbox-box-inner:after {\n width: 8px;\n height: 1px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-large > .checkbox-box > .checkbox-box-inner {\n width: 16px;\n height: 16px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-large.paraui-v3-checkbox-checked > .checkbox-box > .checkbox-box-inner:after {\n top: 45%;\n left: 21%;\n width: 5px;\n height: 8px;\n}\n.paraui-v3-checkbox.paraui-v3-checkbox-large.paraui-v3-checkbox-indeterminate > .checkbox-box > .checkbox-box-inner:after {\n width: 8px;\n height: 1px;\n}";
16
16
  styleInject(css_248z);
17
17
 
18
18
  var Checkbox = function Checkbox(props) {
@@ -1,27 +1,10 @@
1
1
  import { jsx } from 'react/jsx-runtime';
2
2
  import { useRef, useEffect } from 'react';
3
3
  import { Transition } from 'react-transition-group';
4
+ import { g as getTransitionProps, a as getAutoHeightDuration } from '../_verture/util-a77b261e.js';
4
5
  import { $ as $prefixCls } from '../_verture/constant-bf34e6fa.js';
5
6
  import { s as styleInject } from '../_verture/style-inject.es-300983ab.js';
6
7
 
7
- function getTransitionProps(props, options) {
8
- var timeout = props.timeout,
9
- _props$style = props.style,
10
- style = _props$style === void 0 ? {} : _props$style;
11
- return {
12
- duration: style.transitionDuration || typeof timeout === 'number' ? timeout : timeout[options.mode] || 0,
13
- delay: style.transitionDelay
14
- };
15
- }
16
- function getAutoHeightDuration(height) {
17
- if (!height) {
18
- return 0;
19
- }
20
-
21
- var constant = height / 36;
22
- return Math.round((4 + 15 * Math.pow(constant, 0.25) + constant / 5) * 10);
23
- }
24
-
25
8
  var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2021/10/20 下午2:08\n* @description color\n*/\n/**\n* @author linhd\n* @date 2022/8/12 5:28 PM\n* @description 全局css前缀\n*/\n.paraui-v3-collapse-box {\n transition: height 300ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;\n width: 100%;\n overflow: hidden;\n height: 0;\n}\n.paraui-v3-collapse-box > .collapse-box-wrapper {\n display: flex;\n width: 100%;\n}\n.paraui-v3-collapse-box > .collapse-box-wrapper > .collapse-box-wrapper-inner {\n width: 100%;\n}\n.paraui-v3-collapse-box.paraui-v3-collapse-box-entered {\n overflow: visible;\n}\n.paraui-v3-collapse-box.paraui-v3-collapse-box-hidden {\n visibility: hidden;\n}";
26
9
  styleInject(css_248z);
27
10