generated from storybookjs/addon-kit
-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: enable more options to enable NativeWind v4 (#81)
Co-authored-by: Daniel Williams <dannyhyunsoowilliams@gmail.com>
- Loading branch information
1 parent
abe1ef8
commit 5bd15b2
Showing
31 changed files
with
3,384 additions
and
3,344 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,8 @@ | ||
module.exports = { | ||
root: true, | ||
extends: ['@react-native-community', 'plugin:storybook/recommended'], | ||
rules: { 'jsx-quotes': [2, 'prefer-single'] }, | ||
rules: { | ||
'jsx-quotes': [2, 'prefer-single'], | ||
'react/react-in-jsx-scope': 'off', | ||
}, | ||
}; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
@tailwind base; | ||
@tailwind components; | ||
@tailwind utilities; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,18 @@ | ||
export const parameters = { | ||
actions: { argTypesRegex: '^on[A-Z].*' }, | ||
controls: { | ||
matchers: { | ||
color: /(background|color)$/i, | ||
date: /Date$/, | ||
import './global.css'; | ||
|
||
const preview = { | ||
parameters: { | ||
actions: { argTypesRegex: '^on[A-Z].*' }, | ||
controls: { | ||
matchers: { | ||
color: /(background|color)$/i, | ||
date: /Date$/, | ||
}, | ||
}, | ||
docs: { | ||
source: { excludeDecorators: true }, | ||
}, | ||
}, | ||
docs: { | ||
source: { excludeDecorators: true }, | ||
}, | ||
}; | ||
|
||
export default preview; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"typescript.tsdk": "node_modules/typescript/lib", | ||
"tailwindCSS.classAttributes": [ | ||
"class", | ||
"className", | ||
"tw", | ||
".*Style", | ||
"color", | ||
"backgroundColor" | ||
], | ||
"tailwindCSS.experimental.classRegex": [ | ||
["cva\\(([^)]*)\\)", "[\"'`]([^\"'`]*).*?[\"'`]"] | ||
] | ||
} |
672 changes: 336 additions & 336 deletions
672
.yarn/releases/yarn-4.0.2.cjs → .yarn/releases/yarn-4.1.0.cjs
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
nodeLinker: node-modules | ||
|
||
yarnPath: .yarn/releases/yarn-4.0.2.cjs | ||
yarnPath: .yarn/releases/yarn-4.1.0.cjs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/// <reference types="nativewind/types" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
// postcss.config.js | ||
module.exports = { | ||
plugins: { | ||
'postcss-import': {}, | ||
tailwindcss: {}, | ||
autoprefixer: {}, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import { Meta, StoryObj } from '@storybook/react'; | ||
|
||
import { ButtonWind } from './ButtonWind'; | ||
|
||
const meta = { | ||
title: 'components/ButtonWind', | ||
component: ButtonWind, | ||
} satisfies Meta<typeof ButtonWind>; | ||
|
||
export default meta; | ||
|
||
type Story = StoryObj<typeof meta>; | ||
|
||
export const Basic: Story = { | ||
args: { | ||
label: 'Click me', | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import * as React from 'react'; | ||
import { StyleProp, Text, ViewStyle, TouchableOpacity } from 'react-native'; | ||
|
||
type ButtonProps = { | ||
onPress: () => void; | ||
label: string; | ||
style?: StyleProp<ViewStyle>; | ||
}; | ||
|
||
export const ButtonWind = ({ onPress, label, style }: ButtonProps) => { | ||
return ( | ||
<TouchableOpacity | ||
className='bg-slate-500 min-w-0 px-4 py-2 rounded w-24' | ||
style={style} | ||
onPress={onPress} | ||
> | ||
<Text className='text-white text-center'>{label}</Text> | ||
</TouchableOpacity> | ||
); | ||
}; |
Oops, something went wrong.