@kep-platform/basic-component 0.0.22 → 0.0.24

Sign up to get free protection for your applications and to get access to all the features.
@@ -10,7 +10,7 @@ export type ColumnsProps = {
10
10
  } & HtmlHTMLAttributes<HTMLUListElement>;
11
11
  export declare const Column: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<Omit<import("styled-components").FastOmit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, never>, "ref"> & {
12
12
  ref?: ((instance: HTMLLIElement | null) => void) | React.RefObject<HTMLLIElement> | null | undefined;
13
- }, Omit<ColumnType, "dataIndex" | "render"> & {
13
+ }, Omit<ColumnType, "render" | "dataIndex"> & {
14
14
  key: React.Key;
15
15
  title?: React.ReactNode;
16
16
  index?: number | undefined;
package/dist/Menu/Menu.js CHANGED
@@ -44,7 +44,9 @@ function Menu(_ref) {
44
44
  return /*#__PURE__*/React.createElement(MenuListItem, {
45
45
  key: item.key,
46
46
  active: activeKey === item.key,
47
- onClick: function onClick() {
47
+ onClick: function onClick(e) {
48
+ e.stopPropagation();
49
+ e.preventDefault();
48
50
  setActiveKey(item.key);
49
51
  onSelect === null || onSelect === void 0 || onSelect(item.key, item);
50
52
  },
@@ -163,6 +163,8 @@ export var TreeNodeController = function TreeNodeController(_ref) {
163
163
  });
164
164
  }, [onSelect, selectedKeys, multiple, selected]);
165
165
  var onClickExpandIconhandler = useCallback(function (e) {
166
+ e.preventDefault();
167
+ e.stopPropagation();
166
168
  if (expanded) {
167
169
  onExpand(expandedKeys.filter(function (key) {
168
170
  return key !== node[fieldNames.key];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kep-platform/basic-component",
3
- "version": "0.0.22",
3
+ "version": "0.0.24",
4
4
  "description": "A react library developed with dumi",
5
5
  "module": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -74,10 +74,10 @@
74
74
  "react-dom": "^18.0.0",
75
75
  "stylelint": "^14.9.1"
76
76
  },
77
- "gitHead": "664f06c1285e22d9411eb86b566cb04adf649480",
77
+ "gitHead": "1f2ef83b49da934cc5f6cbfd0d452b82622ea3e9",
78
78
  "dependencies": {
79
79
  "@ant-design/icons": "^5.3.7",
80
- "@kep-platform/hooks": "^0.0.22",
80
+ "@kep-platform/hooks": "^0.0.24",
81
81
  "color": "^4.2.3",
82
82
  "rc-pagination": "^4.1.0",
83
83
  "styled-components": "^6.1.11"