Skip to content

Commit

Permalink
Initial storybook integration (#665)
Browse files Browse the repository at this point in the history
* TS4 migration

* Updated jest, ts-jest, tslib, typedoc

* Updated typedoc config

* Updated @types/jest

* Removed old packages

* Initial storybook integration

* adding storybook options for each vis type, iris dataset

* adding i18n for error message header

* build files, small linting error

* pushing build files

* Removed jsdom annotation in tests

* Cleanup stories

Co-authored-by: Moritz Schöfl <[email protected]>
Co-authored-by: dvdanielrehberger <[email protected]>
Co-authored-by: dvzacharycutler <[email protected]>
  • Loading branch information
4 people authored Mar 29, 2022
1 parent b123738 commit fd8bf51
Show file tree
Hide file tree
Showing 92 changed files with 1,503 additions and 97 deletions.
3 changes: 2 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ module.exports = {
"plugin:react/recommended",
"plugin:@typescript-eslint/recommended",
"plugin:jest/recommended",
"plugin:prettier/recommended"
"plugin:prettier/recommended",
"plugin:storybook/recommended",
],
plugins: ["react", "@typescript-eslint", "jest"],
ignorePatterns: ["*.js"],
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/.eslintcache
/.idea
/build/
/storybook-static/
/dist/tsBuildInfoFile
/lib/
*.egg-info/
Expand Down
13 changes: 13 additions & 0 deletions .storybook/main.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
module.exports = {
"stories": [
"../src/**/*.stories.mdx",
"../src/**/*.stories.@(js|jsx|ts|tsx)"
],
"addons": [
"@storybook/addon-links",
"@storybook/addon-essentials",
"@storybook/addon-interactions",
"@storybook/preset-scss"
],
"framework": "@storybook/react"
}
15 changes: 15 additions & 0 deletions .storybook/preview.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import '../src/scss/storybook.scss';
import { initializeLibrary } from '../src/initialize';

// TODO: This is async, how to wait for it?
initializeLibrary();

export const parameters = {
actions: { argTypesRegex: '^on[A-Z].*' },
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/,
},
},
};
2 changes: 1 addition & 1 deletion dist/clue/graph/LocalStorageGraph.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/clue/graph/LocalStorageGraph.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/clue/graph/LocalStorageGraph.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/clue/graph/MemoryGraph.d.ts

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/clue/graph/MemoryGraph.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/clue/graph/MemoryGraph.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/clue/graph/graph.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion dist/components/dialogs.d.ts

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit fd8bf51

Please sign in to comment.