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

Commit

Permalink
Merge pull request #361 from gluestack/fix/passing-props-typing
Browse files Browse the repository at this point in the history
Fix/passing props typing
  • Loading branch information
surajahmed authored Aug 31, 2023
2 parents 305bbac + 40e61e5 commit b791a4c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion packages/react/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@gluestack-style/react",
"description": "A universal & performant styling library for React Native, Next.js & React",
"version": "0.2.10-alpha.0",
"version": "0.2.11",
"keywords": [
"React Native",
"Next.js",
Expand Down
8 changes: 4 additions & 4 deletions packages/react/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,9 @@ export type Aliases = GSConfig['aliases'];
export type Components = GSConfig['components'];
export type IMediaQueries = keyof GSConfig['tokens']['mediaQueries'];

export type SxStyleProps<GenericComponentStyles, Variants> = {
sx?: SxProps<GenericComponentStyles, Variants> & {
[Key in `@${IMediaQueries}`]?: SxProps<GenericComponentStyles, Variants>;
export type SxStyleProps<GenericComponentStyles, Variants, P> = {
sx?: SxProps<GenericComponentStyles, Variants, P> & {
[Key in `@${IMediaQueries}`]?: SxProps<GenericComponentStyles, Variants, P>;
};
};

Expand Down Expand Up @@ -540,7 +540,7 @@ export interface GSConfig
/********************* COMPONENT PROPS TYPE *****************************************/

export type ComponentProps<GenericComponentStyles, Variants, P, ComCon> =
SxStyleProps<GenericComponentStyles, Variants> & {
SxStyleProps<GenericComponentStyles, Variants, P> & {
states?: {
[K in IState]?: boolean;
};
Expand Down

0 comments on commit b791a4c

Please sign in to comment.