From 9a81462cc4dff6d63f46c3fdc754774edbbd1bef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8C=E8=B4=A7=E6=9C=BA=E5=99=A8=E4=BA=BA?= Date: Thu, 9 Jan 2025 14:55:25 +0800 Subject: [PATCH 1/3] chore: update deps --- package.json | 5 +++-- src/Collapse.tsx | 6 +++--- src/Panel.tsx | 2 +- src/hooks/useItems.tsx | 2 +- 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/package.json b/package.json index 616b7a0..f5e958d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { - "name": "rc-collapse", - "version": "4.0.0", + "name": "@rc-component/collapse", + "version": "1.0.0-0", "description": "rc-collapse ui component for react", "keywords": [ "react", @@ -46,6 +46,7 @@ }, "dependencies": { "@babel/runtime": "^7.10.1", + "@rc-component/util": "^1.0.0", "classnames": "2.x", "rc-motion": "^2.3.4", "rc-util": "^5.27.0" diff --git a/src/Collapse.tsx b/src/Collapse.tsx index 0623138..0504476 100644 --- a/src/Collapse.tsx +++ b/src/Collapse.tsx @@ -1,11 +1,11 @@ import classNames from 'classnames'; -import useMergedState from 'rc-util/lib/hooks/useMergedState'; -import warning from 'rc-util/lib/warning'; +import useMergedState from '@rc-component/util/lib/hooks/useMergedState'; +import warning from '@rc-component/util/lib/warning'; import React from 'react'; import useItems from './hooks/useItems'; import type { CollapseProps } from './interface'; import CollapsePanel from './Panel'; -import pickAttrs from 'rc-util/lib/pickAttrs'; +import pickAttrs from '@rc-component/util/lib/pickAttrs'; function getActiveKeysArray(activeKey: React.Key | React.Key[]) { let currentActiveKey = activeKey; diff --git a/src/Panel.tsx b/src/Panel.tsx index 613719f..c463325 100644 --- a/src/Panel.tsx +++ b/src/Panel.tsx @@ -1,6 +1,6 @@ import classNames from 'classnames'; import CSSMotion from 'rc-motion'; -import KeyCode from 'rc-util/lib/KeyCode'; +import KeyCode from '@rc-component/util/lib/KeyCode'; import React from 'react'; import type { CollapsePanelProps } from './interface'; import PanelContent from './PanelContent'; diff --git a/src/hooks/useItems.tsx b/src/hooks/useItems.tsx index 2bc5db7..5c86d02 100644 --- a/src/hooks/useItems.tsx +++ b/src/hooks/useItems.tsx @@ -1,4 +1,4 @@ -import toArray from 'rc-util/lib/Children/toArray'; +import toArray from '@rc-component/util/lib/Children/toArray'; import React from 'react'; import type { CollapsePanelProps, CollapseProps, ItemType } from '../interface'; import CollapsePanel from '../Panel'; From 3946e5c2873984492fc90dc5ceb35fdf47704410 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8C=E8=B4=A7=E6=9C=BA=E5=99=A8=E4=BA=BA?= Date: Thu, 9 Jan 2025 15:46:10 +0800 Subject: [PATCH 2/3] chore: bump father plugin --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index f5e958d..f7513e3 100644 --- a/package.json +++ b/package.json @@ -46,13 +46,13 @@ }, "dependencies": { "@babel/runtime": "^7.10.1", - "@rc-component/util": "^1.0.0", + "@rc-component/util": "^1.0.1", "classnames": "2.x", "rc-motion": "^2.3.4", "rc-util": "^5.27.0" }, "devDependencies": { - "@rc-component/father-plugin": "^1.0.1", + "@rc-component/father-plugin": "^2.0.1", "@testing-library/jest-dom": "^6.1.4", "@testing-library/react": "^14.1.2", "@testing-library/user-event": "^14.5.2", From bb55c280b3a1f82100ec5e41b19175773756c9be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8C=E8=B4=A7=E6=9C=BA=E5=99=A8=E4=BA=BA?= Date: Thu, 9 Jan 2025 15:47:56 +0800 Subject: [PATCH 3/3] chore: clean up --- package.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/package.json b/package.json index f7513e3..9dfb7fe 100644 --- a/package.json +++ b/package.json @@ -48,8 +48,7 @@ "@babel/runtime": "^7.10.1", "@rc-component/util": "^1.0.1", "classnames": "2.x", - "rc-motion": "^2.3.4", - "rc-util": "^5.27.0" + "rc-motion": "^2.3.4" }, "devDependencies": { "@rc-component/father-plugin": "^2.0.1",