diff --git a/.circleci/config.yml b/.circleci/config.yml index 55069b505837..829bfa4fd66b 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -81,6 +81,11 @@ jobs: command: | cd examples/angular-cli yarn build-storybook + - run: + name: "Build polymer-cli" + command: | + cd examples/polymer-cli + yarn build-storybook - run: name: "Run react kitchen-sink (smoke test)" command: | @@ -96,6 +101,10 @@ jobs: command: | cd examples/angular-cli yarn storybook --smoke-test + - run: + name: "Visually test storybook" + command: | + yarn chromatic - run: name: "Run image snapshots" command: yarn test --image @@ -207,26 +216,6 @@ jobs: command: | yarn test --coverage --runInBand --core yarn coverage - storybook: - <<: *defaults - steps: - - checkout - - restore_cache: - name: "Restore core dependencies cache" - keys: - - core-dependencies-{{ checksum "yarn.lock" }} - - restore_cache: - name: "Restore core dist cache" - keys: - - core-dist-{{ .Revision }} - - run: - name: "Link packages" - command: | - yarn install - - run: - name: "Visually test storybook" - command: | - yarn chromatic cli: working_directory: /tmp/storybook docker: @@ -292,9 +281,6 @@ workflows: - unit-test: requires: - build - - storybook: - requires: - - build - cli: requires: - build diff --git a/.eslintignore b/.eslintignore index d04728ab519f..d68999f17799 100644 --- a/.eslintignore +++ b/.eslintignore @@ -2,8 +2,6 @@ dist build coverage node_modules -addons/**/example/** -app/**/demo/** docs/public lib/cli/test *.bundle.js @@ -13,3 +11,4 @@ lib/cli/test !.eslintrc.js !.eslintrc-markdown.js !.jest.config.js +!.storybook diff --git a/.eslintrc-markdown.js b/.eslintrc-markdown.js deleted file mode 100644 index c9ddcbe65f4f..000000000000 --- a/.eslintrc-markdown.js +++ /dev/null @@ -1,59 +0,0 @@ -const error = 2; -const warn = 1; -const ignore = 0; - -module.exports = { - root: true, - extends: ['eslint-config-airbnb', 'plugin:jest/recommended', 'prettier'], - plugins: ['prettier', 'jest', 'react'], - parser: 'babel-eslint', - parserOptions: { - sourceType: 'module', - }, - env: { - es6: true, - node: true, - 'jest/globals': true, - }, - globals: { - storiesOf: true, - addonAPI: true, - __DEV__: true, - fetch: true, - }, - rules: { - strict: [error, 'never'], - 'prettier/prettier': [ - warn, - { - printWidth: 100, - tabWidth: 2, - bracketSpacing: true, - trailingComma: 'es5', - singleQuote: true, - }, - ], - 'no-console': ignore, - 'global-require': ignore, - quotes: [warn, 'single'], - 'no-unused-vars': ignore, - 'class-methods-use-this': ignore, - 'arrow-parens': [warn, 'as-needed'], - 'space-before-function-paren': ignore, - 'import/no-unresolved': ignore, - 'import/extensions': ignore, - 'import/no-extraneous-dependencies': ignore, - 'import/prefer-default-export': ignore, - 'react/prop-types': ignore, - 'react/jsx-wrap-multilines': ignore, - 'react/jsx-uses-react': error, - 'react/jsx-uses-vars': error, - 'react/react-in-jsx-scope': ignore, - 'react/jsx-filename-extension': ignore, - 'jsx-a11y/accessible-emoji': ignore, - 'jsx-a11y/href-no-hash': ignore, - 'jsx-a11y/label-has-for': ignore, - 'jsx-a11y/anchor-is-valid': ['warn', { aspects: ['invalidHref'] }], - 'react/no-unescaped-entities': ignore, - }, -}; diff --git a/.eslintrc.js b/.eslintrc.js index 26561d467c43..fe1935d02fe1 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -4,7 +4,13 @@ const ignore = 0; module.exports = { root: true, - extends: ['eslint-config-airbnb', 'plugin:jest/recommended', 'prettier'], + extends: [ + 'eslint-config-airbnb', + 'plugin:jest/recommended', + 'plugin:import/react-native', + 'prettier', + 'prettier/react', + ], plugins: ['prettier', 'jest', 'react', 'json'], parser: 'babel-eslint', parserOptions: { @@ -25,7 +31,6 @@ module.exports = { }, }, rules: { - strict: [error, 'never'], 'prettier/prettier': [ warn, { @@ -37,16 +42,13 @@ module.exports = { }, ], 'no-debugger': process.env.NODE_ENV === 'production' ? error : ignore, - quotes: [warn, 'single', { avoidEscape: true }], 'class-methods-use-this': ignore, - 'arrow-parens': [warn, 'as-needed'], - 'space-before-function-paren': ignore, - 'import/no-unresolved': error, 'import/extensions': [ error, + 'always', { js: 'never', - json: 'always', + ts: 'never', }, ], 'import/no-extraneous-dependencies': [ @@ -61,6 +63,7 @@ module.exports = { '**/scripts/*.js', '**/stories/**/*.js', '**/__tests__/**/*.js', + '**/.storybook/**/*.js', ], peerDependencies: true, }, @@ -69,24 +72,41 @@ module.exports = { 'import/default': error, 'import/named': error, 'import/namespace': error, - 'react/jsx-wrap-multilines': ignore, - 'react/jsx-indent': ignore, - 'react/jsx-indent-props': ignore, - 'react/jsx-closing-bracket-location': ignore, - 'react/jsx-uses-react': error, - 'react/jsx-uses-vars': error, - 'react/react-in-jsx-scope': error, 'react/jsx-filename-extension': [ warn, { extensions: ['.js', '.jsx'], }, ], - 'jsx-a11y/accessible-emoji': ignore, - 'jsx-a11y/href-no-hash': ignore, - 'jsx-a11y/label-has-for': ignore, - 'jsx-a11y/click-events-have-key-events': error, - 'jsx-a11y/anchor-is-valid': [warn, { aspects: ['invalidHref'] }], 'react/no-unescaped-entities': ignore, + 'jsx-a11y/label-has-for': [ + error, + { + required: { + some: ['nesting', 'id'], + }, + }, + ], + 'jsx-a11y/anchor-is-valid': [ + error, + { + components: ['RoutedLink', 'MenuLink', 'LinkTo', 'Link'], + specialLink: ['overrideParams', 'kind', 'story', 'to'], + }, + ], }, + overrides: [ + { + files: ['**/react-native*/**', '**/REACT_NATIVE*/**', '**/crna*/**'], + rules: { + 'jsx-a11y/accessible-emoji': ignore, + }, + }, + { + files: '**/.storybook/config.js', + rules: { + 'global-require': ignore, + }, + }, + ], }; diff --git a/.remarkrc.js b/.remarkrc.js index 9a2b8e63e7e5..2c78f5c67277 100644 --- a/.remarkrc.js +++ b/.remarkrc.js @@ -1,18 +1,3 @@ module.exports = { - plugins: [ - 'remark-preset-lint-recommended', - ['remark-lint-list-item-indent', false], - [ - 'remark-lint-code', - { - js: { - module: 'node_modules/remark-lint-code-eslint', - options: { - fix: true, - configFile: '.eslintrc-markdown.js', - }, - }, - }, - ], - ], + plugins: ['remark-preset-lint-recommended', ['remark-lint-list-item-indent', false]], }; diff --git a/CHANGELOG.md b/CHANGELOG.md index b13076d8b0fc..89250963b4e6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,139 @@ +# 3.4.0-alpha.8 + +2018-February-11 + +#### Bug Fixes + +- React-Native: Fix by moving managerPath export to `server.js` [#2947](https://github.com/storybooks/storybook/pull/2947) +- Addon-Info: Add type check to PropType on OneOf [#2653](https://github.com/storybooks/storybook/pull/2653) +- Vue: Support .vue extension resolving [#2896](https://github.com/storybooks/storybook/pull/2896) + +#### Documentation + +- Update writing addons documentation [#2951](https://github.com/storybooks/storybook/pull/2951) +- Update docs on LinkTo in addon-links [#2926](https://github.com/storybooks/storybook/pull/2926) + +#### Maintenance + +- Fix "dev" script to be cross-platform [#2922](https://github.com/storybooks/storybook/pull/2922) + +#### Dependency Upgrades + +
+ +98 Updates + + +- Upgraded `jest-cli` in `/` from "22.2.1" to "22.2.2" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `jest-config` in `/` from "22.2.1" to "22.2.2" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `jest-environment-jsdom` in `/` from "22.2.0" to "22.2.2" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `jest-jasmine2` in `/` from "22.2.1" to "22.2.2" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `autoprefixer` in `lib/core` from "7.2.5" to "7.2.6" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `webpack` in `lib/core` from "3.10.0" to "3.11.0" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `autoprefixer` in `app/angular` from "7.2.5" to "7.2.6" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `webpack` in `app/angular` from "3.10.0" to "3.11.0" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `autoprefixer` in `app/polymer` from "7.2.5" to "7.2.6" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `webpack` in `app/polymer` from "3.10.0" to "3.11.0" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `autoprefixer` in `app/react-native` from "7.2.5" to "7.2.6" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `webpack` in `app/react-native` from "3.10.0" to "3.11.0" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `autoprefixer` in `app/react` from "7.2.5" to "7.2.6" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `webpack` in `app/react` from "3.10.0" to "3.11.0" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `autoprefixer` in `app/vue` from "7.2.5" to "7.2.6" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `webpack` in `app/vue` from "3.10.0" to "3.11.0" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `webpack` in `examples/polymer-cli` from "3.10.0" to "3.11.0" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `@types/node` in `examples/angular-cli` from "6.0.99" to "6.0.100" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `webpack` in `examples/vue-kitchen-sink` from "3.10.0" to "3.11.0" [#2957](https://github.com/storybooks/storybook/pull/2957) +- Upgraded `eslint-plugin-jest` in `/` from "21.7.0" to "21.8.0" [#2952](https://github.com/storybooks/storybook/pull/2952) +- Upgraded `react-datetime` in `addons/knobs` from "2.12.0" to "2.13.0" [#2952](https://github.com/storybooks/storybook/pull/2952) +- Upgraded `react-modal` in `lib/ui` from "3.1.12" to "3.1.13" [#2952](https://github.com/storybooks/storybook/pull/2952) +- Upgraded `react-modal` in `app/angular` from "3.1.12" to "3.1.13" [#2952](https://github.com/storybooks/storybook/pull/2952) +- Upgraded `react-modal` in `app/polymer` from "3.1.12" to "3.1.13" [#2952](https://github.com/storybooks/storybook/pull/2952) +- Upgraded `babel-jest` in `examples/cra-kitchen-sink` from "22.2.0" to "22.2.2" [#2952](https://github.com/storybooks/storybook/pull/2952) +- Upgraded `jest` in `examples/cra-kitchen-sink` from "22.2.1" to "22.2.2" [#2952](https://github.com/storybooks/storybook/pull/2952) +- Upgraded `react-scripts` in `examples/cra-kitchen-sink` from "1.1.0" to "1.1.1" [#2952](https://github.com/storybooks/storybook/pull/2952) +- Update gatsby in /docs from 1.9.184 to 1.9.187 [#2950](https://github.com/storybooks/storybook/pull/2950) +- Upgraded `copy-webpack-plugin` in `app/polymer` from "4.3.1" to "4.4.0" [#2945](https://github.com/storybooks/storybook/pull/2945) +- Upgraded `copy-webpack-plugin` in `examples/polymer-cli` from "4.3.1" to "4.4.0" [#2945](https://github.com/storybooks/storybook/pull/2945) +- Upgraded `@angular/cli` in `examples/angular-cli` from "1.6.7" to "1.6.8" [#2945](https://github.com/storybooks/storybook/pull/2945) +- Upgraded `@types/node` in `examples/angular-cli` from "6.0.97" to "6.0.99" [#2945](https://github.com/storybooks/storybook/pull/2945) +- Upgraded `jasmine-core` in `examples/angular-cli` from "2.99.0" to "2.99.1" [#2945](https://github.com/storybooks/storybook/pull/2945) +- Upgraded `gatsby-remark-images` in `/docs` from "1.5.42" to "1.5.43" [#2944](https://github.com/storybooks/storybook/pull/2944) +- Upgraded `gatsby-transformer-remark` in `/docs` from "1.7.30" to "1.7.31" [#2944](https://github.com/storybooks/storybook/pull/2944) +- Upgraded `gatsby-remark-images` in `/docs` from "1.5.41" to "1.5.42" [#2939](https://github.com/storybooks/storybook/pull/2939) +- Upgraded `gatsby` in `/docs` from "1.9.183" to "1.9.184" [#2939](https://github.com/storybooks/storybook/pull/2939) +- Upgraded `@angular/common` in `/` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/compiler` in `/` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/core` in `/` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/forms` in `/` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/platform-browser` in `/` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/platform-browser-dynamic` in `/` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `commander` in `/` from "2.14.0" to "2.14.1" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `jest` in `/` from "22.1.4" to "22.2.0" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `jest-cli` in `/` from "22.1.4" to "22.2.0" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `jest-config` in `/` from "22.1.4" to "22.2.0" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `jest-environment-jsdom` in `/` from "22.1.4" to "22.2.0" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `jest-jasmine2` in `/` from "22.1.4" to "22.2.0" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `graphql` in `addons/graphql` from "0.12.3" to "0.13.0" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `commander` in `lib/core` from "2.14.0" to "2.14.1" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `commander` in `app/react-native` from "2.14.0" to "2.14.1" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `commander` in `lib/cli` from "2.14.0" to "2.14.1" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/animations` in `examples/angular-cli` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/common` in `examples/angular-cli` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/compiler` in `examples/angular-cli` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/core` in `examples/angular-cli` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/forms` in `examples/angular-cli` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/http` in `examples/angular-cli` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/platform-browser` in `examples/angular-cli` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/platform-browser-dynamic` in `examples/angular-cli` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/router` in `examples/angular-cli` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/compiler-cli` in `examples/angular-cli` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `@angular/language-service` in `examples/angular-cli` from "5.2.3" to "5.2.4" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `babel-jest` in `examples/cra-kitchen-sink` from "22.1.0" to "22.2.0" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `jest` in `examples/cra-kitchen-sink` from "22.1.4" to "22.2.0" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Upgraded `eventemitter3` in `examples/official-storybook` from "3.0.0" to "3.0.1" [#2938](https://github.com/storybooks/storybook/pull/2938) +- Update @types/node in examples/angular-cli from 6.0.96 to 6.0.97 [#2932](https://github.com/storybooks/storybook/pull/2932) +- Update gatsby in /docs from 1.9.181 to 1.9.182 [#2929](https://github.com/storybooks/storybook/pull/2929) +- Update jasmine-core in examples/angular-cli from 2.9.1 to 2.99.0 [#2930](https://github.com/storybooks/storybook/pull/2930) +- Upgraded `commander` in `/` from "2.13.0" to "2.14.0" [#2928](https://github.com/storybooks/storybook/pull/2928) +- Upgraded `make-error` in `addons/actions` from "1.3.2" to "1.3.3" [#2928](https://github.com/storybooks/storybook/pull/2928) +- Upgraded `commander` in `app/angular` from "2.13.0" to "2.14.0" [#2928](https://github.com/storybooks/storybook/pull/2928) +- Upgraded `commander` in `app/polymer` from "2.13.0" to "2.14.0" [#2928](https://github.com/storybooks/storybook/pull/2928) +- Upgraded `commander` in `app/react-native` from "2.13.0" to "2.14.0" [#2928](https://github.com/storybooks/storybook/pull/2928) +- Upgraded `react-native` in `app/react-native` from "0.52.2" to "0.53.0" [#2928](https://github.com/storybooks/storybook/pull/2928) +- Upgraded `commander` in `app/react` from "2.13.0" to "2.14.0" [#2928](https://github.com/storybooks/storybook/pull/2928) +- Upgraded `commander` in `app/vue` from "2.13.0" to "2.14.0" [#2928](https://github.com/storybooks/storybook/pull/2928) +- Upgraded `commander` in `lib/cli` from "2.13.0" to "2.14.0" [#2928](https://github.com/storybooks/storybook/pull/2928) +- Upgraded `jest-enzyme` in `/` from "4.1.1" to "4.2.0" [#2919](https://github.com/storybooks/storybook/pull/2919) +- Upgraded `react-modal` in `lib/ui` from "3.1.11" to "3.1.12" [#2919](https://github.com/storybooks/storybook/pull/2919) +- Upgraded `react-modal` in `app/angular` from "3.1.11" to "3.1.12" [#2919](https://github.com/storybooks/storybook/pull/2919) +- Upgraded `react-modal` in `app/polymer` from "3.1.11" to "3.1.12" [#2919](https://github.com/storybooks/storybook/pull/2919) +- Upgraded `gatsby-remark-copy-linked-files` in `/docs` from "1.5.25" to "1.5.26" [#2927](https://github.com/storybooks/storybook/pull/2927) +- Upgraded `gatsby-source-filesystem` in `/docs` from "1.5.16" to "1.5.18" [#2927](https://github.com/storybooks/storybook/pull/2927) +- Upgraded `gatsby` in `/docs` from "1.9.178" to "1.9.179" [#2927](https://github.com/storybooks/storybook/pull/2927) +- Update lodash in /docs from 4.17.4 to 4.17.5 [#2914](https://github.com/storybooks/storybook/pull/2914) +- Update lodash in / from 4.17.4 to 4.17.5 [#2915](https://github.com/storybooks/storybook/pull/2915) +- Upgraded `gatsby-link` in `/docs` from "1.6.35" to "1.6.36" [#2908](https://github.com/storybooks/storybook/pull/2908) +- Upgraded `gatsby` in `/docs` from "1.9.175" to "1.9.177" [#2908](https://github.com/storybooks/storybook/pull/2908) +- Upgraded `@storybook/addon-actions` in `/docs` from "3.3.11" to "3.3.12" [#2911](https://github.com/storybooks/storybook/pull/2911) +- Upgraded `@storybook/addon-links` in `/docs` from "3.3.11" to "3.3.12" [#2911](https://github.com/storybooks/storybook/pull/2911) +- Upgraded `@storybook/addons` in `/docs` from "3.3.11" to "3.3.12" [#2911](https://github.com/storybooks/storybook/pull/2911) +- Upgraded `@storybook/react` in `/docs` from "3.3.11" to "3.3.12" [#2911](https://github.com/storybooks/storybook/pull/2911) +- Upgraded `gatsby` in `/docs` from "1.9.175" to "1.9.178" [#2911](https://github.com/storybooks/storybook/pull/2911) +- Upgraded `eslint` in `/` from "4.16.0" to "4.17.0" [#2912](https://github.com/storybooks/storybook/pull/2912) +- Upgraded `ts-jest` in `/` from "22.0.1" to "22.0.3" [#2912](https://github.com/storybooks/storybook/pull/2912) +- Upgraded `@polymer/polymer` in `examples/polymer-cli` from "2.4.0" to "2.5.0" [#2912](https://github.com/storybooks/storybook/pull/2912) + +
+ +# 3.3.13 + +2018-February-11 + +#### Bug Fixes + +- Angular: add rule for .md to webpack.config.prod.js [#2924](https://github.com/storybooks/storybook/pull/2924) +- Check for correct props in Flow or prop-types [#2902](https://github.com/storybooks/storybook/pull/2902) + # 3.4.0-alpha.7 2018-February-03 @@ -142,7 +278,7 @@ #### Maintenance -- ADD autolabeler.yml for https://github.com/probot/autolabeler [#2809](https://github.com/storybooks/storybook/pull/2809) +- ADD autolabeler.yml for [#2809](https://github.com/storybooks/storybook/pull/2809) - Fix css warning in angular-cli example [#2789](https://github.com/storybooks/storybook/pull/2789) - Move more things to core [#2788](https://github.com/storybooks/storybook/pull/2788) @@ -815,7 +951,7 @@ In addition to the changes listed here, also contains fixes from [3.3.5](#335) a #### Bug Fixes -- [app:angular] Fixed dependency injection for components [#2566](https://github.com/storybooks/storybook/pull/2566) +- `app:angular` Fixed dependency injection for components [#2566](https://github.com/storybooks/storybook/pull/2566) - Revert "Move everything from lodash to lodash-es" [#2591](https://github.com/storybooks/storybook/pull/2591) #### Maintenance @@ -901,7 +1037,7 @@ We'll do a better job of getting out smaller releases next time around. ;-) - Added type annotation to helpers, added ts declaration files for angu… [#2459](https://github.com/storybooks/storybook/pull/2459) - Adding extra metadata to module/components [#2526](https://github.com/storybooks/storybook/pull/2526) - Fix ng component prop output override [#2456](https://github.com/storybooks/storybook/pull/2456) -- [WIP] Angular versions support [#2467](https://github.com/storybooks/storybook/pull/2467) +- `WIP` Angular versions support [#2467](https://github.com/storybooks/storybook/pull/2467) - Angular Add custom pipes support [#2518](https://github.com/storybooks/storybook/pull/2518) - Add angular support: Storybook for Angular [#1474](https://github.com/storybooks/storybook/pull/1474) - Fix addon Knobs: add array in Object PropTypes [#2227](https://github.com/storybooks/storybook/pull/2227) @@ -1158,7 +1294,7 @@ We'll do a better job of getting out smaller releases next time around. ;-) - Added type annotation to helpers, added ts declaration files for angu… [#2459](https://github.com/storybooks/storybook/pull/2459) - Adding extra metadata to module/components [#2526](https://github.com/storybooks/storybook/pull/2526) - Fix ng component prop output override [#2456](https://github.com/storybooks/storybook/pull/2456) -- [WIP] Angular versions support [#2467](https://github.com/storybooks/storybook/pull/2467) +- `WIP` Angular versions support [#2467](https://github.com/storybooks/storybook/pull/2467) - Angular Add custom pipes support [#2518](https://github.com/storybooks/storybook/pull/2518) #### Bug Fixes @@ -1474,7 +1610,7 @@ We'll do a better job of getting out smaller releases next time around. ;-) #### Bug Fixes - Number knob: apply default min/max/step values only in range mode [#2437](https://github.com/storybooks/storybook/pull/2437) -- [addon-actions] Check result of getPropertyDescriptor for IE11 [#2428](https://github.com/storybooks/storybook/pull/2428) +- `addon-actions` Check result of getPropertyDescriptor for IE11 [#2428](https://github.com/storybooks/storybook/pull/2428) - Edited template of search box result item to fix overflow text in row [#2419](https://github.com/storybooks/storybook/pull/2419) - Fix missing supported extension check in case when asset is a string [#2468](https://github.com/storybooks/storybook/pull/2468) @@ -2518,7 +2654,7 @@ Minor bug fixes and documentation updates post 3.0.0 release. - Fixed typo in react-native browser instructions [#1189](https://github.com/storybooks/storybook/pull/1189) - Add instruction for npm install with -D for development dependency [#1168](https://github.com/storybooks/storybook/pull/1168) -- Fix broken link for [addons] in README [#1167](https://github.com/storybooks/storybook/pull/1167) +- Fix broken link for `addons` in README [#1167](https://github.com/storybooks/storybook/pull/1167) - Refreshed logo in docs [#1149](https://github.com/storybooks/storybook/pull/1149) - fix addon broken links in documentation [#1165](https://github.com/storybooks/storybook/pull/1165) - start-storybook cli - expand commands descriptions [#1161](https://github.com/storybooks/storybook/pull/1161) diff --git a/RELEASES.md b/RELEASES.md index ae86af316b97..e4cf86c82d4f 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -86,7 +86,7 @@ addressed before a release can go out by adding them to the milestone. For examp Adding bugs to the milestone helps people looking for good ways to contribute, or to understand what is blocking the release so they can actually do something about it. Discussion about which bugs are critical happens in the `#maintenance` -channel [in our Slack](https://now-examples-slackin-rrirkqohko.now.sh/) [![Storybook Slack](https://now-examples-slackin-rrirkqohko.now.sh/badge.svg)].(https://now-examples-slackin-rrirkqohko.now.sh/) +channel [in our Slack](https://now-examples-slackin-rrirkqohko.now.sh/) [![Storybook Slack](https://now-examples-slackin-rrirkqohko.now.sh/badge.svg)](https://now-examples-slackin-rrirkqohko.now.sh/) If you're experiencing a bug, the best way to make sure that it gets attention diff --git a/ROADMAP.md b/ROADMAP.md index cae6888ac4ca..9fa1de69561c 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -2,22 +2,22 @@ ## Table of contents - * [New features](#new-features) - + [Responsive + multi-device viewports preview.](#responsive--multi-device-viewports-preview) - + [Automatic story detection](#automatic-story-detection) - + [Theme ability and override core UI components](#theme-ability-and-override-core-ui-components) - + [Add a playground addon](#add-a-playground-addon) - + [See multiple (or all) stories in 1 preview.](#see-multiple--or-all--stories-in-1-preview) - * [Supporting other frameworks and libraries](#supporting-other-frameworks-and-libraries) - + [Polymer & Webcomponents](#polymer---webcomponents) - + [Aurelia](#aurelia) - + [Ember](#ember) - * [Breaking changes](#breaking-changes) - + [Addon API](#addon-api) - + [API for adding stories](#api-for-adding-stories) - * [Documentation](#documentation) - + [Better design](#better-design) - + [Record videos and write blog post on how to use, tweak & develop storybook](#record-videos-and-write-blog-post-on-how-to-use--tweak---develop-storybook) +* [New features](#new-features) + + [Responsive + multi-device viewports preview.](#responsive--multi-device-viewports-preview) + + [Automatic story detection](#automatic-story-detection) + + [Theme ability and override core UI components](#theme-ability-and-override-core-ui-components) + + [Add a playground addon](#add-a-playground-addon) + + [See multiple (or all) stories in 1 preview.](#see-multiple--or-all--stories-in-1-preview) +* [Supporting other frameworks and libraries](#supporting-other-frameworks-and-libraries) + + [Polymer & Webcomponents](#polymer---webcomponents) + + [Aurelia](#aurelia) + + [Ember](#ember) +* [Breaking changes](#breaking-changes) + + [Addon API](#addon-api) + + [API for adding stories](#api-for-adding-stories) +* [Documentation](#documentation) + + [Better design](#better-design) + + [Record videos and write blog post on how to use, tweak & develop storybook](#record-videos-and-write-blog-post-on-how-to-use--tweak---develop-storybook) ## New features diff --git a/addons/a11y/.storybook/components/Button/component.js b/addons/a11y/.storybook/components/Button/component.js index cef6111d522b..d9c58bd13acd 100644 --- a/addons/a11y/.storybook/components/Button/component.js +++ b/addons/a11y/.storybook/components/Button/component.js @@ -15,10 +15,10 @@ const styles = { wrong: { color: '#ffffff', backgroundColor: '#4caf50', - } -} + }, +}; -function Button({ label, content, disabled, contrast }) { +function Button({ content, disabled, contrast }) { return ( - ) + ); } Button.propTypes = { - label: PropTypes.string, content: PropTypes.string, disabled: PropTypes.bool, - contrast: PropTypes.oneOf(['ok', 'wrong']) + contrast: PropTypes.oneOf(['ok', 'wrong']), }; Button.defaultProps = { + content: 'null', disabled: false, contrast: 'ok', }; diff --git a/addons/a11y/.storybook/components/Button/stories.js b/addons/a11y/.storybook/components/Button/stories.js index 269e5cab100d..5972b9ea1457 100644 --- a/addons/a11y/.storybook/components/Button/stories.js +++ b/addons/a11y/.storybook/components/Button/stories.js @@ -1,34 +1,17 @@ import React from 'react'; import { storiesOf } from '@storybook/react'; +import Faker from 'faker'; import { checkA11y } from './../../../src'; import Button from './component'; -import Faker from 'faker'; - const text = Faker.lorem.words(); storiesOf('