diff --git a/components/dropdown/index.cjsx b/components/dropdown/index.cjsx index f6eed48c..a5c2284e 100644 --- a/components/dropdown/index.cjsx +++ b/components/dropdown/index.cjsx @@ -1,5 +1,8 @@ ### @todo + +- Disable options +- can set a icon like dispatcher ### require './style' @@ -12,6 +15,7 @@ module.exports = React.createClass className : React.PropTypes.string dataSource : React.PropTypes.object value : React.PropTypes.string + label : React.PropTypes.string getDefaultProps: -> type : "normal" @@ -34,10 +38,11 @@ module.exports = React.createClass className = @props.className if @state.active is true className += " active" - stylesheet = height: @getDOMNode().offsetHeight * Object.keys(@props.dataSource).length -
- {@props.dataSource[@state.value]} + stylesheet = height: @refs.value.getDOMNode().offsetHeight * Object.keys(@props.dataSource).length + +
+ {  if @props.label } + {@props.dataSource[@state.value]}