Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
3y3 committed Sep 14, 2023
1 parent 3e007ef commit 5d92593
Show file tree
Hide file tree
Showing 48 changed files with 44,284 additions and 20,775 deletions.
4 changes: 2 additions & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ module.exports = {
},
'newlines-between': 'always',
groups: [['builtin', 'external'], 'internal', 'parent', 'sibling', 'index'],
warnOnUnassignedImports: true,
// warnOnUnassignedImports: true,
pathGroups: [
{
pattern: '*.s?css$',
pattern: '.scss',
group: 'index',
},
],
Expand Down
18 changes: 18 additions & 0 deletions demo/.babelrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"sourceType": "unambiguous",
"presets": [
[
"@babel/preset-env",
{
"targets": {
"chrome": 100,
"safari": 15,
"firefox": 91
}
}
],
"@babel/preset-react",
"@babel/preset-typescript"
],
"plugins": []
}
3 changes: 3 additions & 0 deletions demo/.storybook/global.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.sb-show-main.sb-main-centered #storybook-root {
padding: 0;
}
45 changes: 45 additions & 0 deletions demo/.storybook/main.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
import {join, dirname} from 'path';

/** @type { import('@storybook/react-webpack5').StorybookConfig } */
const config = {
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],
addons: [
'@storybook/addon-links',
'@storybook/addon-essentials',
{
name: '@storybook/addon-styling',
options: {
sass: {
implementation: require("sass"),
},
}
},
'@storybook/addon-onboarding',
'@storybook/addon-interactions',

],
framework: {
name: '@storybook/react-webpack5',
options: {},
},
docs: {
autodocs: 'tag',
},
async webpackFinal(config, { configType }) {
config.resolve = config.resolve || {};
config.resolve.alias = {
...(config.resolve.alias || {}),
'react': dirname(require.resolve('react')),
'react-dom': dirname(require.resolve('react-dom')),
};
config.module.rules.push({
test: /\.svg$/,
type: 'javascript/auto',
use: ['@svgr/webpack'],
});

return config;
}
};

export default config;
18 changes: 18 additions & 0 deletions demo/.storybook/preview.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/** @type { import('@storybook/react').Preview } */
import { Preview } from '@storybook/react';

import './global.css';

const preview: Preview = {
parameters: {
actions: {argTypesRegex: '^on[A-Z].*'},
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/,
},
},
},
};

export default preview;
Loading

0 comments on commit 5d92593

Please sign in to comment.