2022-12-15 04:03:23 +08:00
|
|
|
import styled from 'styled-components';
|
|
|
|
import { colorText, colorSuccess } from '/imports/ui/stylesheets/styled-components/palette';
|
|
|
|
import Icon from '/imports/ui/components/common/icon/component';
|
2023-05-03 03:24:06 +08:00
|
|
|
import BaseRadio from '@mui/material/Radio';
|
|
|
|
import FormControlLabel from '@mui/material/FormControlLabel';
|
|
|
|
import { styled as muiStyled } from '@mui/system';
|
2022-12-15 04:03:23 +08:00
|
|
|
|
2023-05-03 03:24:06 +08:00
|
|
|
const Radio = muiStyled(BaseRadio)(() => ({
|
|
|
|
'&.Mui-checked': {
|
2022-12-15 04:03:23 +08:00
|
|
|
color: `${colorSuccess} !important`,
|
|
|
|
},
|
2023-05-03 03:24:06 +08:00
|
|
|
}));
|
2022-12-15 04:03:23 +08:00
|
|
|
|
2023-05-03 03:24:06 +08:00
|
|
|
const Label = muiStyled(FormControlLabel)(() => ({
|
|
|
|
'& .MuiFormControlLabel-label': {
|
2022-12-15 04:03:23 +08:00
|
|
|
fontFamily: 'inherit !important',
|
|
|
|
color: `${colorText} !important`,
|
|
|
|
},
|
2023-05-03 03:24:06 +08:00
|
|
|
'&.Mui-disabled': {
|
2022-12-15 04:03:23 +08:00
|
|
|
cursor: 'not-allowed !important',
|
|
|
|
},
|
2023-05-03 03:24:06 +08:00
|
|
|
}));
|
2022-12-15 04:03:23 +08:00
|
|
|
|
|
|
|
const RadioIcon = styled(Icon)``;
|
|
|
|
|
|
|
|
const RadioIconChecked = styled(RadioIcon)``;
|
|
|
|
|
|
|
|
export default {
|
|
|
|
RadioIcon,
|
|
|
|
RadioIconChecked,
|
|
|
|
Radio,
|
|
|
|
Label,
|
|
|
|
};
|