Skip to content

Commit

Permalink
Fix the CheckboxGroupInput design
Browse files Browse the repository at this point in the history
  • Loading branch information
Luwangel committed Jan 10, 2019
1 parent ad3b948 commit 9fe6f2b
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion packages/ra-ui-materialui/src/input/CheckboxGroupInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,12 @@ const sanitizeRestProps = ({ setFilter, setPagination, setSort, ...rest }) =>
const styles = theme => ({
root: {},
label: {
transform: 'translate(0, 5px) scale(0.75)',
transform: 'translate(0, 1.5px) scale(0.75)',
transformOrigin: `top ${theme.direction === 'ltr' ? 'left' : 'right'}`,
},
checkbox: {
height: 32,
},
});

/**
Expand Down Expand Up @@ -114,6 +117,7 @@ export class CheckboxGroupInput extends Component {
options,
translate,
translateChoice,
classes,
} = this.props;
const choiceName = React.isValidElement(optionText) // eslint-disable-line no-nested-ternary
? React.cloneElement(optionText, { record: choice })
Expand All @@ -136,6 +140,7 @@ export class CheckboxGroupInput extends Component {
<Checkbox
id={`${id}_${get(choice, optionValue)}`}
color="primary"
className={classes.checkbox}
{...options}
/>
}
Expand Down

0 comments on commit 9fe6f2b

Please sign in to comment.