mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-22 09:57:02 +01:00
fix Box ts spread props issue (#20107)
This commit is contained in:
parent
733391a964
commit
26d7520a84
@ -8,7 +8,7 @@ import {
|
||||
|
||||
import { Box } from '..';
|
||||
|
||||
import type { PolymorphicRef } from '../box';
|
||||
import type { PolymorphicRef, BoxProps } from '../box';
|
||||
|
||||
import { TextProps, TextComponent } from './text.types';
|
||||
|
||||
@ -63,6 +63,7 @@ export const Text: TextComponent = React.forwardRef(
|
||||
[`mm-text--overflow-wrap-${overflowWrap}`]: Boolean(overflowWrap),
|
||||
},
|
||||
);
|
||||
|
||||
return (
|
||||
<Box
|
||||
className={classnames(computedClassName)}
|
||||
@ -70,7 +71,7 @@ export const Text: TextComponent = React.forwardRef(
|
||||
dir={textDirection}
|
||||
ref={ref}
|
||||
color={TextColor.textDefault}
|
||||
{...props} // TODO: Need to fix Box types to allow for spreading props
|
||||
{...(props as BoxProps<C>)}
|
||||
>
|
||||
{children}
|
||||
</Box>
|
||||
|
Loading…
Reference in New Issue
Block a user