Skip to content

Commit c56b68d

Browse files
committed
patch things
1 parent 8413997 commit c56b68d

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

packages/clerk-js/src/ui/lazyModules/providers.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ export const LazyComponentRenderer = (props: LazyComponentRendererProps) => {
7676
>
7777
<Portal
7878
node={props.node}
79-
component={ClerkComponents['PlanDetails']}
79+
component={ClerkComponents[props.componentName as ClerkComponentName]}
8080
props={props.componentProps}
8181
componentName={props.componentName}
8282
/>

packages/react/src/components/PlanDetailsButton.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import type { __experimental_PlanDetailsButtonProps } from '@clerk/types';
1+
import type { __experimental_PlanDetailsButtonProps, FlattenUnionType } from '@clerk/types';
22
import React from 'react';
33

44
import type { WithClerkProp } from '../types';
@@ -35,7 +35,8 @@ import { withClerk } from './withClerk';
3535
*/
3636
export const PlanDetailsButton = withClerk(
3737
({ clerk, children, ...props }: WithClerkProp<React.PropsWithChildren<__experimental_PlanDetailsButtonProps>>) => {
38-
const { plan, planId, initialPlanPeriod, planDetailsProps, ...rest } = props;
38+
const { plan, planId, initialPlanPeriod, planDetailsProps, ...rest } =
39+
props as FlattenUnionType<__experimental_PlanDetailsButtonProps>;
3940
children = normalizeWithDefaultValue(children, 'Plan details');
4041
const child = assertSingleChild(children)('PlanDetailsButton');
4142

@@ -45,6 +46,7 @@ export const PlanDetailsButton = withClerk(
4546
}
4647

4748
return clerk.__internal_openPlanDetails({
49+
// @ts-expect-error - plan is not required
4850
plan,
4951
planId,
5052
initialPlanPeriod,

0 commit comments

Comments
 (0)