Skip to content

Commit 0f8cbb1

Browse files
committed
Preparing for scrollToTop
1 parent 5be5544 commit 0f8cbb1

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

packages/component/src/BasicScrollToBottom.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const ROOT_CSS = css({
1111
});
1212

1313
export default props =>
14-
<Composer>
14+
<Composer mode={ props.mode === 'top' ? 'top' : 'bottom'}>
1515
<div className={ classNames(ROOT_CSS + '', props.className) }>
1616
<Panel>
1717
{ props.children }

packages/playground/src/App.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,10 @@ class App extends Component {
5252
};
5353
}
5454

55+
componentDidMount() {
56+
this.handleAdd(10);
57+
}
58+
5559
handleAdd(count) {
5660
this.setState(state => ({
5761
paragraphs: [

0 commit comments

Comments
 (0)