@zykj2024/much-library 1.0.10-beta.6 → 1.0.10-beta.7

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,33 +1,7 @@
1
- .mc-cascader__label {
2
- color: #262626;
3
- font-size: 14px;
4
- position: absolute;
5
- top: 0;
6
- left: 11px;
7
- z-index: 2;
8
- height: 100%;
9
- display: -webkit-box;
10
- display: -ms-flexbox;
11
- display: flex;
12
- -webkit-box-align: center;
13
- -ms-flex-align: center;
14
- align-items: center;
15
- }
16
- .mc-cascader__label::after {
17
- content: ':';
18
- margin-left: 2px;
19
- }
20
- .mc-cascader__label.mc-cascader--disabled {
21
- color: rgba(0, 0, 0, 0.25);
22
- cursor: no-drop;
23
- }
24
1
  .mc-cascader__content {
25
2
  width: 100%;
26
3
  height: 100%;
27
4
  }
28
- .mc-cascader__content.ant-cascader.ant-select .ant-select-selector {
29
- padding-left: var(--selector-pl);
30
- }
31
5
  .mc-cascader__content.ant-cascader.ant-select .ant-select-selector .ant-select-selection-overflow-item-rest .ant-select-selection-item {
32
6
  color: #fff;
33
7
  background: #325cf7;
@@ -39,12 +13,6 @@
39
13
  .mc-cascader__content.ant-cascader.ant-select .ant-select-selector .ant-select-selection-item[title*='「'][title$='」'] {
40
14
  color: var(--inexistent-color);
41
15
  }
42
- .mc-cascader__content.ant-cascader.ant-select.ant-select-single .ant-select-selector .ant-select-selection-search {
43
- left: var(--selector-pl);
44
- }
45
- .mc-cascader__content.ant-cascader.ant-select.ant-select-multiple .ant-select-selector .ant-select-selection-placeholder {
46
- left: var(--selector-pl);
47
- }
48
16
  .mc-cascader__content.ant-cascader.ant-select.ant-select-multiple .ant-select-selector .ant-select-selection-search {
49
17
  margin-left: 0;
50
18
  }
@@ -13,6 +13,7 @@ export type McCascaderProps = CascaderProps & {
13
13
  label?: ReactNode;
14
14
  inexistent?: boolean | Inexistent;
15
15
  city?: boolean;
16
+ prefix?: string;
16
17
  [key: string]: any;
17
18
  };
18
19
  declare const McCascader: FC<McCascaderProps>;
@@ -2,8 +2,8 @@ import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
2
2
  import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
3
3
  import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
4
4
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
5
- var _excluded = ["style", "className", "label", "inexistent", "city", "value", "onChange", "options", "multiple", "disabled", "fieldNames", "maxTagCount"];
6
- import { Cascader, Divider, Popover } from 'antd';
5
+ var _excluded = ["style", "className", "label", "inexistent", "city", "value", "onChange", "options", "multiple", "disabled", "fieldNames", "maxTagCount", "prefix"];
6
+ import { Cascader, Popover } from 'antd';
7
7
  import { forwardRef, useEffect, useMemo, useRef, useState } from 'react';
8
8
  import { cityData } from "./city";
9
9
  import "./index.css";
@@ -24,6 +24,7 @@ var McCascader = /*#__PURE__*/forwardRef(function (props, ref) {
24
24
  disabled = props.disabled,
25
25
  fieldNames = props.fieldNames,
26
26
  maxTagCount = props.maxTagCount,
27
+ prefix = props.prefix,
27
28
  rest = _objectWithoutProperties(props, _excluded);
28
29
  var _ref = typeof inexistent === 'boolean' ? {} : inexistent,
29
30
  _ref$inexistentText = _ref.inexistentText,
@@ -48,27 +49,11 @@ var McCascader = /*#__PURE__*/forwardRef(function (props, ref) {
48
49
  } : fieldNames;
49
50
  }, [city, fieldNames]);
50
51
 
51
- /* 获取label宽度 */
52
- var labelRef = useRef();
53
- var _useState = useState(11),
54
- _useState2 = _slicedToArray(_useState, 2),
55
- paddingLeft = _useState2[0],
56
- setPaddingLeft = _useState2[1];
57
- var labelResizeObserver = new ResizeObserver(function (entries) {
58
- setPaddingLeft(entries[0].contentRect.width + 11);
59
- });
60
- useEffect(function () {
61
- labelRef.current && labelResizeObserver.observe(labelRef.current);
62
- return function () {
63
- return labelResizeObserver.disconnect();
64
- };
65
- }, []);
66
-
67
52
  /* 判断value值是否存在于options中 */
68
- var _useState3 = useState(),
69
- _useState4 = _slicedToArray(_useState3, 2),
70
- cascaderValue = _useState4[0],
71
- setCascaderValue = _useState4[1];
53
+ var _useState = useState(),
54
+ _useState2 = _slicedToArray(_useState, 2),
55
+ cascaderValue = _useState2[0],
56
+ setCascaderValue = _useState2[1];
72
57
  var _inexistent = useRef(false);
73
58
  // 获取所有备选项的值列表
74
59
  var _values = useMemo(function () {
@@ -145,38 +130,32 @@ var McCascader = /*#__PURE__*/forwardRef(function (props, ref) {
145
130
  }
146
131
  onChange === null || onChange === void 0 || onChange(_v, _selectedOptions);
147
132
  };
148
- // 扩展全选功能 (继承原有插槽)
149
- var dropdownRender = function dropdownRender(menus, _dropdownRender) {
150
- return /*#__PURE__*/_jsxs("div", {
151
- children: [menus, _dropdownRender, /*#__PURE__*/_jsx(Divider, {
152
- style: {
153
- margin: 0
154
- }
155
- }), /*#__PURE__*/_jsx("div", {
156
- style: {
157
- padding: 8
158
- },
159
- onClick: function onClick() {
160
- // console.log(ref)
161
- },
162
- children: "\u5168\u9009"
163
- })]
164
- });
165
- };
166
- return /*#__PURE__*/_jsxs("div", {
133
+ // 原有多余代码,不知缘由,暂时不删
134
+ // // 扩展全选功能 (继承原有插槽)
135
+ // const dropdownRender = (menus: React.ReactNode,dropdownRender:React.ReactNode) => (
136
+ // <div>
137
+ // {menus}
138
+ // {dropdownRender}
139
+ // <Divider style={{ margin: 0 }} />
140
+ // <div
141
+ // style={{ padding: 8 }}
142
+ // onClick={() => {
143
+ // // console.log(ref)
144
+ // }}>
145
+ // 全选
146
+ // </div>
147
+ // </div>
148
+ // )
149
+
150
+ return /*#__PURE__*/_jsx("div", {
167
151
  style: _objectSpread({
168
- position: label ? 'relative' : 'static',
169
152
  height: multiple ? 'auto' : 32,
170
- '--selector-pl': "".concat(paddingLeft, "px"),
171
153
  '--inexistent-color': inexistentColor
172
154
  }, style),
173
155
  className: "mc-cascader ".concat(multiple && _maxTagCount === 1 ? 'mc-cascader--inline' : '', " ").concat(className || ''),
174
- children: [label && /*#__PURE__*/_jsx("span", {
175
- ref: labelRef,
176
- className: "mc-cascader__label ".concat(disabled ? 'mc-cascader--disabled' : ''),
177
- children: label
178
- }), /*#__PURE__*/_jsx(Cascader, _objectSpread({
156
+ children: /*#__PURE__*/_jsx(Cascader, _objectSpread({
179
157
  ref: ref,
158
+ prefix: label ? "".concat(label, "\uFF1A") : prefix ? prefix : undefined,
180
159
  className: "mc-cascader__content",
181
160
  value: cascaderValue,
182
161
  onChange: change,
@@ -215,7 +194,7 @@ var McCascader = /*#__PURE__*/forwardRef(function (props, ref) {
215
194
  })
216
195
  });
217
196
  }
218
- }, rest))]
197
+ }, rest))
219
198
  });
220
199
  });
221
200
  export default McCascader;
@@ -1,33 +1,7 @@
1
- .mc-select__label {
2
- color: #262626;
3
- font-size: 14px;
4
- position: absolute;
5
- top: 0;
6
- left: 11px;
7
- z-index: 2;
8
- height: 100%;
9
- display: -webkit-box;
10
- display: -ms-flexbox;
11
- display: flex;
12
- -webkit-box-align: center;
13
- -ms-flex-align: center;
14
- align-items: center;
15
- }
16
- .mc-select__label::after {
17
- content: ':';
18
- margin-left: 2px;
19
- }
20
- .mc-select__label.mc-select--disabled {
21
- color: rgba(0, 0, 0, 0.25);
22
- cursor: no-drop;
23
- }
24
1
  .mc-select__content {
25
2
  width: 100%;
26
3
  height: 100%;
27
4
  }
28
- .mc-select__content.ant-select .ant-select-selector {
29
- padding-left: var(--selector-pl);
30
- }
31
5
  .mc-select__content.ant-select .ant-select-selector .ant-select-selection-overflow-item-rest .ant-select-selection-item {
32
6
  color: #fff;
33
7
  background: #325cf7;
@@ -39,12 +13,6 @@
39
13
  .mc-select__content.ant-select .ant-select-selector .ant-select-selection-item[title*='「'][title$='」'] {
40
14
  color: var(--inexistent-color);
41
15
  }
42
- .mc-select__content.ant-select.ant-select-single .ant-select-selector .ant-select-selection-search {
43
- left: var(--selector-pl);
44
- }
45
- .mc-select__content.ant-select.ant-select-multiple .ant-select-selector .ant-select-selection-placeholder {
46
- left: var(--selector-pl);
47
- }
48
16
  .mc-select__content.ant-select.ant-select-multiple .ant-select-selector .ant-select-selection-search {
49
17
  margin-left: 0;
50
18
  }
@@ -42,6 +42,8 @@ export type McSelectProps = Omit<SelectProps, 'mode' | 'fieldNames'> & {
42
42
  searchInPanelPlaceholder?: string;
43
43
  /** 仅多选+("非远程"或"远程+labelvalue"")生效。默认为false,将选中项置顶。 */
44
44
  pinSelectedOptions?: boolean;
45
+ /** antd 5.22.0新加的属性 */
46
+ prefix?: string;
45
47
  };
46
48
  declare const McSelect: FC<McSelectProps>;
47
49
  export default McSelect;
@@ -5,7 +5,7 @@ import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
5
5
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
6
6
  import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
7
7
  import _typeof from "@babel/runtime/helpers/esm/typeof";
8
- var _excluded = ["style", "className", "label", "multiple", "changeOnHidden", "inexistent", "fetchOptions", "pageSize", "extra", "value", "onChange", "labelInValue", "options", "disabled", "maxTagCount", "onSearch", "onPopupScroll", "onBlur", "onDropdownVisibleChange", "toFilterOptions", "searchInPanel", "pinSelectedOptions", "searchInPanelPlaceholder"];
8
+ var _excluded = ["style", "className", "label", "multiple", "changeOnHidden", "inexistent", "fetchOptions", "pageSize", "extra", "value", "onChange", "labelInValue", "options", "disabled", "maxTagCount", "onSearch", "onPopupScroll", "onBlur", "onDropdownVisibleChange", "toFilterOptions", "searchInPanel", "pinSelectedOptions", "searchInPanelPlaceholder", "prefix"];
9
9
  import { Empty, Popover, Select, Spin } from 'antd';
10
10
  import { debounce } from "../Utils";
11
11
  import { forwardRef, useCallback, useEffect, useMemo, useRef, useState } from 'react';
@@ -70,6 +70,7 @@ var McSelect = /*#__PURE__*/forwardRef(function (props, ref) {
70
70
  _props$pinSelectedOpt = props.pinSelectedOptions,
71
71
  pinSelectedOptions = _props$pinSelectedOpt === void 0 ? false : _props$pinSelectedOpt,
72
72
  searchInPanelPlaceholder = props.searchInPanelPlaceholder,
73
+ prefix = props.prefix,
73
74
  rest = _objectWithoutProperties(props, _excluded);
74
75
  var _ref = typeof inexistent === 'boolean' ? {} : inexistent,
75
76
  _ref$inexistentText = _ref.inexistentText,
@@ -82,41 +83,25 @@ var McSelect = /*#__PURE__*/forwardRef(function (props, ref) {
82
83
  return props.hasOwnProperty('maxTagCount') ? maxTagCount : 1;
83
84
  }, [maxTagCount]);
84
85
 
85
- /* 获取label宽度 */
86
- var labelRef = useRef();
87
- var _useState = useState(11),
88
- _useState2 = _slicedToArray(_useState, 2),
89
- paddingLeft = _useState2[0],
90
- setPaddingLeft = _useState2[1];
91
- var labelResizeObserver = new ResizeObserver(function (entries) {
92
- setPaddingLeft(entries[0].contentRect.width + 11);
93
- });
94
- useEffect(function () {
95
- labelRef.current && labelResizeObserver.observe(labelRef.current);
96
- return function () {
97
- return labelResizeObserver.disconnect();
98
- };
99
- }, []);
100
-
101
86
  /* 基础数据 */
102
- var _useState3 = useState(),
103
- _useState4 = _slicedToArray(_useState3, 2),
104
- selectValue = _useState4[0],
105
- setSelectValue = _useState4[1];
87
+ var _useState = useState(),
88
+ _useState2 = _slicedToArray(_useState, 2),
89
+ selectValue = _useState2[0],
90
+ setSelectValue = _useState2[1];
106
91
  var _selectValue = useRef();
107
- var _useState5 = useState([]),
108
- _useState6 = _slicedToArray(_useState5, 2),
109
- selectOptions = _useState6[0],
110
- setSelectOptions = _useState6[1];
92
+ var _useState3 = useState([]),
93
+ _useState4 = _slicedToArray(_useState3, 2),
94
+ selectOptions = _useState4[0],
95
+ setSelectOptions = _useState4[1];
111
96
  var _selectOptions = useRef([]);
112
- var _useState7 = useState(''),
97
+ var _useState5 = useState(''),
98
+ _useState6 = _slicedToArray(_useState5, 2),
99
+ searchValue = _useState6[0],
100
+ setSearchValue = _useState6[1];
101
+ var _useState7 = useState(false),
113
102
  _useState8 = _slicedToArray(_useState7, 2),
114
- searchValue = _useState8[0],
115
- setSearchValue = _useState8[1];
116
- var _useState9 = useState(false),
117
- _useState10 = _slicedToArray(_useState9, 2),
118
- fetching = _useState10[0],
119
- setFetching = _useState10[1];
103
+ fetching = _useState8[0],
104
+ setFetching = _useState8[1];
120
105
  var _extra = useRef(null);
121
106
  var _current = useRef(1);
122
107
  var _maxPage = useRef(1);
@@ -363,22 +348,18 @@ var McSelect = /*#__PURE__*/forwardRef(function (props, ref) {
363
348
  })]
364
349
  });
365
350
  };
