forked from eclipse-sw360/sw360-frontend
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request eclipse-sw360#98 from eclipse-sw360/heliocastro/st…
…orybook Storybook
- Loading branch information
Showing
13 changed files
with
19,900 additions
and
7,081 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
// Copyright (c) Helio Chissini de Castro, 2023. Part of the SW360 Frontend Project. | ||
|
||
// This program and the accompanying materials are made | ||
// available under the terms of the Eclipse Public License 2.0 | ||
// which is available at https://www.eclipse.org/legal/epl-2.0/ | ||
|
||
// SPDX-License-Identifier: EPL-2.0 | ||
// License-Filename: LICENSE | ||
|
||
import path from 'path' | ||
import type { StorybookConfig } from '@storybook/nextjs' | ||
|
||
const config: StorybookConfig = { | ||
framework: { | ||
name: '@storybook/nextjs', | ||
options: {}, | ||
}, | ||
docs: { | ||
autodocs: 'tag', | ||
}, | ||
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'], | ||
addons: [ | ||
'@storybook/addon-links', | ||
'@storybook/addon-essentials', | ||
'@storybook/addon-onboarding', | ||
'@storybook/addon-interactions', | ||
], | ||
webpackFinal: async (config) => { | ||
if (config.resolve) { | ||
config.resolve.alias = { | ||
...config.resolve.alias, | ||
'@': path.resolve(__dirname, '../src'), | ||
} | ||
} | ||
return config | ||
}, | ||
} | ||
export default 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,26 @@ | ||
// Copyright (c) Helio Chissini de Castro, 2023. Part of the SW360 Frontend Project. | ||
|
||
// This program and the accompanying materials are made | ||
// available under the terms of the Eclipse Public License 2.0 | ||
// which is available at https://www.eclipse.org/legal/epl-2.0/ | ||
|
||
// SPDX-License-Identifier: EPL-2.0 | ||
// License-Filename: LICENSE | ||
|
||
import type { Preview } from '@storybook/react' | ||
|
||
import '../src/styles/globals.css' | ||
|
||
const preview: Preview = { | ||
parameters: { | ||
actions: { argTypesRegex: '^on[A-Z].*' }, | ||
controls: { | ||
matchers: { | ||
color: /(background|color)$/i, | ||
date: /Date$/, | ||
}, | ||
}, | ||
}, | ||
} | ||
|
||
export default preview |
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
Oops, something went wrong.