Skip to content

Commit

Permalink
fix: lint
Browse files Browse the repository at this point in the history
  • Loading branch information
jesperhodge committed Mar 11, 2024
1 parent 32ad997 commit 8f46767
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 18 deletions.
12 changes: 6 additions & 6 deletions src/editors/sharedComponents/SelectableBox/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,12 @@ const SelectableBox = React.forwardRef(({

const isChecked = () => {
switch (type) {
case 'radio':
return radioValue === value;
case 'checkbox':
return checkboxValues.includes(value);
default:
return radioValue === value;
case 'radio':
return radioValue === value;
case 'checkbox':
return checkboxValues.includes(value);
default:
return radioValue === value;
}
};

Expand Down
24 changes: 12 additions & 12 deletions src/editors/sharedComponents/SelectableBox/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,21 @@ import FormCheckboxSet from './FormCheckboxSet';
export const getInputType = (component, type) => {
if (component === 'SelectableBox') {
switch (type) {
case 'radio':
return RadioControl;
case 'checkbox':
return CheckboxControl;
default:
return RadioControl;
case 'radio':
return RadioControl;
case 'checkbox':
return CheckboxControl;
default:
return RadioControl;
}
} else if (component === 'SelectableBoxSet') {
switch (type) {
case 'radio':
return FormRadioSet;
case 'checkbox':
return FormCheckboxSet;
default:
return FormRadioSet;
case 'radio':
return FormRadioSet;
case 'checkbox':
return FormCheckboxSet;
default:
return FormRadioSet;
}
}
};

0 comments on commit 8f46767

Please sign in to comment.