Skip to content

Commit b92aba0

Browse files
committed
feat: update react-sticky-box
1 parent bcc7ae0 commit b92aba0

File tree

5 files changed

+11
-32
lines changed

5 files changed

+11
-32
lines changed

packages/antd/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969
"@formily/shared": "2.1.2",
7070
"classnames": "^2.2.6",
7171
"react-sortable-hoc": "^1.11.0",
72-
"react-sticky-box": "^0.9.3"
72+
"react-sticky-box": "^1.0.2"
7373
},
7474
"publishConfig": {
7575
"access": "public"

packages/antd/src/form-button-group/index.tsx

+2-12
Original file line numberDiff line numberDiff line change
@@ -5,24 +5,14 @@
55
* 4. 吸底布局
66
*/
77
import React, { useRef, useLayoutEffect, useState } from 'react'
8-
import StickyBox, { StickyBoxMode } from 'react-sticky-box'
8+
import StickyBox, { StickyBoxCompProps } from 'react-sticky-box'
99
import { ReactFC } from '@formily/react'
1010
import { Space } from 'antd'
1111
import { SpaceProps } from 'antd/lib/space'
1212
import { BaseItem, IFormItemProps } from '../form-item'
1313
import { usePrefixCls } from '../__builtins__'
1414
import cls from 'classnames'
15-
interface IStickyProps {
16-
offsetTop?: number
17-
offsetBottom?: number
18-
bottom?: boolean
19-
onChangeMode?: (
20-
oldMode: StickyBoxMode | undefined,
21-
newMode: StickyBoxMode
22-
) => any
23-
style?: React.CSSProperties
24-
className?: string
25-
padding?: number
15+
interface IStickyProps extends StickyBoxCompProps {
2616
align?: React.CSSProperties['textAlign']
2717
}
2818

packages/next/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@
6868
"@formily/shared": "2.1.2",
6969
"classnames": "^2.2.6",
7070
"react-sortable-hoc": "^1.11.0",
71-
"react-sticky-box": "^0.9.3"
71+
"react-sticky-box": "^1.0.2"
7272
},
7373
"publishConfig": {
7474
"access": "public"

packages/next/src/form-button-group/index.tsx

+2-12
Original file line numberDiff line numberDiff line change
@@ -5,23 +5,13 @@
55
* 4. 吸底布局
66
*/
77
import React, { useRef, useLayoutEffect, useState } from 'react'
8-
import StickyBox, { StickyBoxMode } from 'react-sticky-box'
8+
import StickyBox, { StickyBoxCompProps } from 'react-sticky-box'
99
import { ReactFC } from '@formily/react'
1010
import { Space, ISpaceProps } from '../space'
1111
import { BaseItem, IFormItemProps } from '../form-item'
1212
import { usePrefixCls } from '../__builtins__'
1313
import cls from 'classnames'
14-
interface IStickyProps {
15-
offsetTop?: number
16-
offsetBottom?: number
17-
bottom?: boolean
18-
onChangeMode?: (
19-
oldMode: StickyBoxMode | undefined,
20-
newMode: StickyBoxMode
21-
) => any
22-
style?: React.CSSProperties
23-
className?: string
24-
padding?: number
14+
interface IStickyProps extends StickyBoxCompProps {
2515
align?: React.CSSProperties['textAlign']
2616
}
2717

yarn.lock

+5-6
Original file line numberDiff line numberDiff line change
@@ -1115,7 +1115,7 @@
11151115
dependencies:
11161116
regenerator-runtime "^0.13.4"
11171117

1118-
"@babel/runtime@^7.0.0", "@babel/runtime@^7.1.2", "@babel/runtime@^7.1.5", "@babel/runtime@^7.10.1", "@babel/runtime@^7.10.2", "@babel/runtime@^7.10.4", "@babel/runtime@^7.11.0", "@babel/runtime@^7.11.1", "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.1", "@babel/runtime@^7.12.5", "@babel/runtime@^7.2.0", "@babel/runtime@^7.5.5", "@babel/runtime@^7.7.2", "@babel/runtime@^7.7.6", "@babel/runtime@^7.8.4", "@babel/runtime@^7.9.2":
1118+
"@babel/runtime@^7.0.0", "@babel/runtime@^7.1.2", "@babel/runtime@^7.10.1", "@babel/runtime@^7.10.2", "@babel/runtime@^7.10.4", "@babel/runtime@^7.11.0", "@babel/runtime@^7.11.1", "@babel/runtime@^7.11.2", "@babel/runtime@^7.12.1", "@babel/runtime@^7.12.5", "@babel/runtime@^7.2.0", "@babel/runtime@^7.5.5", "@babel/runtime@^7.7.2", "@babel/runtime@^7.7.6", "@babel/runtime@^7.8.4", "@babel/runtime@^7.9.2":
11191119
version "7.17.9"
11201120
resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.17.9.tgz#d19fbf802d01a8cb6cf053a64e472d42c434ba72"
11211121
integrity sha512-lSiBBvodq29uShpWGNbgFdKYNiFDo5/HIYsaCEY9ff4sb10x9jizo2+pRrSyF4jKZCXqgzuqBOQKbUm90gQwJg==
@@ -16868,12 +16868,11 @@ react-sortable-hoc@^1.11.0:
1686816868
invariant "^2.2.4"
1686916869
prop-types "^15.5.7"
1687016870

16871-
react-sticky-box@^0.9.3:
16872-
version "0.9.3"
16873-
resolved "https://registry.yarnpkg.com/react-sticky-box/-/react-sticky-box-0.9.3.tgz#8450d4cef8e4fdd7b0351520365bc98c97da11af"
16874-
integrity sha512-Y/qO7vTqAvXuRR6G6ZCW4fX2Bz0GZRwiiLTVeZN5CVz9wzs37ev0Xj3KSKF/PzF0jifwATivI4t24qXG8rSz4Q==
16871+
react-sticky-box@^1.0.2:
16872+
version "1.0.2"
16873+
resolved "http://npm.indexed.cn/react-sticky-box/-/react-sticky-box-1.0.2.tgz#7e72a0f237bdf8270cec9254337f49519a411174"
16874+
integrity sha512-Kyvtppdtv1KqJyNU4DtrSMI0unyQRgtraZvVQ0GAazVbYiTsIVpyhpr+5R0Aavzu4uJNSe1awj2rk/qI7i6Zfw==
1687516875
dependencies:
16876-
"@babel/runtime" "^7.1.5"
1687716876
resize-observer-polyfill "^1.5.1"
1687816877

1687916878
react-test-renderer@^16.11.0:

0 commit comments

Comments
 (0)