Skip to content

Commit

Permalink
Merge pull request #1694 from gluestack/release/@gluestack-style/reac…
Browse files Browse the repository at this point in the history
  • Loading branch information
ankit-tailor authored Jan 24, 2024
2 parents 2a2f7cc + 6076a8e commit 8bf701e
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 11 deletions.
8 changes: 8 additions & 0 deletions packages/config/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# @gluestack-ui/config

## 1.1.1

### Patch Changes

- - Fixed typescript memory overflow issue [PR](https://github.com/gluestack/gluestack-ui/pull/1693)
- Updated dependencies
- @gluestack-style/react@1.0.43

## 2.0.0

### Patch Changes
Expand Down
4 changes: 2 additions & 2 deletions packages/config/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@gluestack-ui/config",
"version": "1.1.0",
"version": "1.1.1",
"main": "build/gluestack-ui.config.js",
"types": "build/gluestack-ui.config.d.ts",
"module": "build/gluestack-ui.config",
Expand Down Expand Up @@ -29,7 +29,7 @@
"author": "",
"license": "ISC",
"devDependencies": {
"@gluestack-style/react": "^1.0.22",
"@gluestack-style/react": "^1.0.43",
"@gluestack-ui/themed": "^1.1.0"
},
"peerDependencies": {
Expand Down
6 changes: 6 additions & 0 deletions packages/styled/react/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# @gluestack-style/react

## 1.0.43

### Patch Changes

- - Fixed typescript memory overflow issue [PR](https://github.com/gluestack/gluestack-ui/pull/1693)

## 1.0.42

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/styled/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": "1.0.42",
"version": "1.0.43",
"keywords": [
"React Native",
"Next.js",
Expand Down
18 changes: 10 additions & 8 deletions packages/styled/react/src/createStyle.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
import type { ViewProps, ImageProps, TextProps } from 'react-native';
import type {
IComponentStyleConfig,
ITheme,
UnionToIntersection,
} from './types';
import type { IComponentStyleConfig, ITheme } from './types';

export const createStyle = <T, Variants>(
theme: T | ITheme<Variants, ViewProps | ImageProps | TextProps>,
Expand All @@ -17,9 +13,15 @@ export const createStyle = <T, Variants>(
};

return createdStyles as {
theme: UnionToIntersection<
T | ITheme<Variants, ViewProps | ImageProps | TextProps>
>;
theme: {
variants: keyof Variants extends never
? {}
: {
[key in keyof Variants]: {
[k in keyof Variants[key]]: any;
};
};
};
componentConfig?: Omit<IComponentStyleConfig, 'componentName'>;
};
};

0 comments on commit 8bf701e

Please sign in to comment.