diff --git a/example/storybook/src/api/DescendantsStyles/ContextBasedStyles.tsx b/example/storybook/src/api/DescendantsStyles/ContextBasedStyles.tsx index 9e3a533b6..03351aa26 100644 --- a/example/storybook/src/api/DescendantsStyles/ContextBasedStyles.tsx +++ b/example/storybook/src/api/DescendantsStyles/ContextBasedStyles.tsx @@ -6,6 +6,8 @@ import { Wrapper } from '../../components/Wrapper'; import { AnimatedView } from '@gluestack-style/animation-resolver'; import { CameraIcon } from 'lucide-react-native'; +import Link from 'next/link'; +import { Pressable } from 'react-native'; export const BaseIcon = styled( AsForwarder, { @@ -114,11 +116,27 @@ const Text1 = styled( } ); +const MyLink = styled(Link, {}); export function ContextBasedStyles() { return ( {/* */} - vdkbkdfbv + {/* + vdkbkdfbv + */} + + next link + ); } diff --git a/packages/react/package.json b/packages/react/package.json index 2f31e978c..996e405bc 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,7 +1,7 @@ { "name": "@gluestack-style/react", "description": "A universal & performant styling library for React Native, Next.js & React", - "version": "1.0.0-alpha.0", + "version": "1.0.0-alpha.1", "keywords": [ "React Native", "Next.js", diff --git a/packages/react/src/generateStylePropsFromCSSIds.ts b/packages/react/src/generateStylePropsFromCSSIds.ts index f657a1efe..72cdc4c2a 100644 --- a/packages/react/src/generateStylePropsFromCSSIds.ts +++ b/packages/react/src/generateStylePropsFromCSSIds.ts @@ -170,11 +170,13 @@ export function generateStylePropsFromCSSIds( } Object.assign(props, { - style: propsStyles ? [...styleObj, ...propsStyles] : styleObj, - dataSet: { + 'style': propsStyles ? [...styleObj, ...propsStyles] : styleObj, + 'dataSet': { ...props?.dataSet, style: getDataStyle(props, styleCSSIdsString), }, + // DONOT REMOVE THIS LINE, THIS IS FOR SPECIFIC COMPONENTS LIKE next/link + 'data-style': getDataStyle(props, styleCSSIdsString), }); return props; }