Skip to content
This repository has been archived by the owner on Dec 11, 2023. It is now read-only.

Commit

Permalink
fix: children types
Browse files Browse the repository at this point in the history
  • Loading branch information
ankit-tailor committed Nov 22, 2023
1 parent a2a7c68 commit 188be37
Showing 1 changed file with 4 additions and 14 deletions.
18 changes: 4 additions & 14 deletions packages/react/src/styled.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -994,7 +994,6 @@ export function verboseStyled<P, Variants, ComCon>(

const StyledComponent = (
{
children,
//@ts-ignore
orderedResolved: BUILD_TIME_ORDERED_RESOLVED = [],
//@ts-ignore
Expand All @@ -1009,7 +1008,6 @@ export function verboseStyled<P, Variants, ComCon>(
Partial<ComponentProps<ITypeReactNativeStyles, Variants, P, ComCon>> &
Partial<UtilityProps<ITypeReactNativeStyles, Variants, P>> & {
as?: any;
children?: any;
},
'animationComponentGluestack'
>,
Expand Down Expand Up @@ -2019,15 +2017,11 @@ export function verboseStyled<P, Variants, ComCon>(
style={resolvedStyleMemo}
as={AsComp}
ref={ref}
>
{children}
</ComponentWithPlugin>
/>
);
} else {
component = (
<AsComp {...resolvedStyleProps} style={resolvedStyleMemo} ref={ref}>
{children}
</AsComp>
<AsComp {...resolvedStyleProps} style={resolvedStyleMemo} ref={ref} />
);
}
} else {
Expand All @@ -2040,18 +2034,14 @@ export function verboseStyled<P, Variants, ComCon>(
states={states}
style={resolvedStyleMemo}
ref={ref}
>
{children}
</ComponentWithPlugin>
/>
) : (
<ComponentWithPlugin
{...resolvedStyleProps}
{...propsToBePassedInToPlugin}
style={resolvedStyleMemo}
ref={ref}
>
{children}
</ComponentWithPlugin>
/>
);
}
if (containsDescendant) {
Expand Down

0 comments on commit 188be37

Please sign in to comment.