Skip to content

Commit

Permalink
增加支持传入自定义 className
Browse files Browse the repository at this point in the history
  • Loading branch information
akuma committed May 19, 2016
1 parent 4f76d6e commit 7277f8c
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/components/button/button_area.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,17 @@ export default class ButtonArea extends React.Component {
};

render() {
const {direction, children} = this.props;
const className = classNames({
const {direction, children, className} = this.props;
const cls = classNames({
weui_btn_area: true,
weui_btn_area_inline: direction === 'horizontal'
weui_btn_area_inline: direction === 'horizontal',
[className]: className
});

return (
<div className={className}>
<div className={cls}>
{children}
</div>
);
}
};
};

0 comments on commit 7277f8c

Please sign in to comment.