Skip to content

Commit

Permalink
fix(component): Fixe RadioButton cursor style
Browse files Browse the repository at this point in the history
  • Loading branch information
myxvisual committed Jun 27, 2017
1 parent 982de2f commit 31cc11a
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions src/RadioButton/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@ export interface RadioButtonState {
mouseDowned?: boolean;
}

const rootStyle: React.CSSProperties = {
display: "inline-block",
verticalAlign: "middle",
cursor: "default"
};
const emptyFunc = () => {};
export class RadioButton extends React.Component<RadioButtonProps, RadioButtonState> {
static defaultProps: RadioButtonProps = {
Expand Down Expand Up @@ -136,7 +141,10 @@ export class RadioButton extends React.Component<RadioButtonProps, RadioButtonSt
<div
ref={(rootElm => this.rootElm = rootElm)}
{...attributes}
style={theme.prepareStyles({ display: "inline-block", verticalAlign: "middle", ...style})}
style={style ? theme.prepareStyles({
...rootStyle,
...style
}) : rootStyle}
>
{label ? (
<div
Expand All @@ -153,7 +161,7 @@ export class RadioButton extends React.Component<RadioButtonProps, RadioButtonSt
lineHeight: `${size}px`,
color: disabled ? theme.baseLow : theme.baseMediumHigh,
marginLeft: size / 4,
cursor: "default"
cursor: "text"
}}
>
{label}
Expand Down

0 comments on commit 31cc11a

Please sign in to comment.