@basic-ui/core 0.0.44 → 0.0.45

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -25,7 +25,7 @@ export type IntrinsicElement<E> = E extends ForwardRefComponent<infer I, any>
25
25
  type ForwardRefExoticComponent<E, OwnProps> = React.ForwardRefExoticComponent<
26
26
  Merge<
27
27
  E extends React.ElementType ? React.ComponentPropsWithRef<E> : never,
28
- OwnProps & { as?: E }
28
+ OwnProps & { as?: E; innerAs?: E }
29
29
  >
30
30
  >;
31
31
 
@@ -47,11 +47,14 @@ export interface ForwardRefComponent<
47
47
  */
48
48
  <As = IntrinsicElementString>(
49
49
  props: As extends ''
50
- ? { as: keyof JSX.IntrinsicElements }
50
+ ? {
51
+ as: keyof JSX.IntrinsicElements;
52
+ innerAs?: keyof JSX.IntrinsicElements;
53
+ }
51
54
  : As extends React.ComponentType<infer P>
52
- ? Merge<P, OwnProps & { as: As }>
55
+ ? Merge<P, OwnProps & { as: As; innerAs?: As }>
53
56
  : As extends keyof JSX.IntrinsicElements
54
- ? Merge<JSX.IntrinsicElements[As], OwnProps & { as: As }>
57
+ ? Merge<JSX.IntrinsicElements[As], OwnProps & { as: As; innerAs?: As }>
55
58
  : never
56
59
  ): React.ReactElement | null;
57
60
  }
@@ -62,11 +65,14 @@ export interface MemoComponent<IntrinsicElementString, OwnProps = {}>
62
65
  > {
63
66
  <As = IntrinsicElementString>(
64
67
  props: As extends ''
65
- ? { as: keyof JSX.IntrinsicElements }
68
+ ? {
69
+ as: keyof JSX.IntrinsicElements;
70
+ innerAs?: keyof JSX.IntrinsicElements;
71
+ }
66
72
  : As extends React.ComponentType<infer P>
67
- ? Merge<P, OwnProps & { as: As }>
73
+ ? Merge<P, OwnProps & { as: As; innerAs?: As }>
68
74
  : As extends keyof JSX.IntrinsicElements
69
- ? Merge<JSX.IntrinsicElements[As], OwnProps & { as: As }>
75
+ ? Merge<JSX.IntrinsicElements[As], OwnProps & { as: As; innerAs?: As }>
70
76
  : never
71
77
  ): React.ReactElement | null;
72
78
  }