Skip to content

Commit

Permalink
Update Storybook to v8.2.6 and add initial AppButton story (#2659)
Browse files Browse the repository at this point in the history
* resolved conflicts

* added story

* resolving conflicts

* removed

unnecessary dependency

* resolved conflicts
  • Loading branch information
Mike-Popovych authored Nov 15, 2024
1 parent 5dfe7c6 commit d1239a4
Show file tree
Hide file tree
Showing 53 changed files with 11,203 additions and 28,426 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,5 @@ yarn-error.log*


# scss builds
/src/scss/lib
/src/scss/lib
*storybook.log
17 changes: 0 additions & 17 deletions .storybook/main.js

This file was deleted.

17 changes: 17 additions & 0 deletions .storybook/main.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import type { StorybookConfig } from '@storybook/react-vite'

const config: StorybookConfig = {
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],
addons: [
'@storybook/addon-onboarding',
'@storybook/addon-links',
'@storybook/addon-essentials',
'@chromatic-com/storybook',
'@storybook/addon-interactions'
],
framework: {
name: '@storybook/react-vite',
options: {}
}
}
export default config
3 changes: 0 additions & 3 deletions .storybook/preview-head.html

This file was deleted.

25 changes: 0 additions & 25 deletions .storybook/preview.js

This file was deleted.

34 changes: 34 additions & 0 deletions .storybook/preview.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
import React from 'react'
import { StyledEngineProvider } from '@mui/material/styles'
import { ThemeProvider } from '@mui/material/styles'
import { theme } from '../src/styles/app-theme/custom-mui.styles'
import i18n from '../src/plugins/i18n'
import { I18nextProvider } from 'react-i18next'
import type { Preview } from '@storybook/react'

import '../src/styles/index.css'
import '../src/scss/styles.scss'

const preview: Preview = {
parameters: {
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/i
}
}
},
decorators: [
(Story) => (
<StyledEngineProvider injectFirst>
<ThemeProvider theme={theme}>
<I18nextProvider i18n={i18n}>
<Story />
</I18nextProvider>
</ThemeProvider>
</StyledEngineProvider>
)
]
}

export default preview
2 changes: 1 addition & 1 deletion eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const compat = new FlatCompat({

export default [
{
ignores: ['src/assets/*', 'src/stories/assets/*']
ignores: ['src/assets/*', 'src/stories/assets/*', '.storybook/**/*']
},
...compat.extends(
'eslint:recommended',
Expand Down
Loading

0 comments on commit d1239a4

Please sign in to comment.