https://github.com/react-widget/scrollview
https://github.com/react-widget/scrollview
Last synced: 11 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/react-widget/scrollview
- Owner: react-widget
- Created: 2018-06-29T13:42:06.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-09T07:07:34.000Z (about 3 years ago)
- Last Synced: 2025-02-14T09:43:02.304Z (12 months ago)
- Language: JavaScript
- Homepage: https://react-widget.github.io/scrollview/
- Size: 3.9 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 19
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# scrollview
## Install
`npm install --save react-widget-scrollview`
## Options
```
static propTypes = {
prefixCls: PropTypes.string,
className: PropTypes.oneOfType([PropTypes.string, PropTypes.object]),
scrollViewBodyCls: PropTypes.string,
scrollViewBodyStyle: PropTypes.object,
overflow: PropTypes.oneOfType(['hidden', 'auto', 'scroll', 'visible']),
overflowX: PropTypes.oneOfType(['hidden', 'auto', 'scroll', 'visible']),
overflowY: PropTypes.oneOfType(['hidden', 'auto', 'scroll', 'visible']),
wheelDir: PropTypes.oneOfType(['x', 'y']),
thumbCls: PropTypes.string,
trackCls: PropTypes.string,
scrollBarSize: PropTypes.number,
thumbSize: PropTypes.number,
thumbMinSize: PropTypes.number,
thumbMaxSize: PropTypes.number,
showTrack: PropTypes.bool,
scrollBarOffsetTopOrLeft: PropTypes.number,
scrollBarOffsetRightOrBottom: PropTypes.number,
wheelStep: PropTypes.number,
enablePreventDefaultOnEnd: PropTypes.bool,
onScroll: PropTypes.func,
onHScrollEnd: PropTypes.func,
onVScrollEnd: PropTypes.func,
onHScrollStart: PropTypes.func,
onVScrollStart: PropTypes.func,
};
static defaultProps = {
prefixCls: 'rw-scrollview',
className: '',
scrollViewBodyCls: '',
overflow: 'auto',
overflowX: 'auto',
overflowY: 'auto',
scrollBarSize: 7,
scrollBarOffsetTopOrLeft: 2,
scrollBarOffsetRightOrBottom: 0,
wheelDir: 'y',
thumbCls: '',
trackCls: '',
thumbSize: null,
thumbMinSize: 6,
thumbMaxSize: 999999,
showTrack: true,
wheelStep: 100,
enablePreventDefaultOnEnd: true,
onScroll: null,
onHScrollEnd: null,
onVScrollEnd: null,
onHScrollStart: null,
onVScrollStart: null,
};
```