From 5fcf22e028bf878c5be854c19074480cadf8b4bc Mon Sep 17 00:00:00 2001 From: afc163 Date: Tue, 8 Dec 2015 22:11:02 +0800 Subject: default select value at first position --- src/module/Select.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/module/Select.jsx b/src/module/Select.jsx index 0b91ac5..8cf4e2d 100644 --- a/src/module/Select.jsx +++ b/src/module/Select.jsx @@ -62,7 +62,7 @@ const Select = React.createClass({ // move to selected item const select = ReactDom.findDOMNode(this); const list = ReactDom.findDOMNode(this.refs.list); - let index = this.props.selectedIndex - 1; + let index = this.props.selectedIndex; if (index < 0) { index = 0; } -- cgit v1.2.3