Setup styled-components, typescript, barebones button component, global styles, and shared css variables

This commit is contained in:
2021-09-19 18:31:35 -04:00
parent 89b26adb02
commit 2480b5200d
19 changed files with 26617 additions and 183 deletions

11
.storybook/main.js Normal file
View File

@@ -0,0 +1,11 @@
module.exports = {
"stories": [
"../src/**/*.stories.mdx",
"../src/**/*.stories.@(js|jsx|ts|tsx)"
],
"addons": [
"@storybook/addon-links",
"@storybook/addon-essentials",
"@storybook/preset-create-react-app"
]
}

View File

@@ -0,0 +1,8 @@
<link
rel="stylesheet"
href="https://fonts.googleapis.com/css2?family=IBM+Plex+Mono&display=swap"
/>
<link
rel="stylesheet"
href="https://fonts.googleapis.com/css?family=Nunito+Sans:400,700,800,900"
/>

22
.storybook/preview.js Normal file
View File

@@ -0,0 +1,22 @@
import React from "react";
import { GlobalStyle } from "../src/shared/global";
// Global decorator to apply the styles to all stories
export const decorators = [
(Story) => (
<>
<GlobalStyle />
<Story />
</>
),
];
export const parameters = {
actions: { argTypesRegex: "^on[A-Z].*" },
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/,
},
},
};