Skip to content

Commit

Permalink
chore: update deps
Browse files Browse the repository at this point in the history
  • Loading branch information
wwsun committed Dec 22, 2021
1 parent 34c5396 commit b62654d
Show file tree
Hide file tree
Showing 4 changed files with 936 additions and 639 deletions.
2 changes: 1 addition & 1 deletion .storybook/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ const TsconfigPathsPlugin = require('tsconfig-paths-webpack-plugin');
module.exports = {
stories: ['../docs/**/*.stories.tsx', '../docs/**/*.stories.tsx'],

addons: ['@storybook/addon-docs', 'storybook-addon-outline', '@storybook/addon-storysource'],
addons: ['@storybook/addon-docs', 'storybook-addon-outline'],

babel: async (config) => {
config.plugins.push('babel-plugin-styled-components');
Expand Down
35 changes: 29 additions & 6 deletions docs/group.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,17 +1,35 @@
import React from 'react';
import { Box, Group } from 'coral-system';
import { css } from 'styled-components';
import styled, { css } from 'styled-components';

export default {
title: 'Group',
component: Group,
};


export const Basic = (args: any) => (
<Group>
<button>left</button>
<button>center</button>
<button>right</button>
<Box as="button">left</Box>
<Box as="button">center</Box>
<Box as="button">right</Box>
</Group>
);

const CustomTag = styled.span`
display: inline-block;
background-color: #666;
color: #FFF;
border-radius: 2px;
padding: 0px 8px;
`;


export const TagGroup = (args: any) => (
<Group display="inline-flex">
<CustomTag>left</CustomTag>
<CustomTag>center</CustomTag>
<CustomTag>right</CustomTag>
</Group>
);

Expand All @@ -35,11 +53,16 @@ export const More = (args: any) => (
);

const injectStyle = css`
background-color: red;
padding: 4px;
> button {
border: 0;
outline: none;
}
`;

export const Custom = (args: any) => (
<Group css={injectStyle}>
<Group bg="red" css={injectStyle}>
<button>left</button>
<button>center</button>
<button>right</button>
Expand Down
20 changes: 10 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,34 +44,34 @@
"lodash-es": "^4.17.21"
},
"devDependencies": {
"@babel/preset-env": "^7.16.4",
"@babel/preset-typescript": "^7.16.0",
"@storybook/addon-docs": "^6.4.0",
"@babel/preset-env": "^7.16.5",
"@babel/preset-typescript": "^7.16.5",
"@storybook/addon-docs": "^6.4.9",
"@storybook/addon-storysource": "^6.4.0",
"@storybook/addons": "^6.4.0",
"@storybook/react": "^6.4.0",
"@storybook/addons": "^6.4.9",
"@storybook/react": "^6.4.9",
"@storybook/storybook-deployer": "^2.8.10",
"@types/jest": "^27.0.3",
"@types/lodash-es": "^4.17.5",
"@types/react": "^17.0.37",
"@types/react-dom": "^17.0.11",
"@types/styled-components": "^5.1.15",
"@types/styled-components": "^5.1.18",
"babel-plugin-styled-components": "^2.0.2",
"eslint": "^8.3.0",
"eslint": "^8.5.0",
"eslint-config-prettier": "8.3.0",
"eslint-config-react": "1.1.7",
"eslint-plugin-jest-dom": "^3.6.3",
"eslint-plugin-prettier": "^4.0.0",
"eslint-plugin-react": "^7.27.1",
"eslint-plugin-react-hooks": "^4.3.0",
"eslint-plugin-testing-library": "^5.0.0",
"eslint-plugin-testing-library": "^5.0.1",
"np": "^7.6.0",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"storybook-addon-outline": "^1.4.1",
"storybook-addon-outline": "^1.4.2",
"styled-components": "^5.3.3",
"tsconfig-paths-webpack-plugin": "^3.5.2",
"typescript": "^4.5.2"
"typescript": "^4.5.4"
},
"publishConfig": {
"registry": "https://registry.npmjs.org"
Expand Down
Loading

0 comments on commit b62654d

Please sign in to comment.