-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(Storybook): migrate to version 6 (#801)
- Loading branch information
Showing
234 changed files
with
48,534 additions
and
42,325 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
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 |
---|---|---|
@@ -1,11 +1,9 @@ | ||
import { create } from '@storybook/theming'; | ||
import brandImage from './textkernel.svg'; | ||
|
||
export const OneUITheme = create({ | ||
export default create({ | ||
base: 'light', | ||
|
||
// Branding | ||
brandTitle: 'Textkernel OneUI', | ||
brandUrl: 'https://textkernel.com', | ||
brandImage | ||
brandImage, | ||
}); |
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,31 @@ | ||
const path = require('path'); | ||
const { getRules } = require('../scripts/build/webpack.config'); | ||
|
||
module.exports = { | ||
stories: [ | ||
'../stories/theme/*.@(js|jsx|ts|tsx)', | ||
'../stories/atoms/*.@(js|jsx|ts|tsx)', | ||
'../stories/molecules/*.@(js|jsx|ts|tsx)', | ||
'../stories/organisms/*.@(js|jsx|ts|tsx)', | ||
'../stories/packages/*.@(js|jsx|ts|tsx)', | ||
'../stories/**/*.@(js|jsx|ts|tsx)', | ||
], | ||
addons: [ | ||
'@storybook/addon-actions', | ||
'@storybook/addon-links', | ||
'@storybook/addon-essentials', | ||
'@storybook/addon-interactions', | ||
], | ||
framework: '@storybook/react', | ||
webpackFinal: async (config, { configType }) => { | ||
const type = configType === 'DEVELOPMENT' ? 'dev' : 'prod'; | ||
const rules = getRules(type); | ||
|
||
config.resolve.alias['@textkernel/oneui'] = path.resolve(__dirname, '../src'); | ||
// Make whatever fine-grained changes you need | ||
config.module.rules.push(rules.js, rules.scss); | ||
|
||
// Return the altered config | ||
return config; | ||
}, | ||
}; |
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,6 @@ | ||
import { addons } from '@storybook/addons'; | ||
import TKTheme from './TKTheme'; | ||
|
||
addons.setConfig({ | ||
theme: TKTheme, | ||
}); |
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,15 @@ | ||
export const parameters = { | ||
actions: { argTypesRegex: '^on[A-Z].*' }, | ||
controls: { | ||
matchers: { | ||
color: /(background|color)$/i, | ||
date: /Date$/, | ||
}, | ||
}, | ||
options: { | ||
storySort: { | ||
method: 'alphabetical', | ||
order: ['Concepts', 'Theme', 'Atoms', 'Molecules', 'Organisms', 'Packages'], | ||
}, | ||
}, | ||
}; |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.