fix(striker-ui): append given className to BodyText default

main
Tsu-ba-me 2 years ago
parent 2849ce4704
commit d082d6d3f6
  1. 5
      striker-ui/components/Text/BodyText.tsx

@ -59,6 +59,7 @@ const buildBodyTextClasses = ({
const BodyText: FC<BodyTextProps> = ({ const BodyText: FC<BodyTextProps> = ({
children, children,
className,
inverted = BODY_TEXT_DEFAULT_PROPS.inverted, inverted = BODY_TEXT_DEFAULT_PROPS.inverted,
monospaced = BODY_TEXT_DEFAULT_PROPS.monospaced, monospaced = BODY_TEXT_DEFAULT_PROPS.monospaced,
selected = BODY_TEXT_DEFAULT_PROPS.selected, selected = BODY_TEXT_DEFAULT_PROPS.selected,
@ -68,11 +69,11 @@ const BodyText: FC<BodyTextProps> = ({
}) => ( }) => (
<MUITypography <MUITypography
{...{ {...{
className: buildBodyTextClasses({ className: `${buildBodyTextClasses({
isInvert: inverted, isInvert: inverted,
isMonospace: monospaced, isMonospace: monospaced,
isSelect: selected, isSelect: selected,
}), })} ${className}`,
variant: 'subtitle1', variant: 'subtitle1',
...muiTypographyRestProps, ...muiTypographyRestProps,
sx: { sx: {

Loading…
Cancel
Save