366
- return /*#__PURE__*/_jsxs("div", {
351
+ return /*#__PURE__*/_jsx("div", {
367
352
  style: _objectSpread({
368
353
  position: label ? 'relative' : 'static',
369
354
  height: multiple ? 'auto' : 32,
370
- '--selector-pl': "".concat(paddingLeft, "px"),
371
355
  '--inexistent-color': inexistentColor
372
356
  }, style),
373
357
  className: "mc-select ".concat(multiple && _maxTagCount === 1 ? 'mc-select--inline' : '', " ").concat(className || ''),
374
- children: [label && /*#__PURE__*/_jsx("span", {
375
- ref: labelRef,
376
- className: "mc-select__label ".concat(disabled ? 'mc-select--disabled' : ''),
377
- children: label
378
- }), /*#__PURE__*/_jsx(Select, _objectSpread(_objectSpread({
358
+ children: /*#__PURE__*/_jsx(Select, _objectSpread(_objectSpread({
379
359
  ref: ref,
380
360
  className: "mc-select__content",
381
361
  value: selectValue,
362
+ prefix: label ? "".concat(label, "\uFF1A") : prefix ? prefix : undefined,
382
363
  onChange: change,
383
364
  labelInValue: labelInValue,
384
365
  options: filteredOptions,
@@ -430,7 +411,7 @@ var McSelect = /*#__PURE__*/forwardRef(function (props, ref) {
430
411
  }, rest), {}, {
431
412
  mode: multiple ? 'multiple' : undefined,
432
413
  fieldNames: undefined
433
- }))]
414
+ }))
434
415
  });
435
416
  });
436
417
  export default McSelect;
@@ -1,2 +1,2 @@
1
- declare const _default: "\n/* =========== 布局样式 =========== */\n.ant-pro-layout {\n\n /* 侧边菜单 */\n .ant-pro-sider {\n padding: 8px 0 16px 16px;\n background: transparent !important;\n \n .ant-layout-sider-children {\n background: #f0f4f9;\n border-radius: 12px 0 0 12px;\n padding: 0;\n border-right: 0;\n margin-right: 0;\n overflow: hidden;\n \n .ant-pro-sider-menu {\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n font-size: 18px;\n color: #8C8C8C;\n }\n \n [class*='-selected'] .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n \n a {\n transition: color 0s;\n }\n \n &>.ant-menu-item {\n color: #262626;\n font-weight: 500;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n \n &:first-of-type {\n margin-top: 0;\n }\n \n &:not(.ant-menu-item-selected):hover {\n color: #325cf7;\n background: transparent !important;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n \n &.ant-menu-item-selected {\n color: #325cf7;\n background: #ffffff;\n }\n }\n \n .ant-menu-submenu {\n .ant-menu-submenu-title {\n color: #262626;\n font-weight: 500;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n \n &:hover {\n color: #325cf7;\n background: transparent;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n }\n \n &:first-of-type .ant-menu-submenu-title {\n margin-top: 0;\n }\n \n &.ant-menu-submenu-selected {\n .ant-menu-submenu-title {\n color: #325cf7;\n }\n }\n \n .ant-menu-sub {\n padding: 0;\n \n .ant-menu-item {\n color: #595959;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n padding-left: 44px !important;\n \n &:hover {\n color: #325cf7;\n background: transparent;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n \n &.ant-menu-item-selected {\n color: #325cf7;\n font-weight: 500;\n background: #ffffff;\n }\n }\n }\n }\n }\n \n .ant-pro-sider-footer {\n text-align: right;\n padding: 0 12px 16px;\n \n .menu-footer-collapse-btn {\n width: 24px;\n height: 24px;\n border-radius: 6px;\n padding: 0;\n border: 0;\n \n .ant-btn-icon .anticon {\n font-size: 14px;\n color: #b3b3b3;\n }\n \n &:not(:hover) {\n background: #ffffff;\n }\n }\n }\n }\n \n &.ant-layout-sider-collapsed .ant-layout-sider-children .ant-pro-sider-menu {\n margin-top: -4px;\n \n .ant-menu-item.ant-menu-item-selected,\n .ant-menu-submenu.ant-menu-submenu-selected .ant-menu-submenu-title {\n background: #ffffff;\n }\n }\n }\n \n /* 头部区header */\n .ant-pro-layout-container .ant-pro-layout-header {\n border-bottom: 0 !important;\n \n .ant-pro-top-nav-header-main {\n padding-left: 0;\n \n .ant-pro-top-nav-header-menu {\n padding: 0;\n line-height: 48px;\n \n .ant-menu-item {\n padding: 0 28px;\n margin: 8px;\n \n &:hover {\n font-weight: 500;\n background: rgba(50, 92, 247, 0.1);\n }\n \n &.ant-menu-item-selected {\n font-weight: bold;\n \n &:hover {\n background: rgba(50, 92, 247, 0.1);\n }\n \n &::after {\n content: '';\n display: block;\n width: 21px;\n height: 4px;\n border-radius: 4px;\n background: #325cf7;\n position: absolute;\n bottom: 0;\n left: calc((100% - 21px) / 2);\n }\n }\n }\n }\n }\n }\n \n /* 内容区main */\n .ant-pro-layout-container .ant-pro-layout-content {\n width: calc(100% - 32px);\n margin: 8px 16px 16px;\n padding: 0;\n height: calc(100vh - 88px);\n overflow: auto;\n border-radius: 12px;\n }\n \n .ant-layout-has-sider .ant-pro-layout-container .ant-pro-layout-content {\n width: calc(100% - 16px);\n margin-left: 0;\n border-radius: 0 12px 12px 0;\n }\n }";
1
+ declare const _default: "\n/* =========== 布局样式 =========== */\n.ant-pro-layout {\n\n /* 侧边菜单 */\n .ant-pro-sider {\n padding: 8px 0 16px 16px;\n background: transparent !important;\n \n .ant-layout-sider-children {\n background: #f0f4f9;\n border-radius: 12px 0 0 12px;\n padding: 0;\n border-right: 0;\n margin-right: 0;\n overflow: hidden;\n \n .ant-pro-sider-menu {\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n font-size: 18px;\n color: #8C8C8C;\n }\n \n [class*='-selected'] .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n \n a {\n transition: color 0s;\n }\n \n &>.ant-menu-item {\n color: #262626;\n font-weight: 500;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n \n &:first-of-type {\n margin-top: 0;\n }\n \n &:not(.ant-menu-item-selected):hover {\n color: #325cf7;\n background: transparent !important;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n \n &.ant-menu-item-selected {\n color: #325cf7;\n background: #ffffff;\n }\n }\n \n .ant-menu-submenu {\n .ant-menu-submenu-title {\n color: #262626;\n font-weight: 500;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n \n &:hover {\n color: #325cf7;\n background: transparent;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n }\n \n &:first-of-type .ant-menu-submenu-title {\n margin-top: 0;\n }\n \n &.ant-menu-submenu-selected {\n .ant-menu-submenu-title {\n color: #325cf7;\n }\n }\n \n .ant-menu-sub {\n padding: 0;\n \n .ant-menu-item {\n color: #595959;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n padding-left: 44px !important;\n \n &:hover {\n color: #325cf7;\n background: transparent;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n \n &.ant-menu-item-selected {\n color: #325cf7;\n font-weight: 500;\n background: #ffffff;\n }\n }\n }\n }\n }\n \n .ant-pro-sider-footer {\n text-align: right;\n padding: 0 12px 16px;\n \n .menu-footer-collapse-btn {\n width: 24px;\n height: 24px;\n border-radius: 6px;\n padding: 0;\n border: 0;\n \n .ant-btn-icon .anticon {\n font-size: 14px;\n color: #b3b3b3;\n }\n \n &:not(:hover) {\n background: #ffffff;\n }\n }\n }\n }\n \n &.ant-layout-sider-collapsed .ant-layout-sider-children .ant-pro-sider-menu {\n margin-top: -4px;\n \n .ant-menu-item.ant-menu-item-selected,\n .ant-menu-submenu.ant-menu-submenu-selected .ant-menu-submenu-title {\n background: #ffffff;\n }\n }\n }\n \n /* 头部区header */\n .ant-pro-layout-container .ant-pro-layout-header {\n border-bottom: 0 !important;\n \n .ant-pro-top-nav-header-main {\n padding-left: 0;\n \n .ant-pro-top-nav-header-menu {\n padding: 0;\n line-height: 48px;\n\n .ant-menu-overflow-item-rest {\n margin: 8px;\n }\n \n .ant-menu-item {\n padding: 0 28px;\n margin: 8px;\n \n &:hover {\n font-weight: 500;\n background: rgba(50, 92, 247, 0.1);\n }\n \n &.ant-menu-item-selected {\n font-weight: bold;\n \n &:hover {\n background: rgba(50, 92, 247, 0.1);\n }\n \n &::after {\n content: '';\n display: block;\n width: 21px;\n height: 4px;\n border-radius: 4px;\n background: #325cf7;\n position: absolute;\n bottom: 0;\n left: calc((100% - 21px) / 2);\n }\n }\n }\n }\n }\n }\n \n /* 内容区main */\n .ant-pro-layout-container .ant-pro-layout-content {\n width: calc(100% - 32px);\n margin: 8px 16px 16px;\n padding: 0;\n height: calc(100vh - 88px);\n overflow: auto;\n border-radius: 12px;\n }\n \n .ant-layout-has-sider .ant-pro-layout-container .ant-pro-layout-content {\n width: calc(100% - 16px);\n margin-left: 0;\n border-radius: 0 12px 12px 0;\n }\n }";
2
2
  export default _default;
@@ -1 +1 @@
1
- export default "\n/* =========== \u5E03\u5C40\u6837\u5F0F =========== */\n.ant-pro-layout {\n\n /* \u4FA7\u8FB9\u83DC\u5355 */\n .ant-pro-sider {\n padding: 8px 0 16px 16px;\n background: transparent !important;\n \n .ant-layout-sider-children {\n background: #f0f4f9;\n border-radius: 12px 0 0 12px;\n padding: 0;\n border-right: 0;\n margin-right: 0;\n overflow: hidden;\n \n .ant-pro-sider-menu {\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n font-size: 18px;\n color: #8C8C8C;\n }\n \n [class*='-selected'] .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n \n a {\n transition: color 0s;\n }\n \n &>.ant-menu-item {\n color: #262626;\n font-weight: 500;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n \n &:first-of-type {\n margin-top: 0;\n }\n \n &:not(.ant-menu-item-selected):hover {\n color: #325cf7;\n background: transparent !important;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n \n &.ant-menu-item-selected {\n color: #325cf7;\n background: #ffffff;\n }\n }\n \n .ant-menu-submenu {\n .ant-menu-submenu-title {\n color: #262626;\n font-weight: 500;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n \n &:hover {\n color: #325cf7;\n background: transparent;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n }\n \n &:first-of-type .ant-menu-submenu-title {\n margin-top: 0;\n }\n \n &.ant-menu-submenu-selected {\n .ant-menu-submenu-title {\n color: #325cf7;\n }\n }\n \n .ant-menu-sub {\n padding: 0;\n \n .ant-menu-item {\n color: #595959;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n padding-left: 44px !important;\n \n &:hover {\n color: #325cf7;\n background: transparent;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n \n &.ant-menu-item-selected {\n color: #325cf7;\n font-weight: 500;\n background: #ffffff;\n }\n }\n }\n }\n }\n \n .ant-pro-sider-footer {\n text-align: right;\n padding: 0 12px 16px;\n \n .menu-footer-collapse-btn {\n width: 24px;\n height: 24px;\n border-radius: 6px;\n padding: 0;\n border: 0;\n \n .ant-btn-icon .anticon {\n font-size: 14px;\n color: #b3b3b3;\n }\n \n &:not(:hover) {\n background: #ffffff;\n }\n }\n }\n }\n \n &.ant-layout-sider-collapsed .ant-layout-sider-children .ant-pro-sider-menu {\n margin-top: -4px;\n \n .ant-menu-item.ant-menu-item-selected,\n .ant-menu-submenu.ant-menu-submenu-selected .ant-menu-submenu-title {\n background: #ffffff;\n }\n }\n }\n \n /* \u5934\u90E8\u533Aheader */\n .ant-pro-layout-container .ant-pro-layout-header {\n border-bottom: 0 !important;\n \n .ant-pro-top-nav-header-main {\n padding-left: 0;\n \n .ant-pro-top-nav-header-menu {\n padding: 0;\n line-height: 48px;\n \n .ant-menu-item {\n padding: 0 28px;\n margin: 8px;\n \n &:hover {\n font-weight: 500;\n background: rgba(50, 92, 247, 0.1);\n }\n \n &.ant-menu-item-selected {\n font-weight: bold;\n \n &:hover {\n background: rgba(50, 92, 247, 0.1);\n }\n \n &::after {\n content: '';\n display: block;\n width: 21px;\n height: 4px;\n border-radius: 4px;\n background: #325cf7;\n position: absolute;\n bottom: 0;\n left: calc((100% - 21px) / 2);\n }\n }\n }\n }\n }\n }\n \n /* \u5185\u5BB9\u533Amain */\n .ant-pro-layout-container .ant-pro-layout-content {\n width: calc(100% - 32px);\n margin: 8px 16px 16px;\n padding: 0;\n height: calc(100vh - 88px);\n overflow: auto;\n border-radius: 12px;\n }\n \n .ant-layout-has-sider .ant-pro-layout-container .ant-pro-layout-content {\n width: calc(100% - 16px);\n margin-left: 0;\n border-radius: 0 12px 12px 0;\n }\n }";
1
+ export default "\n/* =========== \u5E03\u5C40\u6837\u5F0F =========== */\n.ant-pro-layout {\n\n /* \u4FA7\u8FB9\u83DC\u5355 */\n .ant-pro-sider {\n padding: 8px 0 16px 16px;\n background: transparent !important;\n \n .ant-layout-sider-children {\n background: #f0f4f9;\n border-radius: 12px 0 0 12px;\n padding: 0;\n border-right: 0;\n margin-right: 0;\n overflow: hidden;\n \n .ant-pro-sider-menu {\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n font-size: 18px;\n color: #8C8C8C;\n }\n \n [class*='-selected'] .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n \n a {\n transition: color 0s;\n }\n \n &>.ant-menu-item {\n color: #262626;\n font-weight: 500;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n \n &:first-of-type {\n margin-top: 0;\n }\n \n &:not(.ant-menu-item-selected):hover {\n color: #325cf7;\n background: transparent !important;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n \n &.ant-menu-item-selected {\n color: #325cf7;\n background: #ffffff;\n }\n }\n \n .ant-menu-submenu {\n .ant-menu-submenu-title {\n color: #262626;\n font-weight: 500;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n \n &:hover {\n color: #325cf7;\n background: transparent;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n }\n \n &:first-of-type .ant-menu-submenu-title {\n margin-top: 0;\n }\n \n &.ant-menu-submenu-selected {\n .ant-menu-submenu-title {\n color: #325cf7;\n }\n }\n \n .ant-menu-sub {\n padding: 0;\n \n .ant-menu-item {\n color: #595959;\n margin: 4px 0;\n width: 100%;\n border-radius: 4px 0 0 4px;\n padding-left: 44px !important;\n \n &:hover {\n color: #325cf7;\n background: transparent;\n \n .ant-pro-base-menu-inline-item-icon .anticon {\n color: #325cf7;\n }\n }\n \n &.ant-menu-item-selected {\n color: #325cf7;\n font-weight: 500;\n background: #ffffff;\n }\n }\n }\n }\n }\n \n .ant-pro-sider-footer {\n text-align: right;\n padding: 0 12px 16px;\n \n .menu-footer-collapse-btn {\n width: 24px;\n height: 24px;\n border-radius: 6px;\n padding: 0;\n border: 0;\n \n .ant-btn-icon .anticon {\n font-size: 14px;\n color: #b3b3b3;\n }\n \n &:not(:hover) {\n background: #ffffff;\n }\n }\n }\n }\n \n &.ant-layout-sider-collapsed .ant-layout-sider-children .ant-pro-sider-menu {\n margin-top: -4px;\n \n .ant-menu-item.ant-menu-item-selected,\n .ant-menu-submenu.ant-menu-submenu-selected .ant-menu-submenu-title {\n background: #ffffff;\n }\n }\n }\n \n /* \u5934\u90E8\u533Aheader */\n .ant-pro-layout-container .ant-pro-layout-header {\n border-bottom: 0 !important;\n \n .ant-pro-top-nav-header-main {\n padding-left: 0;\n \n .ant-pro-top-nav-header-menu {\n padding: 0;\n line-height: 48px;\n\n .ant-menu-overflow-item-rest {\n margin: 8px;\n }\n \n .ant-menu-item {\n padding: 0 28px;\n margin: 8px;\n \n &:hover {\n font-weight: 500;\n background: rgba(50, 92, 247, 0.1);\n }\n \n &.ant-menu-item-selected {\n font-weight: bold;\n \n &:hover {\n background: rgba(50, 92, 247, 0.1);\n }\n \n &::after {\n content: '';\n display: block;\n width: 21px;\n height: 4px;\n border-radius: 4px;\n background: #325cf7;\n position: absolute;\n bottom: 0;\n left: calc((100% - 21px) / 2);\n }\n }\n }\n }\n }\n }\n \n /* \u5185\u5BB9\u533Amain */\n .ant-pro-layout-container .ant-pro-layout-content {\n width: calc(100% - 32px);\n margin: 8px 16px 16px;\n padding: 0;\n height: calc(100vh - 88px);\n overflow: auto;\n border-radius: 12px;\n }\n \n .ant-layout-has-sider .ant-pro-layout-container .ant-pro-layout-content {\n width: calc(100% - 16px);\n margin-left: 0;\n border-radius: 0 12px 12px 0;\n }\n }";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zykj2024/much-library",
3
- "version": "1.0.10-beta.6",
3
+ "version": "1.0.10-beta.7",
4
4
  "description": "react library",
5
5
  "license": "MIT",
6
6
  "module": "dist/index.js",
@@ -47,7 +47,7 @@
47
47
  "@babel/runtime": "^7.25.6",
48
48
  "@dnd-kit/core": "^6.1.0",
49
49
  "@dnd-kit/sortable": "^8.0.0",
50
- "antd": "^5.16.2",
50
+ "antd": "^5.22.0",
51
51
  "antd-style": "^3.6.2",
52
52
  "dayjs": "^1.11.12",
53
53
  "lodash": "^4.17.21",