2.0.10 • Published 9 years ago
apeman-react-scroll v2.0.10
apeman-react-scroll
apeman react package for scroll components.
Installation
$ npm install apeman-react-scroll --saveDemo
Live demo is hosted on GitHub Pages.
Usage
'use strict'
import React from 'react'
import {ApScroll, ApScrollStyle} from 'apeman-react-scroll'
const ExampleComponent = React.createClass({
render () {
return (
<div>
<ApScrollStyle />
<ApScroll>
<div>
Scrollable content
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
Hey, there
</div>
</ApScroll>
</div>
)
}
})Components
ApScrollStyle
Props
| Name | Type | Default | Description | |
|---|---|---|---|---|
| style | object | {} | ||
| highlightColor | string | ApStyle.DEFAULT_HIGHLIGHT_COLOR | ||
| backgroundColor | ApStyle.DEFAULT_BACKGROUND_COLOR |
ApScroll
Props
| Name | Type | Default | Description | |
|---|---|---|---|---|
| direction | enum | 'y' | ||
| showScrollbars | bool | false | ||
| disableMouseWheel | bool | false | ||
| iScrollRef | func | (e) => undefined | ||
| onScrollCancel | func | (e) => undefined | ||
| onScrollStart | func | (e) => undefined | ||
| onScroll | func | (e) => undefined | ||
| onScrollEnd | func | (e) => undefined | ||
| onFlick | func | (e) => undefined | ||
| id | `ap-scroll-${uuid.v4()}` |
License
This software is released under the MIT License.