Skip to content

Commit d628c9b

Browse files
authored
Avoid rc package deep imports (#327)
* fix: avoid rc package deep imports * chore: address import review comments
1 parent 533ee70 commit d628c9b

3 files changed

Lines changed: 4 additions & 7 deletions

File tree

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,12 @@
4747
},
4848
"dependencies": {
4949
"@babel/runtime": "^7.11.1",
50-
"@rc-component/util": "^1.3.0",
50+
"@rc-component/util": "^1.11.1",
5151
"clsx": "^2.1.1",
5252
"@rc-component/motion": "^1.1.4"
5353
},
5454
"devDependencies": {
55-
"@rc-component/father-plugin": "^2.0.1",
55+
"@rc-component/father-plugin": "^2.2.0",
5656
"@rc-component/np": "^1.0.0",
5757
"@testing-library/jest-dom": "^6.9.1",
5858
"@testing-library/react": "^14.2.1",

src/MotionThumb.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import CSSMotion from '@rc-component/motion';
2-
import useLayoutEffect from '@rc-component/util/lib/hooks/useLayoutEffect';
3-
import { composeRef } from '@rc-component/util/lib/ref';
2+
import { composeRef, useLayoutEffect } from '@rc-component/util';
43
import { clsx } from 'clsx';
54
import * as React from 'react';
65
import type { SegmentedValue } from '.';

src/index.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
import useControlledState from '@rc-component/util/lib/hooks/useControlledState';
2-
import omit from '@rc-component/util/lib/omit';
3-
import { composeRef } from '@rc-component/util/lib/ref';
1+
import { composeRef, omit, useControlledState } from '@rc-component/util';
42
import { clsx } from 'clsx';
53
import * as React from 'react';
64

0 commit comments

Comments
 (0)