diff options
| author | Furkan Sahin <furkan-dev@proton.me> | 2023-08-28 21:33:44 -0500 |
|---|---|---|
| committer | Furkan Sahin <furkan-dev@proton.me> | 2023-08-28 21:33:44 -0500 |
| commit | 2a308fb5bec47aac0f59e074d793cec6e95db1c3 (patch) | |
| tree | e8d8026ab7074ae1c273c819e049eb211309e04f /components/Box/index.tsx | |
| parent | a0e64e73ef07c1cc3623d2712c483bf45884d350 (diff) | |
Add wg2nd
Diffstat (limited to 'components/Box/index.tsx')
| -rw-r--r-- | components/Box/index.tsx | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/components/Box/index.tsx b/components/Box/index.tsx new file mode 100644 index 0000000..32866b2 --- /dev/null +++ b/components/Box/index.tsx @@ -0,0 +1,18 @@ +import { getSystemStyle, SystemProps } from '../utils/systemProps'; + +interface BoxProps extends SystemProps { + style?: React.CSSProperties; + children?: React.ReactNode; +}; + +const Box: React.FC<BoxProps> = ({ style, children, ...props}) => { + const systemStyle = getSystemStyle(props, style); + + return ( + <div style={systemStyle}> + { children } + </div> + ); +}; + +export default Box; |
