From ef00c53a53f7c9d159027a00beca7b6da8b4fb65 Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Tue, 19 Nov 2019 07:21:44 +0800 Subject: [PATCH 001/132] Addon-essentials: Proof of concept --- .eslintignore | 5 +- addons/essentials/README.md | 3 + addons/essentials/package.json | 55 ++++ addons/essentials/src/index.ts | 5 + addons/essentials/tsconfig.json | 9 + .../cra-ts-essentials/.storybook/config.ts | 4 + .../cra-ts-essentials/.storybook/presets.js | 1 + examples/cra-ts-essentials/README.md | 44 +++ examples/cra-ts-essentials/package.json | 44 +++ examples/cra-ts-essentials/public/favicon.ico | Bin 0 -> 22382 bytes examples/cra-ts-essentials/public/index.html | 43 +++ examples/cra-ts-essentials/public/logo192.png | Bin 0 -> 8581 bytes examples/cra-ts-essentials/public/logo512.png | Bin 0 -> 22920 bytes .../cra-ts-essentials/public/manifest.json | 25 ++ examples/cra-ts-essentials/public/robots.txt | 2 + examples/cra-ts-essentials/src/App.css | 22 ++ examples/cra-ts-essentials/src/App.test.tsx | 9 + examples/cra-ts-essentials/src/App.tsx | 26 ++ examples/cra-ts-essentials/src/index.css | 13 + examples/cra-ts-essentials/src/index.tsx | 12 + examples/cra-ts-essentials/src/logo.svg | 1 + .../cra-ts-essentials/src/react-app-env.d.ts | 1 + .../cra-ts-essentials/src/serviceWorker.ts | 143 ++++++++++ .../src/stories/0-Welcome.stories.tsx | 14 + .../src/stories/1-Button.stories.tsx | 18 ++ examples/cra-ts-essentials/tsconfig.json | 25 ++ yarn.lock | 264 ++++++++++++++++-- 27 files changed, 767 insertions(+), 21 deletions(-) create mode 100644 addons/essentials/README.md create mode 100644 addons/essentials/package.json create mode 100644 addons/essentials/src/index.ts create mode 100644 addons/essentials/tsconfig.json create mode 100644 examples/cra-ts-essentials/.storybook/config.ts create mode 100644 examples/cra-ts-essentials/.storybook/presets.js create mode 100644 examples/cra-ts-essentials/README.md create mode 100644 examples/cra-ts-essentials/package.json create mode 100644 examples/cra-ts-essentials/public/favicon.ico create mode 100644 examples/cra-ts-essentials/public/index.html create mode 100644 examples/cra-ts-essentials/public/logo192.png create mode 100644 examples/cra-ts-essentials/public/logo512.png create mode 100644 examples/cra-ts-essentials/public/manifest.json create mode 100644 examples/cra-ts-essentials/public/robots.txt create mode 100644 examples/cra-ts-essentials/src/App.css create mode 100644 examples/cra-ts-essentials/src/App.test.tsx create mode 100644 examples/cra-ts-essentials/src/App.tsx create mode 100644 examples/cra-ts-essentials/src/index.css create mode 100644 examples/cra-ts-essentials/src/index.tsx create mode 100644 examples/cra-ts-essentials/src/logo.svg create mode 100644 examples/cra-ts-essentials/src/react-app-env.d.ts create mode 100644 examples/cra-ts-essentials/src/serviceWorker.ts create mode 100644 examples/cra-ts-essentials/src/stories/0-Welcome.stories.tsx create mode 100644 examples/cra-ts-essentials/src/stories/1-Button.stories.tsx create mode 100644 examples/cra-ts-essentials/tsconfig.json diff --git a/.eslintignore b/.eslintignore index 4b921681522..ad542e10775 100644 --- a/.eslintignore +++ b/.eslintignore @@ -15,8 +15,9 @@ scripts/storage examples/ember-cli/.storybook/preview-head.html examples/official-storybook/tests/addon-jest.test.js examples/cra-ts-kitchen-sink/*.json -examples/cra-ts-kitchen-sink/public/*.json -examples/cra-ts-kitchen-sink/public/*.html +examples/cra-ts-kitchen-sink/public/* +examples/cra-ts-essentials/*.json +examples/cra-ts-essentials/public/* !.remarkrc.js !.babelrc.js diff --git a/addons/essentials/README.md b/addons/essentials/README.md new file mode 100644 index 00000000000..85e64c71f29 --- /dev/null +++ b/addons/essentials/README.md @@ -0,0 +1,3 @@ +# Storybook Essentials + +Storybook Essentials is a curated collection of addons that bring out the best of Storybook. diff --git a/addons/essentials/package.json b/addons/essentials/package.json new file mode 100644 index 00000000000..5e3ff6c52e8 --- /dev/null +++ b/addons/essentials/package.json @@ -0,0 +1,55 @@ +{ + "name": "@storybook/addon-essentials", + "version": "5.3.0-beta.1", + "description": "Curated addons to bring out the best of Storybook", + "keywords": [ + "addon", + "essentials", + "storybook" + ], + "homepage": "https://github.com/storybookjs/storybook/tree/master/addons/essentials", + "bugs": { + "url": "https://github.com/storybookjs/storybook/issues" + }, + "repository": { + "type": "git", + "url": "https://github.com/storybookjs/storybook.git", + "directory": "addons/essentials" + }, + "license": "MIT", + "files": [ + "dist/**/*", + "docs/**/*", + "angular/**/*", + "common/**/*", + "html/**/*", + "react/**/*", + "vue/**/*", + "web-components/**/*", + "README.md", + "*.js", + "*.d.ts" + ], + "main": "dist/index.js", + "types": "dist/index.d.ts", + "scripts": { + "prepare": "node ../../scripts/prepare.js" + }, + "dependencies": { + "@storybook/addon-actions": "5.3.0-beta.1", + "@storybook/addon-docs": "5.3.0-beta.1", + "@storybook/addons": "5.3.0-beta.1", + "@storybook/api": "5.3.0-beta.1" + }, + "devDependencies": { + "@types/jest": "^24.0.11" + }, + "peerDependencies": { + "babel-loader": "^8.0.0", + "react": "^16.8.0", + "react-is": "^16.8.0" + }, + "publishConfig": { + "access": "public" + } +} diff --git a/addons/essentials/src/index.ts b/addons/essentials/src/index.ts new file mode 100644 index 00000000000..7e9ee3e6a2b --- /dev/null +++ b/addons/essentials/src/index.ts @@ -0,0 +1,5 @@ +export const presets = () => ['@storybook/addon-docs/preset']; + +export function addons(entry: any[] = [], options: any) { + return [...entry, '@storybook/addon-actions/register']; +} diff --git a/addons/essentials/tsconfig.json b/addons/essentials/tsconfig.json new file mode 100644 index 00000000000..eac4a67bed7 --- /dev/null +++ b/addons/essentials/tsconfig.json @@ -0,0 +1,9 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "rootDir": "./src", + "types": ["webpack-env", "jest"] + }, + "include": ["src/**/*"], + "exclude": ["src/**.test.ts"] +} diff --git a/examples/cra-ts-essentials/.storybook/config.ts b/examples/cra-ts-essentials/.storybook/config.ts new file mode 100644 index 00000000000..0a0a64e2816 --- /dev/null +++ b/examples/cra-ts-essentials/.storybook/config.ts @@ -0,0 +1,4 @@ +import { configure } from '@storybook/react'; + +// automatically import all files ending in *.stories.(tsx|jsx) +configure(require.context('../src/stories', true, /\.stories\.[tj]sx?$/), module); diff --git a/examples/cra-ts-essentials/.storybook/presets.js b/examples/cra-ts-essentials/.storybook/presets.js new file mode 100644 index 00000000000..9244f574f63 --- /dev/null +++ b/examples/cra-ts-essentials/.storybook/presets.js @@ -0,0 +1 @@ +module.exports = ['@storybook/preset-create-react-app', '@storybook/addon-essentials']; diff --git a/examples/cra-ts-essentials/README.md b/examples/cra-ts-essentials/README.md new file mode 100644 index 00000000000..2fa78e71b5a --- /dev/null +++ b/examples/cra-ts-essentials/README.md @@ -0,0 +1,44 @@ +This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app). + +## Available Scripts + +In the project directory, you can run: + +### `yarn start` + +Runs the app in the development mode.
+Open [http://localhost:3000](http://localhost:3000) to view it in the browser. + +The page will reload if you make edits.
+You will also see any lint errors in the console. + +### `yarn test` + +Launches the test runner in the interactive watch mode.
+See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information. + +### `yarn build` + +Builds the app for production to the `build` folder.
+It correctly bundles React in production mode and optimizes the build for the best performance. + +The build is minified and the filenames include the hashes.
+Your app is ready to be deployed! + +See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information. + +### `yarn eject` + +**Note: this is a one-way operation. Once you `eject`, you can’t go back!** + +If you aren’t satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project. + +Instead, it will copy all the configuration files and the transitive dependencies (Webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own. + +You don’t have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it. + +## Learn More + +You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started). + +To learn React, check out the [React documentation](https://reactjs.org/). diff --git a/examples/cra-ts-essentials/package.json b/examples/cra-ts-essentials/package.json new file mode 100644 index 00000000000..6e749a3c1e3 --- /dev/null +++ b/examples/cra-ts-essentials/package.json @@ -0,0 +1,44 @@ +{ + "name": "cra-ts-essentials", + "version": "0.1.0", + "private": true, + "scripts": { + "build": "react-scripts build", + "build-storybook": "build-storybook -s public", + "eject": "react-scripts eject", + "start": "react-scripts start", + "storybook": "start-storybook -p 9009 -s public", + "test": "react-scripts test" + }, + "browserslist": { + "production": [ + ">0.2%", + "not dead", + "not op_mini all" + ], + "development": [ + "last 1 chrome version", + "last 1 firefox version", + "last 1 safari version" + ] + }, + "eslintConfig": { + "extends": "react-app" + }, + "dependencies": { + "@storybook/addon-essentials": "^5.3.0-beta.1", + "@storybook/addons": "^5.3.0-beta.1", + "@storybook/react": "^5.3.0-beta.1", + "@types/jest": "24.0.22", + "@types/node": "12.12.6", + "@types/react": "16.9.11", + "@types/react-dom": "16.9.4", + "react": "^16.11.0", + "react-dom": "^16.11.0", + "react-scripts": "3.2.0", + "typescript": "3.7.2" + }, + "devDependencies": { + "@storybook/preset-create-react-app": "^1.2.0" + } +} diff --git a/examples/cra-ts-essentials/public/favicon.ico b/examples/cra-ts-essentials/public/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..c2c86b859eaa20639adf92ff979c2be8d580433e GIT binary patch literal 22382 zcmeI4_m@>g631uH?hiA>Aq+VTNjPWS;EE`MGJt>?K?MV56hy>`7*J7EOc)R|k_>>b z$<4tHZVqnp59+N?_4~fpbLZao?tAP3ciB0o&waPMLU(m_RdsdWX>0pJ+ZWq9JKOBp z-M02iZEdsK+SiSaLvu*!^O)cRqLua3I8RFCx>l&hKB3cjSJ6zFeF@g z-Gs36nhD|g14F_Mw~Y%=?H(G=J$G{N{wBO{Tt6;cedBoNG3#s7!}dd+;l&R-!|7k2 z?sd?+X~WpweMtCUw|1QO6L~CO(H*wFH7q>-#;|bd%84$Yt8W_b{pcmH3V-;myMJ_e z^?QTD_Jf^a*T)0Gv+oY^^3E>?gclEYhS$D7D6D^IbhSS&1L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xB2jA z^w+FM`iDHQiOdi7i97rh?!2>(-ZOf>UorST_(rc*S8G?UgSFVoco=Id1)r!~Cvw1N zu-=q2DDv;oHX$#@P+aob@!#x!IY)sf`1sSZ`;@$KBD1>lUC>_J&vf`V;F3M-gm{yE z7w6)flaU+K+C&eSGv&UO|0b7O)9ZG(yNr|X$5*bJ5Wn}V#3A&TSW58NTk&sYJSlG3 z-<&yUO!TuJ9^dx(zS_nPPHNADN8BZP%yXlhKKWI_r{7$OUNg^D<{zKRdZZAar~LBh zac_tD!d|dOs{aqb^oz43?a_hZyPQV!;`v+T&;Ga(d{H}nZKV)T$=|Lp{VYR+Z?N#4 z6yiF*>te0A9dV!9?s@Yvw1{=YpL>U8aPnY~3-v|vDQfo^ucFW70L$RxkBM^?Ki~(5 zE8;jheD8z*E7Kq1Bk4ajrVM|rw{CH%i?ku>NWd@20Ym>p2YQh+f$Yf zcP@mV&4-kwA-JqO%DnsdZ7s8&*_VhG&qnym>^>-c2iJ@JPR|G$;nVK>t_nWBw;BE^ zeSWu6*jvhfvri~XgS~+7fiu3J{8lsj1nyjjKmMmI|14aY`2r^^U-Br@zgsNVnQia$ zZgC^uxM^R6{*x;p4%GUm4cni`FH6sJRYn6knuJqqUp@vJM_1N0idKwLrYGuyxF-q?8KL+a+I8rUOfw_5oB2lD5f;d3X4 zJ5Ah&WdE1FA3)secO`Rp62r5<~m_U#9gdeUyLKJ9CbYQqHy>{e|9{^t8& zegB|7>&clAck|MNVbeFrktOvg3z02+fklW+i z75E(uea`*)|61hwI0Glv#osFTd$jcF+lgF`R(}5r_>AF1E=RLI|J&#PL|*%vcRjTR QPNaAH_W=L@JAozeZ|l@fegFUf literal 0 HcmV?d00001 diff --git a/examples/cra-ts-essentials/public/index.html b/examples/cra-ts-essentials/public/index.html new file mode 100644 index 00000000000..c240d2ca8b0 --- /dev/null +++ b/examples/cra-ts-essentials/public/index.html @@ -0,0 +1,43 @@ + + + + + + + + + + + + + React App + + + +
+ + + diff --git a/examples/cra-ts-essentials/public/logo192.png b/examples/cra-ts-essentials/public/logo192.png new file mode 100644 index 0000000000000000000000000000000000000000..fa313abf53936aefc517dbd583b724a57199d415 GIT binary patch literal 8581 zcmaiac_5VE{_rzKwn+A*7-QepMq}U2*s@1OwlPM=Fi2!eWJ~rfBhg5aqM0lSqfKO~ zNmx@9*BR`^U^P=X{puv!8Q5XVM+)t$4T&asdFqgGQM|Oj~&iEny;YNmB`sZ{(26#+_59}O1I3!&6 zoB{j~UtRF`?z9>l_6H^6i~-!;&H-jdAYx!gRF9~t!wtD$`b7T#T_r>z`wlWAK-r@1kLxKNzVC%{wHKRyZ<*j9{(?DghyDM1r71HQU67z|9L^U zOLQnk%?T4uh$Q-9EY4y=BBcIUV%ILZ4!CoeV0UvI9upD{TGs%sfzu>U#ftP(*?cJuFlgw$92H#PMCApEa{1?m2p0}BCIQPloXQozAKiV`LStVBex zKzZ?yVb0=q95+@1O6epKJWbED;n?{l$x9(CKT3H^-)LqZKB zDON(RN?gY{j@1jh<~OJ471+k2S6xPK^z2C?*cmu7Me^UcZfkmES|)kpMb6eFgnbfG z5>=5?R;!UK_H>N@;n(rBv~O?#H7ESjRL(RF2$2<)ORIob`Y(UR|VV65ilX0O1pBw~-cAurF3 zSk@-1mKVdn_Oh#Qs>a;Dxin`s&PMWlM}4}FL@=GccyRcWP>*bgT{UBg^@Jbe;iaOK zpuzZMWJl`E!`Qb%b3aTfNQ9G{Y@2(q4=i5FM}eycXDG@e902w`-TgocmG+4Nz`+k_ za}$?yr0?ZX6Xh0#-3e$^s5zSBNP+wvR4&AkkM9)jpu6#CB*4ci=wRX*>M>g@80ERg zf*T>|p5f%*z&0cl+GXk?6t-VTD7RM0BI6LN#zuGf3Ug}e!^$-+X7p6F*5u&y7P+5< zY>gTi(wYVet*f1GyD0w0$D2!{c%_`Z%(-Ad4;bO4bpUSAP@Y63NGv-o3SDM3_NIZm zfT9ICl>A|uDv(&XvAq@#hyX_=Xm82=r^|-b)!y_11r!47d}(6sF!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8vT?-7h!zjFA)gTtfY`fE2k$83Uwbr_DdL!rS9Ymuu& z*Ocij^Pho)t((`UX1XzJ@w5Fm)HvZ;+k#P#M{=wd2bl?~E0>agrY{l|TQkCRa>kj= zgzMwqn%CBek{73D{E`z*f_;+8l0Vne7!8$JJKr+p&?|(tv>$({t$bl_J==+tE8N@_ zg3~h#xUBZcb>AALs8%xhrB=hGTa7yD8~x0!y|0n-Lw3G>DhoypQDL5HD+_e7;XHC%ym$uO_h3(b2xB4@GqikTqnH{m=rSD@&i z&Pyd(HtsfCTxTZWa&pZhLkZ|C_o*4TWMAW8q503wQx$Zvd+vxE{@JbYg4i znar>ks_lKS;BU*oq9?{C<)K1Ic3;m>5WdMG;5{=fFhrqUU~|axc2Vv7WLf;;S7utJ z?veDc2snujgvvJ*`e8m6vnFEp<5>Iaz@niWo+Q43`tVhkWT(D}DOi$Qyq@iIm>1c6 zPuuoz_H@9(_UIkt?;V&<+9S^M{IS>XEE_MRjMFi}D%z=+N7ZCk<1y+Tk2o&{+b-q_ zA=6KbYGqPB|7ZMrrOWZ@mlIDguHzp#(J6Q<_)Z1KwqI8#c%am5amaaUl78Y>^zr}s b!B~?t+WWKS5u5)CcMJGaRz{_UZlwPKNp@r} literal 0 HcmV?d00001 diff --git a/examples/cra-ts-essentials/public/manifest.json b/examples/cra-ts-essentials/public/manifest.json new file mode 100644 index 00000000000..080d6c77ac2 --- /dev/null +++ b/examples/cra-ts-essentials/public/manifest.json @@ -0,0 +1,25 @@ +{ + "short_name": "React App", + "name": "Create React App Sample", + "icons": [ + { + "src": "favicon.ico", + "sizes": "64x64 32x32 24x24 16x16", + "type": "image/x-icon" + }, + { + "src": "logo192.png", + "type": "image/png", + "sizes": "192x192" + }, + { + "src": "logo512.png", + "type": "image/png", + "sizes": "512x512" + } + ], + "start_url": ".", + "display": "standalone", + "theme_color": "#000000", + "background_color": "#ffffff" +} diff --git a/examples/cra-ts-essentials/public/robots.txt b/examples/cra-ts-essentials/public/robots.txt new file mode 100644 index 00000000000..01b0f9a1073 --- /dev/null +++ b/examples/cra-ts-essentials/public/robots.txt @@ -0,0 +1,2 @@ +# https://www.robotstxt.org/robotstxt.html +User-agent: * diff --git a/examples/cra-ts-essentials/src/App.css b/examples/cra-ts-essentials/src/App.css new file mode 100644 index 00000000000..afc3885715f --- /dev/null +++ b/examples/cra-ts-essentials/src/App.css @@ -0,0 +1,22 @@ +.App { + text-align: center; +} + +.App-logo { + height: 40vmin; +} + +.App-header { + background-color: #282c34; + min-height: 100vh; + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + font-size: calc(10px + 2vmin); + color: white; +} + +.App-link { + color: #09d3ac; +} diff --git a/examples/cra-ts-essentials/src/App.test.tsx b/examples/cra-ts-essentials/src/App.test.tsx new file mode 100644 index 00000000000..a754b201bf9 --- /dev/null +++ b/examples/cra-ts-essentials/src/App.test.tsx @@ -0,0 +1,9 @@ +import React from 'react'; +import ReactDOM from 'react-dom'; +import App from './App'; + +it('renders without crashing', () => { + const div = document.createElement('div'); + ReactDOM.render(, div); + ReactDOM.unmountComponentAtNode(div); +}); diff --git a/examples/cra-ts-essentials/src/App.tsx b/examples/cra-ts-essentials/src/App.tsx new file mode 100644 index 00000000000..226ee6316af --- /dev/null +++ b/examples/cra-ts-essentials/src/App.tsx @@ -0,0 +1,26 @@ +import React from 'react'; +import logo from './logo.svg'; +import './App.css'; + +const App: React.FC = () => { + return ( +

+
+ logo +

+ Edit src/App.tsx and save to reload. +

+ + Learn React + +
+
+ ); +} + +export default App; diff --git a/examples/cra-ts-essentials/src/index.css b/examples/cra-ts-essentials/src/index.css new file mode 100644 index 00000000000..ec2585e8c0b --- /dev/null +++ b/examples/cra-ts-essentials/src/index.css @@ -0,0 +1,13 @@ +body { + margin: 0; + font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', + 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', + sans-serif; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +code { + font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New', + monospace; +} diff --git a/examples/cra-ts-essentials/src/index.tsx b/examples/cra-ts-essentials/src/index.tsx new file mode 100644 index 00000000000..87d1be55189 --- /dev/null +++ b/examples/cra-ts-essentials/src/index.tsx @@ -0,0 +1,12 @@ +import React from 'react'; +import ReactDOM from 'react-dom'; +import './index.css'; +import App from './App'; +import * as serviceWorker from './serviceWorker'; + +ReactDOM.render(, document.getElementById('root')); + +// If you want your app to work offline and load faster, you can change +// unregister() to register() below. Note this comes with some pitfalls. +// Learn more about service workers: https://bit.ly/CRA-PWA +serviceWorker.unregister(); diff --git a/examples/cra-ts-essentials/src/logo.svg b/examples/cra-ts-essentials/src/logo.svg new file mode 100644 index 00000000000..2e5df0d3ab2 --- /dev/null +++ b/examples/cra-ts-essentials/src/logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/examples/cra-ts-essentials/src/react-app-env.d.ts b/examples/cra-ts-essentials/src/react-app-env.d.ts new file mode 100644 index 00000000000..6431bc5fc6b --- /dev/null +++ b/examples/cra-ts-essentials/src/react-app-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/examples/cra-ts-essentials/src/serviceWorker.ts b/examples/cra-ts-essentials/src/serviceWorker.ts new file mode 100644 index 00000000000..15d90cb81a1 --- /dev/null +++ b/examples/cra-ts-essentials/src/serviceWorker.ts @@ -0,0 +1,143 @@ +// This optional code is used to register a service worker. +// register() is not called by default. + +// This lets the app load faster on subsequent visits in production, and gives +// it offline capabilities. However, it also means that developers (and users) +// will only see deployed updates on subsequent visits to a page, after all the +// existing tabs open on the page have been closed, since previously cached +// resources are updated in the background. + +// To learn more about the benefits of this model and instructions on how to +// opt-in, read https://bit.ly/CRA-PWA + +const isLocalhost = Boolean( + window.location.hostname === 'localhost' || + // [::1] is the IPv6 localhost address. + window.location.hostname === '[::1]' || + // 127.0.0.1/8 is considered localhost for IPv4. + window.location.hostname.match( + /^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/ + ) +); + +type Config = { + onSuccess?: (registration: ServiceWorkerRegistration) => void; + onUpdate?: (registration: ServiceWorkerRegistration) => void; +}; + +export function register(config?: Config) { + if (process.env.NODE_ENV === 'production' && 'serviceWorker' in navigator) { + // The URL constructor is available in all browsers that support SW. + const publicUrl = new URL( + (process as { env: { [key: string]: string } }).env.PUBLIC_URL, + window.location.href + ); + if (publicUrl.origin !== window.location.origin) { + // Our service worker won't work if PUBLIC_URL is on a different origin + // from what our page is served on. This might happen if a CDN is used to + // serve assets; see https://github.com/facebook/create-react-app/issues/2374 + return; + } + + window.addEventListener('load', () => { + const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`; + + if (isLocalhost) { + // This is running on localhost. Let's check if a service worker still exists or not. + checkValidServiceWorker(swUrl, config); + + // Add some additional logging to localhost, pointing developers to the + // service worker/PWA documentation. + navigator.serviceWorker.ready.then(() => { + console.log( + 'This web app is being served cache-first by a service ' + + 'worker. To learn more, visit https://bit.ly/CRA-PWA' + ); + }); + } else { + // Is not localhost. Just register service worker + registerValidSW(swUrl, config); + } + }); + } +} + +function registerValidSW(swUrl: string, config?: Config) { + navigator.serviceWorker + .register(swUrl) + .then(registration => { + registration.onupdatefound = () => { + const installingWorker = registration.installing; + if (installingWorker == null) { + return; + } + installingWorker.onstatechange = () => { + if (installingWorker.state === 'installed') { + if (navigator.serviceWorker.controller) { + // At this point, the updated precached content has been fetched, + // but the previous service worker will still serve the older + // content until all client tabs are closed. + console.log( + 'New content is available and will be used when all ' + + 'tabs for this page are closed. See https://bit.ly/CRA-PWA.' + ); + + // Execute callback + if (config && config.onUpdate) { + config.onUpdate(registration); + } + } else { + // At this point, everything has been precached. + // It's the perfect time to display a + // "Content is cached for offline use." message. + console.log('Content is cached for offline use.'); + + // Execute callback + if (config && config.onSuccess) { + config.onSuccess(registration); + } + } + } + }; + }; + }) + .catch(error => { + console.error('Error during service worker registration:', error); + }); +} + +function checkValidServiceWorker(swUrl: string, config?: Config) { + // Check if the service worker can be found. If it can't reload the page. + fetch(swUrl) + .then(response => { + // Ensure service worker exists, and that we really are getting a JS file. + const contentType = response.headers.get('content-type'); + if ( + response.status === 404 || + (contentType != null && contentType.indexOf('javascript') === -1) + ) { + // No service worker found. Probably a different app. Reload the page. + navigator.serviceWorker.ready.then(registration => { + registration.unregister().then(() => { + window.location.reload(); + }); + }); + } else { + // Service worker found. Proceed as normal. + registerValidSW(swUrl, config); + } + }) + .catch(() => { + console.log( + 'No internet connection found. App is running in offline mode.' + ); + }); +} + +export function unregister() { + if ('serviceWorker' in navigator) { + navigator.serviceWorker.ready.then(registration => { + registration.unregister(); + }); + } +} diff --git a/examples/cra-ts-essentials/src/stories/0-Welcome.stories.tsx b/examples/cra-ts-essentials/src/stories/0-Welcome.stories.tsx new file mode 100644 index 00000000000..fa267f24c31 --- /dev/null +++ b/examples/cra-ts-essentials/src/stories/0-Welcome.stories.tsx @@ -0,0 +1,14 @@ +import React from 'react'; +import { linkTo } from '@storybook/addon-links'; +import { Welcome } from '@storybook/react/demo'; + +export default { + title: 'Welcome', + component: Welcome, +}; + +export const toStorybook = () => ; + +toStorybook.story = { + name: 'to Storybook', +}; diff --git a/examples/cra-ts-essentials/src/stories/1-Button.stories.tsx b/examples/cra-ts-essentials/src/stories/1-Button.stories.tsx new file mode 100644 index 00000000000..ee421d08d5b --- /dev/null +++ b/examples/cra-ts-essentials/src/stories/1-Button.stories.tsx @@ -0,0 +1,18 @@ +import React from 'react'; +import { action } from '@storybook/addon-actions'; +import { Button } from '@storybook/react/demo'; + +export default { + title: 'Button', + component: Button, +}; + +export const text = () => ; + +export const emoji = () => ( + +); diff --git a/examples/cra-ts-essentials/tsconfig.json b/examples/cra-ts-essentials/tsconfig.json new file mode 100644 index 00000000000..f2850b71613 --- /dev/null +++ b/examples/cra-ts-essentials/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "es5", + "lib": [ + "dom", + "dom.iterable", + "esnext" + ], + "allowJs": true, + "skipLibCheck": true, + "esModuleInterop": true, + "allowSyntheticDefaultImports": true, + "strict": true, + "forceConsistentCasingInFileNames": true, + "module": "esnext", + "moduleResolution": "node", + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "react" + }, + "include": [ + "src" + ] +} diff --git a/yarn.lock b/yarn.lock index 33e0718d29c..1308398babf 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3466,6 +3466,118 @@ resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-0.7.0.tgz#9a06f4f137ee84d7df0460c1fdb1135ffa6c50fd" integrity sha512-ONhaKPIufzzrlNbqtWFFd+jlnemX6lJAgq9ZeiZtS7I1PIf/la7CW4m83rTXRnVnsMbW2k56pGYu7AUFJD9Pow== +"@storybook/addon-docs@5.3.0-alpha.41": + version "5.3.0-alpha.41" + resolved "https://registry.yarnpkg.com/@storybook/addon-docs/-/addon-docs-5.3.0-alpha.41.tgz#cb2eb7b09e3b31752b8c74b23fefaab3e9284dca" + integrity sha512-lX/yiX+A1lCMOA6ZCVGCjJQ1D7DYs8MVOURhpnIa4ZN4BkI0ezmwbtwVs0bUGX/kSa7kYZRiNbted8PPMKD67A== + dependencies: + "@babel/generator" "^7.4.0" + "@babel/parser" "^7.4.2" + "@babel/plugin-transform-react-jsx" "^7.3.0" + "@egoist/vue-to-react" "^1.1.0" + "@jest/transform" "^24.9.0" + "@mdx-js/loader" "^1.1.0" + "@mdx-js/mdx" "^1.1.0" + "@mdx-js/react" "^1.0.27" + "@storybook/addons" "5.3.0-alpha.41" + "@storybook/api" "5.3.0-alpha.41" + "@storybook/components" "5.3.0-alpha.41" + "@storybook/router" "5.3.0-alpha.41" + "@storybook/source-loader" "5.3.0-alpha.41" + "@storybook/theming" "5.3.0-alpha.41" + core-js "^3.0.1" + doctrine "^3.0.0" + global "^4.3.2" + js-string-escape "^1.0.1" + lodash "^4.17.15" + prop-types "^15.7.2" + storybook-addon-vue-info "^1.2.1" + ts-dedent "^1.1.0" + +"@storybook/addons@5.3.0-alpha.41": + version "5.3.0-alpha.41" + resolved "https://registry.yarnpkg.com/@storybook/addons/-/addons-5.3.0-alpha.41.tgz#f40e57f23da76ef492489ac9b6c0add89490b716" + integrity sha512-X4OGhR5lzK+JOElj7l8f4nNnQH+DAi7EQ7jvbPhoL6lp8MThQArHmj0qZKzoSX4k6geFFapJR5KemxK3s9TMgA== + dependencies: + "@storybook/api" "5.3.0-alpha.41" + "@storybook/channels" "5.3.0-alpha.41" + "@storybook/client-logger" "5.3.0-alpha.41" + "@storybook/core-events" "5.3.0-alpha.41" + core-js "^3.0.1" + global "^4.3.2" + util-deprecate "^1.0.2" + +"@storybook/api@5.3.0-alpha.41": + version "5.3.0-alpha.41" + resolved "https://registry.yarnpkg.com/@storybook/api/-/api-5.3.0-alpha.41.tgz#6634f69d5c5de79bee68465754ff9609f566b60b" + integrity sha512-0KO/Kbr2W6q3RpyskMHwlL6EDs3FbszPbFOC9cqqxYlcM0pP0iWJNh3OT3HHCGpsykCjRRztVwM4nt4Ydz5W0Q== + dependencies: + "@storybook/channels" "5.3.0-alpha.41" + "@storybook/client-logger" "5.3.0-alpha.41" + "@storybook/core-events" "5.3.0-alpha.41" + "@storybook/router" "5.3.0-alpha.41" + "@storybook/theming" "5.3.0-alpha.41" + core-js "^3.0.1" + fast-deep-equal "^2.0.1" + global "^4.3.2" + lodash "^4.17.15" + memoizerific "^1.11.3" + prop-types "^15.6.2" + react "^16.8.3" + semver "^6.0.0" + shallow-equal "^1.1.0" + store2 "^2.7.1" + telejson "^3.0.3" + util-deprecate "^1.0.2" + +"@storybook/channels@5.3.0-alpha.41": + version "5.3.0-alpha.41" + resolved "https://registry.yarnpkg.com/@storybook/channels/-/channels-5.3.0-alpha.41.tgz#009594e1de8e0810dac988095af914dc9cc1efaa" + integrity sha512-jg0UOYf10rNsLozdaNKQ893Wcw0J33AEz7pFN5F7emAm/CQg9DG2/PB2WGjDzK2Q0QlHdv3KEcPhyn3kYjVSFQ== + dependencies: + core-js "^3.0.1" + +"@storybook/client-logger@5.3.0-alpha.41": + version "5.3.0-alpha.41" + resolved "https://registry.yarnpkg.com/@storybook/client-logger/-/client-logger-5.3.0-alpha.41.tgz#e451f797e480bd6211b2bc52997a10213ef484b9" + integrity sha512-4nVqAUb83DzZ6PJSWy957fRahzWSiZ7tBhk3xfF3MQ6LNayp3lSZ6ocZiNF5JrBL3UZkxRDk8bBRKo0/ZkX+IA== + dependencies: + core-js "^3.0.1" + +"@storybook/components@5.3.0-alpha.41": + version "5.3.0-alpha.41" + resolved "https://registry.yarnpkg.com/@storybook/components/-/components-5.3.0-alpha.41.tgz#e771e8a39470c41da3b3de1683a577014c3801cd" + integrity sha512-rGY62FLw4nEr8KxUbDWp9PCZr9wMMlvJHoVji4H0nC5MS0aWQanlE06ZnGQ1p8IR+qvDotIHgbKkfJROgqM2yQ== + dependencies: + "@storybook/client-logger" "5.3.0-alpha.41" + "@storybook/theming" "5.3.0-alpha.41" + "@types/react-syntax-highlighter" "11.0.1" + "@types/react-textarea-autosize" "^4.3.3" + core-js "^3.0.1" + global "^4.3.2" + lodash "^4.17.15" + markdown-to-jsx "^6.9.1" + memoizerific "^1.11.3" + polished "^3.3.1" + popper.js "^1.14.7" + prop-types "^15.7.2" + react "^16.8.3" + react-dom "^16.8.3" + react-focus-lock "^2.1.0" + react-helmet-async "^1.0.2" + react-popper-tooltip "^2.8.3" + react-syntax-highlighter "^11.0.2" + react-textarea-autosize "^7.1.0" + simplebar-react "^1.0.0-alpha.6" + ts-dedent "^1.1.0" + +"@storybook/core-events@5.3.0-alpha.41": + version "5.3.0-alpha.41" + resolved "https://registry.yarnpkg.com/@storybook/core-events/-/core-events-5.3.0-alpha.41.tgz#a39423e98e8753609972748119dd3b68131e6e90" + integrity sha512-XX196XdEZ6PIyzrxJfIapf2mKz/OGpwblBe53WtHZ4U1jLoajhVciXWU31gaxjNd+GuD2aMUhcdBFv6piL+LEg== + dependencies: + core-js "^3.0.1" + "@storybook/eslint-config-storybook@^2.0.0": version "2.1.0" resolved "https://registry.yarnpkg.com/@storybook/eslint-config-storybook/-/eslint-config-storybook-2.1.0.tgz#db785ebad0d0e6194e3497e1600ff5be936f943f" @@ -3505,7 +3617,7 @@ pretty-hrtime "^1.0.3" regenerator-runtime "^0.12.1" -"@storybook/preset-create-react-app@^1.3.1": +"@storybook/preset-create-react-app@^1.2.0", "@storybook/preset-create-react-app@^1.3.1": version "1.3.1" resolved "https://registry.yarnpkg.com/@storybook/preset-create-react-app/-/preset-create-react-app-1.3.1.tgz#1a7cb7d58b64a2254c566f9907eab8340a531506" integrity sha512-atJ4Jbq5QYXRa+8wscfN1kCnDk3/Dn8RZy/xm1OVrozptjlRz2CuiJEDqfmKeIEi81fBuUs41Uc3M+VWocSklg== @@ -3514,6 +3626,52 @@ "@types/webpack" "^4.39.8" react-docgen-typescript-loader "^3.3.0" +"@storybook/router@5.3.0-alpha.41": + version "5.3.0-alpha.41" + resolved "https://registry.yarnpkg.com/@storybook/router/-/router-5.3.0-alpha.41.tgz#bccf18506b68778d485e9f11d4d9d30d7f9fa437" + integrity sha512-Ump0il+v8fT8g9kXF8tVpa5hjVzU85Av3Xe8/TeKn9T+uqGdnOFuVJ3N/tKUTf6xcnIBFQ7mJBE64h2m/luOWQ== + dependencies: + "@reach/router" "^1.2.1" + "@types/reach__router" "^1.2.3" + core-js "^3.0.1" + global "^4.3.2" + lodash "^4.17.15" + memoizerific "^1.11.3" + qs "^6.6.0" + +"@storybook/source-loader@5.3.0-alpha.41": + version "5.3.0-alpha.41" + resolved "https://registry.yarnpkg.com/@storybook/source-loader/-/source-loader-5.3.0-alpha.41.tgz#8aab59284231fc170e5df9d99371b0a40705870b" + integrity sha512-WcsC9lo908InKa4F2xixgwvrQ/Yy82DTWo0L/ggxbNN00tn53M+8p4KnQtD8qJ9KX3T+THOhgvzGFHj6mS3z0A== + dependencies: + "@storybook/addons" "5.3.0-alpha.41" + "@storybook/router" "5.3.0-alpha.41" + core-js "^3.0.1" + estraverse "^4.2.0" + global "^4.3.2" + loader-utils "^1.2.3" + prettier "^1.16.4" + prop-types "^15.7.2" + regenerator-runtime "^0.13.3" + +"@storybook/theming@5.3.0-alpha.41": + version "5.3.0-alpha.41" + resolved "https://registry.yarnpkg.com/@storybook/theming/-/theming-5.3.0-alpha.41.tgz#c756865bb5354f6648099982e22d4052c6914ef1" + integrity sha512-U3jVgDVgLObq0FxKCoaOzwkPFNm1wr0N1aEAhZfVrArsK/OS1i6VuJiEQg7nq+pjDtsQI2kND5giigxvCDnjgA== + dependencies: + "@emotion/core" "^10.0.20" + "@emotion/styled" "^10.0.17" + "@storybook/client-logger" "5.3.0-alpha.41" + core-js "^3.0.1" + deep-object-diff "^1.1.0" + emotion-theming "^10.0.19" + global "^4.3.2" + memoizerific "^1.11.3" + polished "^3.3.1" + prop-types "^15.7.2" + resolve-from "^5.0.0" + ts-dedent "^1.1.0" + "@svgr/babel-plugin-add-jsx-attribute@^4.2.0": version "4.2.0" resolved "https://registry.yarnpkg.com/@svgr/babel-plugin-add-jsx-attribute/-/babel-plugin-add-jsx-attribute-4.2.0.tgz#dadcb6218503532d6884b210e7f3c502caaa44b1" @@ -3900,6 +4058,13 @@ dependencies: "@types/jest-diff" "*" +"@types/jest@24.0.22": + version "24.0.22" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-24.0.22.tgz#08a50be08e78aba850a1185626e71d31e2336145" + integrity sha512-t2OvhNZnrNjlzi2i0/cxbLVM59WN15I2r1Qtb7wDv28PnV9IzrPtagFRey/S9ezdLD0zyh1XGMQIEQND2YEfrw== + dependencies: + "@types/jest-diff" "*" + "@types/jest@^23.0.2", "@types/jest@^23.3.1": version "23.3.14" resolved "https://registry.yarnpkg.com/@types/jest/-/jest-23.3.14.tgz#37daaf78069e7948520474c87b80092ea912520a" @@ -3959,6 +4124,11 @@ resolved "https://registry.yarnpkg.com/@types/node/-/node-12.11.1.tgz#1fd7b821f798b7fa29f667a1be8f3442bb8922a3" integrity sha512-TJtwsqZ39pqcljJpajeoofYRfeZ7/I/OMUQ5pR4q5wOKf2ocrUvBAZUMhWsOvKx3dVc/aaV5GluBivt0sWqA5A== +"@types/node@12.12.6": + version "12.12.6" + resolved "https://registry.yarnpkg.com/@types/node/-/node-12.12.6.tgz#a47240c10d86a9a57bb0c633f0b2e0aea9ce9253" + integrity sha512-FjsYUPzEJdGXjwKqSpE0/9QEh6kzhTAeObA54rn6j3rR4C/mzpI9L0KNfoeASSPMMdxIsoJuCLDWcM/rVjIsSA== + "@types/node@^6.0.0": version "6.14.9" resolved "https://registry.yarnpkg.com/@types/node/-/node-6.14.9.tgz#733583e21ef0eab85a9737dfafbaa66345a92ef0" @@ -4045,7 +4215,7 @@ dependencies: "@types/react" "*" -"@types/react-dom@*": +"@types/react-dom@*", "@types/react-dom@16.9.4": version "16.9.4" resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-16.9.4.tgz#0b58df09a60961dcb77f62d4f1832427513420df" integrity sha512-fya9xteU/n90tda0s+FtN5Ym4tbgxpq/hb/Af24dvs6uYnYn+fspaxw5USlw0R8apDNwxsqumdRoCoKitckQqw== @@ -4093,6 +4263,13 @@ "@types/react-dom" "*" "@types/react-transition-group" "*" +"@types/react-syntax-highlighter@11.0.1": + version "11.0.1" + resolved "https://registry.yarnpkg.com/@types/react-syntax-highlighter/-/react-syntax-highlighter-11.0.1.tgz#37215d91c23c556d8b369cd7d9a2d8756ec8c9c5" + integrity sha512-SQfkfKoSOQE1RLSJtPzo/uguliluNNt9tmjENca6+wZ1jfojUM3jNOQ2c6KCzQVtIknOZWrJTCoJMy4RSQcGOA== + dependencies: + "@types/react" "*" + "@types/react-syntax-highlighter@11.0.2": version "11.0.2" resolved "https://registry.yarnpkg.com/@types/react-syntax-highlighter/-/react-syntax-highlighter-11.0.2.tgz#a2e3ff657d7c47813f80ca930f3d959c31ec51e3" @@ -4114,7 +4291,7 @@ dependencies: "@types/react" "*" -"@types/react@*", "@types/react@^16.8.14": +"@types/react@*", "@types/react@16.9.11", "@types/react@^16.8.14": version "16.9.11" resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.11.tgz#70e0b7ad79058a7842f25ccf2999807076ada120" integrity sha512-UBT4GZ3PokTXSWmdgC/GeCGEJXE5ofWyibCcecRLUVN2ZBpXQGVgQGtG2foS7CrTKFKlQVVswLvf7Js6XA/CVQ== @@ -10391,6 +10568,11 @@ decompress-response@^4.2.0: dependencies: mimic-response "^2.0.0" +dedent-tabs@^0.8.0: + version "0.8.0" + resolved "https://registry.yarnpkg.com/dedent-tabs/-/dedent-tabs-0.8.0.tgz#e8e37e2a84f8d305bc714c2f1121fee873170db6" + integrity sha512-YKS/ItX7e9+TdLaUiwht1IxkFDbQEHNJSTruwvrwODRXFov8X7C7iCwrUynrsOh1+CkwmjFK51P5d1HsrI5VJA== + dedent@^0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/dedent/-/dedent-0.6.0.tgz#0e6da8f0ce52838ef5cec5c8f9396b0c1b64a3cb" @@ -15335,6 +15517,11 @@ hex-color-regex@^1.1.0: resolved "https://registry.yarnpkg.com/hex-color-regex/-/hex-color-regex-1.1.0.tgz#4c06fccb4602fe2602b3c93df82d7e7dbf1a8a8e" integrity sha512-l9sfDFsuqtOqKDsQdqrMRk0U85RZc0RtOR9yPI7mRVOa4FsR/BVnZ0shmQRM96Ji99kYZP/7hn1cedc1+ApsTQ== +highlight.js@^9.12.0: + version "9.16.2" + resolved "https://registry.yarnpkg.com/highlight.js/-/highlight.js-9.16.2.tgz#68368d039ffe1c6211bcc07e483daf95de3e403e" + integrity sha512-feMUrVLZvjy0oC7FVJQcSQRqbBq9kwqnYE4+Kj9ZjbHh3g+BisiPgF49NyQbVLNdrL/qqZr3Ca9yOKwgn2i/tw== + highlight.js@~9.13.0: version "9.13.1" resolved "https://registry.yarnpkg.com/highlight.js/-/highlight.js-9.13.1.tgz#054586d53a6863311168488a0f58d6c505ce641e" @@ -25127,15 +25314,25 @@ react-dom@^15.4.2: object-assign "^4.1.0" prop-types "^15.5.10" -react-dom@^16.10.2, react-dom@^16.8.3, react-dom@^16.8.4: - version "16.12.0" - resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-16.12.0.tgz#0da4b714b8d13c2038c9396b54a92baea633fe11" - integrity sha512-LMxFfAGrcS3kETtQaCkTKjMiifahaMySFDn71fZUNpPHZQEzmk/GiAeIT8JSOrHB23fnuCOMruL2a8NYlw+8Gw== +react-dom@^16.10.2: + version "16.10.2" + resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-16.10.2.tgz#4840bce5409176bc3a1f2bd8cb10b92db452fda6" + integrity sha512-kWGDcH3ItJK4+6Pl9DZB16BXYAZyrYQItU4OMy0jAkv5aNqc+mAKb4TpFtAteI6TJZu+9ZlNhaeNQSVQDHJzkw== dependencies: loose-envify "^1.1.0" object-assign "^4.1.1" prop-types "^15.6.2" - scheduler "^0.18.0" + scheduler "^0.16.2" + +react-dom@^16.11.0, react-dom@^16.8.3, react-dom@^16.8.4: + version "16.11.0" + resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-16.11.0.tgz#7e7c4a5a85a569d565c2462f5d345da2dd849af5" + integrity sha512-nrRyIUE1e7j8PaXSPtyRKtz+2y9ubW/ghNgqKFHHAHaeP0fpF5uXR+sq8IMRHC+ZUxw7W9NyCDTBtwWxvkb0iA== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + prop-types "^15.6.2" + scheduler "^0.17.0" react-draggable@^4.0.3: version "4.1.0" @@ -25714,10 +25911,10 @@ react-transition-group@^2.2.1: prop-types "^15.6.2" react-lifecycles-compat "^3.0.4" -react@*, react@^16.10.2, react@^16.6.0, react@^16.8.3, react@^16.8.4: - version "16.12.0" - resolved "https://registry.yarnpkg.com/react/-/react-16.12.0.tgz#0c0a9c6a142429e3614834d5a778e18aa78a0b83" - integrity sha512-fglqy3k5E+81pA8s+7K0/T3DBCF0ZDOher1elBFzF7O6arXJgzyu/FW+COxFvAWXJoJN9KIZbT2LXlukwphYTA== +react@*, react@^16.11.0, react@^16.6.0, react@^16.8.3, react@^16.8.4: + version "16.11.0" + resolved "https://registry.yarnpkg.com/react/-/react-16.11.0.tgz#d294545fe62299ccee83363599bf904e4a07fdbb" + integrity sha512-M5Y8yITaLmU0ynd0r1Yvfq98Rmll6q8AxaEe88c8e7LxO8fZ2cNgmFt0aGAS9wzf1Ao32NKXtCl+/tVVtkxq6g== dependencies: loose-envify "^1.1.0" object-assign "^4.1.1" @@ -25743,6 +25940,15 @@ react@^15.4.2: object-assign "^4.1.0" prop-types "^15.5.10" +react@^16.10.2: + version "16.12.0" + resolved "https://registry.yarnpkg.com/react/-/react-16.12.0.tgz#0c0a9c6a142429e3614834d5a778e18aa78a0b83" + integrity sha512-fglqy3k5E+81pA8s+7K0/T3DBCF0ZDOher1elBFzF7O6arXJgzyu/FW+COxFvAWXJoJN9KIZbT2LXlukwphYTA== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + prop-types "^15.6.2" + reactcss@^1.2.0: version "1.2.3" resolved "https://registry.yarnpkg.com/reactcss/-/reactcss-1.2.3.tgz#c00013875e557b1cf0dfd9a368a1c3dab3b548dd" @@ -28566,6 +28772,21 @@ store2@^2.7.1: resolved "https://registry.yarnpkg.com/store2/-/store2-2.10.0.tgz#46b82bb91878daf1b0d56dec2f1d41e54d5103cf" integrity sha512-tWEpK0snS2RPUq1i3R6OahfJNjWCQYNxq0+by1amCSuw0mXtymJpzmZIeYpA1UAa+7B0grCpNYIbDcd7AgTbFg== +storybook-addon-vue-info@^1.2.1: + version "1.3.4" + resolved "https://registry.yarnpkg.com/storybook-addon-vue-info/-/storybook-addon-vue-info-1.3.4.tgz#40535a3a351bd6a521983de2181e0856764c45d4" + integrity sha512-JJ7hctSJhgH0MPvNdL6OYGeTmCE1KZfgX/ry4U4qr1jh+7ec9uwf69zvy+Q4EWZlJ5HEShLFUCZIIVPMwkbsBg== + dependencies: + clone "^2.1.2" + dedent-tabs "^0.8.0" + highlight.js "^9.12.0" + loader-utils "^1.2.3" + marked "^0.7.0" + querystring "^0.2.0" + vue-docgen-api "^3.11.4" + vue-template-compiler "^2.5.16" + vuera "^0.2.3" + storybook-chromatic@^2.2.2: version "2.2.2" resolved "https://registry.yarnpkg.com/storybook-chromatic/-/storybook-chromatic-2.2.2.tgz#eade5178f334d6dd173dbe980c902ae90e727cb0" @@ -30293,16 +30514,16 @@ typescript@3.6.4: resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.6.4.tgz#b18752bb3792bc1a0281335f7f6ebf1bbfc5b91d" integrity sha512-unoCll1+l+YK4i4F8f22TaNVPRHcD9PA3yCuZ8g5e0qGqlVlJ/8FSateOLLSagn+Yg5+ZwuPkL8LFUc0Jcvksg== +typescript@3.7.2, typescript@^3.2.2, typescript@^3.4.0: + version "3.7.2" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.7.2.tgz#27e489b95fa5909445e9fef5ee48d81697ad18fb" + integrity sha512-ml7V7JfiN2Xwvcer+XAf2csGO1bPBdRbFCkYBczNZggrBZ9c7G3riSUeJmqEU5uOtXNPMhE3n+R4FA/3YOAWOQ== + typescript@^2.4.2: version "2.9.2" resolved "https://registry.yarnpkg.com/typescript/-/typescript-2.9.2.tgz#1cbf61d05d6b96269244eb6a3bce4bd914e0f00c" integrity sha512-Gr4p6nFNaoufRIY4NMdpQRNmgxVIGMs4Fcu/ujdYk3nAZqk7supzBE9idmvfZIlH/Cuj//dvi+019qEue9lV0w== -typescript@^3.2.2, typescript@^3.4.0: - version "3.7.2" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.7.2.tgz#27e489b95fa5909445e9fef5ee48d81697ad18fb" - integrity sha512-ml7V7JfiN2Xwvcer+XAf2csGO1bPBdRbFCkYBczNZggrBZ9c7G3riSUeJmqEU5uOtXNPMhE3n+R4FA/3YOAWOQ== - ua-parser-js@^0.7.18, ua-parser-js@^0.7.19: version "0.7.20" resolved "https://registry.yarnpkg.com/ua-parser-js/-/ua-parser-js-0.7.20.tgz#7527178b82f6a62a0f243d1f94fd30e3e3c21098" @@ -31216,7 +31437,7 @@ vue-class-component@^7.0.1: resolved "https://registry.yarnpkg.com/vue-class-component/-/vue-class-component-7.1.0.tgz#b33efcb10e17236d684f70b1e96f1946ec793e87" integrity sha512-G9152NzUkz0i0xTfhk0Afc8vzdXxDR1pfN4dTwE72cskkgJtdXfrKBkMfGvDuxUh35U500g5Ve4xL8PEGdWeHg== -vue-docgen-api@^3.26.0: +vue-docgen-api@^3.11.4, vue-docgen-api@^3.26.0: version "3.26.0" resolved "https://registry.yarnpkg.com/vue-docgen-api/-/vue-docgen-api-3.26.0.tgz#2afc6a39e72862fbbc60ceb8510c681749f05460" integrity sha512-ujdg4i5ZI/wE46RZQMFzKnDGyhEuPCu+fMA86CAd9EIek/6+OqraSVBm5ZkLrbEd5f8xxdnqMU4yiSGHHeao/Q== @@ -31272,7 +31493,7 @@ vue-style-loader@^4.1.0: hash-sum "^1.0.2" loader-utils "^1.0.2" -vue-template-compiler@^2.0.0, vue-template-compiler@^2.6.8: +vue-template-compiler@^2.0.0, vue-template-compiler@^2.5.16, vue-template-compiler@^2.6.8: version "2.6.10" resolved "https://registry.yarnpkg.com/vue-template-compiler/-/vue-template-compiler-2.6.10.tgz#323b4f3495f04faa3503337a82f5d6507799c9cc" integrity sha512-jVZkw4/I/HT5ZMvRnhv78okGusqe0+qH2A0Em0Cp8aq78+NK9TII263CDVz2QXZsIT+yyV/gZc/j/vlwa+Epyg== @@ -31290,6 +31511,11 @@ vue@^2.6.8: resolved "https://registry.yarnpkg.com/vue/-/vue-2.6.10.tgz#a72b1a42a4d82a721ea438d1b6bf55e66195c637" integrity sha512-ImThpeNU9HbdZL3utgMCq0oiMzAkt1mcgy3/E6zWC/G6AaQoeuFdsl9nDhTDU3X1R6FK7nsIUuRACVcjI+A2GQ== +vuera@^0.2.3: + version "0.2.6" + resolved "https://registry.yarnpkg.com/vuera/-/vuera-0.2.6.tgz#1252c7c11cd7467ddd552124b7bf3bee50d56382" + integrity sha512-yEV9vVRlgTzyNbxCt31PrbchNegAPI+65Buz4xrDVauVIGAWDCs69JMJzx6I6JMxlUAM6p5HDAE4OBoh/mwaUA== + vuex@^3.1.0: version "3.1.2" resolved "https://registry.yarnpkg.com/vuex/-/vuex-3.1.2.tgz#a2863f4005aa73f2587e55c3fadf3f01f69c7d4d" From 95a14b1a2cd43489f10baed18c7f4c31a52c510b Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Fri, 29 Nov 2019 00:45:41 +0100 Subject: [PATCH 002/132] REMOVE uses of css template literals --- addons/jest/src/styles.js | 573 ------------- lib/components/src/Button/Button.tsx | 440 +++++----- .../src/tooltip/WithTooltip.stories.tsx | 38 +- .../src/typography/DocumentWrapper.tsx | 750 +++++++----------- 4 files changed, 547 insertions(+), 1254 deletions(-) delete mode 100644 addons/jest/src/styles.js diff --git a/addons/jest/src/styles.js b/addons/jest/src/styles.js deleted file mode 100644 index 19a9ea6943f..00000000000 --- a/addons/jest/src/styles.js +++ /dev/null @@ -1,573 +0,0 @@ -import { document } from 'global'; - -const styles = ` - @font-face { - font-family: octicons-link; - src: url(data:font/woff;charset=utf-8;base64,d09GRgABAAAAAAZwABAAAAAACFQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABEU0lHAAAGaAAAAAgAAAAIAAAAAUdTVUIAAAZcAAAACgAAAAoAAQAAT1MvMgAAAyQAAABJAAAAYFYEU3RjbWFwAAADcAAAAEUAAACAAJThvmN2dCAAAATkAAAABAAAAAQAAAAAZnBnbQAAA7gAAACyAAABCUM+8IhnYXNwAAAGTAAAABAAAAAQABoAI2dseWYAAAFsAAABPAAAAZwcEq9taGVhZAAAAsgAAAA0AAAANgh4a91oaGVhAAADCAAAABoAAAAkCA8DRGhtdHgAAAL8AAAADAAAAAwGAACfbG9jYQAAAsAAAAAIAAAACABiATBtYXhwAAACqAAAABgAAAAgAA8ASm5hbWUAAAToAAABQgAAAlXu73sO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AAHja28jAwOC00ZrBeQNDQOWO//sdBBgYGRiYWYAEELEwMTE4uzo5Zzo5b2BxdnFOcALxNjA6b2ByTswC8jYwg0VlNuoCTWAMqNzMzsoK1rEhNqByEyerg5PMJlYuVueETKcd/89uBpnpvIEVomeHLoMsAAe1Id4AAAAAAAB42oWQT07CQBTGv0JBhagk7HQzKxca2sJCE1hDt4QF+9JOS0nbaaYDCQfwCJ7Au3AHj+LO13FMmm6cl7785vven0kBjHCBhfpYuNa5Ph1c0e2Xu3jEvWG7UdPDLZ4N92nOm+EBXuAbHmIMSRMs+4aUEd4Nd3CHD8NdvOLTsA2GL8M9PODbcL+hD7C1xoaHeLJSEao0FEW14ckxC+TU8TxvsY6X0eLPmRhry2WVioLpkrbp84LLQPGI7c6sOiUzpWIWS5GzlSgUzzLBSikOPFTOXqly7rqx0Z1Q5BAIoZBSFihQYQOOBEdkCOgXTOHA07HAGjGWiIjaPZNW13/+lm6S9FT7rLHFJ6fQbkATOG1j2OFMucKJJsxIVfQORl+9Jyda6Sl1dUYhSCm1dyClfoeDve4qMYdLEbfqHf3O/AdDumsjAAB42mNgYoAAZQYjBmyAGYQZmdhL8zLdDEydARfoAqIAAAABAAMABwAKABMAB///AA8AAQAAAAAAAAAAAAAAAAABAAAAAA==) format('woff'); - } - .markdown-body { - -ms-text-size-adjust: 100%; - -webkit-text-size-adjust: 100%; - line-height: 1.5; - color: #333; - font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"; - font-size: 16px; - line-height: 1.5; - word-wrap: break-word; - } - .markdown-body .pl-c { - color: #969896; - } - .markdown-body .pl-c1, - .markdown-body .pl-s .pl-v { - color: #0086b3; - } - .markdown-body .pl-e, - .markdown-body .pl-en { - color: #795da3; - } - .markdown-body .pl-smi, - .markdown-body .pl-s .pl-s1 { - color: #333; - } - .markdown-body .pl-ent { - color: #63a35c; - } - .markdown-body .pl-k { - color: #a71d5d; - } - .markdown-body .pl-s, - .markdown-body .pl-pds, - .markdown-body .pl-s .pl-pse .pl-s1, - .markdown-body .pl-sr, - .markdown-body .pl-sr .pl-cce, - .markdown-body .pl-sr .pl-sre, - .markdown-body .pl-sr .pl-sra { - color: #183691; - } - .markdown-body .pl-v { - color: #ed6a43; - } - .markdown-body .pl-id { - color: #b52a1d; - } - .markdown-body .pl-ii { - color: #f8f8f8; - background-color: #b52a1d; - } - .markdown-body .pl-sr .pl-cce { - font-weight: bold; - color: #63a35c; - } - .markdown-body .pl-ml { - color: #693a17; - } - .markdown-body .pl-mh, - .markdown-body .pl-mh .pl-en, - .markdown-body .pl-ms { - font-weight: bold; - color: #1d3e81; - } - .markdown-body .pl-mq { - color: #008080; - } - .markdown-body .pl-mi { - font-style: italic; - color: #333; - } - .markdown-body .pl-mb { - font-weight: bold; - color: #333; - } - .markdown-body .pl-md { - color: #bd2c00; - background-color: #ffecec; - } - .markdown-body .pl-mi1 { - color: #55a532; - background-color: #eaffea; - } - .markdown-body .pl-mdr { - font-weight: bold; - color: #795da3; - } - .markdown-body .pl-mo { - color: #1d3e81; - } - .markdown-body .octicon { - display: inline-block; - vertical-align: text-top; - fill: currentColor; - } - .markdown-body a { - background-color: transparent; - -webkit-text-decoration-skip: objects; - } - .markdown-body a:active, - .markdown-body a:hover { - outline-width: 0; - } - .markdown-body strong { - font-weight: inherit; - } - .markdown-body strong { - font-weight: bolder; - } - .markdown-body h1 { - font-size: 2em; - margin: 0.67em 0; - } - .markdown-body img { - border-style: none; - } - .markdown-body svg:not(:root) { - overflow: hidden; - } - .markdown-body code, - .markdown-body kbd, - .markdown-body pre { - font-family: monospace, monospace; - font-size: 1em; - } - .markdown-body hr { - box-sizing: content-box; - height: 0; - overflow: visible; - } - .markdown-body input { - font: inherit; - margin: 0; - } - .markdown-body input { - overflow: visible; - } - .markdown-body [type="checkbox"] { - box-sizing: border-box; - padding: 0; - } - .markdown-body * { - box-sizing: border-box; - } - .markdown-body input { - font-family: inherit; - font-size: inherit; - line-height: inherit; - } - .markdown-body a { - color: #4078c0; - text-decoration: none; - } - .markdown-body a:hover, - .markdown-body a:active { - text-decoration: underline; - } - .markdown-body strong { - font-weight: 600; - } - .markdown-body hr { - height: 0; - margin: 15px 0; - overflow: hidden; - background: transparent; - border: 0; - border-bottom: 1px solid #ddd; - } - .markdown-body hr::before { - display: table; - content: ""; - } - .markdown-body hr::after { - display: table; - clear: both; - content: ""; - } - .markdown-body table { - border-spacing: 0; - border-collapse: collapse; - } - .markdown-body td, - .markdown-body th { - padding: 0; - } - .markdown-body h1, - .markdown-body h2, - .markdown-body h3, - .markdown-body h4, - .markdown-body h5, - .markdown-body h6 { - margin-top: 0; - margin-bottom: 0; - } - .markdown-body h1 { - font-size: 32px; - font-weight: 600; - } - .markdown-body h2 { - font-size: 24px; - font-weight: 600; - } - .markdown-body h3 { - font-size: 20px; - font-weight: 600; - } - .markdown-body h4 { - font-size: 16px; - font-weight: 600; - } - .markdown-body h5 { - font-size: 14px; - font-weight: 600; - } - .markdown-body h6 { - font-size: 12px; - font-weight: 600; - } - .markdown-body p { - margin-top: 0; - margin-bottom: 10px; - } - .markdown-body blockquote { - margin: 0; - } - .markdown-body ul, - .markdown-body ol { - padding-left: 0; - margin-top: 0; - margin-bottom: 0; - } - .markdown-body ol ol, - .markdown-body ul ol { - list-style-type: lower-roman; - } - .markdown-body ul ul ol, - .markdown-body ul ol ol, - .markdown-body ol ul ol, - .markdown-body ol ol ol { - list-style-type: lower-alpha; - } - .markdown-body dd { - margin-left: 0; - } - .markdown-body code { - font-family: Consolas, "Liberation Mono", Menlo, Courier, monospace; - font-size: 12px; - } - .markdown-body pre { - margin-top: 0; - margin-bottom: 0; - font: 12px Consolas, "Liberation Mono", Menlo, Courier, monospace; - } - .markdown-body .octicon { - vertical-align: text-bottom; - } - .markdown-body input { - -webkit-font-feature-settings: "liga" 0; - font-feature-settings: "liga" 0; - } - .markdown-body::before { - display: table; - content: ""; - } - .markdown-body::after { - display: table; - clear: both; - content: ""; - } - .markdown-body>*:first-child { - margin-top: 0 !important; - } - .markdown-body>*:last-child { - margin-bottom: 0 !important; - } - .markdown-body a:not([href]) { - color: inherit; - text-decoration: none; - } - .markdown-body .anchor { - float: left; - padding-right: 4px; - margin-left: -20px; - line-height: 1; - } - .markdown-body .anchor:focus { - outline: none; - } - .markdown-body p, - .markdown-body blockquote, - .markdown-body ul, - .markdown-body ol, - .markdown-body dl, - .markdown-body table, - .markdown-body pre { - margin-top: 0; - margin-bottom: 16px; - } - .markdown-body hr { - height: 0.25em; - padding: 0; - margin: 24px 0; - background-color: #e7e7e7; - border: 0; - } - .markdown-body blockquote { - padding: 0 1em; - color: #777; - border-left: 0.25em solid #ddd; - } - .markdown-body blockquote>:first-child { - margin-top: 0; - } - .markdown-body blockquote>:last-child { - margin-bottom: 0; - } - .markdown-body kbd { - display: inline-block; - padding: 3px 5px; - font-size: 11px; - line-height: 10px; - color: #555; - vertical-align: middle; - background-color: #fcfcfc; - border: solid 1px #ccc; - border-bottom-color: #bbb; - border-radius: 3px; - box-shadow: inset 0 -1px 0 #bbb; - } - .markdown-body h1, - .markdown-body h2, - .markdown-body h3, - .markdown-body h4, - .markdown-body h5, - .markdown-body h6 { - margin-top: 24px; - margin-bottom: 16px; - font-weight: 600; - line-height: 1.25; - } - .markdown-body h1 .octicon-link, - .markdown-body h2 .octicon-link, - .markdown-body h3 .octicon-link, - .markdown-body h4 .octicon-link, - .markdown-body h5 .octicon-link, - .markdown-body h6 .octicon-link { - color: #000; - vertical-align: middle; - visibility: hidden; - } - .markdown-body h1:hover .anchor, - .markdown-body h2:hover .anchor, - .markdown-body h3:hover .anchor, - .markdown-body h4:hover .anchor, - .markdown-body h5:hover .anchor, - .markdown-body h6:hover .anchor { - text-decoration: none; - } - .markdown-body h1:hover .anchor .octicon-link, - .markdown-body h2:hover .anchor .octicon-link, - .markdown-body h3:hover .anchor .octicon-link, - .markdown-body h4:hover .anchor .octicon-link, - .markdown-body h5:hover .anchor .octicon-link, - .markdown-body h6:hover .anchor .octicon-link { - visibility: visible; - } - .markdown-body h1 { - padding-bottom: 0.3em; - font-size: 2em; - border-bottom: 1px solid #eee; - } - .markdown-body h2 { - padding-bottom: 0.3em; - font-size: 1.5em; - border-bottom: 1px solid #eee; - } - .markdown-body h3 { - font-size: 1.25em; - } - .markdown-body h4 { - font-size: 1em; - } - .markdown-body h5 { - font-size: 0.875em; - } - .markdown-body h6 { - font-size: 0.85em; - color: #777; - } - .markdown-body ul, - .markdown-body ol { - padding-left: 2em; - } - .markdown-body ul ul, - .markdown-body ul ol, - .markdown-body ol ol, - .markdown-body ol ul { - margin-top: 0; - margin-bottom: 0; - } - .markdown-body li>p { - margin-top: 16px; - } - .markdown-body li+li { - margin-top: 0.25em; - } - .markdown-body dl { - padding: 0; - } - .markdown-body dl dt { - padding: 0; - margin-top: 16px; - font-size: 1em; - font-style: italic; - font-weight: bold; - } - .markdown-body dl dd { - padding: 0 16px; - margin-bottom: 16px; - } - .markdown-body table { - display: block; - width: 100%; - overflow: auto; - } - .markdown-body table th { - font-weight: bold; - } - .markdown-body table th, - .markdown-body table td { - padding: 6px 13px; - border: 1px solid #ddd; - } - .markdown-body table tr { - background-color: #fff; - border-top: 1px solid #ccc; - } - .markdown-body table tr:nth-child(2n) { - background-color: #f8f8f8; - } - .markdown-body img { - max-width: 100%; - box-sizing: content-box; - background-color: #fff; - } - .markdown-body code { - padding: 0; - padding-top: 0.2em; - padding-bottom: 0.2em; - margin: 0; - font-size: 85%; - background-color: rgba(0,0,0,0.04); - border-radius: 3px; - } - .markdown-body code::before, - .markdown-body code::after { - letter-spacing: -0.2em; - content: " "; - } - .markdown-body pre { - word-wrap: normal; - } - .markdown-body pre>code { - padding: 0; - margin: 0; - font-size: 100%; - word-break: normal; - white-space: pre; - background: transparent; - border: 0; - } - .markdown-body .highlight { - margin-bottom: 16px; - } - .markdown-body .highlight pre { - margin-bottom: 0; - word-break: normal; - } - .markdown-body .highlight pre, - .markdown-body pre { - padding: 16px; - overflow: auto; - font-size: 85%; - line-height: 1.45; - background-color: #f7f7f7; - border-radius: 3px; - } - .markdown-body pre code { - display: inline; - max-width: auto; - padding: 0; - margin: 0; - overflow: visible; - line-height: inherit; - word-wrap: normal; - background-color: transparent; - border: 0; - } - .markdown-body pre code::before, - .markdown-body pre code::after { - content: normal; - } - .markdown-body .pl-0 { - padding-left: 0 !important; - } - .markdown-body .pl-1 { - padding-left: 3px !important; - } - .markdown-body .pl-2 { - padding-left: 6px !important; - } - .markdown-body .pl-3 { - padding-left: 12px !important; - } - .markdown-body .pl-4 { - padding-left: 24px !important; - } - .markdown-body .pl-5 { - padding-left: 36px !important; - } - .markdown-body .pl-6 { - padding-left: 48px !important; - } - .markdown-body .full-commit .btn-outline:not(:disabled):hover { - color: #4078c0; - border: 1px solid #4078c0; - } - .markdown-body kbd { - display: inline-block; - padding: 3px 5px; - font: 11px Consolas, "Liberation Mono", Menlo, Courier, monospace; - line-height: 10px; - color: #555; - vertical-align: middle; - background-color: #fcfcfc; - border: solid 1px #ccc; - border-bottom-color: #bbb; - border-radius: 3px; - box-shadow: inset 0 -1px 0 #bbb; - } - .markdown-body :checked+.radio-label { - position: relative; - z-index: 1; - border-color: #4078c0; - } - .markdown-body .task-list-item { - list-style-type: none; - } - .markdown-body .task-list-item+.task-list-item { - margin-top: 3px; - } - .markdown-body .task-list-item input { - margin: 0 0.2em 0.25em -1.6em; - vertical-align: middle; - } - .markdown-body hr { - border-bottom-color: #eee; - } -`; - -if (document && !document.getElementById('github-markdown-css')) { - const styleNode = document.createElement('style'); - styleNode.id = 'github-markdown-css'; - styleNode.innerHTML = styles; - - document.head.appendChild(styleNode); -} diff --git a/lib/components/src/Button/Button.tsx b/lib/components/src/Button/Button.tsx index d5ee1387457..e5691b91a4f 100644 --- a/lib/components/src/Button/Button.tsx +++ b/lib/components/src/Button/Button.tsx @@ -1,226 +1,7 @@ import React, { FunctionComponent, forwardRef } from 'react'; -import { styled, css } from '@storybook/theming'; +import { styled } from '@storybook/theming'; import { darken, lighten, rgba, transparentize } from 'polished'; -type ButtonWrapperProps = ButtonProps; - -const ButtonWrapper = styled.button` - border: 0; - border-radius: 3em; - cursor: pointer; - display: inline-block; - overflow: hidden; - padding: ${props => (props.small ? '10px 16px' : '13px 20px')}; - position: relative; - text-align: center; - text-decoration: none; - transition: all 150ms ease-out; - transform: translate3d(0,0,0); - vertical-align: top; - white-space: nowrap; - user-select: none; - opacity: 1; - margin: 0; - background: transparent; - - - font-size: ${props => - props.small ? props.theme.typography.size.s1 : props.theme.typography.size.s2 - 1}px; - font-weight: ${props => props.theme.typography.weight.bold}; - line-height: 1; - - - svg { - display: inline-block; - height: ${props => (props.small ? '14' : '16')}px; - width: ${props => (props.small ? '14' : '16')}px; - vertical-align: top; - margin-right: ${props => (props.small ? '4' : '6')}px; - margin-top: ${props => (props.small ? '-1' : '-2')}px; - margin-bottom: ${props => (props.small ? '-1' : '-2')}px; - - /* Necessary for js mouse events to not glitch out when hovering on svgs */ - pointer-events: none; - - path { fill: currentColor; } - } - - ${props => - props.disabled && - css` - cursor: not-allowed !important; - opacity: 0.5; - &:hover { - transform: none; - } - `} - - ${props => - props.containsIcon && - css` - svg { - display: block; - margin: 0; - } - - ${props.small && - css` - padding: 9px; - `} - - ${!props.small && - css` - padding: 12px; - `} - `} - - /* Colored button for primary CTAs */ - ${props => - props.primary && - css` - background: ${props.theme.color.primary}; - color: ${props.theme.color.lightest}; - - &:hover { - background: ${darken(0.05, props.theme.color.primary)}; - } - &:active { - box-shadow: rgba(0, 0, 0, 0.1) 0 0 0 3em inset; - } - &:focus { - box-shadow: ${rgba(props.theme.color.primary, 0.4)} 0 1px 9px 2px; - } - &:focus:hover { - box-shadow: ${rgba(props.theme.color.primary, 0.2)} 0 8px 18px 0px; - } - `} - - - /* Colored button for secondary CTAs */ - ${props => - props.secondary && - css` - background: ${props.theme.color.secondary}; - color: ${props.theme.color.lightest}; - - &:hover { - background: ${darken(0.05, props.theme.color.secondary)}; - } - &:active { - box-shadow: rgba(0, 0, 0, 0.1) 0 0 0 3em inset; - } - &:focus { - box-shadow: ${rgba(props.theme.color.secondary, 0.4)} 0 1px 9px 2px; - } - &:focus:hover { - box-shadow: ${rgba(props.theme.color.secondary, 0.2)} 0 8px 18px 0px; - } - `} - - /* Button for tertiary CTAs and forms that responds to theme */ - ${props => - props.tertiary && - css` - background: ${props.theme.base === 'light' - ? darken(0.02, props.theme.input.background) - : lighten(0.02, props.theme.input.background)}; - color: ${props.theme.input.color}; - box-shadow: ${props.theme.input.border} 0 0 0 1px inset; - border-radius: ${props.theme.input.borderRadius}px; - - &:hover { - background: ${props.theme.base === 'light' - ? darken(0.05, props.theme.input.background) - : lighten(0.05, props.theme.input.background)}; - ${props.inForm - ? '' - : 'box-shadow: rgba(0,0,0,.2) 0 2px 6px 0, rgba(0,0,0,.1) 0 0 0 1px inset'} - } - &:active { - background: ${props.theme.base === 'light' - ? props.theme.input.background - : props.theme.input.background}; - } - &:focus { - box-shadow: ${rgba(props.theme.color.secondary, 0.4)} 0 0 0 1px inset; - } - `} - - /* Button that's outlined */ - ${props => - props.outline && - css` - box-shadow: ${transparentize(0.8, props.theme.color.defaultText)} 0 0 0 1px inset; - color: ${transparentize(0.3, props.theme.color.defaultText)}; - background: transparent; - - &:hover { - box-shadow: ${transparentize(0.5, props.theme.color.defaultText)} 0 0 0 1px inset; - } - - &:active { - box-shadow: ${transparentize(0.5, props.theme.color.defaultText)} 0 0 0 2px inset; - color: ${transparentize(0, props.theme.color.defaultText)}; - } - - ${props.primary && - css` - box-shadow: ${props.theme.color.primary} 0 0 0 1px inset; - color: ${props.theme.color.primary}; - - svg path { - fill: ${props.theme.color.primary}; - } - - &:hover { - box-shadow: ${props.theme.color.primary} 0 0 0 1px inset; - background: transparent; - } - - &:active { - background: ${props.theme.color.primary}; - box-shadow: ${props.theme.color.primary} 0 0 0 1px inset; - color: ${props.theme.color.lightest}; - } - &:focus { - box-shadow: ${props.theme.color.primary} 0 0 0 1px inset, - ${rgba(props.theme.color.primary, 0.4)} 0 1px 9px 2px; - } - &:focus:hover { - box-shadow: ${props.theme.color.primary} 0 0 0 1px inset, - ${rgba(props.theme.color.primary, 0.2)} 0 8px 18px 0px; - } - `}; - - ${props.secondary && - css` - box-shadow: ${props.theme.color.secondary} 0 0 0 1px inset; - color: ${props.theme.color.secondary}; - - &:hover { - box-shadow: ${props.theme.color.secondary} 0 0 0 1px inset; - background: transparent; - } - - &:active { - background: ${props.theme.color.secondary}; - box-shadow: ${props.theme.color.secondary} 0 0 0 1px inset; - color: ${props.theme.color.lightest}; - } - &:focus { - box-shadow: ${props.theme.color.secondary} 0 0 0 1px inset, - ${rgba(props.theme.color.secondary, 0.4)} 0 1px 9px 2px; - } - &:focus:hover { - box-shadow: ${props.theme.color.secondary} 0 0 0 1px inset, - ${rgba(props.theme.color.secondary, 0.2)} 0 8px 18px 0px; - } - `}; - `} -`; - -const ButtonLink = ButtonWrapper.withComponent('a'); - export interface ButtonProps { isLink?: boolean; primary?: boolean; @@ -233,6 +14,225 @@ export interface ButtonProps { containsIcon?: boolean; } +type ButtonWrapperProps = ButtonProps; + +const ButtonWrapper = styled.button( + ({ small, theme }) => ({ + border: 0, + borderRadius: '3em', + cursor: 'pointer', + display: 'inline-block', + overflow: 'hidden', + padding: small ? '10px' : '16px', + position: 'relative', + textAlign: 'center', + textDecoration: 'none', + transition: 'all 150ms ease-out', + transform: 'translate3d(0,0,0)', + verticalAlign: 'top', + whiteSpace: 'nowrap', + userSelect: 'none', + opacity: '1', + margin: '0', + background: 'transparent', + + fontSize: `${small ? theme.typography.size.s1 : theme.typography.size.s2 - 1}px`, + fontWeight: theme.typography.weight.bold, + lineHeight: '1', + + svg: { + display: 'inline-block', + height: small ? 14 : 16, + width: small ? 14 : 16, + + verticalAlign: 'top', + marginRight: small ? 4 : 6, + marginTop: small ? -1 : -2, + marginBottom: small ? -1 : -2, + + /* Necessary for js mouse events to not glitch out when hovering on svgs */ + pointerEvents: 'none', + + path: { + fill: 'currentColor }', + }, + }, + }), + ({ disabled }) => + disabled + ? { + cursor: 'not-allowed !important', + opacity: '0.5', + '&:hover': { + transform: 'none', + }, + } + : {}, + ({ containsIcon, small }) => + containsIcon + ? { + svg: { + display: 'block', + margin: '0', + }, + ...(small ? { padding: 9 } : { padding: 12 }), + } + : {}, + ({ theme, primary }) => + primary + ? { + background: theme.color.primary, + color: theme.color.lightest, + + '&:hover': { + background: darken(0.05, theme.color.primary), + }, + '&:active': { + boxShadow: 'rgba(0, 0, 0, 0.1) 0 0 0 3em inset', + }, + '&:focus': { + boxShadow: `${rgba(theme.color.primary, 0.4)} 0 1px 9px 2px`, + }, + '&:focus:hover': { + boxShadow: `${rgba(theme.color.primary, 0.2)} 0 8px 18px 0px`, + }, + } + : {}, + ({ theme, secondary }) => + secondary + ? { + background: theme.color.secondary, + color: theme.color.lightest, + + '&:hover': { + background: darken(0.05, theme.color.secondary), + }, + '&:active': { + boxShadow: 'rgba(0, 0, 0, 0.1) 0 0 0 3em inset', + }, + '&:focus': { + boxShadow: `${rgba(theme.color.secondary, 0.4)} 0 1px 9px 2px`, + }, + '&:focus:hover': { + boxShadow: `${rgba(theme.color.secondary, 0.2)} 0 8px 18px 0px`, + }, + } + : {}, + ({ theme, tertiary, inForm }) => + tertiary + ? { + background: + theme.base === 'light' + ? darken(0.02, theme.input.background) + : lighten(0.02, theme.input.background), + color: theme.input.color, + boxShadow: `${theme.input.border} 0 0 0 1px inset`, + borderRadius: theme.input.borderRadius, + + '&:hover': { + background: + theme.base === 'light' + ? darken(0.05, theme.input.background) + : lighten(0.05, theme.input.background), + ...(inForm + ? {} + : { + boxShadow: 'rgba(0,0,0,.2) 0 2px 6px 0, rgba(0,0,0,.1) 0 0 0 1px inset', + }), + }, + '&:active': { + background: theme.input.background, + }, + '&:focus': { + boxShadow: `${rgba(theme.color.secondary, 0.4)} 0 0 0 1px inset`, + }, + } + : {}, + ({ theme, outline }) => + outline + ? { + boxShadow: `${transparentize(0.8, theme.color.defaultText)} 0 0 0 1px inset`, + color: `${transparentize(0.3, theme.color.defaultText)}`, + background: 'transparent', + + '&:hover': { + boxShadow: `${transparentize(0.5, theme.color.defaultText)} 0 0 0 1px inset`, + }, + + '&:active': { + boxShadow: `${transparentize(0.5, theme.color.defaultText)} 0 0 0 2px inset`, + color: `${transparentize(0, theme.color.defaultText)}`, + }, + } + : {}, + ({ theme, outline, primary }) => + outline && primary + ? { + boxShadow: `${theme.color.primary} 0 0 0 1px inset`, + color: `${theme.color.primary}`, + + 'svg path': { + fill: theme.color.primary, + }, + + '&:hover': { + boxShadow: `${theme.color.primary} 0 0 0 1px inset`, + background: 'transparent', + }, + + '&:active': { + background: theme.color.primary, + boxShadow: `${theme.color.primary} 0 0 0 1px inset`, + color: theme.color.lightest, + }, + '&:focus': { + boxShadow: `${theme.color.primary} 0 0 0 1px inset, ${rgba( + theme.color.primary, + 0.4 + )} 0 1px 9px 2px`, + }, + '&:focus:hover': { + boxShadow: `${theme.color.primary} 0 0 0 1px inset, ${rgba( + theme.color.primary, + 0.2 + )} 0 8px 18px 0px`, + }, + } + : {}, + ({ theme, outline, primary, secondary }) => { + const color = primary || secondary; + return outline && color + ? { + boxShadow: `${color} 0 0 0 1px inset`, + color: `${color}`, + + 'svg path': { + fill: color, + }, + + '&:hover': { + boxShadow: `${color} 0 0 0 1px inset`, + background: 'transparent', + }, + + '&:active': { + background: color, + boxShadow: `${color} 0 0 0 1px inset`, + color: theme.color.lightest, + }, + '&:focus': { + boxShadow: `${color} 0 0 0 1px inset, ${rgba(color, 0.4)} 0 1px 9px 2px`, + }, + '&:focus:hover': { + boxShadow: `${color} 0 0 0 1px inset, ${rgba(color, 0.2)} 0 8px 18px 0px`, + }, + } + : {}; + } +); + +const ButtonLink = ButtonWrapper.withComponent('a'); + export const Button = Object.assign( forwardRef(({ isLink, children, ...props }, ref) => { if (isLink) { diff --git a/lib/components/src/tooltip/WithTooltip.stories.tsx b/lib/components/src/tooltip/WithTooltip.stories.tsx index eb1b05ca1b3..d73cbefb815 100644 --- a/lib/components/src/tooltip/WithTooltip.stories.tsx +++ b/lib/components/src/tooltip/WithTooltip.stories.tsx @@ -5,28 +5,28 @@ import { styled } from '@storybook/theming'; import { TooltipMessage } from './TooltipMessage'; import { WithToolTipState as WithTooltip } from './WithTooltip'; -const ViewPort = styled.div` - height: 300px; -`; +const ViewPort = styled.div({ + height: 300, +}); -const BackgroundBox = styled.div` - width: 500px; - height: 500px; - overflow-y: scroll; - background: #eee; - position: relative; -`; +const BackgroundBox = styled.div({ + width: 500, + height: 500, + overflowY: 'scroll', + background: '#eee', + position: 'relative', +}); -const Spacer = styled.div` - height: 100px; -`; +const Spacer = styled.div({ + height: 100, +}); -const Trigger = styled.div` - width: 200px; - height: 100px; - background-color: red; - color: white; -`; +const Trigger = styled.div({ + width: 200, + height: 100, + backgroundColor: 'red', + color: 'white', +}); interface TooltipProps { onHide?: () => void; diff --git a/lib/components/src/typography/DocumentWrapper.tsx b/lib/components/src/typography/DocumentWrapper.tsx index 7576d8a2271..54511c2e97e 100644 --- a/lib/components/src/typography/DocumentWrapper.tsx +++ b/lib/components/src/typography/DocumentWrapper.tsx @@ -1,442 +1,308 @@ -import { styled, css } from '@storybook/theming'; - -export const DocumentWrapper = styled.div( - ({ theme }) => css` - /* Custom styles atop GitHub base theme (see below) */ - font-size: ${theme.typography.size.s2}px; - line-height: 1.6; - - h1 { - font-size: ${theme.typography.size.l1}px; - font-weight: ${theme.typography.weight.black}; - } - - h2 { - font-size: ${theme.typography.size.m2}px; - border-bottom: 1px solid ${theme.appBorderColor}; - } - - h3 { - font-size: ${theme.typography.size.m1}px; - } - - h4 { - font-size: ${theme.typography.size.s3}px; - } - - h5 { - font-size: ${theme.typography.size.s2}px; - } - - h6 { - font-size: ${theme.typography.size.s2}px; - color: ${theme.color.dark}; - } - - /* Custom for SB SyntaxHighlighter */ - - pre:not(.hljs) { - background: transparent; - border: none; - border-radius: 0; - padding: 0; - margin: 0; - } - - pre pre, - pre.hljs { - padding: 15px; - margin: 0; - - white-space: pre-wrap; - color: inherit; - - font-size: 13px; - line-height: 19px; - - code { - color: inherit; - font-size: inherit; - } - } - - pre code { - margin: 0; - padding: 0; - white-space: pre; - border: none; - background: transparent; - } - - pre code, - pre tt { - background-color: transparent; - border: none; - } - - /* GitHub inspired Markdown styles loosely from https://gist.github.com/tuzz/3331384 */ - - body > *:first-of-type { - margin-top: 0 !important; - } - - body > *:last-child { - margin-bottom: 0 !important; - } - - a { - color: ${theme.color.secondary}; - text-decoration: none; - } - - a.absent { - color: #cc0000; - } - - a.anchor { - display: block; - padding-left: 30px; - margin-left: -30px; - cursor: pointer; - position: absolute; - top: 0; - left: 0; - bottom: 0; - } - - h1, - h2, - h3, - h4, - h5, - h6 { - margin: 20px 0 10px; - padding: 0; - cursor: text; - position: relative; - } - - h2:first-of-type, - h1:first-of-type, - h1:first-of-type + h2, - h3:first-of-type, - h4:first-of-type, - h5:first-of-type, - h6:first-of-type { - margin-top: 0; - padding-top: 0; - } - - h1:hover a.anchor, - h2:hover a.anchor, - h3:hover a.anchor, - h4:hover a.anchor, - h5:hover a.anchor, - h6:hover a.anchor { - text-decoration: none; - } - - h1 tt, - h1 code { - font-size: inherit; - } - - h2 tt, - h2 code { - font-size: inherit; - } - - h3 tt, - h3 code { - font-size: inherit; - } - - h4 tt, - h4 code { - font-size: inherit; - } - - h5 tt, - h5 code { - font-size: inherit; - } - - h6 tt, - h6 code { - font-size: inherit; - } - - p, - blockquote, - ul, - ol, - dl, - li, - table, - pre { - margin: 15px 0; - } - - hr { - border: 0 none; - border-top: 1px solid ${theme.appBorderColor}; - height: 4px; - padding: 0; - } - - body > h2:first-of-type { - margin-top: 0; - padding-top: 0; - } - - body > h1:first-of-type { - margin-top: 0; - padding-top: 0; - } - - body > h1:first-of-type + h2 { - margin-top: 0; - padding-top: 0; - } - - body > h3:first-of-type, - body > h4:first-of-type, - body > h5:first-of-type, - body > h6:first-of-type { - margin-top: 0; - padding-top: 0; - } - - a:first-of-type h1, - a:first-of-type h2, - a:first-of-type h3, - a:first-of-type h4, - a:first-of-type h5, - a:first-of-type h6 { - margin-top: 0; - padding-top: 0; - } - - h1 p, - h2 p, - h3 p, - h4 p, - h5 p, - h6 p { - margin-top: 0; - } - - li p.first { - display: inline-block; - } - - ul, - ol { - padding-left: 30px; - } - - ul :first-of-type, - ol :first-of-type { - margin-top: 0; - } - - ul :last-child, - ol :last-child { - margin-bottom: 0; - } - - dl { - padding: 0; - } - - dl dt { - font-size: 14px; - font-weight: bold; - font-style: italic; - padding: 0; - margin: 15px 0 5px; - } - - dl dt:first-of-type { - padding: 0; - } - - dl dt > :first-of-type { - margin-top: 0; - } - - dl dt > :last-child { - margin-bottom: 0; - } - - dl dd { - margin: 0 0 15px; - padding: 0 15px; - } - - dl dd > :first-of-type { - margin-top: 0; - } - - dl dd > :last-child { - margin-bottom: 0; - } - - blockquote { - border-left: 4px solid ${theme.color.medium}; - padding: 0 15px; - color: ${theme.color.dark}; - } - - blockquote > :first-of-type { - margin-top: 0; - } - - blockquote > :last-child { - margin-bottom: 0; - } - - table { - padding: 0; - border-collapse: collapse; - } - table tr { - border-top: 1px solid ${theme.appBorderColor}; - background-color: white; - margin: 0; - padding: 0; - } - - table tr:nth-of-type(2n) { - background-color: ${theme.color.lighter}; - } - - table tr th { - font-weight: bold; - border: 1px solid ${theme.appBorderColor}; - text-align: left; - margin: 0; - padding: 6px 13px; - } - - table tr td { - border: 1px solid ${theme.appBorderColor}; - text-align: left; - margin: 0; - padding: 6px 13px; - } - - table tr th :first-of-type, - table tr td :first-of-type { - margin-top: 0; - } - - table tr th :last-child, - table tr td :last-child { - margin-bottom: 0; - } - - img { - max-width: 100%; - } - - span.frame { - display: block; - overflow: hidden; - } - - span.frame > span { - border: 1px solid ${theme.color.medium}; - display: block; - float: left; - overflow: hidden; - margin: 13px 0 0; - padding: 7px; - width: auto; - } - - span.frame span img { - display: block; - float: left; - } - - span.frame span span { - clear: both; - color: ${theme.color.darkest}; - display: block; - padding: 5px 0 0; - } - - span.align-center { - display: block; - overflow: hidden; - clear: both; - } - - span.align-center > span { - display: block; - overflow: hidden; - margin: 13px auto 0; - text-align: center; - } - - span.align-center span img { - margin: 0 auto; - text-align: center; - } - - span.align-right { - display: block; - overflow: hidden; - clear: both; - } - - span.align-right > span { - display: block; - overflow: hidden; - margin: 13px 0 0; - text-align: right; - } - - span.align-right span img { - margin: 0; - text-align: right; - } - - span.float-left { - display: block; - margin-right: 13px; - overflow: hidden; - float: left; - } - - span.float-left span { - margin: 13px 0 0; - } - - span.float-right { - display: block; - margin-left: 13px; - overflow: hidden; - float: right; - } - - span.float-right > span { - display: block; - overflow: hidden; - margin: 13px auto 0; - text-align: right; - } - - code, - tt { - margin: 0 2px; - padding: 0 5px; - white-space: nowrap; - border: 1px solid ${theme.color.mediumlight}; - background-color: ${theme.color.lighter}; - border-radius: 3px; - color: ${theme.base === 'dark' && theme.color.darkest}; - } - ` -); +import { styled } from '@storybook/theming'; + +export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ + fontSize: `${theme.typography.size.s2}px`, + lineHeight: '1.6', + + h1: { + fontSize: `${theme.typography.size.l1}px`, + fontWeight: theme.typography.weight.black, + }, + h2: { + fontSize: `${theme.typography.size.m2}px`, + borderBottom: `1px solid ${theme.appBorderColor}`, + }, + h3: { + fontSize: `${theme.typography.size.m1}px`, + }, + h4: { + fontSize: `${theme.typography.size.s3}px`, + }, + h5: { + fontSize: `${theme.typography.size.s2}px`, + }, + h6: { + fontSize: `${theme.typography.size.s2}px`, + color: `${theme.color.dark}`, + }, + 'pre:not(.hljs)': { + background: 'transparent', + border: 'none', + borderRadius: '0', + padding: '0', + margin: '0', + }, + 'pre pre, pre.hljs': { + padding: '15px', + margin: '0', + whiteSpace: 'pre-wrap', + color: 'inherit', + fontSize: '13px', + lineHeight: '19px', + }, + 'pre pre code, pre.hljs code': { + color: 'inherit', + fontSize: 'inherit', + }, + 'pre code': { + margin: '0', + padding: '0', + whiteSpace: 'pre', + border: 'none', + background: 'transparent', + }, + 'pre code, pre tt': { + backgroundColor: 'transparent', + border: 'none', + }, + /* GitHub inspired Markdown styles loosely from https://gist.github.com/tuzz/3331384 */ + 'body > *:first-of-type': { + marginTop: '0 !important', + }, + 'body > *:last-child': { + marginBottom: '0 !important', + }, + a: { + color: theme.color.secondary, + textDecoration: 'none', + }, + 'a.absent': { + color: '#cc0000', + }, + 'a.anchor': { + display: 'block', + paddingLeft: '30px', + marginLeft: '-30px', + cursor: 'pointer', + position: 'absolute', + top: '0', + left: '0', + bottom: '0', + }, + 'h1, h2, h3, h4, h5, h6': { + margin: '20px 0 10px', + padding: '0', + cursor: 'text', + position: 'relative', + + '&:first-of-type': { + marginTop: '0', + paddingTop: '0', + }, + '&:hover a.anchor': { + textDecoration: 'none', + }, + '& tt, & code': { + fontSize: 'inherit', + }, + }, + 'h1:first-of-type + h2': { + marginTop: '0', + paddingTop: '0', + }, + 'p, blockquote, ul, ol, dl, li, table, pre': { + margin: '15px 0', + }, + hr: { + border: '0 none', + borderTop: `1px solid ${theme.appBorderColor}`, + height: '4px', + padding: '0', + }, + 'body > h1:first-of-type, body > h2:first-of-type, body > h3:first-of-type, body > h4:first-of-type, body > h5:first-of-type, body > h6:first-of-type': { + marginTop: '0', + paddingTop: '0', + }, + 'body > h1:first-of-type + h2': { + marginTop: '0', + paddingTop: '0', + }, + 'a:first-of-type h1, a:first-of-type h2, a:first-of-type h3, a:first-of-type h4, a:first-of-type h5, a:first-of-type h6': { + marginTop: '0', + paddingTop: '0', + }, + 'h1 p, h2 p, h3 p, h4 p, h5 p, h6 p': { + marginTop: '0', + }, + 'li p.first': { + display: 'inline-block', + }, + 'ul, ol': { + paddingLeft: '30px', + + '& :first-of-type': { + marginTop: '0', + }, + '& :last-child': { + marginBottom: '0', + }, + }, + dl: { + padding: '0', + }, + + 'dl dt': { + fontSize: '14px', + fontWeight: 'bold', + fontStyle: 'italic', + margin: '0 0 15px', + padding: '0 15px', + + '&:first-of-type': { + padding: '0', + }, + '& > :first-of-type': { + marginTop: '0', + }, + '& > :last-child': { + marginBottom: '0', + }, + }, + + blockquote: { + borderLeft: `4px solid ${theme.color.medium}`, + padding: '0 15px', + color: `${theme.color.dark}`, + + '& > :first-of-type': { + marginTop: '0', + }, + + '& > :last-child': { + marginBottom: '0', + }, + }, + + table: { + padding: '0', + borderCollapse: 'collapse', + + '& tr': { + borderTop: `1px solid ${theme.appBorderColor}`, + backgroundColor: 'white', + margin: '0', + padding: '0', + + '& th': { + fontWeight: 'bold', + border: `1px solid ${theme.appBorderColor}`, + textAlign: 'left', + margin: '0', + padding: '6px 13px', + }, + + '& td': { + border: `1px solid ${theme.appBorderColor}`, + textAlign: 'left', + margin: '0', + padding: '6px 13px', + }, + '&:nth-of-type(2n)': { + backgroundColor: `${theme.color.lighter}`, + }, + + '& th :first-of-type, & td :first-of-type': { + marginTop: '0', + }, + '& th :last-child, & td :last-child': { + marginBottom: '0', + }, + }, + }, + img: { + maxWidth: '100%', + }, + '&': { + display: 'block', + overflow: 'hidden', + + '& > span': { + border: `1px solid ${theme.color.medium}`, + display: 'block', + float: 'left', + overflow: 'hidden', + margin: '13px 0 0', + padding: '7px', + width: 'auto', + }, + + '& span img': { + display: 'block', + float: 'left', + }, + + '& span span': { + clear: 'both', + color: `${theme.color.darkest}`, + display: 'block', + padding: '5px 0 0', + }, + }, + 'span.align-center': { + display: 'block', + overflow: 'hidden', + clear: 'both', + + '& > span': { + display: 'block', + overflow: 'hidden', + margin: '13px auto 0', + textAlign: 'center', + }, + '& span img': { + margin: '0 auto', + textAlign: 'center', + }, + }, + 'span.align-right': { + display: 'block', + overflow: 'hidden', + clear: 'both', + + '& > span': { + display: 'block', + overflow: 'hidden', + margin: '13px 0 0', + textAlign: 'right', + }, + + '& span img': { + margin: '0', + textAlign: 'right', + }, + }, + + 'span.float-left': { + display: 'block', + marginRight: '13px', + overflow: 'hidden', + float: 'left', + + '& span': { + margin: '13px 0 0', + }, + }, + + 'span.float-right': { + display: 'block', + marginLeft: '13px', + overflow: 'hidden', + float: 'right', + + '& > span': { + display: 'block', + overflow: 'hidden', + margin: '13px auto 0', + textAlign: 'right', + }, + }, + 'code, tt': { + margin: '0 2px', + padding: '0 5px', + whiteSpace: 'nowrap', + border: `1px solid ${theme.color.mediumlight}`, + backgroundColor: `${theme.color.lighter}`, + borderRadius: '3px', + color: `${theme.base === 'dark' && theme.color.darkest}`, + }, +})); From 0c1034042c813b148620b2a0e0e574ec7bf0849b Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Fri, 29 Nov 2019 01:27:18 +0100 Subject: [PATCH 003/132] REMOVE some more use of css template literal tag usage --- lib/components/src/Button/Button.tsx | 24 +- lib/components/src/typography/link/link.tsx | 297 ++++++++++---------- 2 files changed, 158 insertions(+), 163 deletions(-) diff --git a/lib/components/src/Button/Button.tsx b/lib/components/src/Button/Button.tsx index e5691b91a4f..c338af66661 100644 --- a/lib/components/src/Button/Button.tsx +++ b/lib/components/src/Button/Button.tsx @@ -32,8 +32,8 @@ const ButtonWrapper = styled.button( verticalAlign: 'top', whiteSpace: 'nowrap', userSelect: 'none', - opacity: '1', - margin: '0', + opacity: 1, + margin: 0, background: 'transparent', fontSize: `${small ? theme.typography.size.s1 : theme.typography.size.s2 - 1}px`, @@ -62,7 +62,7 @@ const ButtonWrapper = styled.button( disabled ? { cursor: 'not-allowed !important', - opacity: '0.5', + opacity: 0.5, '&:hover': { transform: 'none', }, @@ -73,7 +73,7 @@ const ButtonWrapper = styled.button( ? { svg: { display: 'block', - margin: '0', + margin: 0, }, ...(small ? { padding: 9 } : { padding: 12 }), } @@ -152,7 +152,7 @@ const ButtonWrapper = styled.button( outline ? { boxShadow: `${transparentize(0.8, theme.color.defaultText)} 0 0 0 1px inset`, - color: `${transparentize(0.3, theme.color.defaultText)}`, + color: transparentize(0.3, theme.color.defaultText), background: 'transparent', '&:hover': { @@ -161,7 +161,7 @@ const ButtonWrapper = styled.button( '&:active': { boxShadow: `${transparentize(0.5, theme.color.defaultText)} 0 0 0 2px inset`, - color: `${transparentize(0, theme.color.defaultText)}`, + color: transparentize(0, theme.color.defaultText), }, } : {}, @@ -169,7 +169,7 @@ const ButtonWrapper = styled.button( outline && primary ? { boxShadow: `${theme.color.primary} 0 0 0 1px inset`, - color: `${theme.color.primary}`, + color: theme.color.primary, 'svg path': { fill: theme.color.primary, @@ -200,11 +200,17 @@ const ButtonWrapper = styled.button( } : {}, ({ theme, outline, primary, secondary }) => { - const color = primary || secondary; + let color; + if (primary) { + color = theme.color.primary; + } + if (secondary) { + color = theme.color.secondary; + } return outline && color ? { boxShadow: `${color} 0 0 0 1px inset`, - color: `${color}`, + color, 'svg path': { fill: color, diff --git a/lib/components/src/typography/link/link.tsx b/lib/components/src/typography/link/link.tsx index c37e9ebba94..5dc47ac1e3c 100644 --- a/lib/components/src/typography/link/link.tsx +++ b/lib/components/src/typography/link/link.tsx @@ -1,10 +1,10 @@ import React, { AnchorHTMLAttributes, FunctionComponent, MouseEvent } from 'react'; -import { styled, css, Theme } from '@storybook/theming'; +import { styled } from '@storybook/theming'; import { darken } from 'polished'; import { Icons } from '../../icon/icon'; -// Cmd/Ctrl/Shift/Alt + Click should trigger default browser behaviour. Same applies to non-left clicks +// Cmd/Ctrl/Shift/Alt + Click should trigger default browser behavior. Same applies to non-left clicks const LEFT_BUTTON = 0; const isPlainLeftClick = (e: MouseEvent) => @@ -25,166 +25,155 @@ export interface LinkStylesProps { isButton?: boolean; } -const linkStyles = (props: LinkStylesProps & { theme: Theme }) => css` - display: inline-block; - transition: all 150ms ease-out; - text-decoration: none; - - color: ${props.theme.color.secondary}; - svg path { - fill: ${props.theme.color.secondary}; - } - - &:hover, - &:focus { - cursor: pointer; - color: ${darken(0.07, props.theme.color.secondary)}; - svg path { - fill: ${darken(0.07, props.theme.color.secondary)}; - } - } - &:active { - color: ${darken(0.1, props.theme.color.secondary)}; - svg path { - fill: ${darken(0.1, props.theme.color.secondary)}; - } - } - - svg { - display: inline-block; - height: 1em; - width: 1em; - vertical-align: text-top; - position: relative; - bottom: -0.125em; - margin-right: 0.4em; - } - - ${props.secondary && - css` - color: ${props.theme.color.mediumdark}; - svg path { - fill: ${props.theme.color.mediumdark}; - } - - &:hover { - color: ${props.theme.color.dark}; - svg path { - fill: ${props.theme.color.dark}; - } - } - - &:active { - color: ${props.theme.color.darker}; - svg path { - fill: ${props.theme.color.darker}; - } - } - `}; - - ${props.tertiary && - css` - color: ${props.theme.color.dark}; - svg path { - fill: ${props.theme.color.dark}; - } - - &:hover { - color: ${props.theme.color.darkest}; - svg path { - fill: ${props.theme.color.darkest}; - } - } - - &:active { - color: ${props.theme.color.mediumdark}; - svg path { - fill: ${props.theme.color.mediumdark}; - } - } - `}; - - ${props.nochrome && - css` - color: inherit; - - &:hover, - &:active { - color: inherit; - text-decoration: underline; - } - `}; - - ${props.inverse && - css` - color: ${props.theme.color.lightest}; - svg path { - fill: ${props.theme.color.lightest}; - } - - &:hover { - color: ${props.theme.color.lighter}; - svg path { - fill: ${props.theme.color.lighter}; - } - } - - &:active { - color: ${props.theme.color.light}; - svg path { - fill: ${props.theme.color.light}; - } - } - `}; - - ${props.isButton && - css` - border: 0; - border-radius: 0; - background: none; - padding: 0; - font-size: inherit; - `}; -`; - export interface LinkInnerProps { withArrow?: boolean; containsIcon?: boolean; } -const LinkInner = styled.span` - ${(props: LinkInnerProps) => - props.withArrow && - css` - > svg:last-of-type { - height: 0.7em; - width: 0.7em; - margin-right: 0; - margin-left: 0.25em; - bottom: auto; - vertical-align: inherit; - } - `}; - - ${props => - props.containsIcon && - css` - svg { - height: 1em; - width: 1em; - vertical-align: middle; - position: relative; - bottom: 0; - margin-right: 0; - } - `}; -`; +const LinkInner = styled.span( + ({ withArrow }) => + withArrow + ? { + '> svg:last-of-type': { + height: '0.7em', + width: '0.7em', + marginRight: 0, + marginLeft: '0.25em', + bottom: 'auto', + verticalAlign: 'inherit', + }, + } + : {}, + ({ containsIcon }) => + containsIcon + ? { + svg: { + height: '1em', + width: '1em', + verticalAlign: 'middle', + position: 'relative', + bottom: 0, + marginRight: 0, + }, + } + : {} +); type AProps = AnchorHTMLAttributes; -const A = styled.a` - ${linkStyles}; -`; +const A = styled.a( + ({ theme }) => ({ + display: 'inline-block', + transition: 'all 150ms ease-out', + textDecoration: 'none', + + color: theme.color.secondary, + + '&:hover, &:focus': { + cursor: 'pointer', + color: darken(0.07, theme.color.secondary), + 'svg path': { + fill: darken(0.07, theme.color.secondary), + }, + }, + '&:active': { + color: darken(0.1, theme.color.secondary), + 'svg path': { + fill: darken(0.1, theme.color.secondary), + }, + }, + + svg: { + display: 'inline-block', + height: '1em', + width: '1em', + verticalAlign: 'text-top', + position: 'relative', + bottom: '-0.125em', + marginRight: '0.4em', + + '& path': { + fill: theme.color.secondary, + }, + }, + }), + ({ theme, secondary, tertiary }) => { + let color; + if (secondary) { + color = theme.color.secondary; + } + if (tertiary) { + color = theme.color.tertiary; + } + + return color + ? { + color: theme.color.mediumdark, + 'svg path': { + fill: theme.color.mediumdark, + }, + + '&:hover': { + color: theme.color.dark, + 'svg path': { + fill: theme.color.dark, + }, + }, + + '&:active': { + color: theme.color.darker, + 'svg path': { + fill: theme.color.darker, + }, + }, + } + : {}; + }, + ({ nochrome }) => + nochrome + ? { + color: 'inherit', + + '&:hover, &:active': { + color: 'inherit', + textDecoration: 'underline', + }, + } + : {}, + ({ theme, inverse }) => + inverse + ? { + color: theme.color.lightest, + 'svg path': { + fill: theme.color.lightest, + }, + + '&:hover': { + color: theme.color.lighter, + 'svg path': { + fill: theme.color.lighter, + }, + }, + + '&:active': { + color: theme.color.light, + 'svg path': { + fill: theme.color.light, + }, + }, + } + : {}, + ({ isButton }) => + isButton + ? { + border: 0, + borderRadius: 0, + background: 'none', + padding: 0, + fontSize: 'inherit', + } + : {} +); export interface LinkProps extends LinkInnerProps, LinkStylesProps { cancel?: boolean; From 03d4074313add2e61e996c9ab244b5b429e1215a Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Fri, 29 Nov 2019 02:11:46 +0100 Subject: [PATCH 004/132] CHANGE css values that are numbers to actual numbers --- addons/a11y/src/components/A11YPanel.tsx | 6 +- .../a11y/src/components/Report/Elements.tsx | 6 +- addons/a11y/src/components/Report/Info.tsx | 6 +- addons/a11y/src/components/Report/Item.tsx | 4 +- addons/a11y/src/components/Report/Rules.tsx | 20 ++-- addons/a11y/src/components/Report/Tags.tsx | 2 +- addons/a11y/src/components/Tabs.tsx | 14 +-- .../src/components/ActionLogger/style.tsx | 4 +- addons/centered/src/styles.ts | 8 +- addons/events/src/components/Panel.tsx | 2 +- addons/info/src/components/Story.js | 2 +- .../src/components/markdown/pre/copyButton.js | 4 +- addons/jest/src/components/Message.tsx | 22 ++-- addons/jest/src/components/Panel.tsx | 16 +-- addons/jest/src/components/Result.tsx | 2 +- addons/knobs/src/components/types/Number.tsx | 4 +- addons/viewport/src/Tool.tsx | 6 +- examples/mithril-kitchen-sink/src/Button.js | 6 +- examples/mithril-kitchen-sink/src/Welcome.js | 2 +- .../addon-info/story-source.stories.js | 2 +- .../stories/addon-knobs/with-knobs.stories.js | 4 +- .../MITHRIL/template-csf/stories/Button.js | 6 +- .../MITHRIL/template-csf/stories/Welcome.js | 10 +- lib/components/src/Button/Button.tsx | 77 ++++++------- lib/components/src/blocks/DocsPage.tsx | 9 +- lib/components/src/blocks/EmptyBlock.tsx | 2 +- .../src/blocks/PropsTable/PropJsDoc.tsx | 8 +- .../src/blocks/PropsTable/PropRow.tsx | 8 +- .../src/blocks/PropsTable/PropValue.tsx | 8 +- .../src/blocks/PropsTable/PropsTable.tsx | 8 +- lib/components/src/form/input/input.tsx | 2 +- lib/components/src/tooltip/ListItem.tsx | 8 +- .../src/tooltip/Tooltip.stories.tsx | 2 +- .../src/typography/DocumentFormatting.tsx | 40 +++---- .../src/typography/DocumentWrapper.tsx | 106 +++++++++--------- lib/components/src/typography/shared.tsx | 4 +- lib/core/src/client/preview/NoDocs.js | 4 +- lib/ui/src/components/layout/container.js | 2 +- lib/ui/src/components/sidebar/Sidebar.tsx | 2 +- .../src/components/sidebar/SidebarHeading.tsx | 6 +- .../src/components/sidebar/SidebarSearch.tsx | 73 ++++++------ lib/ui/src/settings/shortcuts.js | 2 +- 42 files changed, 254 insertions(+), 275 deletions(-) diff --git a/addons/a11y/src/components/A11YPanel.tsx b/addons/a11y/src/components/A11YPanel.tsx index 194acca7be6..a2d7a7fc73d 100644 --- a/addons/a11y/src/components/A11YPanel.tsx +++ b/addons/a11y/src/components/A11YPanel.tsx @@ -22,9 +22,9 @@ export enum RuleType { const Icon = styled(Icons)( { - height: '12px', - width: '12px', - marginRight: '4px', + height: 12, + width: 12, + marginRight: 4, }, ({ status, theme }: any) => status === 'running' diff --git a/addons/a11y/src/components/Report/Elements.tsx b/addons/a11y/src/components/Report/Elements.tsx index ce713ec948a..d2fc529b8d0 100644 --- a/addons/a11y/src/components/Report/Elements.tsx +++ b/addons/a11y/src/components/Report/Elements.tsx @@ -15,15 +15,15 @@ const ItemTitle = styled.span<{}>(({ theme }) => ({ borderBottom: `1px solid ${theme.appBorderColor}`, width: '100%', display: 'flex', - paddingBottom: '6px', - marginBottom: '6px', + paddingBottom: 6, + marginBottom: 6, justifyContent: 'space-between', })); const HighlightToggleElement = styled.span({ fontWeight: 'normal', alignSelf: 'center', - paddingRight: '15px', + paddingRight: 15, input: { margin: 0 }, }); diff --git a/addons/a11y/src/components/Report/Info.tsx b/addons/a11y/src/components/Report/Info.tsx index 5b1995fe414..743a617c02f 100644 --- a/addons/a11y/src/components/Report/Info.tsx +++ b/addons/a11y/src/components/Report/Info.tsx @@ -4,14 +4,14 @@ import { styled } from '@storybook/theming'; import { Result } from 'axe-core'; const Wrapper = styled.div({ - padding: '12px', - marginBottom: '10px', + padding: 12, + marginBottom: 10, }); const Help = styled.p({ margin: '0 0 12px', }); const Link = styled.a({ - marginTop: '12px', + marginTop: 12, textDecoration: 'underline', color: 'inherit', display: 'block', diff --git a/addons/a11y/src/components/Report/Item.tsx b/addons/a11y/src/components/Report/Item.tsx index 9122ff53c67..2ece16f74a1 100644 --- a/addons/a11y/src/components/Report/Item.tsx +++ b/addons/a11y/src/components/Report/Item.tsx @@ -24,7 +24,7 @@ const Icon = styled(Icons)(({ theme }) => ({ width: 10, minWidth: 10, color: theme.color.mediumdark, - marginRight: '10px', + marginRight: 10, transition: 'transform 0.1s ease-in-out', alignSelf: 'center', display: 'inline-flex', @@ -49,7 +49,7 @@ const HeaderBar = styled.div<{}>(({ theme }) => ({ const HighlightToggleElement = styled.span({ fontWeight: 'normal', float: 'right', - marginRight: '15px', + marginRight: 15, alignSelf: 'center', input: { margin: 0 }, }); diff --git a/addons/a11y/src/components/Report/Rules.tsx b/addons/a11y/src/components/Report/Rules.tsx index a7a61c3a671..48fe2dd924a 100644 --- a/addons/a11y/src/components/Report/Rules.tsx +++ b/addons/a11y/src/components/Report/Rules.tsx @@ -16,9 +16,9 @@ const impactColors = { const List = styled.div({ display: 'flex', flexDirection: 'column', - paddingBottom: '4px', - paddingRight: '4px', - paddingTop: '4px', + paddingBottom: 4, + paddingRight: 4, + paddingTop: 4, fontWeight: '400', } as any); @@ -26,23 +26,23 @@ const Item = styled.div(({ elementWidth }: { elementWidth: number }) => { const maxWidthBeforeBreak = 407; return { flexDirection: elementWidth > maxWidthBeforeBreak ? 'row' : 'inherit', - marginBottom: elementWidth > maxWidthBeforeBreak ? '6px' : '12px', + marginBottom: elementWidth > maxWidthBeforeBreak ? 6 : 12, display: elementWidth > maxWidthBeforeBreak ? 'flex' : 'block', }; }); const StyledBadge = styled(Badge)(({ status }: { status: string }) => ({ padding: '2px 8px', - marginBottom: '3px', - minWidth: '65px', + marginBottom: 3, + minWidth: 65, maxWidth: 'fit-content', width: '100%', textAlign: 'center', })); const Message = styled.div({ - paddingLeft: '6px', - paddingRight: '23px', + paddingLeft: 6, + paddingRight: 23, }); const Status = styled.div(({ passes, impact }: { passes: boolean; impact: string }) => ({ @@ -51,8 +51,8 @@ const Status = styled.div(({ passes, impact }: { passes: boolean; impact: string alignItems: 'center', color: passes ? impactColors.success : (impactColors as any)[impact], '& > svg': { - height: '16px', - width: '16px', + height: 16, + width: 16, }, })); diff --git a/addons/a11y/src/components/Report/Tags.tsx b/addons/a11y/src/components/Report/Tags.tsx index 62968af6aa3..e11245f5562 100644 --- a/addons/a11y/src/components/Report/Tags.tsx +++ b/addons/a11y/src/components/Report/Tags.tsx @@ -11,7 +11,7 @@ const Wrapper = styled.div({ const Item = styled.div<{}>(({ theme }) => ({ margin: '0 6px', - padding: '5px', + padding: 5, border: `1px solid ${theme.appBorderColor}`, borderRadius: theme.appBorderRadius, })); diff --git a/addons/a11y/src/components/Tabs.tsx b/addons/a11y/src/components/Tabs.tsx index 4ebeac7c490..26b6febaa04 100644 --- a/addons/a11y/src/components/Tabs.tsx +++ b/addons/a11y/src/components/Tabs.tsx @@ -18,8 +18,8 @@ const Container = styled.div({ const HighlightToggleLabel = styled.label<{}>(({ theme }) => ({ cursor: 'pointer', userSelect: 'none', - marginBottom: '3px', - marginRight: '3px', + marginBottom: 3, + marginRight: 3, color: theme.color.dark, })); @@ -31,7 +31,7 @@ const GlobalToggle = styled.div(({ elementWidth }: { elementWidth: number }) => padding: elementWidth > maxWidthBeforeBreak ? '12px 15px 10px 0' : '12px 0px 3px 12px', height: '40px', border: 'none', - marginTop: elementWidth > maxWidthBeforeBreak ? '-40px' : '0px', + marginTop: elementWidth > maxWidthBeforeBreak ? -40 : 0, float: elementWidth > maxWidthBeforeBreak ? 'right' : 'left', display: elementWidth > maxWidthBeforeBreak ? 'flex' : 'block', alignItems: 'center', @@ -39,10 +39,10 @@ const GlobalToggle = styled.div(({ elementWidth }: { elementWidth: number }) => borderBottom: elementWidth > maxWidthBeforeBreak ? 'none' : '1px solid rgba(0,0,0,.1)', input: { - marginLeft: '10', - marginRight: '0', - marginTop: '0', - marginBottom: '0', + marginLeft: 10, + marginRight: 0, + marginTop: 0, + marginBottom: 0, }, }; }); diff --git a/addons/actions/src/components/ActionLogger/style.tsx b/addons/actions/src/components/ActionLogger/style.tsx index 54abfbec156..450e407a697 100644 --- a/addons/actions/src/components/ActionLogger/style.tsx +++ b/addons/actions/src/components/ActionLogger/style.tsx @@ -3,7 +3,7 @@ import { opacify } from 'polished'; export const Action = styled.div({ display: 'flex', - padding: '0', + padding: 0, borderLeft: '5px solid transparent', borderBottom: '1px solid transparent', transition: 'all 0.1s', @@ -17,7 +17,7 @@ export const Counter = styled.div<{}>(({ theme }) => ({ fontWeight: theme.typography.weight.bold, lineHeight: 1, padding: '1px 5px', - borderRadius: '20px', + borderRadius: 20, margin: '2px 0px', })); diff --git a/addons/centered/src/styles.ts b/addons/centered/src/styles.ts index 9a8dcf291da..3dbda3d9319 100644 --- a/addons/centered/src/styles.ts +++ b/addons/centered/src/styles.ts @@ -1,10 +1,10 @@ const styles = { style: { position: 'fixed', - top: '0', - left: '0', - bottom: '0', - right: '0', + top: 0, + left: 0, + bottom: 0, + right: 0, display: 'flex', alignItems: 'center', overflow: 'auto', diff --git a/addons/events/src/components/Panel.tsx b/addons/events/src/components/Panel.tsx index 6c79a5ff2e5..ed1ff169fde 100644 --- a/addons/events/src/components/Panel.tsx +++ b/addons/events/src/components/Panel.tsx @@ -11,7 +11,7 @@ import { Event as EventType, OnEmitEvent } from '../index'; const Wrapper = styled.div({ width: '100%', boxSizing: 'border-box', - padding: '10px', + padding: 10, minHeight: '100%', }); diff --git a/addons/info/src/components/Story.js b/addons/info/src/components/Story.js index 051d603cae8..42f5026f080 100644 --- a/addons/info/src/components/Story.js +++ b/addons/info/src/components/Story.js @@ -18,7 +18,7 @@ const stylesheetBase = { button: { base: { fontFamily: 'sans-serif', - fontSize: '12px', + fontSize: 12, display: 'block', position: 'fixed', border: 'none', diff --git a/addons/info/src/components/markdown/pre/copyButton.js b/addons/info/src/components/markdown/pre/copyButton.js index e92c0da3166..cf44fa8c3b5 100644 --- a/addons/info/src/components/markdown/pre/copyButton.js +++ b/addons/info/src/components/markdown/pre/copyButton.js @@ -16,11 +16,11 @@ function CopyButton({ onClick, toggled }) { alignSelf: 'flex-start', flexShrink: '0', overflow: 'hidden', - borderWidth: '1px', + borderWidth: 1, borderStyle: 'solid', borderColor: 'rgb(238, 238, 238)', borderImage: 'initial', - borderRadius: '3px', + borderRadius: 3, padding: '3px 10px', }} > diff --git a/addons/jest/src/components/Message.tsx b/addons/jest/src/components/Message.tsx index 2382b4c3116..b87dccac668 100644 --- a/addons/jest/src/components/Message.tsx +++ b/addons/jest/src/components/Message.tsx @@ -22,27 +22,27 @@ class TestDetail { } const StackTrace = styled.pre<{}>(({ theme }) => ({ background: theme.color.lighter, - paddingTop: '4px', - paddingBottom: '4px', - paddingLeft: '6px', - borderRadius: '2px', + paddingTop: 4, + paddingBottom: 4, + paddingLeft: 6, + borderRadius: 2, overflow: 'auto', margin: '10px 30px 10px 30px', whiteSpace: 'pre', })); const Results = styled.div({ - paddingTop: '10px', - marginLeft: '31px', - marginRight: '30px', + paddingTop: 10, + marginLeft: 31, + marginRight: 30, }); const Description = styled.div<{}>(({ theme }) => ({ - paddingBottom: '10px', - paddingTop: '10px', + paddingBottom: 10, + paddingTop: 10, borderBottom: theme.appBorderColor, - marginLeft: '31px', - marginRight: '30px', + marginLeft: 31, + marginRight: 30, overflowWrap: 'break-word', })); diff --git a/addons/jest/src/components/Panel.tsx b/addons/jest/src/components/Panel.tsx index de8f6fe6071..e085d93d4cf 100644 --- a/addons/jest/src/components/Panel.tsx +++ b/addons/jest/src/components/Panel.tsx @@ -26,10 +26,10 @@ const Item = styled.li({ const ProgressWrapper = styled.div({ position: 'relative', - height: '10px', - width: '30px', + height: 10, + width: 30, display: 'flex', - top: '-2px', + top: -2, }); const SuiteHead = styled.div({ @@ -37,8 +37,8 @@ const SuiteHead = styled.div({ alignItems: 'baseline', position: 'absolute', zIndex: 2, - right: '20px', - marginTop: '15px', + right: 20, + marginTop: 15, }); const SuiteTotals = styled(({ result, className, width }) => ( @@ -62,7 +62,7 @@ const SuiteTotals = styled(({ result, className, width }) => ( alignItems: 'center', color: theme.color.dark, fontSize: '14px', - marginTop: '-5px', + marginTop: -5, '& > *': { marginRight: 10, }, @@ -70,8 +70,8 @@ const SuiteTotals = styled(({ result, className, width }) => ( const SuiteProgressPortion = styled.div<{ color: any; progressPercent: number }>( ({ theme, color, progressPercent }) => ({ - height: '6px', - top: '3px', + height: 6, + top: 3, width: `${progressPercent}%`, backgroundColor: color, }) diff --git a/addons/jest/src/components/Result.tsx b/addons/jest/src/components/Result.tsx index f0eb3e9e015..14cbe8d50c1 100644 --- a/addons/jest/src/components/Result.tsx +++ b/addons/jest/src/components/Result.tsx @@ -34,7 +34,7 @@ const Icon = styled(Icons)(({ theme }) => ({ width: 10, minWidth: 10, color: theme.color.mediumdark, - marginRight: '10px', + marginRight: 10, transition: 'transform 0.1s ease-in-out', alignSelf: 'center', display: 'inline-flex', diff --git a/addons/knobs/src/components/types/Number.tsx b/addons/knobs/src/components/types/Number.tsx index 949ed9a3e67..7778976f0e2 100644 --- a/addons/knobs/src/components/types/Number.tsx +++ b/addons/knobs/src/components/types/Number.tsx @@ -27,12 +27,12 @@ interface NumberTypeProps extends KnobControlProps { const RangeInput = styled.input( { boxSizing: 'border-box', - height: '25px', + height: 25, outline: 'none', border: '1px solid #f7f4f4', borderRadius: 2, fontSize: 11, - padding: '5px', + padding: 5, color: '#444', }, { diff --git a/addons/viewport/src/Tool.tsx b/addons/viewport/src/Tool.tsx index 2813d119e7b..761b95a5d22 100644 --- a/addons/viewport/src/Tool.tsx +++ b/addons/viewport/src/Tool.tsx @@ -84,10 +84,10 @@ const ActiveViewportSize = styled.div(() => ({ const ActiveViewportLabel = styled.div<{}>(({ theme }) => ({ display: 'inline-block', textDecoration: 'none', - padding: '10px', + padding: 10, fontWeight: theme.typography.weight.bold, fontSize: theme.typography.size.s2 - 1, - lineHeight: 1, + lineHeight: '1', height: 40, border: 'none', borderTop: '3px solid transparent', @@ -102,7 +102,7 @@ const IconButtonWithLabel = styled(IconButton)(() => ({ const IconButtonLabel = styled.div<{}>(({ theme }) => ({ fontSize: theme.typography.size.s2 - 1, - marginLeft: '10px', + marginLeft: 10, })); interface ViewportToolState { diff --git a/examples/mithril-kitchen-sink/src/Button.js b/examples/mithril-kitchen-sink/src/Button.js index edec915a04b..08d3f45a617 100644 --- a/examples/mithril-kitchen-sink/src/Button.js +++ b/examples/mithril-kitchen-sink/src/Button.js @@ -4,12 +4,12 @@ import m from 'mithril'; const style = { border: '1px solid #eee', - borderRadius: '3px', + borderRadius: 3, backgroundColor: '#FFFFFF', cursor: 'pointer', - fontSize: '15px', + fontSize: 15, padding: '3px 10px', - margin: '10px', + margin: 10, }; const Button = { diff --git a/examples/mithril-kitchen-sink/src/Welcome.js b/examples/mithril-kitchen-sink/src/Welcome.js index 86e83201655..3826e784d53 100644 --- a/examples/mithril-kitchen-sink/src/Welcome.js +++ b/examples/mithril-kitchen-sink/src/Welcome.js @@ -6,7 +6,7 @@ const Main = { view: vnode => (
( backgroundColor: 'powderblue', fontSize: '16px', boxShadow: '1px 1px rgba(0, 0, 0, .07)', - borderRadius: '5px', + borderRadius: 5, padding: '4px 8px', }} /> diff --git a/examples/official-storybook/stories/addon-knobs/with-knobs.stories.js b/examples/official-storybook/stories/addon-knobs/with-knobs.stories.js index 4b9109dd07b..e458969cc86 100644 --- a/examples/official-storybook/stories/addon-knobs/with-knobs.stories.js +++ b/examples/official-storybook/stories/addon-knobs/with-knobs.stories.js @@ -69,7 +69,7 @@ export const TweaksStaticValues = () => { const otherStyles = object('Styles', { border: '2px dashed silver', borderRadius: 10, - padding: '10px', + padding: 10, }); const nice = boolean('Nice', true); const images = files('Happy Picture', 'image/*', [ @@ -173,7 +173,7 @@ export const TweaksStaticValuesOrganizedInGroups = () => { { border: '2px dashed silver', borderRadius: 10, - padding: '10px', + padding: 10, }, GROUP_IDS.DISPLAY ); diff --git a/lib/cli/generators/MITHRIL/template-csf/stories/Button.js b/lib/cli/generators/MITHRIL/template-csf/stories/Button.js index edec915a04b..08d3f45a617 100644 --- a/lib/cli/generators/MITHRIL/template-csf/stories/Button.js +++ b/lib/cli/generators/MITHRIL/template-csf/stories/Button.js @@ -4,12 +4,12 @@ import m from 'mithril'; const style = { border: '1px solid #eee', - borderRadius: '3px', + borderRadius: 3, backgroundColor: '#FFFFFF', cursor: 'pointer', - fontSize: '15px', + fontSize: 15, padding: '3px 10px', - margin: '10px', + margin: 10, }; const Button = { diff --git a/lib/cli/generators/MITHRIL/template-csf/stories/Welcome.js b/lib/cli/generators/MITHRIL/template-csf/stories/Welcome.js index d7dd3eca7ff..2c0f425a5f8 100644 --- a/lib/cli/generators/MITHRIL/template-csf/stories/Welcome.js +++ b/lib/cli/generators/MITHRIL/template-csf/stories/Welcome.js @@ -7,7 +7,7 @@ const Main = { view: vnode => (
( @@ -112,7 +112,7 @@ const StoryLink = { color: '#1474f3', textDecoration: 'none', borderBottom: '1px solid #1474f3', - paddingBottom: '2px', + paddingBottom: 2, }} onClick={vnode.state.onclick} > diff --git a/lib/components/src/Button/Button.tsx b/lib/components/src/Button/Button.tsx index c338af66661..f25112013fd 100644 --- a/lib/components/src/Button/Button.tsx +++ b/lib/components/src/Button/Button.tsx @@ -23,7 +23,7 @@ const ButtonWrapper = styled.button( cursor: 'pointer', display: 'inline-block', overflow: 'hidden', - padding: small ? '10px' : '16px', + padding: small ? 10 : 16, position: 'relative', textAlign: 'center', textDecoration: 'none', @@ -78,46 +78,36 @@ const ButtonWrapper = styled.button( ...(small ? { padding: 9 } : { padding: 12 }), } : {}, - ({ theme, primary }) => - primary + ({ theme, primary, secondary }) => { + let color; + + if (primary) { + color = theme.color.primary; + } + if (secondary) { + color = theme.color.secondary; + } + + return color ? { - background: theme.color.primary, + background: color, color: theme.color.lightest, '&:hover': { - background: darken(0.05, theme.color.primary), + background: darken(0.05, color), }, '&:active': { boxShadow: 'rgba(0, 0, 0, 0.1) 0 0 0 3em inset', }, '&:focus': { - boxShadow: `${rgba(theme.color.primary, 0.4)} 0 1px 9px 2px`, + boxShadow: `${rgba(color, 0.4)} 0 1px 9px 2px`, }, '&:focus:hover': { - boxShadow: `${rgba(theme.color.primary, 0.2)} 0 8px 18px 0px`, + boxShadow: `${rgba(color, 0.2)} 0 8px 18px 0px`, }, } - : {}, - ({ theme, secondary }) => - secondary - ? { - background: theme.color.secondary, - color: theme.color.lightest, - - '&:hover': { - background: darken(0.05, theme.color.secondary), - }, - '&:active': { - boxShadow: 'rgba(0, 0, 0, 0.1) 0 0 0 3em inset', - }, - '&:focus': { - boxShadow: `${rgba(theme.color.secondary, 0.4)} 0 1px 9px 2px`, - }, - '&:focus:hover': { - boxShadow: `${rgba(theme.color.secondary, 0.2)} 0 8px 18px 0px`, - }, - } - : {}, + : {}; + }, ({ theme, tertiary, inForm }) => tertiary ? { @@ -165,40 +155,37 @@ const ButtonWrapper = styled.button( }, } : {}, - ({ theme, outline, primary }) => - outline && primary + ({ theme, outline, primary }) => { + const color = theme.color.primary; + + return outline && primary ? { - boxShadow: `${theme.color.primary} 0 0 0 1px inset`, - color: theme.color.primary, + boxShadow: `${color} 0 0 0 1px inset`, + color, 'svg path': { - fill: theme.color.primary, + fill: color, }, '&:hover': { - boxShadow: `${theme.color.primary} 0 0 0 1px inset`, + boxShadow: `${color} 0 0 0 1px inset`, background: 'transparent', }, '&:active': { - background: theme.color.primary, - boxShadow: `${theme.color.primary} 0 0 0 1px inset`, + background: color, + boxShadow: `${color} 0 0 0 1px inset`, color: theme.color.lightest, }, '&:focus': { - boxShadow: `${theme.color.primary} 0 0 0 1px inset, ${rgba( - theme.color.primary, - 0.4 - )} 0 1px 9px 2px`, + boxShadow: `${color} 0 0 0 1px inset, ${rgba(color, 0.4)} 0 1px 9px 2px`, }, '&:focus:hover': { - boxShadow: `${theme.color.primary} 0 0 0 1px inset, ${rgba( - theme.color.primary, - 0.2 - )} 0 8px 18px 0px`, + boxShadow: `${color} 0 0 0 1px inset, ${rgba(color, 0.2)} 0 8px 18px 0px`, }, } - : {}, + : {}; + }, ({ theme, outline, primary, secondary }) => { let color; if (primary) { diff --git a/lib/components/src/blocks/DocsPage.tsx b/lib/components/src/blocks/DocsPage.tsx index d2d723ec431..e6897e7d23f 100644 --- a/lib/components/src/blocks/DocsPage.tsx +++ b/lib/components/src/blocks/DocsPage.tsx @@ -29,18 +29,15 @@ export const Subtitle = styled.h2<{}>(withReset, ({ theme }: { theme: Theme }) = fontSize: theme.typography.size.s3, lineHeight: '20px', borderBottom: 'none', - marginBottom: '15px', + marginBottom: 15, [`@media (min-width: ${breakpoint}px)`]: { fontSize: theme.typography.size.m1, lineHeight: '28px', - marginBottom: '24px', + marginBottom: 24, }, - color: - theme.base === 'light' - ? transparentize(0.25, theme.color.defaultText) - : transparentize(0.25, theme.color.defaultText), + color: transparentize(0.25, theme.color.defaultText), })); export const DocsContent = styled.div({ diff --git a/lib/components/src/blocks/EmptyBlock.tsx b/lib/components/src/blocks/EmptyBlock.tsx index 39dba076bd2..39e117943ec 100644 --- a/lib/components/src/blocks/EmptyBlock.tsx +++ b/lib/components/src/blocks/EmptyBlock.tsx @@ -11,7 +11,7 @@ const Wrapper = styled.div<{}>(withReset, ({ theme }) => ({ fontSize: `${theme.typography.size.s2}px`, alignItems: 'center', justifyContent: 'center', - padding: '20px', + padding: 20, margin: '25px 0 40px', color: diff --git a/lib/components/src/blocks/PropsTable/PropJsDoc.tsx b/lib/components/src/blocks/PropsTable/PropJsDoc.tsx index 0eae9a2f434..5dbb8e98818 100644 --- a/lib/components/src/blocks/PropsTable/PropJsDoc.tsx +++ b/lib/components/src/blocks/PropsTable/PropJsDoc.tsx @@ -27,8 +27,8 @@ export const Table = styled.table(({ theme }) => ({ }, // End escape - marginTop: '0', - marginBottom: '0', + marginTop: 0, + marginBottom: 0, 'th:first-of-type, td:first-of-type': { paddingLeft: 0, @@ -39,8 +39,8 @@ export const Table = styled.table(({ theme }) => ({ }, td: { - paddingTop: '0', - paddingBottom: '4px', + paddingTop: 0, + paddingBottom: 4, '&:not(:first-of-type)': { paddingLeft: 10, diff --git a/lib/components/src/blocks/PropsTable/PropRow.tsx b/lib/components/src/blocks/PropsTable/PropRow.tsx index 425b1d46298..83d45fb841e 100644 --- a/lib/components/src/blocks/PropsTable/PropRow.tsx +++ b/lib/components/src/blocks/PropsTable/PropRow.tsx @@ -23,7 +23,7 @@ const Required = styled.span(({ theme }) => ({ const Description = styled.div(({ theme }) => ({ '&&': { p: { - margin: '0', + margin: 0, }, }, @@ -40,7 +40,7 @@ const Type = styled.div<{ hasDescription: boolean }>(({ theme, hasDescription }) theme.base === 'light' ? transparentize(0.1, theme.color.defaultText) : transparentize(0.2, theme.color.defaultText), - marginTop: hasDescription ? '4px' : '0', + marginTop: hasDescription ? 4 : 0, })); const TypeWithJsDoc = styled.div<{ hasDescription: boolean }>(({ theme, hasDescription }) => ({ @@ -48,8 +48,8 @@ const TypeWithJsDoc = styled.div<{ hasDescription: boolean }>(({ theme, hasDescr theme.base === 'light' ? transparentize(0.1, theme.color.defaultText) : transparentize(0.2, theme.color.defaultText), - marginTop: hasDescription ? '12px' : '0', - marginBottom: '12px', + marginTop: hasDescription ? 12 : 0, + marginBottom: 12, })); export const PropRow: FC = ({ diff --git a/lib/components/src/blocks/PropsTable/PropValue.tsx b/lib/components/src/blocks/PropsTable/PropValue.tsx index 7c1c5705624..f86e8dec98b 100644 --- a/lib/components/src/blocks/PropsTable/PropValue.tsx +++ b/lib/components/src/blocks/PropsTable/PropValue.tsx @@ -36,9 +36,9 @@ const Expandable = styled.div<{}>(codeCommon, ({ theme }) => ({ const Detail = styled.div<{ width: string }>(({ theme, width }) => ({ width, - minWidth: '200px', - maxWidth: '800px', - padding: '15px', + minWidth: 200, + maxWidth: 800, + padding: 15, // Dont remove the mono fontFamily here even if it seem useless, this is used by the browser to calculate the length of a "ch" unit. fontFamily: theme.typography.fonts.mono, fontSize: theme.typography.size.s2 - 1, @@ -54,7 +54,7 @@ const ArrowIcon = styled(Icons)({ height: 10, width: 10, minWidth: 10, - marginLeft: '4px', + marginLeft: 4, }); const EmptyProp = () => { diff --git a/lib/components/src/blocks/PropsTable/PropsTable.tsx b/lib/components/src/blocks/PropsTable/PropsTable.tsx index ca2ac324635..d2914eb3561 100644 --- a/lib/components/src/blocks/PropsTable/PropsTable.tsx +++ b/lib/components/src/blocks/PropsTable/PropsTable.tsx @@ -31,15 +31,15 @@ export const Table = styled.table<{}>(({ theme }) => ({ width: '100%', // Margin collapse - marginTop: '25px', - marginBottom: '40px', + marginTop: 25, + marginBottom: 40, 'th:first-of-type, td:first-of-type': { paddingLeft: 20, }, 'th:last-of-type, td:last-of-type': { - paddingRight: '20px', + paddingRight: 20, width: '20%', }, @@ -67,7 +67,7 @@ export const Table = styled.table<{}>(({ theme }) => ({ }, '&:last-of-type': { - paddingRight: '20px', + paddingRight: 20, }, }, diff --git a/lib/components/src/form/input/input.tsx b/lib/components/src/form/input/input.tsx index 56727cdad7e..6badf1b9b76 100644 --- a/lib/components/src/form/input/input.tsx +++ b/lib/components/src/form/input/input.tsx @@ -8,7 +8,7 @@ import { Button as StyledButton } from '../../Button/Button'; const styleResets: CSSObject = { // resets appearance: 'none', - border: '0', + border: '0 none', boxSizing: 'inherit', display: ' block', margin: ' 0', diff --git a/lib/components/src/tooltip/ListItem.tsx b/lib/components/src/tooltip/ListItem.tsx index 8aad87be8a1..7505e37280f 100644 --- a/lib/components/src/tooltip/ListItem.tsx +++ b/lib/components/src/tooltip/ListItem.tsx @@ -49,12 +49,12 @@ const Right = styled.span( { '& svg': { transition: 'all 200ms ease-out', - opacity: '0', - height: '12px', - width: '12px', + opacity: 0, + height: 12, + width: 12, margin: '3px 0', verticalAlign: 'top', - } as any, + }, '& path': { fill: 'inherit', }, diff --git a/lib/components/src/tooltip/Tooltip.stories.tsx b/lib/components/src/tooltip/Tooltip.stories.tsx index 99cec614ec6..925cd6e5301 100644 --- a/lib/components/src/tooltip/Tooltip.stories.tsx +++ b/lib/components/src/tooltip/Tooltip.stories.tsx @@ -4,7 +4,7 @@ import { styled } from '@storybook/theming'; import { Tooltip } from './Tooltip'; // Popper would position the tooltip absolutely. We just need to make sure we are pos:rel -const mockPopperProps = { style: { position: 'relative', top: '20px', left: '20px' } }; +const mockPopperProps = { style: { position: 'relative', top: 20, left: 20 } }; const Content = styled.div({ width: '100px', diff --git a/lib/components/src/typography/DocumentFormatting.tsx b/lib/components/src/typography/DocumentFormatting.tsx index 778bb9e4056..ebd9b26c824 100644 --- a/lib/components/src/typography/DocumentFormatting.tsx +++ b/lib/components/src/typography/DocumentFormatting.tsx @@ -9,7 +9,7 @@ export const H1 = styled.h1<{}>(withReset, headerCommon, ({ theme }) => ({ export const H2 = styled.h2<{}>(withReset, headerCommon, ({ theme }) => ({ fontSize: `${theme.typography.size.m2}px`, - paddingBottom: '4px', + paddingBottom: 4, borderBottom: `1px solid ${theme.appBorderColor}`, })); @@ -94,21 +94,21 @@ export const A = styled(Link)<{}>(withReset, ({ theme }) => ({ }, '&.anchor': { display: 'block', - paddingLeft: '30px', - marginLeft: '-30px', + paddingLeft: 30, + marginLeft: -30, cursor: 'pointer', position: 'absolute', - top: '0', - left: '0', - bottom: '0', + top: 0, + left: 0, + bottom: 0, }, })); export const HR = styled.hr<{}>(({ theme }) => ({ border: '0 none', borderTop: `1px solid ${theme.appBorderColor}`, - height: '4px', - padding: '0', + height: 4, + padding: 0, })); export const DL = styled.dl<{}>(withReset, { @@ -151,7 +151,7 @@ export const Blockquote = styled.blockquote<{}>(withReset, withMargin, ({ theme padding: '0 15px', color: theme.color.dark, '& > :first-of-type': { - marginTop: '0', + marginTop: 0, }, '& > :last-child': { marginBottom: 0, @@ -166,8 +166,8 @@ export const Table = styled.table<{}>(withReset, withMargin, ({ theme }) => ({ '& tr': { borderTop: `1px solid ${theme.appBorderColor}`, backgroundColor: 'white', - margin: '0', - padding: '0', + margin: 0, + padding: 0, }, '& tr:nth-of-type(2n)': { backgroundColor: `${theme.color.lighter}`, @@ -176,20 +176,20 @@ export const Table = styled.table<{}>(withReset, withMargin, ({ theme }) => ({ fontWeight: 'bold', border: `1px solid ${theme.appBorderColor}`, textAlign: 'left', - margin: '0', + margin: 0, padding: '6px 13px', }, '& tr td': { border: `1px solid ${theme.appBorderColor}`, textAlign: 'left', - margin: '0', + margin: 0, padding: '6px 13px', }, '& tr th :first-of-type, & tr td :first-of-type': { - marginTop: '0', + marginTop: 0, }, '& tr th :last-child, & tr td :last-child': { - marginBottom: '0', + marginBottom: 0, }, })); @@ -210,7 +210,7 @@ export const Span = styled.span<{}>(withReset, ({ theme }) => ({ float: 'left', overflow: 'hidden', margin: '13px 0 0', - padding: '7px', + padding: 7, width: 'auto', }, '&.frame span img': { @@ -250,12 +250,12 @@ export const Span = styled.span<{}>(withReset, ({ theme }) => ({ textAlign: 'right', }, '&.align-right span img': { - margin: '0', + margin: 0, textAlign: 'right', }, '&.float-left': { display: 'block', - marginRight: '13px', + marginRight: 13, overflow: 'hidden', float: 'left', }, @@ -264,7 +264,7 @@ export const Span = styled.span<{}>(withReset, ({ theme }) => ({ }, '&.float-right': { display: 'block', - marginLeft: '13px', + marginLeft: 13, overflow: 'hidden', float: 'right', }, @@ -277,7 +277,7 @@ export const Span = styled.span<{}>(withReset, ({ theme }) => ({ })); const listCommon: CSSObject = { - paddingLeft: '30px', + paddingLeft: 30, '& :first-of-type': { marginTop: 0, }, diff --git a/lib/components/src/typography/DocumentWrapper.tsx b/lib/components/src/typography/DocumentWrapper.tsx index 54511c2e97e..e035b2699f7 100644 --- a/lib/components/src/typography/DocumentWrapper.tsx +++ b/lib/components/src/typography/DocumentWrapper.tsx @@ -23,18 +23,18 @@ export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ }, h6: { fontSize: `${theme.typography.size.s2}px`, - color: `${theme.color.dark}`, + color: theme.color.dark, }, 'pre:not(.hljs)': { background: 'transparent', border: 'none', - borderRadius: '0', - padding: '0', - margin: '0', + borderRadius: 0, + padding: 0, + margin: 0, }, 'pre pre, pre.hljs': { - padding: '15px', - margin: '0', + padding: 15, + margin: 0, whiteSpace: 'pre-wrap', color: 'inherit', fontSize: '13px', @@ -45,8 +45,8 @@ export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ fontSize: 'inherit', }, 'pre code': { - margin: '0', - padding: '0', + margin: 0, + padding: 0, whiteSpace: 'pre', border: 'none', background: 'transparent', @@ -71,23 +71,23 @@ export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ }, 'a.anchor': { display: 'block', - paddingLeft: '30px', - marginLeft: '-30px', + paddingLeft: 30, + marginLeft: -30, cursor: 'pointer', position: 'absolute', - top: '0', - left: '0', - bottom: '0', + top: 0, + left: 0, + bottom: 0, }, 'h1, h2, h3, h4, h5, h6': { margin: '20px 0 10px', - padding: '0', + padding: 0, cursor: 'text', position: 'relative', '&:first-of-type': { - marginTop: '0', - paddingTop: '0', + marginTop: 0, + paddingTop: 0, }, '&:hover a.anchor': { textDecoration: 'none', @@ -97,8 +97,8 @@ export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ }, }, 'h1:first-of-type + h2': { - marginTop: '0', - paddingTop: '0', + marginTop: 0, + paddingTop: 0, }, 'p, blockquote, ul, ol, dl, li, table, pre': { margin: '15px 0', @@ -106,39 +106,39 @@ export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ hr: { border: '0 none', borderTop: `1px solid ${theme.appBorderColor}`, - height: '4px', - padding: '0', + height: 4, + padding: 0, }, 'body > h1:first-of-type, body > h2:first-of-type, body > h3:first-of-type, body > h4:first-of-type, body > h5:first-of-type, body > h6:first-of-type': { - marginTop: '0', - paddingTop: '0', + marginTop: 0, + paddingTop: 0, }, 'body > h1:first-of-type + h2': { - marginTop: '0', - paddingTop: '0', + marginTop: 0, + paddingTop: 0, }, 'a:first-of-type h1, a:first-of-type h2, a:first-of-type h3, a:first-of-type h4, a:first-of-type h5, a:first-of-type h6': { - marginTop: '0', - paddingTop: '0', + marginTop: 0, + paddingTop: 0, }, 'h1 p, h2 p, h3 p, h4 p, h5 p, h6 p': { - marginTop: '0', + marginTop: 0, }, 'li p.first': { display: 'inline-block', }, 'ul, ol': { - paddingLeft: '30px', + paddingLeft: 30, '& :first-of-type': { - marginTop: '0', + marginTop: 0, }, '& :last-child': { - marginBottom: '0', + marginBottom: 0, }, }, dl: { - padding: '0', + padding: 0, }, 'dl dt': { @@ -149,63 +149,63 @@ export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ padding: '0 15px', '&:first-of-type': { - padding: '0', + padding: 0, }, '& > :first-of-type': { - marginTop: '0', + marginTop: 0, }, '& > :last-child': { - marginBottom: '0', + marginBottom: 0, }, }, blockquote: { borderLeft: `4px solid ${theme.color.medium}`, padding: '0 15px', - color: `${theme.color.dark}`, + color: theme.color.dark, '& > :first-of-type': { - marginTop: '0', + marginTop: 0, }, '& > :last-child': { - marginBottom: '0', + marginBottom: 0, }, }, table: { - padding: '0', + padding: 0, borderCollapse: 'collapse', '& tr': { borderTop: `1px solid ${theme.appBorderColor}`, backgroundColor: 'white', - margin: '0', - padding: '0', + margin: 0, + padding: 0, '& th': { fontWeight: 'bold', border: `1px solid ${theme.appBorderColor}`, textAlign: 'left', - margin: '0', + margin: 0, padding: '6px 13px', }, '& td': { border: `1px solid ${theme.appBorderColor}`, textAlign: 'left', - margin: '0', + margin: 0, padding: '6px 13px', }, '&:nth-of-type(2n)': { - backgroundColor: `${theme.color.lighter}`, + backgroundColor: theme.color.lighter, }, '& th :first-of-type, & td :first-of-type': { - marginTop: '0', + marginTop: 0, }, '& th :last-child, & td :last-child': { - marginBottom: '0', + marginBottom: 0, }, }, }, @@ -222,7 +222,7 @@ export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ float: 'left', overflow: 'hidden', margin: '13px 0 0', - padding: '7px', + padding: 7, width: 'auto', }, @@ -233,7 +233,7 @@ export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ '& span span': { clear: 'both', - color: `${theme.color.darkest}`, + color: theme.color.darkest, display: 'block', padding: '5px 0 0', }, @@ -267,14 +267,14 @@ export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ }, '& span img': { - margin: '0', + margin: 0, textAlign: 'right', }, }, 'span.float-left': { display: 'block', - marginRight: '13px', + marginRight: 13, overflow: 'hidden', float: 'left', @@ -285,7 +285,7 @@ export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ 'span.float-right': { display: 'block', - marginLeft: '13px', + marginLeft: 13, overflow: 'hidden', float: 'right', @@ -301,8 +301,8 @@ export const DocumentWrapper = styled.div<{}>(({ theme }) => ({ padding: '0 5px', whiteSpace: 'nowrap', border: `1px solid ${theme.color.mediumlight}`, - backgroundColor: `${theme.color.lighter}`, - borderRadius: '3px', - color: `${theme.base === 'dark' && theme.color.darkest}`, + backgroundColor: theme.color.lighter, + borderRadius: 3, + color: theme.base === 'dark' && theme.color.darkest, }, })); diff --git a/lib/components/src/typography/shared.tsx b/lib/components/src/typography/shared.tsx index 0ec259df0a5..4ff39c0bf94 100644 --- a/lib/components/src/typography/shared.tsx +++ b/lib/components/src/typography/shared.tsx @@ -25,11 +25,9 @@ export const codeCommon = ({ theme }: { theme: Theme }): CSSObject => ({ padding: '3px 5px', whiteSpace: 'nowrap', - borderRadius: '3px', + borderRadius: 3, fontSize: theme.typography.size.s2 - 1, - // color: theme.base === 'dark' && theme.color.darkest, - border: theme.base === 'light' ? `1px solid ${theme.color.mediumlight}` diff --git a/lib/core/src/client/preview/NoDocs.js b/lib/core/src/client/preview/NoDocs.js index 9394b8b4e4d..b9a57da4fc8 100644 --- a/lib/core/src/client/preview/NoDocs.js +++ b/lib/core/src/client/preview/NoDocs.js @@ -8,8 +8,8 @@ const wrapper = { const main = { margin: 'auto', - padding: '30px', - borderRadius: '10px', + padding: 30, + borderRadius: 10, background: 'rgba(0,0,0,0.03)', }; diff --git a/lib/ui/src/components/layout/container.js b/lib/ui/src/components/layout/container.js index 8bd3d5b4a11..e432a4fb1a8 100644 --- a/lib/ui/src/components/layout/container.js +++ b/lib/ui/src/components/layout/container.js @@ -88,7 +88,7 @@ const Paper = styled.div( isFullscreen ? { boxShadow: 'none', - borderRadius: '0', + borderRadius: 0, } : { background: theme.background.content, diff --git a/lib/ui/src/components/sidebar/Sidebar.tsx b/lib/ui/src/components/sidebar/Sidebar.tsx index 071cf207f01..ac3310a8587 100644 --- a/lib/ui/src/components/sidebar/Sidebar.tsx +++ b/lib/ui/src/components/sidebar/Sidebar.tsx @@ -28,7 +28,7 @@ const Container = styled.nav({ const CustomScrollArea = styled(ScrollArea)({ '.simplebar-track.simplebar-vertical': { - right: '4px', + right: 4, }, }); diff --git a/lib/ui/src/components/sidebar/SidebarHeading.tsx b/lib/ui/src/components/sidebar/SidebarHeading.tsx index 8990ed97251..5ae09b6c0ac 100644 --- a/lib/ui/src/components/sidebar/SidebarHeading.tsx +++ b/lib/ui/src/components/sidebar/SidebarHeading.tsx @@ -49,12 +49,12 @@ export type MenuButtonProps = ComponentProps & highlighted: boolean; }; -const MenuButton = styled(Button)(props => ({ +const MenuButton = styled(Button)(({ highlighted, theme }) => ({ position: 'relative', overflow: 'visible', padding: 7, - ...(props.highlighted && { + ...(highlighted && { '&:after': { content: '""', position: 'absolute', @@ -63,7 +63,7 @@ const MenuButton = styled(Button)(props => ({ width: 8, height: 8, borderRadius: 8, - background: `${props.theme.color.positive}`, + background: theme.color.positive, }, }), })); diff --git a/lib/ui/src/components/sidebar/SidebarSearch.tsx b/lib/ui/src/components/sidebar/SidebarSearch.tsx index ace8f79c689..ee83b3b2805 100644 --- a/lib/ui/src/components/sidebar/SidebarSearch.tsx +++ b/lib/ui/src/components/sidebar/SidebarSearch.tsx @@ -66,45 +66,42 @@ export type FilterFormProps = ComponentProps<'form'> & { focussed: boolean; }; -const FilterForm = styled.form( - ({ theme, focussed }) => - ({ +const FilterForm = styled.form(({ theme, focussed }) => ({ + transition: 'all 150ms ease-out', + borderBottom: '1px solid transparent', + borderBottomColor: focussed + ? opacify(0.3, theme.appBorderColor) + : opacify(0.1, theme.appBorderColor), + outline: 0, + position: 'relative', + + input: { + color: theme.input.color, + fontSize: theme.typography.size.s2 - 1, + lineHeight: '20px', + paddingTop: 2, + paddingBottom: 2, + paddingLeft: 20, + }, + + '> svg': { + transition: 'all 150ms ease-out', + position: 'absolute', + top: '50%', + height: 12, + width: 12, + transform: 'translateY(-50%)', + zIndex: 1, + + background: 'transparent', + + path: { transition: 'all 150ms ease-out', - borderBottom: '1px solid transparent', - borderBottomColor: focussed - ? opacify(0.3, theme.appBorderColor) - : opacify(0.1, theme.appBorderColor), - outline: 0, - position: 'relative', - - input: { - color: theme.input.color, - fontSize: theme.typography.size.s2 - 1, - lineHeight: '20px', - paddingTop: '2px', - paddingBottom: '2px', - paddingLeft: '20px', - }, - - '> svg': { - transition: 'all 150ms ease-out', - position: 'absolute', - top: '50%', - height: '12px', - width: '12px', - transform: 'translateY(-50%)', - zIndex: '1', - - background: 'transparent', - - path: { - transition: 'all 150ms ease-out', - fill: 'currentColor', - opacity: focussed ? 1 : 0.3, - }, - }, - } as any) // FIXME: emotion have hard time to provide '> svg' typing -); + fill: 'currentColor', + opacity: focussed ? 1 : 0.3, + }, + }, +})); export type PureSidebarSearchProps = FilterFieldProps & { onChange: (arg: string) => void; diff --git a/lib/ui/src/settings/shortcuts.js b/lib/ui/src/settings/shortcuts.js index 7a940e77649..7abf235f0b8 100644 --- a/lib/ui/src/settings/shortcuts.js +++ b/lib/ui/src/settings/shortcuts.js @@ -46,7 +46,7 @@ export const GridWrapper = styled.div({ display: 'grid', gridTemplateColumns: '1fr', gridAutoRows: 'minmax(auto, auto)', - marginBottom: '20px', + marginBottom: 20, }); // Form From 7c402220e12ca1997d91dd6a1bc604543b721ff2 Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Fri, 29 Nov 2019 02:15:11 +0100 Subject: [PATCH 005/132] FIX incorrect padding on button --- lib/components/src/Button/Button.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/components/src/Button/Button.tsx b/lib/components/src/Button/Button.tsx index f25112013fd..e5ca2f38533 100644 --- a/lib/components/src/Button/Button.tsx +++ b/lib/components/src/Button/Button.tsx @@ -23,7 +23,7 @@ const ButtonWrapper = styled.button( cursor: 'pointer', display: 'inline-block', overflow: 'hidden', - padding: small ? 10 : 16, + padding: small ? '10px 16px' : '13px 20px', position: 'relative', textAlign: 'center', textDecoration: 'none', From afc8eb95394987927a2191cc0fd701af561070df Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Fri, 29 Nov 2019 02:24:33 +0100 Subject: [PATCH 006/132] FIX snapshots --- .../components/__snapshots__/A11YPanel.test.js.snap | 10 +++++----- addons/info/src/__snapshots__/index.test.js.snap | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/addons/a11y/src/components/__snapshots__/A11YPanel.test.js.snap b/addons/a11y/src/components/__snapshots__/A11YPanel.test.js.snap index 2ac873d4753..52d8e6a9e67 100644 --- a/addons/a11y/src/components/__snapshots__/A11YPanel.test.js.snap +++ b/addons/a11y/src/components/__snapshots__/A11YPanel.test.js.snap @@ -229,7 +229,6 @@ exports[`A11YPanel should render report 1`] = ` "15paq49": true, "1977chw": true, "19mcg9j": true, - "1ez3l8h": true, "1imo1gr": true, "1kbt4a0": true, "1l7fvsg": true, @@ -239,6 +238,7 @@ exports[`A11YPanel should render report 1`] = ` "6z0ulf": true, "animation-u07e3c": true, "aq4p19": true, + "f68qle": true, "fg630j": true, "iau1th": true, "jb2puo": true, @@ -620,13 +620,13 @@ exports[`A11YPanel should render report 1`] = ` data-emotion="css" > - .css-1ez3l8h{cursor:pointer;font-size:14px;padding:12px 0px 3px 12px;height:40px;border:none;margin-top:0px;float:left;display:block;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;width:100%;border-bottom:1px solid rgba(0,0,0,.1);} + .css-f68qle{cursor:pointer;font-size:14px;padding:12px 0px 3px 12px;height:40px;border:none;margin-top:0;float:left;display:block;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;width:100%;border-bottom:1px solid rgba(0,0,0,.1);} , , \ No newline at end of file + \ No newline at end of file From ebdc5af3be4d18f5d79be41b758281a869d9641a Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Sat, 7 Dec 2019 16:41:45 +0800 Subject: [PATCH 066/132] 5.3.0-beta.19 changelog --- CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index b91f70870b6..9a7a17869a3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,13 @@ +## 5.3.0-beta.19 (December 7, 2019) + +### Features + +* Addon-essentials ([#9019](https://github.com/storybookjs/storybook/pull/9019)) + +### Bug Fixes + +* Addon-docs: Fix prop table default value for web-components ([#9086](https://github.com/storybookjs/storybook/pull/9086)) + ## 5.3.0-beta.18 (December 6, 2019) ### Features From 2a383b483f2a8a69ef7f7e77e5f850048f9cde47 Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Sat, 7 Dec 2019 16:43:06 +0800 Subject: [PATCH 067/132] Update peer dependencies to 5.3.0-beta.19 --- addons/ondevice-knobs/package.json | 4 ++-- addons/storyshots/storyshots-puppeteer/package.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/ondevice-knobs/package.json b/addons/ondevice-knobs/package.json index 0b2a06555f0..e1031ff468f 100644 --- a/addons/ondevice-knobs/package.json +++ b/addons/ondevice-knobs/package.json @@ -39,11 +39,11 @@ "react-native-switch": "^1.5.0" }, "peerDependencies": { - "@storybook/addon-knobs": "5.3.0-beta.18", + "@storybook/addon-knobs": "5.3.0-beta.19", "react": "*", "react-native": "*" }, "publishConfig": { "access": "public" } -} +} \ No newline at end of file diff --git a/addons/storyshots/storyshots-puppeteer/package.json b/addons/storyshots/storyshots-puppeteer/package.json index 0b5e20906c3..54ff6995c5c 100644 --- a/addons/storyshots/storyshots-puppeteer/package.json +++ b/addons/storyshots/storyshots-puppeteer/package.json @@ -41,7 +41,7 @@ "@types/puppeteer": "^2.0.0" }, "peerDependencies": { - "@storybook/addon-storyshots": "5.3.0-beta.18", + "@storybook/addon-storyshots": "5.3.0-beta.19", "puppeteer": "^1.12.2 || ^2.0.0" }, "publishConfig": { @@ -52,4 +52,4 @@ "optional": true } } -} +} \ No newline at end of file From 9843746f3a0a831a2d9c234f21754f30ae403965 Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Sat, 7 Dec 2019 16:47:47 +0800 Subject: [PATCH 068/132] v5.3.0-beta.19 --- addons/a11y/package.json | 14 ++--- addons/actions/package.json | 14 ++--- addons/backgrounds/package.json | 14 ++--- addons/centered/package.json | 4 +- addons/contexts/package.json | 10 ++-- addons/cssresources/package.json | 10 ++-- addons/design-assets/package.json | 14 ++--- addons/docs/package.json | 16 ++--- addons/essentials/package.json | 20 +++---- addons/events/package.json | 12 ++-- addons/google-analytics/package.json | 6 +- addons/graphql/package.json | 6 +- addons/info/package.json | 10 ++-- addons/jest/package.json | 12 ++-- addons/knobs/package.json | 14 ++--- addons/links/package.json | 10 ++-- addons/notes/package.json | 16 ++--- addons/ondevice-actions/package.json | 8 +-- addons/ondevice-backgrounds/package.json | 8 +-- addons/ondevice-knobs/package.json | 8 +-- addons/ondevice-notes/package.json | 12 ++-- addons/options/package.json | 4 +- addons/queryparams/package.json | 14 ++--- .../storyshots/storyshots-core/package.json | 12 ++-- .../storyshots-puppeteer/package.json | 8 +-- addons/storysource/package.json | 12 ++-- addons/viewport/package.json | 14 ++--- app/angular/package.json | 8 +-- app/ember/package.json | 4 +- app/html/package.json | 6 +- app/marko/package.json | 6 +- app/mithril/package.json | 6 +- app/polymer/package.json | 4 +- app/preact/package.json | 6 +- app/rax/package.json | 4 +- app/react-native-server/package.json | 14 ++--- app/react-native/package.json | 12 ++-- app/react/package.json | 8 +-- app/riot/package.json | 4 +- app/svelte/package.json | 6 +- app/vue/package.json | 6 +- app/web-components/package.json | 6 +- dev-kits/addon-decorator/package.json | 6 +- dev-kits/addon-parameter/package.json | 14 ++--- dev-kits/addon-preview-wrapper/package.json | 4 +- dev-kits/addon-roundtrip/package.json | 16 ++--- .../crna-kitchen-sink/package.json | 20 +++---- examples/angular-cli/package.json | 32 +++++----- examples/cra-kitchen-sink/package.json | 36 ++++++------ examples/cra-react15/package.json | 12 ++-- examples/cra-ts-essentials/package.json | 8 +-- examples/cra-ts-kitchen-sink/package.json | 18 +++--- examples/dev-kits/package.json | 22 +++---- examples/ember-cli/package.json | 30 +++++----- examples/html-kitchen-sink/package.json | 42 +++++++------- examples/marko-cli/package.json | 18 +++--- examples/mithril-kitchen-sink/package.json | 30 +++++----- examples/official-storybook/package.json | 58 +++++++++---------- examples/polymer-cli/package.json | 26 ++++----- examples/preact-kitchen-sink/package.json | 32 +++++----- examples/rax-kitchen-sink/package.json | 38 ++++++------ examples/riot-kitchen-sink/package.json | 30 +++++----- examples/standalone-preview/package.json | 4 +- examples/svelte-kitchen-sink/package.json | 30 +++++----- examples/vue-kitchen-sink/package.json | 34 +++++------ .../web-components-kitchen-sink/package.json | 42 +++++++------- lerna.json | 2 +- lib/addons/package.json | 10 ++-- lib/api/package.json | 12 ++-- lib/channel-postmessage/package.json | 6 +- lib/channel-websocket/package.json | 4 +- lib/channels/package.json | 2 +- lib/cli-sb/package.json | 4 +- lib/cli-storybook/package.json | 4 +- lib/cli/package.json | 58 +++++++++---------- lib/client-api/package.json | 14 ++--- lib/client-logger/package.json | 2 +- lib/codemod/package.json | 6 +- lib/components/package.json | 6 +- lib/core-events/package.json | 2 +- lib/core/package.json | 20 +++---- lib/node-logger/package.json | 2 +- lib/postinstall/package.json | 2 +- lib/router/package.json | 2 +- lib/source-loader/package.json | 8 +-- lib/theming/package.json | 4 +- lib/ui/package.json | 22 +++---- 87 files changed, 598 insertions(+), 598 deletions(-) diff --git a/addons/a11y/package.json b/addons/a11y/package.json index b490a151239..45c477757b0 100644 --- a/addons/a11y/package.json +++ b/addons/a11y/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-a11y", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "a11y addon for storybook", "keywords": [ "a11y", @@ -33,12 +33,12 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "axe-core": "^3.3.2", "core-js": "^3.0.1", "global": "^4.3.2", diff --git a/addons/actions/package.json b/addons/actions/package.json index 0d292d2f7ee..dd4dc98d9cc 100644 --- a/addons/actions/package.json +++ b/addons/actions/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-actions", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Action Logger addon for storybook", "keywords": [ "storybook" @@ -28,12 +28,12 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "fast-deep-equal": "^2.0.1", "global": "^4.3.2", diff --git a/addons/backgrounds/package.json b/addons/backgrounds/package.json index 408a0e43f4e..db2c1216ee2 100644 --- a/addons/backgrounds/package.json +++ b/addons/backgrounds/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-backgrounds", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "A storybook addon to show different backgrounds for your preview", "keywords": [ "addon", @@ -32,12 +32,12 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "memoizerific": "^1.11.3", "react": "^16.8.3", diff --git a/addons/centered/package.json b/addons/centered/package.json index d4d95df8471..32b5a9c970b 100644 --- a/addons/centered/package.json +++ b/addons/centered/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-centered", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook decorator to center components", "keywords": [ "addon", @@ -29,7 +29,7 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "util-deprecate": "^1.0.2" diff --git a/addons/contexts/package.json b/addons/contexts/package.json index b452c75ebf4..c5cdb5425a0 100644 --- a/addons/contexts/package.json +++ b/addons/contexts/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-contexts", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook Addon Contexts", "keywords": [ "preact", @@ -27,10 +27,10 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "qs": "^6.6.0" diff --git a/addons/cssresources/package.json b/addons/cssresources/package.json index 272751e8f5f..e1617bdf2a3 100644 --- a/addons/cssresources/package.json +++ b/addons/cssresources/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-cssresources", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "A storybook addon to switch between css resources at runtime for your story", "keywords": [ "addon", @@ -32,10 +32,10 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "react": "^16.8.3" diff --git a/addons/design-assets/package.json b/addons/design-assets/package.json index f685de55c87..32ce868aaf1 100644 --- a/addons/design-assets/package.json +++ b/addons/design-assets/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-design-assets", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Design asset preview for storybook", "keywords": [ "addon", @@ -34,12 +34,12 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "react": "^16.8.3", diff --git a/addons/docs/package.json b/addons/docs/package.json index b203f519d4b..c0983b6c103 100644 --- a/addons/docs/package.json +++ b/addons/docs/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-docs", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Superior documentation for your components", "keywords": [ "addon", @@ -45,13 +45,13 @@ "@mdx-js/loader": "^1.5.1", "@mdx-js/mdx": "^1.5.1", "@mdx-js/react": "^1.5.1", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/postinstall": "5.3.0-beta.18", - "@storybook/router": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/postinstall": "5.3.0-beta.19", + "@storybook/router": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "acorn": "^7.1.0", "acorn-jsx": "^5.1.0", "acorn-walk": "^7.0.0", diff --git a/addons/essentials/package.json b/addons/essentials/package.json index cb5ac9480ce..c11a6f0bec4 100644 --- a/addons/essentials/package.json +++ b/addons/essentials/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-essentials", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Curated addons to bring out the best of Storybook", "keywords": [ "addon", @@ -27,15 +27,15 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-docs": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/node-logger": "5.3.0-beta.18", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-docs": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/node-logger": "5.3.0-beta.19", "ts-dedent": "^1.1.0" }, "devDependencies": { diff --git a/addons/events/package.json b/addons/events/package.json index b6ffa43d518..4b5c66c474d 100644 --- a/addons/events/package.json +++ b/addons/events/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-events", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Add events to your Storybook stories.", "keywords": [ "addon", @@ -31,11 +31,11 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "format-json": "^1.0.3", "lodash": "^4.17.15", diff --git a/addons/google-analytics/package.json b/addons/google-analytics/package.json index 80eec2d908a..018b4073171 100644 --- a/addons/google-analytics/package.json +++ b/addons/google-analytics/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-google-analytics", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook addon for google analytics", "keywords": [ "addon", @@ -20,8 +20,8 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "react-ga": "^2.5.7" diff --git a/addons/graphql/package.json b/addons/graphql/package.json index 7dc146ee45a..23905666972 100644 --- a/addons/graphql/package.json +++ b/addons/graphql/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-graphql", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook addon to display the GraphiQL IDE", "keywords": [ "addon", @@ -29,8 +29,8 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "graphiql": "^0.16.0", diff --git a/addons/info/package.json b/addons/info/package.json index f95d58792c5..b1279f31b5a 100644 --- a/addons/info/package.json +++ b/addons/info/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-info", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "A Storybook addon to show additional information for your stories.", "keywords": [ "addon", @@ -28,10 +28,10 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "marksy": "^7.0.0", diff --git a/addons/jest/package.json b/addons/jest/package.json index 13ee049233f..162ac93afce 100644 --- a/addons/jest/package.json +++ b/addons/jest/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-jest", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "React storybook addon that show component jest report", "keywords": [ "addon", @@ -35,11 +35,11 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "react": "^16.8.3", diff --git a/addons/knobs/package.json b/addons/knobs/package.json index f8dbb402249..c0a7badd8e1 100644 --- a/addons/knobs/package.json +++ b/addons/knobs/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-knobs", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook Addon Prop Editor Component", "keywords": [ "addon", @@ -29,12 +29,12 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "@types/react-color": "^3.0.1", "copy-to-clipboard": "^3.0.8", "core-js": "^3.0.1", diff --git a/addons/links/package.json b/addons/links/package.json index 9f0560d29d2..60505872543 100644 --- a/addons/links/package.json +++ b/addons/links/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-links", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Story Links addon for storybook", "keywords": [ "addon", @@ -29,10 +29,10 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/router": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/router": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "prop-types": "^15.7.2", diff --git a/addons/notes/package.json b/addons/notes/package.json index 387d590b57c..57ea4d5c3cf 100644 --- a/addons/notes/package.json +++ b/addons/notes/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-notes", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Write notes for your Storybook stories.", "keywords": [ "addon", @@ -30,13 +30,13 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/router": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/router": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "markdown-to-jsx": "^6.10.3", diff --git a/addons/ondevice-actions/package.json b/addons/ondevice-actions/package.json index 0c4060fa770..874cf48b852 100644 --- a/addons/ondevice-actions/package.json +++ b/addons/ondevice-actions/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-ondevice-actions", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Action Logger addon for react-native storybook", "keywords": [ "storybook" @@ -26,13 +26,13 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", "core-js": "^3.0.1", "fast-deep-equal": "^2.0.1" }, "devDependencies": { - "@storybook/addon-actions": "5.3.0-beta.18" + "@storybook/addon-actions": "5.3.0-beta.19" }, "peerDependencies": { "@storybook/addon-actions": "*", diff --git a/addons/ondevice-backgrounds/package.json b/addons/ondevice-backgrounds/package.json index 22ce6bc3297..4b4a6dc111d 100644 --- a/addons/ondevice-backgrounds/package.json +++ b/addons/ondevice-backgrounds/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-ondevice-backgrounds", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "A react-native storybook addon to show different backgrounds for your preview", "keywords": [ "addon", @@ -31,9 +31,9 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", "core-js": "^3.0.1", "prop-types": "^15.7.2" }, diff --git a/addons/ondevice-knobs/package.json b/addons/ondevice-knobs/package.json index e1031ff468f..eeac09f26d1 100644 --- a/addons/ondevice-knobs/package.json +++ b/addons/ondevice-knobs/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-ondevice-knobs", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Display storybook story knobs on your deviced.", "keywords": [ "addon", @@ -28,8 +28,8 @@ }, "dependencies": { "@emotion/native": "^10.0.14", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", "core-js": "^3.0.1", "deep-equal": "^1.0.1", "prop-types": "^15.7.2", @@ -46,4 +46,4 @@ "publishConfig": { "access": "public" } -} \ No newline at end of file +} diff --git a/addons/ondevice-notes/package.json b/addons/ondevice-notes/package.json index 69c7e9f3baf..b74c077cc4b 100644 --- a/addons/ondevice-notes/package.json +++ b/addons/ondevice-notes/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-ondevice-notes", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Write notes for your react-native Storybook stories.", "keywords": [ "addon", @@ -28,11 +28,11 @@ }, "dependencies": { "@emotion/core": "^10.0.20", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", "core-js": "^3.0.1", "prop-types": "^15.7.2", "react-native-simple-markdown": "^1.1.0" diff --git a/addons/options/package.json b/addons/options/package.json index f808425c51d..08e906ece30 100644 --- a/addons/options/package.json +++ b/addons/options/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-options", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Options addon for storybook", "keywords": [ "addon", @@ -29,7 +29,7 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", "core-js": "^3.0.1", "util-deprecate": "^1.0.2" }, diff --git a/addons/queryparams/package.json b/addons/queryparams/package.json index 61d320d38f8..dd44e6ad91c 100644 --- a/addons/queryparams/package.json +++ b/addons/queryparams/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-queryparams", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "parameter addon for storybook", "keywords": [ "addon", @@ -30,12 +30,12 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "qs": "^6.6.0", diff --git a/addons/storyshots/storyshots-core/package.json b/addons/storyshots/storyshots-core/package.json index 1079920f9d4..3aea9d97a2b 100644 --- a/addons/storyshots/storyshots-core/package.json +++ b/addons/storyshots/storyshots-core/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-storyshots", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "StoryShots is a Jest Snapshot Testing Addon for Storybook.", "keywords": [ "addon", @@ -33,9 +33,9 @@ }, "dependencies": { "@jest/transform": "^24.9.0", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", "@types/glob": "^7.1.1", "@types/jest": "^24.0.16", "@types/jest-specific-snapshot": "^0.5.3", @@ -49,8 +49,8 @@ "ts-dedent": "^1.1.0" }, "devDependencies": { - "@storybook/addon-docs": "5.3.0-beta.18", - "@storybook/react": "5.3.0-beta.18", + "@storybook/addon-docs": "5.3.0-beta.19", + "@storybook/react": "5.3.0-beta.19", "babel-loader": "^8.0.6", "enzyme-to-json": "^3.4.1", "jest-emotion": "^10.0.17", diff --git a/addons/storyshots/storyshots-puppeteer/package.json b/addons/storyshots/storyshots-puppeteer/package.json index 54ff6995c5c..1694ce9ade7 100644 --- a/addons/storyshots/storyshots-puppeteer/package.json +++ b/addons/storyshots/storyshots-puppeteer/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-storyshots-puppeteer", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Image snapshots addition to StoryShots based on puppeteer", "keywords": [ "addon", @@ -30,8 +30,8 @@ }, "dependencies": { "@hypnosphi/jest-puppeteer-axe": "^1.4.0", - "@storybook/node-logger": "5.3.0-beta.18", - "@storybook/router": "5.3.0-beta.18", + "@storybook/node-logger": "5.3.0-beta.19", + "@storybook/router": "5.3.0-beta.19", "@types/jest-image-snapshot": "^2.8.0", "core-js": "^3.0.1", "jest-image-snapshot": "^2.8.2", @@ -52,4 +52,4 @@ "optional": true } } -} \ No newline at end of file +} diff --git a/addons/storysource/package.json b/addons/storysource/package.json index f110717c0aa..02b348c632a 100644 --- a/addons/storysource/package.json +++ b/addons/storysource/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-storysource", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Stories addon for storybook", "keywords": [ "addon", @@ -28,11 +28,11 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/router": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/router": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "estraverse": "^4.2.0", "loader-utils": "^1.2.3", diff --git a/addons/viewport/package.json b/addons/viewport/package.json index 15233bb82ef..420718ebb39 100644 --- a/addons/viewport/package.json +++ b/addons/viewport/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-viewport", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook addon to change the viewport size to mobile", "keywords": [ "addon", @@ -29,12 +29,12 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "memoizerific": "^1.11.3", diff --git a/app/angular/package.json b/app/angular/package.json index 04a269b55bf..c1f12e8cba0 100644 --- a/app/angular/package.json +++ b/app/angular/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/angular", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for Angular: Develop Angular Components in isolation with Hot Reloading.", "keywords": [ "storybook" @@ -33,9 +33,9 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", - "@storybook/node-logger": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", + "@storybook/node-logger": "5.3.0-beta.19", "core-js": "^3.0.1", "fork-ts-checker-webpack-plugin": "^3.0.1", "global": "^4.3.2", diff --git a/app/ember/package.json b/app/ember/package.json index 082ae05a306..4ca59f47977 100644 --- a/app/ember/package.json +++ b/app/ember/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/ember", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for Ember: Develop Ember Component in isolation with Hot Reloading.", "homepage": "https://github.com/storybookjs/storybook/tree/master/app/ember", "bugs": { @@ -31,7 +31,7 @@ }, "dependencies": { "@ember/test-helpers": "^1.5.0", - "@storybook/core": "5.3.0-beta.18", + "@storybook/core": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "regenerator-runtime": "^0.13.3", diff --git a/app/html/package.json b/app/html/package.json index 7a116e9f554..38e640f7696 100644 --- a/app/html/package.json +++ b/app/html/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/html", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for HTML: View HTML snippets in isolation with Hot Reloading.", "keywords": [ "storybook" @@ -33,8 +33,8 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", "@types/webpack-env": "^1.13.9", "core-js": "^3.0.1", "global": "^4.3.2", diff --git a/app/marko/package.json b/app/marko/package.json index 56e2120b253..fbf3758e12f 100644 --- a/app/marko/package.json +++ b/app/marko/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/marko", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for Marko: Develop Marko Component in isolation with Hot Reloading.", "keywords": [ "storybook" @@ -33,8 +33,8 @@ }, "dependencies": { "@marko/webpack": "^2.0.0", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "regenerator-runtime": "^0.13.3", diff --git a/app/mithril/package.json b/app/mithril/package.json index 621db3d1e17..b5589e5bc81 100644 --- a/app/mithril/package.json +++ b/app/mithril/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/mithril", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for Mithril: Develop Mithril Component in isolation.", "keywords": [ "storybook" @@ -35,8 +35,8 @@ "dependencies": { "@babel/core": "^7.6.2", "@babel/plugin-transform-react-jsx": "^7.3.0", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", "@types/mithril": "^2.0.0", "core-js": "^3.0.1", "global": "^4.3.2", diff --git a/app/polymer/package.json b/app/polymer/package.json index 93e4c296e4b..099e8cfd7c6 100644 --- a/app/polymer/package.json +++ b/app/polymer/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/polymer", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for Polymer: Develop Polymer components in isolation with Hot Reloading.", "keywords": [ "storybook" @@ -32,7 +32,7 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/core": "5.3.0-beta.18", + "@storybook/core": "5.3.0-beta.19", "@webcomponents/webcomponentsjs": "^1.2.0", "core-js": "^3.0.1", "global": "^4.3.2", diff --git a/app/preact/package.json b/app/preact/package.json index 7a55c9aeb02..64f66715c4c 100644 --- a/app/preact/package.json +++ b/app/preact/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/preact", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for Preact: Develop Preact Component in isolation.", "keywords": [ "storybook" @@ -34,8 +34,8 @@ }, "dependencies": { "@babel/plugin-transform-react-jsx": "^7.3.0", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", "@types/webpack-env": "^1.13.9", "core-js": "^3.0.1", "global": "^4.3.2", diff --git a/app/rax/package.json b/app/rax/package.json index ecbbe37b12c..9e92a3c6fcb 100644 --- a/app/rax/package.json +++ b/app/rax/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/rax", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for Rax: Develop Rax Component in isolation.", "keywords": [ "rax", @@ -33,7 +33,7 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/core": "5.3.0-beta.18", + "@storybook/core": "5.3.0-beta.19", "babel-preset-rax": "^1.0.0-beta.0", "core-js": "^3.0.1", "driver-dom": "^2.0.0", diff --git a/app/react-native-server/package.json b/app/react-native-server/package.json index 86d65df282c..7bc0acf26e5 100644 --- a/app/react-native-server/package.json +++ b/app/react-native-server/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/react-native-server", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "A better way to develop React Native Components for your app", "keywords": [ "react", @@ -31,12 +31,12 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/channel-websocket": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/ui": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/channel-websocket": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/ui": "5.3.0-beta.19", "commander": "^4.0.1", "core-js": "^3.0.1", "global": "^4.3.2", diff --git a/app/react-native/package.json b/app/react-native/package.json index 39f404fdbfb..d8f7a27a726 100644 --- a/app/react-native/package.json +++ b/app/react-native/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/react-native", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "A better way to develop React Native Components for your app", "keywords": [ "react", @@ -31,11 +31,11 @@ "dependencies": { "@emotion/core": "^10.0.20", "@emotion/native": "^10.0.14", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/channel-websocket": "5.3.0-beta.18", - "@storybook/channels": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/channel-websocket": "5.3.0-beta.19", + "@storybook/channels": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", "core-js": "^3.0.1", "emotion-theming": "^10.0.19", "react-native-swipe-gestures": "^1.0.4" diff --git a/app/react/package.json b/app/react/package.json index e95ea2c26bf..e8efdcb86b9 100644 --- a/app/react/package.json +++ b/app/react/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/react", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for React: Develop React Component in isolation with Hot Reloading.", "keywords": [ "storybook" @@ -36,9 +36,9 @@ "@babel/plugin-transform-react-constant-elements": "^7.2.0", "@babel/preset-flow": "^7.0.0", "@babel/preset-react": "^7.0.0", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", - "@storybook/node-logger": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", + "@storybook/node-logger": "5.3.0-beta.19", "@svgr/webpack": "^4.0.3", "@types/webpack-env": "^1.13.7", "babel-plugin-add-react-displayname": "^0.0.5", diff --git a/app/riot/package.json b/app/riot/package.json index c1a5f33adc3..cfcf3c91593 100644 --- a/app/riot/package.json +++ b/app/riot/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/riot", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for riot.js: View riot snippets in isolation with Hot Reloading.", "keywords": [ "storybook" @@ -33,7 +33,7 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/core": "5.3.0-beta.18", + "@storybook/core": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "raw-loader": "^3.1.0", diff --git a/app/svelte/package.json b/app/svelte/package.json index d3a778b91e4..670f4baad72 100644 --- a/app/svelte/package.json +++ b/app/svelte/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/svelte", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for Svelte: Develop Svelte Component in isolation with Hot Reloading.", "keywords": [ "storybook" @@ -33,8 +33,8 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "regenerator-runtime": "^0.13.3", diff --git a/app/vue/package.json b/app/vue/package.json index e9dc7833ce9..16ff8d048cc 100644 --- a/app/vue/package.json +++ b/app/vue/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/vue", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for Vue: Develop Vue Component in isolation with Hot Reloading.", "keywords": [ "storybook" @@ -33,8 +33,8 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", "@types/webpack-env": "^1.13.9", "core-js": "^3.0.1", "global": "^4.3.2", diff --git a/app/web-components/package.json b/app/web-components/package.json index 79d0d1aa511..baecf323cc0 100644 --- a/app/web-components/package.json +++ b/app/web-components/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/web-components", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook for web-components: View web components snippets in isolation with Hot Reloading.", "keywords": [ "lit-html", @@ -37,8 +37,8 @@ "dependencies": { "@babel/plugin-syntax-dynamic-import": "^7.2.0", "@babel/plugin-syntax-import-meta": "^7.2.0", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", "@types/webpack-env": "^1.13.9", "babel-plugin-bundled-import-meta": "^0.3.1", "core-js": "^3.0.1", diff --git a/dev-kits/addon-decorator/package.json b/dev-kits/addon-decorator/package.json index cc6aace83dd..a2dae88c994 100644 --- a/dev-kits/addon-decorator/package.json +++ b/dev-kits/addon-decorator/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-decorator", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "decorator addon for storybook", "keywords": [ "addon", @@ -24,8 +24,8 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.4.0" }, diff --git a/dev-kits/addon-parameter/package.json b/dev-kits/addon-parameter/package.json index ca0ccb7792f..2772061c2e0 100644 --- a/dev-kits/addon-parameter/package.json +++ b/dev-kits/addon-parameter/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-parameter", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "parameter addon for storybook", "keywords": [ "addon", @@ -24,12 +24,12 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "react": "^16.8.3", diff --git a/dev-kits/addon-preview-wrapper/package.json b/dev-kits/addon-preview-wrapper/package.json index 236c41bde54..7b25ffb277b 100644 --- a/dev-kits/addon-preview-wrapper/package.json +++ b/dev-kits/addon-preview-wrapper/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-preview-wrapper", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "preview wrapper addon for storybook", "keywords": [ "addon", @@ -24,7 +24,7 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", "react": "^16.8.3" }, "publishConfig": { diff --git a/dev-kits/addon-roundtrip/package.json b/dev-kits/addon-roundtrip/package.json index 725e11ed808..76fc1774ad6 100644 --- a/dev-kits/addon-roundtrip/package.json +++ b/dev-kits/addon-roundtrip/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addon-roundtrip", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "roundtrip addon for storybook", "keywords": [ "addon", @@ -24,13 +24,13 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "react": "^16.8.3", diff --git a/examples-native/crna-kitchen-sink/package.json b/examples-native/crna-kitchen-sink/package.json index d268838f776..ab7cbd29a5e 100644 --- a/examples-native/crna-kitchen-sink/package.json +++ b/examples-native/crna-kitchen-sink/package.json @@ -1,6 +1,6 @@ { "name": "crna-kitchen-sink", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "main": "node_modules/expo/AppEntry.js", "workspaces": { @@ -31,15 +31,15 @@ "devDependencies": { "@babel/core": "^7.2.2", "@babel/plugin-transform-react-jsx-source": "^7.2.0", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-ondevice-actions": "5.3.0-beta.18", - "@storybook/addon-ondevice-backgrounds": "5.3.0-beta.18", - "@storybook/addon-ondevice-knobs": "5.3.0-beta.18", - "@storybook/addon-ondevice-notes": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/react-native": "5.3.0-beta.18", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-ondevice-actions": "5.3.0-beta.19", + "@storybook/addon-ondevice-backgrounds": "5.3.0-beta.19", + "@storybook/addon-ondevice-knobs": "5.3.0-beta.19", + "@storybook/addon-ondevice-notes": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/react-native": "5.3.0-beta.19", "babel-loader": "^8.0.4", "babel-plugin-module-resolver": "^3.2.0", "babel-preset-expo": "^7.0.0", diff --git a/examples/angular-cli/package.json b/examples/angular-cli/package.json index 73e009f5504..fb797525b96 100644 --- a/examples/angular-cli/package.json +++ b/examples/angular-cli/package.json @@ -1,6 +1,6 @@ { "name": "angular-cli", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "license": "MIT", "scripts": { @@ -37,21 +37,21 @@ "@angular/cli": "^8.3.6", "@angular/compiler-cli": "^8.2.8", "@compodoc/compodoc": "^1.1.11", - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-docs": "5.3.0-beta.18", - "@storybook/addon-jest": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/angular": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-docs": "5.3.0-beta.19", + "@storybook/addon-jest": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/angular": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", "@types/core-js": "^2.5.0", "@types/jest": "^24.0.11", "@types/node": "^12.12.11", diff --git a/examples/cra-kitchen-sink/package.json b/examples/cra-kitchen-sink/package.json index f6038cddbc4..12557a14eda 100644 --- a/examples/cra-kitchen-sink/package.json +++ b/examples/cra-kitchen-sink/package.json @@ -1,6 +1,6 @@ { "name": "cra-kitchen-sink", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build": "react-scripts build", @@ -18,23 +18,23 @@ "react-lifecycles-compat": "^3.0.4" }, "devDependencies": { - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-docs": "5.3.0-beta.18", - "@storybook/addon-events": "5.3.0-beta.18", - "@storybook/addon-info": "5.3.0-beta.18", - "@storybook/addon-jest": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/react": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-docs": "5.3.0-beta.19", + "@storybook/addon-events": "5.3.0-beta.19", + "@storybook/addon-info": "5.3.0-beta.19", + "@storybook/addon-jest": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/react": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "react-scripts": "^3.0.1" } } diff --git a/examples/cra-react15/package.json b/examples/cra-react15/package.json index 469957079f3..f7c8ec11a2b 100644 --- a/examples/cra-react15/package.json +++ b/examples/cra-react15/package.json @@ -1,6 +1,6 @@ { "name": "cra-react15", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build": "react-scripts build", @@ -18,11 +18,11 @@ "react-scripts": "3.0.1" }, "devDependencies": { - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/react": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/react": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "babel-core": "6", "babel-runtime": "6" } diff --git a/examples/cra-ts-essentials/package.json b/examples/cra-ts-essentials/package.json index 36a4af0e123..694c1616e39 100644 --- a/examples/cra-ts-essentials/package.json +++ b/examples/cra-ts-essentials/package.json @@ -1,6 +1,6 @@ { "name": "cra-ts-essentials", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build": "react-scripts build", @@ -36,9 +36,9 @@ "typescript": "3.7.2" }, "devDependencies": { - "@storybook/addon-essentials": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", + "@storybook/addon-essentials": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", "@storybook/preset-create-react-app": "^1.2.0", - "@storybook/react": "5.3.0-beta.18" + "@storybook/react": "5.3.0-beta.19" } } diff --git a/examples/cra-ts-kitchen-sink/package.json b/examples/cra-ts-kitchen-sink/package.json index 70ab0b4aa7c..67f2fec10c6 100644 --- a/examples/cra-ts-kitchen-sink/package.json +++ b/examples/cra-ts-kitchen-sink/package.json @@ -1,6 +1,6 @@ { "name": "cra-ts-kitchen-sink", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build": "react-scripts build", @@ -34,15 +34,15 @@ "typescript": "3.7.2" }, "devDependencies": { - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-info": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-info": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", "@storybook/preset-create-react-app": "^1.3.1", - "@storybook/react": "5.3.0-beta.18", + "@storybook/react": "5.3.0-beta.19", "@types/enzyme": "^3.9.0", "@types/react": "^16.8.14", "@types/react-dom": "^16.8.2", diff --git a/examples/dev-kits/package.json b/examples/dev-kits/package.json index f7e0ddf0853..4634688be34 100644 --- a/examples/dev-kits/package.json +++ b/examples/dev-kits/package.json @@ -1,22 +1,22 @@ { "name": "@storybook/example-devkits", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build-storybook": "build-storybook -c ./", "storybook": "start-storybook -p 9011 -c ./" }, "devDependencies": { - "@storybook/addon-decorator": "5.3.0-beta.18", - "@storybook/addon-parameter": "5.3.0-beta.18", - "@storybook/addon-preview-wrapper": "5.3.0-beta.18", - "@storybook/addon-roundtrip": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/node-logger": "5.3.0-beta.18", - "@storybook/react": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addon-decorator": "5.3.0-beta.19", + "@storybook/addon-parameter": "5.3.0-beta.19", + "@storybook/addon-preview-wrapper": "5.3.0-beta.19", + "@storybook/addon-roundtrip": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/node-logger": "5.3.0-beta.19", + "@storybook/react": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "cors": "^2.8.5", "cross-env": "^6.0.3", "enzyme-to-json": "^3.4.1", diff --git a/examples/ember-cli/package.json b/examples/ember-cli/package.json index 8411c925019..c65782da1cb 100644 --- a/examples/ember-cli/package.json +++ b/examples/ember-cli/package.json @@ -1,6 +1,6 @@ { "name": "ember-example", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build": "ember build", @@ -15,21 +15,21 @@ }, "devDependencies": { "@babel/core": "^7.3.4", - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-docs": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/ember": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-docs": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/ember": "5.3.0-beta.19", "@storybook/ember-cli-storybook": "^0.2.0", - "@storybook/source-loader": "5.3.0-beta.18", + "@storybook/source-loader": "5.3.0-beta.19", "babel-loader": "^8", "broccoli-asset-rev": "^3.0.0", "cross-env": "^6.0.3", diff --git a/examples/html-kitchen-sink/package.json b/examples/html-kitchen-sink/package.json index a03244abc74..9d19acee291 100644 --- a/examples/html-kitchen-sink/package.json +++ b/examples/html-kitchen-sink/package.json @@ -1,6 +1,6 @@ { "name": "html-kitchen-sink", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "description": "", "keywords": [], @@ -13,26 +13,26 @@ "storybook": "start-storybook -p 9006" }, "devDependencies": { - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-docs": "5.3.0-beta.18", - "@storybook/addon-events": "5.3.0-beta.18", - "@storybook/addon-jest": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/html": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-docs": "5.3.0-beta.19", + "@storybook/addon-events": "5.3.0-beta.19", + "@storybook/addon-jest": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/html": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", "eventemitter3": "^4.0.0", "format-json": "^1.0.3", "global": "^4.3.2", diff --git a/examples/marko-cli/package.json b/examples/marko-cli/package.json index 1f06cf0bb27..71fb2f3e720 100644 --- a/examples/marko-cli/package.json +++ b/examples/marko-cli/package.json @@ -1,6 +1,6 @@ { "name": "marko-cli", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "description": "Demo of how to build an app using marko-starter", "repository": { @@ -23,14 +23,14 @@ "marko-starter": "^2.1.0" }, "devDependencies": { - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/marko": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/marko": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", "prettier": "^1.16.4", "webpack": "^4.33.0" } diff --git a/examples/mithril-kitchen-sink/package.json b/examples/mithril-kitchen-sink/package.json index 9745d37bd2d..4e52d00634c 100644 --- a/examples/mithril-kitchen-sink/package.json +++ b/examples/mithril-kitchen-sink/package.json @@ -1,6 +1,6 @@ { "name": "mithril-example", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build-storybook": "build-storybook", @@ -10,20 +10,20 @@ "mithril": "^1.1.6" }, "devDependencies": { - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/mithril": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/mithril": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", "webpack": "^4.33.0" } } diff --git a/examples/official-storybook/package.json b/examples/official-storybook/package.json index 07e44c66a1d..632184b1294 100644 --- a/examples/official-storybook/package.json +++ b/examples/official-storybook/package.json @@ -1,6 +1,6 @@ { "name": "official-storybook", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build-storybook": "cross-env STORYBOOK_DISPLAY_WARNING=true DISPLAY_WARNING=true build-storybook -c ./", @@ -14,34 +14,34 @@ }, "devDependencies": { "@packtracker/webpack-plugin": "^2.0.1", - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-contexts": "5.3.0-beta.18", - "@storybook/addon-cssresources": "5.3.0-beta.18", - "@storybook/addon-design-assets": "5.3.0-beta.18", - "@storybook/addon-docs": "5.3.0-beta.18", - "@storybook/addon-events": "5.3.0-beta.18", - "@storybook/addon-graphql": "5.3.0-beta.18", - "@storybook/addon-info": "5.3.0-beta.18", - "@storybook/addon-jest": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-queryparams": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addon-storyshots-puppeteer": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/node-logger": "5.3.0-beta.18", - "@storybook/react": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-contexts": "5.3.0-beta.19", + "@storybook/addon-cssresources": "5.3.0-beta.19", + "@storybook/addon-design-assets": "5.3.0-beta.19", + "@storybook/addon-docs": "5.3.0-beta.19", + "@storybook/addon-events": "5.3.0-beta.19", + "@storybook/addon-graphql": "5.3.0-beta.19", + "@storybook/addon-info": "5.3.0-beta.19", + "@storybook/addon-jest": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-queryparams": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addon-storyshots-puppeteer": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/node-logger": "5.3.0-beta.19", + "@storybook/react": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "cors": "^2.8.5", "cross-env": "^6.0.3", "enzyme-to-json": "^3.4.1", diff --git a/examples/polymer-cli/package.json b/examples/polymer-cli/package.json index a7d7f2f486c..bc63fff6517 100644 --- a/examples/polymer-cli/package.json +++ b/examples/polymer-cli/package.json @@ -1,6 +1,6 @@ { "name": "polymer-cli", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build-storybook": "build-storybook", @@ -9,18 +9,18 @@ }, "dependencies": { "@polymer/polymer": "^2.6.0", - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/polymer": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/polymer": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", "@webcomponents/webcomponentsjs": "^1.2.0", "global": "^4.3.2", "lit-html": "^1.0.0", diff --git a/examples/preact-kitchen-sink/package.json b/examples/preact-kitchen-sink/package.json index 0af4597c396..c939b9cdb39 100644 --- a/examples/preact-kitchen-sink/package.json +++ b/examples/preact-kitchen-sink/package.json @@ -1,6 +1,6 @@ { "name": "preact-example", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build": "cross-env NODE_ENV=production webpack --progress --hide-modules", @@ -15,21 +15,21 @@ "devDependencies": { "@babel/core": "^7.3.4", "@babel/plugin-transform-runtime": "^7.2.0", - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-contexts": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/preact": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-contexts": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/preact": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", "babel-loader": "^8.0.4", "cross-env": "^6.0.3", "file-loader": "^4.2.0", diff --git a/examples/rax-kitchen-sink/package.json b/examples/rax-kitchen-sink/package.json index d492d65fe8b..45098e57f2b 100644 --- a/examples/rax-kitchen-sink/package.json +++ b/examples/rax-kitchen-sink/package.json @@ -1,6 +1,6 @@ { "name": "rax-kitchen-sink", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build": "rax-scripts build", @@ -21,24 +21,24 @@ "rax-view": "^1.0.0" }, "devDependencies": { - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-events": "5.3.0-beta.18", - "@storybook/addon-info": "5.3.0-beta.18", - "@storybook/addon-jest": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/rax": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-events": "5.3.0-beta.19", + "@storybook/addon-info": "5.3.0-beta.19", + "@storybook/addon-jest": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/rax": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "babel-eslint": "^10.0.3", "babel-preset-rax": "^1.0.0-beta.0", "rax-scripts": "^2.0.0", diff --git a/examples/riot-kitchen-sink/package.json b/examples/riot-kitchen-sink/package.json index 0dc4e20a652..24848e69d5c 100644 --- a/examples/riot-kitchen-sink/package.json +++ b/examples/riot-kitchen-sink/package.json @@ -1,6 +1,6 @@ { "name": "riot-example", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build": "cross-env NODE_ENV=production webpack --progress --hide-modules", @@ -15,20 +15,20 @@ }, "devDependencies": { "@babel/core": "^7.3.4", - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/riot": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/riot": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", "babel-loader": "^8.0.4", "cross-env": "^6.0.3", "file-loader": "^4.2.0", diff --git a/examples/standalone-preview/package.json b/examples/standalone-preview/package.json index 02b10a04d4d..a7e442ca790 100644 --- a/examples/standalone-preview/package.json +++ b/examples/standalone-preview/package.json @@ -1,12 +1,12 @@ { "name": "standalone-preview", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "storybook": "parcel ./storybook.html --port 1337" }, "devDependencies": { - "@storybook/react": "5.3.0-beta.18", + "@storybook/react": "5.3.0-beta.19", "parcel": "^1.12.3", "react": "^16.8.4", "react-dom": "^16.8.4" diff --git a/examples/svelte-kitchen-sink/package.json b/examples/svelte-kitchen-sink/package.json index eb82530b1b7..72633327a95 100644 --- a/examples/svelte-kitchen-sink/package.json +++ b/examples/svelte-kitchen-sink/package.json @@ -1,6 +1,6 @@ { "name": "svelte-example", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build-storybook": "build-storybook -s public", @@ -10,19 +10,19 @@ "global": "^4.3.2" }, "devDependencies": { - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", - "@storybook/svelte": "5.3.0-beta.18" + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", + "@storybook/svelte": "5.3.0-beta.19" } } diff --git a/examples/vue-kitchen-sink/package.json b/examples/vue-kitchen-sink/package.json index e1eac8815cf..33ecb1552f3 100644 --- a/examples/vue-kitchen-sink/package.json +++ b/examples/vue-kitchen-sink/package.json @@ -1,6 +1,6 @@ { "name": "vue-example", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "scripts": { "build": "cross-env NODE_ENV=production webpack --progress --hide-modules", @@ -14,22 +14,22 @@ }, "devDependencies": { "@babel/core": "^7.3.4", - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-contexts": "5.3.0-beta.18", - "@storybook/addon-docs": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", - "@storybook/vue": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-contexts": "5.3.0-beta.19", + "@storybook/addon-docs": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", + "@storybook/vue": "5.3.0-beta.19", "babel-core": "^7.0.0-bridge.0", "babel-loader": "^8.0.5", "cross-env": "^6.0.3", diff --git a/examples/web-components-kitchen-sink/package.json b/examples/web-components-kitchen-sink/package.json index 0ecff71b66c..1f03391b430 100644 --- a/examples/web-components-kitchen-sink/package.json +++ b/examples/web-components-kitchen-sink/package.json @@ -1,6 +1,6 @@ { "name": "web-components-kitchen-sink", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "description": "", "keywords": [], @@ -12,26 +12,26 @@ "storybook": "start-storybook -p 9006" }, "devDependencies": { - "@storybook/addon-a11y": "5.3.0-beta.18", - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-backgrounds": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-docs": "5.3.0-beta.18", - "@storybook/addon-events": "5.3.0-beta.18", - "@storybook/addon-jest": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addon-storysource": "5.3.0-beta.18", - "@storybook/addon-viewport": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", - "@storybook/core": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/source-loader": "5.3.0-beta.18", - "@storybook/web-components": "5.3.0-beta.18", + "@storybook/addon-a11y": "5.3.0-beta.19", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-backgrounds": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-docs": "5.3.0-beta.19", + "@storybook/addon-events": "5.3.0-beta.19", + "@storybook/addon-jest": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addon-storysource": "5.3.0-beta.19", + "@storybook/addon-viewport": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", + "@storybook/core": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/source-loader": "5.3.0-beta.19", + "@storybook/web-components": "5.3.0-beta.19", "babel-loader": "^8.0.5", "eventemitter3": "^4.0.0", "format-json": "^1.0.3", diff --git a/lerna.json b/lerna.json index 4895709981b..ac46df957da 100644 --- a/lerna.json +++ b/lerna.json @@ -2,5 +2,5 @@ "npmClient": "yarn", "useWorkspaces": true, "registry": "https://registry.npmjs.org", - "version": "5.3.0-beta.18" + "version": "5.3.0-beta.19" } diff --git a/lib/addons/package.json b/lib/addons/package.json index 1fd3356f693..fd1f4d97177 100644 --- a/lib/addons/package.json +++ b/lib/addons/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/addons", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook addons store", "keywords": [ "storybook" @@ -27,10 +27,10 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/api": "5.3.0-beta.18", - "@storybook/channels": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", + "@storybook/api": "5.3.0-beta.19", + "@storybook/channels": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "util-deprecate": "^1.0.2" diff --git a/lib/api/package.json b/lib/api/package.json index 22ce2098b16..2471264c57f 100644 --- a/lib/api/package.json +++ b/lib/api/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/api", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Core Storybook API & Context", "keywords": [ "storybook" @@ -26,11 +26,11 @@ "prepare": "node ./scripts/generateVersion.js && node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/channels": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/router": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/channels": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/router": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", "fast-deep-equal": "^2.0.1", "global": "^4.3.2", diff --git a/lib/channel-postmessage/package.json b/lib/channel-postmessage/package.json index fc9043366fe..9d405775faf 100644 --- a/lib/channel-postmessage/package.json +++ b/lib/channel-postmessage/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/channel-postmessage", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "", "keywords": [ "storybook" @@ -27,8 +27,8 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/channels": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", + "@storybook/channels": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "telejson": "^3.2.0" diff --git a/lib/channel-websocket/package.json b/lib/channel-websocket/package.json index 344fb7f255b..cc1f5252139 100644 --- a/lib/channel-websocket/package.json +++ b/lib/channel-websocket/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/channel-websocket", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "", "keywords": [ "storybook" @@ -27,7 +27,7 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/channels": "5.3.0-beta.18", + "@storybook/channels": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", "json-fn": "^1.1.1" diff --git a/lib/channels/package.json b/lib/channels/package.json index 306dce1ec7c..8da6d9ee53a 100644 --- a/lib/channels/package.json +++ b/lib/channels/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/channels", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "", "keywords": [ "storybook" diff --git a/lib/cli-sb/package.json b/lib/cli-sb/package.json index 14c6bdb9420..4751faf319d 100644 --- a/lib/cli-sb/package.json +++ b/lib/cli-sb/package.json @@ -1,6 +1,6 @@ { "name": "sb", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "description": "Storybook CLI", "keywords": [ @@ -23,7 +23,7 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/cli": "5.3.0-beta.18" + "@storybook/cli": "5.3.0-beta.19" }, "publishConfig": { "access": "public" diff --git a/lib/cli-storybook/package.json b/lib/cli-storybook/package.json index b5386ae9035..17d58335411 100644 --- a/lib/cli-storybook/package.json +++ b/lib/cli-storybook/package.json @@ -1,6 +1,6 @@ { "name": "storybook", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "private": true, "description": "Storybook CLI", "keywords": [ @@ -24,7 +24,7 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/cli": "5.3.0-beta.18" + "@storybook/cli": "5.3.0-beta.19" }, "publishConfig": { "access": "public" diff --git a/lib/cli/package.json b/lib/cli/package.json index ab408d8b278..5653df4cf0b 100644 --- a/lib/cli/package.json +++ b/lib/cli/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/cli", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook's CLI - easiest method of adding storybook to your projects", "keywords": [ "cli", @@ -38,7 +38,7 @@ "dependencies": { "@babel/core": "^7.4.5", "@babel/preset-env": "^7.4.5", - "@storybook/codemod": "5.3.0-beta.18", + "@storybook/codemod": "5.3.0-beta.19", "chalk": "^3.0.0", "commander": "^4.0.1", "core-js": "^3.0.1", @@ -57,33 +57,33 @@ "update-notifier": "^3.0.0" }, "devDependencies": { - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-centered": "5.3.0-beta.18", - "@storybook/addon-graphql": "5.3.0-beta.18", - "@storybook/addon-info": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", - "@storybook/addon-links": "5.3.0-beta.18", - "@storybook/addon-notes": "5.3.0-beta.18", - "@storybook/addon-options": "5.3.0-beta.18", - "@storybook/addon-storyshots": "5.3.0-beta.18", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/angular": "5.3.0-beta.18", - "@storybook/channel-postmessage": "5.3.0-beta.18", - "@storybook/channel-websocket": "5.3.0-beta.18", - "@storybook/channels": "5.3.0-beta.18", - "@storybook/ember": "5.3.0-beta.18", - "@storybook/html": "5.3.0-beta.18", - "@storybook/marko": "5.3.0-beta.18", - "@storybook/mithril": "5.3.0-beta.18", - "@storybook/polymer": "5.3.0-beta.18", - "@storybook/preact": "5.3.0-beta.18", - "@storybook/rax": "5.3.0-beta.18", - "@storybook/react": "5.3.0-beta.18", - "@storybook/react-native": "5.3.0-beta.18", - "@storybook/riot": "5.3.0-beta.18", - "@storybook/svelte": "5.3.0-beta.18", - "@storybook/ui": "5.3.0-beta.18", - "@storybook/vue": "5.3.0-beta.18" + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-centered": "5.3.0-beta.19", + "@storybook/addon-graphql": "5.3.0-beta.19", + "@storybook/addon-info": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", + "@storybook/addon-links": "5.3.0-beta.19", + "@storybook/addon-notes": "5.3.0-beta.19", + "@storybook/addon-options": "5.3.0-beta.19", + "@storybook/addon-storyshots": "5.3.0-beta.19", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/angular": "5.3.0-beta.19", + "@storybook/channel-postmessage": "5.3.0-beta.19", + "@storybook/channel-websocket": "5.3.0-beta.19", + "@storybook/channels": "5.3.0-beta.19", + "@storybook/ember": "5.3.0-beta.19", + "@storybook/html": "5.3.0-beta.19", + "@storybook/marko": "5.3.0-beta.19", + "@storybook/mithril": "5.3.0-beta.19", + "@storybook/polymer": "5.3.0-beta.19", + "@storybook/preact": "5.3.0-beta.19", + "@storybook/rax": "5.3.0-beta.19", + "@storybook/react": "5.3.0-beta.19", + "@storybook/react-native": "5.3.0-beta.19", + "@storybook/riot": "5.3.0-beta.19", + "@storybook/svelte": "5.3.0-beta.19", + "@storybook/ui": "5.3.0-beta.19", + "@storybook/vue": "5.3.0-beta.19" }, "publishConfig": { "access": "public" diff --git a/lib/client-api/package.json b/lib/client-api/package.json index 076b15fbaa3..1d905f00361 100644 --- a/lib/client-api/package.json +++ b/lib/client-api/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/client-api", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook Client API", "keywords": [ "storybook" @@ -27,12 +27,12 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/channel-postmessage": "5.3.0-beta.18", - "@storybook/channels": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/router": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/channel-postmessage": "5.3.0-beta.19", + "@storybook/channels": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/router": "5.3.0-beta.19", "core-js": "^3.0.1", "eventemitter3": "^4.0.0", "global": "^4.3.2", diff --git a/lib/client-logger/package.json b/lib/client-logger/package.json index c77d5c815b2..2d89b49ae0d 100644 --- a/lib/client-logger/package.json +++ b/lib/client-logger/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/client-logger", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "", "keywords": [ "storybook" diff --git a/lib/codemod/package.json b/lib/codemod/package.json index d5189efb6c1..03631e9673c 100644 --- a/lib/codemod/package.json +++ b/lib/codemod/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/codemod", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "A collection of codemod scripts written with JSCodeshift", "keywords": [ "storybook" @@ -29,8 +29,8 @@ "dependencies": { "@hypnosphi/jscodeshift": "^0.6.4", "@mdx-js/mdx": "^1.5.1", - "@storybook/node-logger": "5.3.0-beta.18", - "@storybook/router": "5.3.0-beta.18", + "@storybook/node-logger": "5.3.0-beta.19", + "@storybook/router": "5.3.0-beta.19", "core-js": "^3.0.1", "cross-spawn": "^7.0.0", "globby": "^10.0.1", diff --git a/lib/components/package.json b/lib/components/package.json index a2f6800ab64..efb01d83b98 100644 --- a/lib/components/package.json +++ b/lib/components/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/components", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Core Storybook Components", "keywords": [ "storybook" @@ -27,8 +27,8 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "@types/react-syntax-highlighter": "11.0.2", "@types/react-textarea-autosize": "^4.3.3", "core-js": "^3.0.1", diff --git a/lib/core-events/package.json b/lib/core-events/package.json index 669c2a5281f..a9edab3f180 100644 --- a/lib/core-events/package.json +++ b/lib/core-events/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/core-events", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Event names used in storybook core", "keywords": [ "storybook" diff --git a/lib/core/package.json b/lib/core/package.json index e0de62faa0d..64a277b048c 100644 --- a/lib/core/package.json +++ b/lib/core/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/core", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook framework-agnostic API", "keywords": [ "storybook" @@ -32,15 +32,15 @@ "@babel/plugin-syntax-dynamic-import": "^7.2.0", "@babel/plugin-transform-react-constant-elements": "^7.2.0", "@babel/preset-env": "^7.4.5", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/channel-postmessage": "5.3.0-beta.18", - "@storybook/client-api": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/node-logger": "5.3.0-beta.18", - "@storybook/router": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", - "@storybook/ui": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/channel-postmessage": "5.3.0-beta.19", + "@storybook/client-api": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/node-logger": "5.3.0-beta.19", + "@storybook/router": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", + "@storybook/ui": "5.3.0-beta.19", "airbnb-js-shims": "^2.2.1", "ansi-to-html": "^0.6.11", "autoprefixer": "^9.7.2", diff --git a/lib/node-logger/package.json b/lib/node-logger/package.json index 8732b25f95e..686eeefcde1 100644 --- a/lib/node-logger/package.json +++ b/lib/node-logger/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/node-logger", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "", "keywords": [ "storybook" diff --git a/lib/postinstall/package.json b/lib/postinstall/package.json index 567eccc3ac5..03c1e6d2bea 100644 --- a/lib/postinstall/package.json +++ b/lib/postinstall/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/postinstall", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Storybook addons postinstall utilities", "keywords": [ "api", diff --git a/lib/router/package.json b/lib/router/package.json index edb051ab0d1..ea4ba628d19 100644 --- a/lib/router/package.json +++ b/lib/router/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/router", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Core Storybook Router", "keywords": [ "storybook" diff --git a/lib/source-loader/package.json b/lib/source-loader/package.json index 6b70323494f..379aaf7cdc4 100644 --- a/lib/source-loader/package.json +++ b/lib/source-loader/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/source-loader", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Source loader", "keywords": [ "lib", @@ -28,9 +28,9 @@ "prepare": "node ../../scripts/prepare.js" }, "dependencies": { - "@storybook/addons": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/router": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/router": "5.3.0-beta.19", "core-js": "^3.0.1", "estraverse": "^4.2.0", "global": "^4.3.2", diff --git a/lib/theming/package.json b/lib/theming/package.json index 33a8d9399ea..a07583d8651 100644 --- a/lib/theming/package.json +++ b/lib/theming/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/theming", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Core Storybook Components", "keywords": [ "storybook" @@ -29,7 +29,7 @@ "dependencies": { "@emotion/core": "^10.0.20", "@emotion/styled": "^10.0.17", - "@storybook/client-logger": "5.3.0-beta.18", + "@storybook/client-logger": "5.3.0-beta.19", "core-js": "^3.0.1", "deep-object-diff": "^1.1.0", "emotion-theming": "^10.0.19", diff --git a/lib/ui/package.json b/lib/ui/package.json index e519b8c8187..01aa0d7c3b3 100644 --- a/lib/ui/package.json +++ b/lib/ui/package.json @@ -1,6 +1,6 @@ { "name": "@storybook/ui", - "version": "5.3.0-beta.18", + "version": "5.3.0-beta.19", "description": "Core Storybook UI", "keywords": [ "storybook" @@ -28,14 +28,14 @@ }, "dependencies": { "@emotion/core": "^10.0.20", - "@storybook/addons": "5.3.0-beta.18", - "@storybook/api": "5.3.0-beta.18", - "@storybook/channels": "5.3.0-beta.18", - "@storybook/client-logger": "5.3.0-beta.18", - "@storybook/components": "5.3.0-beta.18", - "@storybook/core-events": "5.3.0-beta.18", - "@storybook/router": "5.3.0-beta.18", - "@storybook/theming": "5.3.0-beta.18", + "@storybook/addons": "5.3.0-beta.19", + "@storybook/api": "5.3.0-beta.19", + "@storybook/channels": "5.3.0-beta.19", + "@storybook/client-logger": "5.3.0-beta.19", + "@storybook/components": "5.3.0-beta.19", + "@storybook/core-events": "5.3.0-beta.19", + "@storybook/router": "5.3.0-beta.19", + "@storybook/theming": "5.3.0-beta.19", "copy-to-clipboard": "^3.0.8", "core-js": "^3.0.1", "core-js-pure": "^3.0.1", @@ -63,8 +63,8 @@ "util-deprecate": "^1.0.2" }, "devDependencies": { - "@storybook/addon-actions": "5.3.0-beta.18", - "@storybook/addon-knobs": "5.3.0-beta.18", + "@storybook/addon-actions": "5.3.0-beta.19", + "@storybook/addon-knobs": "5.3.0-beta.19", "corejs-upgrade-webpack-plugin": "^2.2.0", "flush-promises": "^1.0.2", "terser-webpack-plugin": "^2.1.2", From f1d1eb76798ac0c011c846c1e71e3c52dd676c8c Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Sat, 7 Dec 2019 08:55:50 +0000 Subject: [PATCH 069/132] Bump fork-ts-checker-webpack-plugin from 3.1.0 to 3.1.1 Bumps [fork-ts-checker-webpack-plugin](https://github.com/TypeStrong/fork-ts-checker-webpack-plugin) from 3.1.0 to 3.1.1. - [Release notes](https://github.com/TypeStrong/fork-ts-checker-webpack-plugin/releases) - [Changelog](https://github.com/TypeStrong/fork-ts-checker-webpack-plugin/blob/master/CHANGELOG.md) - [Commits](https://github.com/TypeStrong/fork-ts-checker-webpack-plugin/compare/v3.1.0...v3.1.1) Signed-off-by: dependabot-preview[bot] --- yarn.lock | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/yarn.lock b/yarn.lock index 62a2e9c4ac9..1379547e1ca 100644 --- a/yarn.lock +++ b/yarn.lock @@ -8708,7 +8708,7 @@ cheerio@^1.0.0-rc.2, cheerio@^1.0.0-rc.3: lodash "^4.15.0" parse5 "^3.0.1" -"chokidar@>=2.0.0 <4.0.0", chokidar@^3.0.0, chokidar@^3.1.1: +"chokidar@>=2.0.0 <4.0.0", chokidar@^3.0.0, chokidar@^3.1.1, chokidar@^3.3.0: version "3.3.0" resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.3.0.tgz#12c0714668c55800f659e262d4962a97faf554a6" integrity sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A== @@ -14211,13 +14211,13 @@ fork-ts-checker-webpack-plugin@1.5.0: worker-rpc "^0.1.0" fork-ts-checker-webpack-plugin@^3.0.1: - version "3.1.0" - resolved "https://registry.yarnpkg.com/fork-ts-checker-webpack-plugin/-/fork-ts-checker-webpack-plugin-3.1.0.tgz#fb411a4b2c3697e1cd7f83436d4feeacbcc70c7b" - integrity sha512-6OkRfjuNMNqb14f01xokcWcKV5Ekknc2FvziNpcTYru+kxIYFA2MtuuBI19MHThZnjSBhoi35Dcq+I0oUkFjmQ== + version "3.1.1" + resolved "https://registry.yarnpkg.com/fork-ts-checker-webpack-plugin/-/fork-ts-checker-webpack-plugin-3.1.1.tgz#a1642c0d3e65f50c2cc1742e9c0a80f441f86b19" + integrity sha512-DuVkPNrM12jR41KM2e+N+styka0EgLkTnXmNcXdgOM37vtGeY+oCBK/Jx0hzSeEU6memFCtWb4htrHPMDfwwUQ== dependencies: babel-code-frame "^6.22.0" chalk "^2.4.1" - chokidar "^2.0.4" + chokidar "^3.3.0" micromatch "^3.1.10" minimatch "^3.0.4" semver "^5.6.0" From 29dddfc4409a5765de4f5370a44dc6025eea2437 Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Sat, 7 Dec 2019 16:56:24 +0800 Subject: [PATCH 070/132] Update version.ts to 5.3.0-beta.19 --- lib/api/src/version.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/api/src/version.ts b/lib/api/src/version.ts index 82b541b979e..02fb66a305b 100644 --- a/lib/api/src/version.ts +++ b/lib/api/src/version.ts @@ -1 +1 @@ -export const version = '5.3.0-beta.18'; +export const version = '5.3.0-beta.19'; From 788e65a3e2e0375e4c36c387a16cb4f61b294112 Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Sat, 7 Dec 2019 17:00:07 +0800 Subject: [PATCH 071/132] 5.3.0-beta.19 next.json version file --- docs/src/versions/next.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/src/versions/next.json b/docs/src/versions/next.json index f047349c745..8fcc00ef7ad 100644 --- a/docs/src/versions/next.json +++ b/docs/src/versions/next.json @@ -1 +1 @@ -{"version":"5.3.0-beta.18","info":{"plain":"### Features\n\n* CLI: Change generators to Triconfig ([#9075](https://github.com/storybookjs/storybook/pull/9075))\n* Addon-docs: Add Props for Ember ([#9067](https://github.com/storybookjs/storybook/pull/9067))\n* MDX: Handle quotes / template literals in title ([#9069](https://github.com/storybookjs/storybook/pull/9069))\n\n### Bug Fixes\n\n* Addon-docs: MDX Octicon anchors should not be tabbable ([#9063](https://github.com/storybookjs/storybook/pull/9063))\n\n### Dependency Upgrades\n\n* Addon-docs: Upgrade vue-docgen-loader ([#9082](https://github.com/storybookjs/storybook/pull/9082))"}} \ No newline at end of file +{"version":"5.3.0-beta.19","info":{"plain":"### Features\n\n* Addon-essentials ([#9019](https://github.com/storybookjs/storybook/pull/9019))\n\n### Bug Fixes\n\n* Addon-docs: Fix prop table default value for web-components ([#9086](https://github.com/storybookjs/storybook/pull/9086))"}} \ No newline at end of file From d9fad400a1bfe7360eb3b54494d157e6b2a21d4e Mon Sep 17 00:00:00 2001 From: Shota Fuji Date: Sat, 7 Dec 2019 08:40:12 +0000 Subject: [PATCH 072/132] Source-loader: Support function declaration exports Added support for named exports with function declaration in source-loader, in order to fix that the story's source code doesn't show up in Docs mode's code preview. The changes in generate-helpers.js is necessary because we can't wrap named export functions: ``` export function foo() {} // turns into this if we just wrapped it export wrapper(function foo() {}) // syntax error! ``` --- __mocks__/inject-decorator.ts.csf.txt | 10 +++ .../inject-decorator.csf.test.js.snap | 14 +++- .../abstract-syntax-tree/generate-helpers.js | 6 +- .../abstract-syntax-tree/traverse-helpers.js | 69 ++++++++++++++----- 4 files changed, 79 insertions(+), 20 deletions(-) diff --git a/__mocks__/inject-decorator.ts.csf.txt b/__mocks__/inject-decorator.ts.csf.txt index 47e60534ac8..27b5a65e36f 100644 --- a/__mocks__/inject-decorator.ts.csf.txt +++ b/__mocks__/inject-decorator.ts.csf.txt @@ -17,3 +17,13 @@ export const emoji = () => ( ); + +export function emojiFn() { + return ( + + ) +}; diff --git a/lib/source-loader/src/server/abstract-syntax-tree/__snapshots__/inject-decorator.csf.test.js.snap b/lib/source-loader/src/server/abstract-syntax-tree/__snapshots__/inject-decorator.csf.test.js.snap index 3721312e035..f686ff20b33 100644 --- a/lib/source-loader/src/server/abstract-syntax-tree/__snapshots__/inject-decorator.csf.test.js.snap +++ b/lib/source-loader/src/server/abstract-syntax-tree/__snapshots__/inject-decorator.csf.test.js.snap @@ -5,7 +5,7 @@ exports[`inject-decorator positive - ts - csf includes storySource parameter in import { action } from \\"@storybook/addon-actions\\"; import { Button } from \\"@storybook/react/demo\\"; -export default {parameters: {\\"storySource\\":{\\"source\\":\\"import React from \\\\\\"react\\\\\\";\\\\nimport { action } from \\\\\\"@storybook/addon-actions\\\\\\";\\\\nimport { Button } from \\\\\\"@storybook/react/demo\\\\\\";\\\\n\\\\nexport default {\\\\n title: \\\\\\"Button\\\\\\"\\\\n};\\\\n\\\\nexport const text = () => (\\\\n \\\\n);\\\\n\\\\nexport const emoji = () => (\\\\n \\\\n);\\\\n\\",\\"locationsMap\\":{\\"button--text\\":{\\"startLoc\\":{\\"col\\":20,\\"line\\":9},\\"endLoc\\":{\\"col\\":1,\\"line\\":11},\\"startBody\\":{\\"col\\":20,\\"line\\":9},\\"endBody\\":{\\"col\\":1,\\"line\\":11}},\\"button--emoji\\":{\\"startLoc\\":{\\"col\\":21,\\"line\\":13},\\"endLoc\\":{\\"col\\":1,\\"line\\":19},\\"startBody\\":{\\"col\\":21,\\"line\\":13},\\"endBody\\":{\\"col\\":1,\\"line\\":19}}}},}, +export default {parameters: {\\"storySource\\":{\\"source\\":\\"import React from \\\\\\"react\\\\\\";\\\\nimport { action } from \\\\\\"@storybook/addon-actions\\\\\\";\\\\nimport { Button } from \\\\\\"@storybook/react/demo\\\\\\";\\\\n\\\\nexport default {\\\\n title: \\\\\\"Button\\\\\\"\\\\n};\\\\n\\\\nexport const text = () => (\\\\n \\\\n);\\\\n\\\\nexport const emoji = () => (\\\\n \\\\n);\\\\n\\\\nexport function emojiFn() {\\\\n return (\\\\n \\\\n )\\\\n};\\\\n\\",\\"locationsMap\\":{\\"button--text\\":{\\"startLoc\\":{\\"col\\":20,\\"line\\":9},\\"endLoc\\":{\\"col\\":1,\\"line\\":11},\\"startBody\\":{\\"col\\":20,\\"line\\":9},\\"endBody\\":{\\"col\\":1,\\"line\\":11}},\\"button--emoji\\":{\\"startLoc\\":{\\"col\\":21,\\"line\\":13},\\"endLoc\\":{\\"col\\":1,\\"line\\":19},\\"startBody\\":{\\"col\\":21,\\"line\\":13},\\"endBody\\":{\\"col\\":1,\\"line\\":19}},\\"button--emoji-fn\\":{\\"startLoc\\":{\\"col\\":7,\\"line\\":21},\\"endLoc\\":{\\"col\\":1,\\"line\\":29},\\"startBody\\":{\\"col\\":7,\\"line\\":21},\\"endBody\\":{\\"col\\":1,\\"line\\":29}}}},}, title: \\"Button\\" }; @@ -19,6 +19,16 @@ export const emoji = addSourceDecorator(() => ( 😀 😎 👍 💯 -), {__STORY__, __ADDS_MAP__,__MAIN_FILE_LOCATION__,__MODULE_DEPENDENCIES__,__LOCAL_DEPENDENCIES__,__SOURCE_PREFIX__,__IDS_TO_FRAMEWORKS__}); +), {__STORY__, __ADDS_MAP__,__MAIN_FILE_LOCATION__,__MODULE_DEPENDENCIES__,__LOCAL_DEPENDENCIES__,__SOURCE_PREFIX__,__IDS_TO_FRAMEWORKS__});; + +export const emojiFn = addSourceDecorator(function emojiFn() { + return ( + + ) +}, {__STORY__, __ADDS_MAP__,__MAIN_FILE_LOCATION__,__MODULE_DEPENDENCIES__,__LOCAL_DEPENDENCIES__,__SOURCE_PREFIX__,__IDS_TO_FRAMEWORKS__}); " `; diff --git a/lib/source-loader/src/server/abstract-syntax-tree/generate-helpers.js b/lib/source-loader/src/server/abstract-syntax-tree/generate-helpers.js index 4f1ec791427..5c77a0b0846 100644 --- a/lib/source-loader/src/server/abstract-syntax-tree/generate-helpers.js +++ b/lib/source-loader/src/server/abstract-syntax-tree/generate-helpers.js @@ -68,7 +68,9 @@ const STORY_DECORATOR_STATEMENT = const ADD_PARAMETERS_STATEMENT = '.addParameters({ storySource: { source: __STORY__, locationsMap: __ADDS_MAP__ } })'; const applyExportDecoratorStatement = part => - ` addSourceDecorator(${part}, {__STORY__, __ADDS_MAP__,__MAIN_FILE_LOCATION__,__MODULE_DEPENDENCIES__,__LOCAL_DEPENDENCIES__,__SOURCE_PREFIX__,__IDS_TO_FRAMEWORKS__});`; + part.declaration.isVariableDeclaration + ? ` addSourceDecorator(${part.source}, {__STORY__, __ADDS_MAP__,__MAIN_FILE_LOCATION__,__MODULE_DEPENDENCIES__,__LOCAL_DEPENDENCIES__,__SOURCE_PREFIX__,__IDS_TO_FRAMEWORKS__});` + : ` const ${part.declaration.ident} = addSourceDecorator(${part.source}, {__STORY__, __ADDS_MAP__,__MAIN_FILE_LOCATION__,__MODULE_DEPENDENCIES__,__LOCAL_DEPENDENCIES__,__SOURCE_PREFIX__,__IDS_TO_FRAMEWORKS__});`; export function generateSourceWithDecorators(source, ast, withParameters) { const { comments = [] } = ast; @@ -91,7 +93,7 @@ export function generateSourceWithDecorators(source, ast, withParameters) { const partsUsingExports = splitExports(ast, source); const newSource = partsUsingExports - .map((part, i) => (i % 2 === 0 ? part : applyExportDecoratorStatement(part))) + .map((part, i) => (i % 2 === 0 ? part.source : applyExportDecoratorStatement(part))) .join(''); return { diff --git a/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js b/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js index be8ba109600..053235a50c6 100644 --- a/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js +++ b/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js @@ -28,9 +28,11 @@ export function splitExports(ast, source) { fallback: 'iteration', enter: node => { patchNode(node); - if ( - node.type === 'ExportNamedDeclaration' && - node.declaration && + + const isNamedExport = node.type === 'ExportNamedDeclaration' && node.declaration; + + const isFunctionVariableExport = + isNamedExport && node.declaration.declarations && node.declaration.declarations.length === 1 && node.declaration.declarations[0].type === 'VariableDeclarator' && @@ -39,17 +41,36 @@ export function splitExports(ast, source) { node.declaration.declarations[0].init && ['CallExpression', 'ArrowFunctionExpression', 'FunctionExpression'].includes( node.declaration.declarations[0].init.type - ) - ) { - const functionNode = node.declaration.declarations[0].init; - parts.push(source.substring(lastIndex, functionNode.start - 1)); - parts.push(source.substring(functionNode.start, functionNode.end)); + ); + + const isFunctionDeclarationExport = + isNamedExport && + node.declaration.type === 'FunctionDeclaration' && + node.declaration.id && + node.declaration.id.name; + + if (isFunctionDeclarationExport || isFunctionVariableExport) { + const functionNode = isFunctionVariableExport + ? node.declaration.declarations[0].init + : node.declaration; + parts.push({ + source: source.substring(lastIndex, functionNode.start - 1), + }); + parts.push({ + source: source.substring(functionNode.start, functionNode.end), + declaration: { + isVariableDeclaration: isFunctionVariableExport, + ident: isFunctionVariableExport + ? node.declaration.declarations[0].id.name + : functionNode.id.name, + }, + }); lastIndex = functionNode.end; } }, }); - if (source.length > lastIndex + 1) parts.push(source.substring(lastIndex + 1)); + if (source.length > lastIndex + 1) parts.push({ source: source.substring(lastIndex + 1) }); if (parts.length === 1) return [source]; return parts; } @@ -110,9 +131,11 @@ export function findExportsMap(ast) { fallback: 'iteration', enter: node => { patchNode(node); - if ( - node.type === 'ExportNamedDeclaration' && - node.declaration && + + const isNamedExport = node.type === 'ExportNamedDeclaration' && node.declaration; + + const isFunctionVariableExport = + isNamedExport && node.declaration.declarations && node.declaration.declarations.length === 1 && node.declaration.declarations[0].type === 'VariableDeclarator' && @@ -121,10 +144,24 @@ export function findExportsMap(ast) { node.declaration.declarations[0].init && ['CallExpression', 'ArrowFunctionExpression', 'FunctionExpression'].includes( node.declaration.declarations[0].init.type - ) - ) { - const storyName = storyNameFromExport(node.declaration.declarations[0].id.name); - const toAdd = handleExportedName(title, storyName, node.declaration.declarations[0].init); + ); + + const isFunctionDeclarationExport = + isNamedExport && + node.declaration.type === 'FunctionDeclaration' && + node.declaration.id && + node.declaration.id.name; + + if (isFunctionDeclarationExport || isFunctionVariableExport) { + const exportDeclaration = isFunctionVariableExport + ? node.declaration.declarations[0] + : node.declaration; + const storyName = storyNameFromExport(exportDeclaration.id.name); + const toAdd = handleExportedName( + title, + storyName, + exportDeclaration.init || exportDeclaration + ); Object.assign(addsMap, toAdd); } }, From 6f81b2d0b072749ae388adc19fab8bb69a86b61e Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Sat, 7 Dec 2019 22:49:45 +0800 Subject: [PATCH 073/132] Addon-essentials: Remove docs from essentials --- addons/essentials/package.json | 1 - addons/essentials/src/index.ts | 3 +-- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/addons/essentials/package.json b/addons/essentials/package.json index c11a6f0bec4..6dd44c19c7b 100644 --- a/addons/essentials/package.json +++ b/addons/essentials/package.json @@ -29,7 +29,6 @@ "dependencies": { "@storybook/addon-actions": "5.3.0-beta.19", "@storybook/addon-backgrounds": "5.3.0-beta.19", - "@storybook/addon-docs": "5.3.0-beta.19", "@storybook/addon-knobs": "5.3.0-beta.19", "@storybook/addon-links": "5.3.0-beta.19", "@storybook/addon-viewport": "5.3.0-beta.19", diff --git a/addons/essentials/src/index.ts b/addons/essentials/src/index.ts index 6f823726a56..e54700b9284 100644 --- a/addons/essentials/src/index.ts +++ b/addons/essentials/src/index.ts @@ -4,7 +4,6 @@ import { logger } from '@storybook/node-logger'; type PresetOptions = { actions?: any; backgrounds?: any; - docs?: any; knobs?: any; links?: any; viewport?: any; @@ -27,7 +26,7 @@ const isInstalled = (addon: string) => { const makeAddon = (key: string) => `@storybook/addon-${key}`; export function presets(options: PresetOptions = {}) { - const presetAddons = ['docs', 'knobs'] + const presetAddons = ['knobs'] .filter(key => (options as any)[key] !== false) .map(key => makeAddon(key)) .filter(addon => !isInstalled(addon)) From b4363393766230e5d9f702a8a0d6cc5b72a8d754 Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Mon, 9 Dec 2019 12:16:01 +0800 Subject: [PATCH 074/132] Refactor router utils into CSF library --- addons/docs/package.json | 2 +- addons/docs/src/blocks/Title.tsx | 2 +- addons/docs/src/mdx/mdx-compiler-plugin.js | 2 +- addons/links/package.json | 1 + addons/links/src/preview.ts | 2 +- .../storyshots-puppeteer/package.json | 2 +- .../storyshots-puppeteer/src/url.ts | 2 +- lib/api/package.json | 1 + lib/api/src/modules/stories.ts | 2 +- lib/api/src/modules/url.ts | 2 +- lib/client-api/package.json | 2 +- lib/client-api/src/client_api.ts | 2 +- lib/client-api/src/story_store.test.ts | 2 +- lib/codemod/package.json | 2 +- lib/codemod/src/transforms/csf-to-mdx.js | 15 +--- .../src/transforms/storiesof-to-csf.js | 2 +- lib/core/package.json | 1 + lib/core/src/client/preview/index.js | 2 +- lib/core/src/client/preview/start.js | 18 +---- lib/core/src/client/preview/start.test.js | 40 +---------- lib/core/src/client/preview/url.js | 2 +- lib/csf/README.md | 3 + lib/csf/package.json | 35 ++++++++++ .../utils.test.js => csf/src/index.test.ts} | 40 ++++++++++- lib/csf/src/index.ts | 69 +++++++++++++++++++ lib/csf/tsconfig.json | 8 +++ lib/router/package.json | 1 + lib/router/src/utils.ts | 44 ------------ lib/source-loader/package.json | 2 +- .../abstract-syntax-tree/parse-helpers.js | 2 +- .../abstract-syntax-tree/traverse-helpers.js | 4 +- lib/ui/paths.js | 1 + 32 files changed, 182 insertions(+), 133 deletions(-) create mode 100644 lib/csf/README.md create mode 100644 lib/csf/package.json rename lib/{router/src/utils.test.js => csf/src/index.test.ts} (50%) create mode 100644 lib/csf/src/index.ts create mode 100644 lib/csf/tsconfig.json diff --git a/addons/docs/package.json b/addons/docs/package.json index c0983b6c103..78435fc1b02 100644 --- a/addons/docs/package.json +++ b/addons/docs/package.json @@ -48,8 +48,8 @@ "@storybook/addons": "5.3.0-beta.19", "@storybook/api": "5.3.0-beta.19", "@storybook/components": "5.3.0-beta.19", + "@storybook/csf": "5.3.0-beta.19", "@storybook/postinstall": "5.3.0-beta.19", - "@storybook/router": "5.3.0-beta.19", "@storybook/source-loader": "5.3.0-beta.19", "@storybook/theming": "5.3.0-beta.19", "acorn": "^7.1.0", diff --git a/addons/docs/src/blocks/Title.tsx b/addons/docs/src/blocks/Title.tsx index a670600d6e2..527b34b3d94 100644 --- a/addons/docs/src/blocks/Title.tsx +++ b/addons/docs/src/blocks/Title.tsx @@ -1,5 +1,5 @@ import React, { useContext, FunctionComponent } from 'react'; -import { parseKind } from '@storybook/router'; +import { parseKind } from '@storybook/csf'; import { Title as PureTitle } from '@storybook/components'; import { DocsContext } from './DocsContext'; import { StringSlot } from './shared'; diff --git a/addons/docs/src/mdx/mdx-compiler-plugin.js b/addons/docs/src/mdx/mdx-compiler-plugin.js index 85ef5c38731..518a6493e25 100644 --- a/addons/docs/src/mdx/mdx-compiler-plugin.js +++ b/addons/docs/src/mdx/mdx-compiler-plugin.js @@ -3,7 +3,7 @@ const parser = require('@babel/parser'); const generate = require('@babel/generator').default; const camelCase = require('lodash/camelCase'); const jsStringEscape = require('js-string-escape'); -const { toId, storyNameFromExport } = require('@storybook/router/utils'); +const { toId, storyNameFromExport } = require('@storybook/csf'); // Generate the MDX as is, but append named exports for every // story in the contents diff --git a/addons/links/package.json b/addons/links/package.json index 60505872543..7e99b7c8399 100644 --- a/addons/links/package.json +++ b/addons/links/package.json @@ -32,6 +32,7 @@ "@storybook/addons": "5.3.0-beta.19", "@storybook/client-logger": "5.3.0-beta.19", "@storybook/core-events": "5.3.0-beta.19", + "@storybook/csf": "5.3.0-beta.19", "@storybook/router": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", diff --git a/addons/links/src/preview.ts b/addons/links/src/preview.ts index 779ab5633b0..0aeb0ebd9ed 100644 --- a/addons/links/src/preview.ts +++ b/addons/links/src/preview.ts @@ -7,7 +7,7 @@ import { import qs from 'qs'; import addons from '@storybook/addons'; import { STORY_CHANGED, SELECT_STORY } from '@storybook/core-events'; -import { toId } from '@storybook/router/utils'; +import { toId } from '@storybook/csf'; import { logger } from '@storybook/client-logger'; interface ParamsId { diff --git a/addons/storyshots/storyshots-puppeteer/package.json b/addons/storyshots/storyshots-puppeteer/package.json index 1694ce9ade7..a0672f22f62 100644 --- a/addons/storyshots/storyshots-puppeteer/package.json +++ b/addons/storyshots/storyshots-puppeteer/package.json @@ -30,8 +30,8 @@ }, "dependencies": { "@hypnosphi/jest-puppeteer-axe": "^1.4.0", + "@storybook/csf": "5.3.0-beta.19", "@storybook/node-logger": "5.3.0-beta.19", - "@storybook/router": "5.3.0-beta.19", "@types/jest-image-snapshot": "^2.8.0", "core-js": "^3.0.1", "jest-image-snapshot": "^2.8.2", diff --git a/addons/storyshots/storyshots-puppeteer/src/url.ts b/addons/storyshots/storyshots-puppeteer/src/url.ts index 1104bb80bec..6c5a1eaef64 100644 --- a/addons/storyshots/storyshots-puppeteer/src/url.ts +++ b/addons/storyshots/storyshots-puppeteer/src/url.ts @@ -1,4 +1,4 @@ -import { toId } from '@storybook/router/utils'; +import { toId } from '@storybook/csf'; import { URL } from 'url'; diff --git a/lib/api/package.json b/lib/api/package.json index 2471264c57f..3de0fa8dade 100644 --- a/lib/api/package.json +++ b/lib/api/package.json @@ -29,6 +29,7 @@ "@storybook/channels": "5.3.0-beta.19", "@storybook/client-logger": "5.3.0-beta.19", "@storybook/core-events": "5.3.0-beta.19", + "@storybook/csf": "5.3.0-beta.19", "@storybook/router": "5.3.0-beta.19", "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", diff --git a/lib/api/src/modules/stories.ts b/lib/api/src/modules/stories.ts index e41556d914a..afdffa2b169 100644 --- a/lib/api/src/modules/stories.ts +++ b/lib/api/src/modules/stories.ts @@ -1,5 +1,5 @@ // FIXME: we shouldn't import from dist but there are no types otherwise -import { toId, sanitize, parseKind } from '@storybook/router'; +import { toId, sanitize, parseKind } from '@storybook/csf'; import deprecate from 'util-deprecate'; import { Module } from '../index'; diff --git a/lib/api/src/modules/url.ts b/lib/api/src/modules/url.ts index 735dbf12274..6aec64d905f 100644 --- a/lib/api/src/modules/url.ts +++ b/lib/api/src/modules/url.ts @@ -1,5 +1,5 @@ import { queryFromLocation } from '@storybook/router'; -import { toId } from '@storybook/router/dist/utils'; +import { toId } from '@storybook/csf'; import { Module } from '../index'; import { PanelPositions } from './layout'; diff --git a/lib/client-api/package.json b/lib/client-api/package.json index 1d905f00361..83a103e1726 100644 --- a/lib/client-api/package.json +++ b/lib/client-api/package.json @@ -32,7 +32,7 @@ "@storybook/channels": "5.3.0-beta.19", "@storybook/client-logger": "5.3.0-beta.19", "@storybook/core-events": "5.3.0-beta.19", - "@storybook/router": "5.3.0-beta.19", + "@storybook/csf": "5.3.0-beta.19", "core-js": "^3.0.1", "eventemitter3": "^4.0.0", "global": "^4.3.2", diff --git a/lib/client-api/src/client_api.ts b/lib/client-api/src/client_api.ts index 67ca6dc77f0..af2c9db0844 100644 --- a/lib/client-api/src/client_api.ts +++ b/lib/client-api/src/client_api.ts @@ -4,7 +4,7 @@ import isPlainObject from 'is-plain-object'; import { logger } from '@storybook/client-logger'; import addons, { StoryContext, StoryFn, Parameters } from '@storybook/addons'; import Events from '@storybook/core-events'; -import { toId } from '@storybook/router/utils'; +import { toId } from '@storybook/csf'; import mergeWith from 'lodash/mergeWith'; import isEqual from 'lodash/isEqual'; diff --git a/lib/client-api/src/story_store.test.ts b/lib/client-api/src/story_store.test.ts index 96baf327023..30c5bf5b6de 100644 --- a/lib/client-api/src/story_store.test.ts +++ b/lib/client-api/src/story_store.test.ts @@ -1,5 +1,5 @@ import createChannel from '@storybook/channel-postmessage'; -import { toId } from '@storybook/router/utils'; +import { toId } from '@storybook/csf'; import addons from '@storybook/addons'; import StoryStore from './story_store'; diff --git a/lib/codemod/package.json b/lib/codemod/package.json index 03631e9673c..b2b59ca5376 100644 --- a/lib/codemod/package.json +++ b/lib/codemod/package.json @@ -29,8 +29,8 @@ "dependencies": { "@hypnosphi/jscodeshift": "^0.6.4", "@mdx-js/mdx": "^1.5.1", + "@storybook/csf": "5.3.0-beta.19", "@storybook/node-logger": "5.3.0-beta.19", - "@storybook/router": "5.3.0-beta.19", "core-js": "^3.0.1", "cross-spawn": "^7.0.0", "globby": "^10.0.1", diff --git a/lib/codemod/src/transforms/csf-to-mdx.js b/lib/codemod/src/transforms/csf-to-mdx.js index fffa371bfc7..020426e1ba3 100644 --- a/lib/codemod/src/transforms/csf-to-mdx.js +++ b/lib/codemod/src/transforms/csf-to-mdx.js @@ -1,18 +1,5 @@ import recast from 'recast'; - -// FIXME: duplicate code from @storybook/core start.js -function isExportStory(key, { includeStories, excludeStories }) { - function matches(storyKey, arrayOrRegex) { - if (Array.isArray(arrayOrRegex)) { - return arrayOrRegex.includes(storyKey); - } - return storyKey.match(arrayOrRegex); - } - return ( - (!includeStories || matches(key, includeStories)) && - (!excludeStories || !matches(key, excludeStories)) - ); -} +import { isExportStory } from '@storybook/csf'; function exportMdx(root, options) { // eslint-disable-next-line no-underscore-dangle diff --git a/lib/codemod/src/transforms/storiesof-to-csf.js b/lib/codemod/src/transforms/storiesof-to-csf.js index 482cf6819a7..77e46900cdc 100644 --- a/lib/codemod/src/transforms/storiesof-to-csf.js +++ b/lib/codemod/src/transforms/storiesof-to-csf.js @@ -1,6 +1,6 @@ import prettier from 'prettier'; import { logger } from '@storybook/node-logger'; -import { storyNameFromExport } from '@storybook/router'; +import { storyNameFromExport } from '@storybook/csf'; import { sanitizeName } from '../lib/utils'; /** diff --git a/lib/core/package.json b/lib/core/package.json index 64a277b048c..1c3b3256525 100644 --- a/lib/core/package.json +++ b/lib/core/package.json @@ -37,6 +37,7 @@ "@storybook/client-api": "5.3.0-beta.19", "@storybook/client-logger": "5.3.0-beta.19", "@storybook/core-events": "5.3.0-beta.19", + "@storybook/csf": "5.3.0-beta.19", "@storybook/node-logger": "5.3.0-beta.19", "@storybook/router": "5.3.0-beta.19", "@storybook/theming": "5.3.0-beta.19", diff --git a/lib/core/src/client/preview/index.js b/lib/core/src/client/preview/index.js index 5fd9ec35687..0197cec7d3b 100644 --- a/lib/core/src/client/preview/index.js +++ b/lib/core/src/client/preview/index.js @@ -1,5 +1,5 @@ import { ClientApi, StoryStore, ConfigApi } from '@storybook/client-api'; -import { toId } from '@storybook/router/utils'; +import { toId } from '@storybook/csf'; import start from './start'; export default { diff --git a/lib/core/src/client/preview/start.js b/lib/core/src/client/preview/start.js index 9318203dae5..89d2b96ec79 100644 --- a/lib/core/src/client/preview/start.js +++ b/lib/core/src/client/preview/start.js @@ -7,7 +7,7 @@ import AnsiToHtml from 'ansi-to-html'; import addons from '@storybook/addons'; import createChannel from '@storybook/channel-postmessage'; import { ClientApi, StoryStore, ConfigApi } from '@storybook/client-api'; -import { toId, storyNameFromExport } from '@storybook/router/utils'; +import { toId, storyNameFromExport, isExportStory } from '@storybook/csf'; import { logger } from '@storybook/client-logger'; import Events from '@storybook/core-events'; @@ -24,22 +24,6 @@ const classes = { ERROR: 'sb-show-errordisplay', }; -function matches(storyKey, arrayOrRegex) { - if (Array.isArray(arrayOrRegex)) { - return arrayOrRegex.includes(storyKey); - } - return storyKey.match(arrayOrRegex); -} - -export function isExportStory(key, { includeStories, excludeStories }) { - return ( - // https://babeljs.io/docs/en/babel-plugin-transform-modules-commonjs - key !== '__esModule' && - (!includeStories || matches(key, includeStories)) && - (!excludeStories || !matches(key, excludeStories)) - ); -} - function showMain() { document.body.classList.remove(classes.NOPREVIEW); document.body.classList.remove(classes.ERROR); diff --git a/lib/core/src/client/preview/start.test.js b/lib/core/src/client/preview/start.test.js index 4b64ec026b4..bf56348e50f 100644 --- a/lib/core/src/client/preview/start.test.js +++ b/lib/core/src/client/preview/start.test.js @@ -2,7 +2,7 @@ import { history, document, window } from 'global'; import Events from '@storybook/core-events'; -import start, { isExportStory } from './start'; +import start from './start'; jest.mock('@storybook/client-logger'); jest.mock('global', () => ({ @@ -143,41 +143,3 @@ describe('STORY_INIT', () => { expect(store.setSelection).toHaveBeenCalledWith({ storyId: 'kind--story' }); }); }); - -describe('story filters for module exports', () => { - it('should exclude __esModule', () => { - expect(isExportStory('__esModule', {})).toBeFalsy(); - }); - - it('should include all stories when there are no filters', () => { - expect(isExportStory('a', {})).toBeTruthy(); - }); - - it('should filter stories by arrays', () => { - expect(isExportStory('a', { includeStories: ['a'] })).toBeTruthy(); - expect(isExportStory('a', { includeStories: [] })).toBeFalsy(); - expect(isExportStory('a', { includeStories: ['b'] })).toBeFalsy(); - - expect(isExportStory('a', { excludeStories: ['a'] })).toBeFalsy(); - expect(isExportStory('a', { excludeStories: [] })).toBeTruthy(); - expect(isExportStory('a', { excludeStories: ['b'] })).toBeTruthy(); - - expect(isExportStory('a', { includeStories: ['a'], excludeStories: ['a'] })).toBeFalsy(); - expect(isExportStory('a', { includeStories: [], excludeStories: [] })).toBeFalsy(); - expect(isExportStory('a', { includeStories: ['a'], excludeStories: ['b'] })).toBeTruthy(); - }); - - it('should filter stories by regex', () => { - expect(isExportStory('a', { includeStories: /a/ })).toBeTruthy(); - expect(isExportStory('a', { includeStories: /.*/ })).toBeTruthy(); - expect(isExportStory('a', { includeStories: /b/ })).toBeFalsy(); - - expect(isExportStory('a', { excludeStories: /a/ })).toBeFalsy(); - expect(isExportStory('a', { excludeStories: /.*/ })).toBeFalsy(); - expect(isExportStory('a', { excludeStories: /b/ })).toBeTruthy(); - - expect(isExportStory('a', { includeStories: /a/, excludeStories: ['a'] })).toBeFalsy(); - expect(isExportStory('a', { includeStories: /.*/, excludeStories: /.*/ })).toBeFalsy(); - expect(isExportStory('a', { includeStories: /a/, excludeStories: /b/ })).toBeTruthy(); - }); -}); diff --git a/lib/core/src/client/preview/url.js b/lib/core/src/client/preview/url.js index 47daf2130de..93f81c42678 100644 --- a/lib/core/src/client/preview/url.js +++ b/lib/core/src/client/preview/url.js @@ -1,6 +1,6 @@ import { history, document } from 'global'; import qs from 'qs'; -import { toId } from '@storybook/router/utils'; +import { toId } from '@storybook/csf'; export function pathToId(path) { const match = (path || '').match(/^\/story\/(.+)/); diff --git a/lib/csf/README.md b/lib/csf/README.md new file mode 100644 index 00000000000..1a00256d0d8 --- /dev/null +++ b/lib/csf/README.md @@ -0,0 +1,3 @@ +# Storybook CSF + +A minimal set of utility functions for dealing with Storybook [Component Story Format](https://storybook.js.org/docs/formats/component-story-format/). diff --git a/lib/csf/package.json b/lib/csf/package.json new file mode 100644 index 00000000000..eca8941066d --- /dev/null +++ b/lib/csf/package.json @@ -0,0 +1,35 @@ +{ + "name": "@storybook/csf", + "version": "5.3.0-beta.19", + "description": "", + "keywords": [ + "storybook" + ], + "homepage": "https://github.com/storybookjs/storybook/tree/master/lib/csf", + "bugs": { + "url": "https://github.com/storybookjs/storybook/issues" + }, + "repository": { + "type": "git", + "url": "https://github.com/storybookjs/storybook.git", + "directory": "lib/csf" + }, + "license": "MIT", + "files": [ + "dist/**/*", + "README.md", + "*.js", + "*.d.ts" + ], + "main": "dist/index.js", + "types": "dist/index.d.ts", + "scripts": { + "prepare": "node ../../scripts/prepare.js" + }, + "dependencies": { + "lodash": "^4.17.15" + }, + "publishConfig": { + "access": "public" + } +} diff --git a/lib/router/src/utils.test.js b/lib/csf/src/index.test.ts similarity index 50% rename from lib/router/src/utils.test.js rename to lib/csf/src/index.test.ts index 57a9bf40edf..27d0095039b 100644 --- a/lib/router/src/utils.test.js +++ b/lib/csf/src/index.test.ts @@ -1,4 +1,4 @@ -import { toId, storyNameFromExport } from './utils'; +import { toId, storyNameFromExport, isExportStory } from '.'; describe('toId', () => { [ @@ -51,3 +51,41 @@ describe('storyNameFromExport', () => { Object.entries(testCases).forEach(([key, val]) => expect(storyNameFromExport(key)).toBe(val)); }); }); + +describe('isExportStory', () => { + it('should exclude __esModule', () => { + expect(isExportStory('__esModule', {})).toBeFalsy(); + }); + + it('should include all stories when there are no filters', () => { + expect(isExportStory('a', {})).toBeTruthy(); + }); + + it('should filter stories by arrays', () => { + expect(isExportStory('a', { includeStories: ['a'] })).toBeTruthy(); + expect(isExportStory('a', { includeStories: [] })).toBeFalsy(); + expect(isExportStory('a', { includeStories: ['b'] })).toBeFalsy(); + + expect(isExportStory('a', { excludeStories: ['a'] })).toBeFalsy(); + expect(isExportStory('a', { excludeStories: [] })).toBeTruthy(); + expect(isExportStory('a', { excludeStories: ['b'] })).toBeTruthy(); + + expect(isExportStory('a', { includeStories: ['a'], excludeStories: ['a'] })).toBeFalsy(); + expect(isExportStory('a', { includeStories: [], excludeStories: [] })).toBeFalsy(); + expect(isExportStory('a', { includeStories: ['a'], excludeStories: ['b'] })).toBeTruthy(); + }); + + it('should filter stories by regex', () => { + expect(isExportStory('a', { includeStories: /a/ })).toBeTruthy(); + expect(isExportStory('a', { includeStories: /.*/ })).toBeTruthy(); + expect(isExportStory('a', { includeStories: /b/ })).toBeFalsy(); + + expect(isExportStory('a', { excludeStories: /a/ })).toBeFalsy(); + expect(isExportStory('a', { excludeStories: /.*/ })).toBeFalsy(); + expect(isExportStory('a', { excludeStories: /b/ })).toBeTruthy(); + + expect(isExportStory('a', { includeStories: /a/, excludeStories: ['a'] })).toBeFalsy(); + expect(isExportStory('a', { includeStories: /.*/, excludeStories: /.*/ })).toBeFalsy(); + expect(isExportStory('a', { includeStories: /a/, excludeStories: /b/ })).toBeTruthy(); + }); +}); diff --git a/lib/csf/src/index.ts b/lib/csf/src/index.ts new file mode 100644 index 00000000000..23a03a6cbc3 --- /dev/null +++ b/lib/csf/src/index.ts @@ -0,0 +1,69 @@ +import startCase from 'lodash/startCase'; + +// Remove punctuation https://gist.github.com/davidjrice/9d2af51100e41c6c4b4a +export const sanitize = (string: string) => { + return ( + string + .toLowerCase() + // eslint-disable-next-line no-useless-escape + .replace(/[ ’–—―′¿'`~!@#$%^&*()_|+\-=?;:'",.<>\{\}\[\]\\\/]/gi, '-') + .replace(/-+/g, '-') + .replace(/^-+/, '') + .replace(/-+$/, '') + ); +}; + +const sanitizeSafe = (string: string, part: string) => { + const sanitized = sanitize(string); + if (sanitized === '') { + throw new Error(`Invalid ${part} '${string}', must include alphanumeric characters`); + } + return sanitized; +}; + +export const toId = (kind: string, name: string) => + `${sanitizeSafe(kind, 'kind')}--${sanitizeSafe(name, 'name')}`; + +// Transform the CSF named export into a readable story name +export const storyNameFromExport = (key: string) => startCase(key); + +type StoryDescriptor = string[] | RegExp; +export interface IncludeExcludeOptions { + includeStories?: StoryDescriptor; + excludeStories?: StoryDescriptor; +} + +function matches(storyKey: string, arrayOrRegex?: StoryDescriptor) { + if (Array.isArray(arrayOrRegex)) { + return arrayOrRegex.includes(storyKey); + } + return storyKey.match(arrayOrRegex); +} + +export function isExportStory( + key: string, + { includeStories, excludeStories }: IncludeExcludeOptions +) { + return ( + // https://babeljs.io/docs/en/babel-plugin-transform-modules-commonjs + key !== '__esModule' && + (!includeStories || matches(key, includeStories)) && + (!excludeStories || !matches(key, excludeStories)) + ); +} + +interface SeparatorOptions { + rootSeparator: string | RegExp; + groupSeparator: string | RegExp; +} + +export const parseKind = (kind: string, { rootSeparator, groupSeparator }: SeparatorOptions) => { + const [root, remainder] = kind.split(rootSeparator, 2); + const groups = (remainder || kind).split(groupSeparator).filter(i => !!i); + + // when there's no remainder, it means the root wasn't found/split + return { + root: remainder ? root : null, + groups, + }; +}; diff --git a/lib/csf/tsconfig.json b/lib/csf/tsconfig.json new file mode 100644 index 00000000000..a24ec639386 --- /dev/null +++ b/lib/csf/tsconfig.json @@ -0,0 +1,8 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "rootDir": "./src" + }, + "include": ["src/**/*"], + "exclude": ["src/**.test.ts"] +} diff --git a/lib/router/package.json b/lib/router/package.json index ea4ba628d19..daa280b27e9 100644 --- a/lib/router/package.json +++ b/lib/router/package.json @@ -28,6 +28,7 @@ }, "dependencies": { "@reach/router": "^1.2.1", + "@storybook/csf": "5.3.0-beta.19", "@types/reach__router": "^1.2.3", "core-js": "^3.0.1", "global": "^4.3.2", diff --git a/lib/router/src/utils.ts b/lib/router/src/utils.ts index c094db1d092..e3713abc3e4 100644 --- a/lib/router/src/utils.ts +++ b/lib/router/src/utils.ts @@ -1,43 +1,13 @@ import qs from 'qs'; import memoize from 'memoizerific'; -import startCase from 'lodash/startCase'; interface StoryData { viewMode?: string; storyId?: string; } -interface SeparatorOptions { - rootSeparator: string | RegExp; - groupSeparator: string | RegExp; -} - const splitPathRegex = /\/([^/]+)\/([^/]+)?/; -// Remove punctuation https://gist.github.com/davidjrice/9d2af51100e41c6c4b4a -export const sanitize = (string: string) => { - return ( - string - .toLowerCase() - // eslint-disable-next-line no-useless-escape - .replace(/[ ’–—―′¿'`~!@#$%^&*()_|+\-=?;:'",.<>\{\}\[\]\\\/]/gi, '-') - .replace(/-+/g, '-') - .replace(/^-+/, '') - .replace(/-+$/, '') - ); -}; - -const sanitizeSafe = (string: string, part: string) => { - const sanitized = sanitize(string); - if (sanitized === '') { - throw new Error(`Invalid ${part} '${string}', must include alphanumeric characters`); - } - return sanitized; -}; - -export const toId = (kind: string, name: string) => - `${sanitizeSafe(kind, 'kind')}--${sanitizeSafe(name, 'name')}`; - export const parsePath: (path?: string) => StoryData = memoize(1000)( (path: string | undefined | null) => { const result: StoryData = { @@ -83,17 +53,3 @@ export const getMatch = memoize(1000)((current: string, target: string, startsWi } return null; }); - -export const parseKind = (kind: string, { rootSeparator, groupSeparator }: SeparatorOptions) => { - const [root, remainder] = kind.split(rootSeparator, 2); - const groups = (remainder || kind).split(groupSeparator).filter(i => !!i); - - // when there's no remainder, it means the root wasn't found/split - return { - root: remainder ? root : null, - groups, - }; -}; - -// Transform the CSF named export into a readable story name -export const storyNameFromExport = (key: string) => startCase(key); diff --git a/lib/source-loader/package.json b/lib/source-loader/package.json index 379aaf7cdc4..a4af1c7dd26 100644 --- a/lib/source-loader/package.json +++ b/lib/source-loader/package.json @@ -30,7 +30,7 @@ "dependencies": { "@storybook/addons": "5.3.0-beta.19", "@storybook/client-logger": "5.3.0-beta.19", - "@storybook/router": "5.3.0-beta.19", + "@storybook/csf": "5.3.0-beta.19", "core-js": "^3.0.1", "estraverse": "^4.2.0", "global": "^4.3.2", diff --git a/lib/source-loader/src/server/abstract-syntax-tree/parse-helpers.js b/lib/source-loader/src/server/abstract-syntax-tree/parse-helpers.js index a96ed14b094..7da7f744c78 100644 --- a/lib/source-loader/src/server/abstract-syntax-tree/parse-helpers.js +++ b/lib/source-loader/src/server/abstract-syntax-tree/parse-helpers.js @@ -1,4 +1,4 @@ -const { toId } = require('@storybook/router/utils'); +const { toId } = require('@storybook/csf'); const STORIES_OF = 'storiesOf'; diff --git a/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js b/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js index 053235a50c6..1b35dab4f28 100644 --- a/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js +++ b/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js @@ -1,4 +1,4 @@ -import { storyNameFromExport } from '@storybook/router/utils'; +import { storyNameFromExport } from '@storybook/csf'; import { handleADD, handleSTORYOF, patchNode, handleExportedName } from './parse-helpers'; const estraverse = require('estraverse'); @@ -23,6 +23,8 @@ export function splitSTORYOF(ast, source) { export function splitExports(ast, source) { const parts = []; let lastIndex = 0; + const excludeStories = ['text']; + const includeStories = undefined; estraverse.traverse(ast, { fallback: 'iteration', diff --git a/lib/ui/paths.js b/lib/ui/paths.js index e14bef875a3..908c631d808 100644 --- a/lib/ui/paths.js +++ b/lib/ui/paths.js @@ -11,6 +11,7 @@ module.exports = { '@storybook/channels': dirname(resolve('@storybook/channels/package.json')), '@storybook/components': dirname(resolve('@storybook/components/package.json')), '@storybook/core-events': dirname(resolve('@storybook/core-events/package.json')), + '@storybook/csf': dirname(resolve('@storybook/csf/package.json')), '@storybook/router': dirname(resolve('@storybook/router/package.json')), '@storybook/theming': dirname(resolve('@storybook/theming/package.json')), '@storybook/ui': dirname(resolve('@storybook/ui/package.json')), From 022816d3f0ce9ab050c35b5d99c3921fa4f17458 Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Mon, 9 Dec 2019 12:25:26 +0800 Subject: [PATCH 075/132] Remove test code --- .../src/server/abstract-syntax-tree/traverse-helpers.js | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js b/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js index 1b35dab4f28..beebb7297ee 100644 --- a/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js +++ b/lib/source-loader/src/server/abstract-syntax-tree/traverse-helpers.js @@ -23,8 +23,6 @@ export function splitSTORYOF(ast, source) { export function splitExports(ast, source) { const parts = []; let lastIndex = 0; - const excludeStories = ['text']; - const includeStories = undefined; estraverse.traverse(ast, { fallback: 'iteration', From 267a47f4de8024358d305f906026818cfea7390a Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Mon, 9 Dec 2019 15:02:56 +0800 Subject: [PATCH 076/132] Extract @storybook/csf from monorepo --- addons/docs/package.json | 2 +- addons/links/package.json | 2 +- .../storyshots-puppeteer/package.json | 2 +- lib/api/package.json | 2 +- lib/client-api/package.json | 2 +- lib/codemod/package.json | 2 +- lib/core/package.json | 2 +- lib/csf/README.md | 3 - lib/csf/package.json | 35 ------- lib/csf/src/index.test.ts | 91 ------------------- lib/csf/src/index.ts | 69 -------------- lib/csf/tsconfig.json | 8 -- lib/router/package.json | 2 +- lib/source-loader/package.json | 2 +- yarn.lock | 7 ++ 15 files changed, 16 insertions(+), 215 deletions(-) delete mode 100644 lib/csf/README.md delete mode 100644 lib/csf/package.json delete mode 100644 lib/csf/src/index.test.ts delete mode 100644 lib/csf/src/index.ts delete mode 100644 lib/csf/tsconfig.json diff --git a/addons/docs/package.json b/addons/docs/package.json index 78435fc1b02..a2a5407a6b8 100644 --- a/addons/docs/package.json +++ b/addons/docs/package.json @@ -48,7 +48,7 @@ "@storybook/addons": "5.3.0-beta.19", "@storybook/api": "5.3.0-beta.19", "@storybook/components": "5.3.0-beta.19", - "@storybook/csf": "5.3.0-beta.19", + "@storybook/csf": "0.0.1", "@storybook/postinstall": "5.3.0-beta.19", "@storybook/source-loader": "5.3.0-beta.19", "@storybook/theming": "5.3.0-beta.19", diff --git a/addons/links/package.json b/addons/links/package.json index 7e99b7c8399..547db3d7d43 100644 --- a/addons/links/package.json +++ b/addons/links/package.json @@ -32,7 +32,7 @@ "@storybook/addons": "5.3.0-beta.19", "@storybook/client-logger": "5.3.0-beta.19", "@storybook/core-events": "5.3.0-beta.19", - "@storybook/csf": "5.3.0-beta.19", + "@storybook/csf": "0.0.1", "@storybook/router": "5.3.0-beta.19", "core-js": "^3.0.1", "global": "^4.3.2", diff --git a/addons/storyshots/storyshots-puppeteer/package.json b/addons/storyshots/storyshots-puppeteer/package.json index a0672f22f62..b5bb64a3b9b 100644 --- a/addons/storyshots/storyshots-puppeteer/package.json +++ b/addons/storyshots/storyshots-puppeteer/package.json @@ -30,7 +30,7 @@ }, "dependencies": { "@hypnosphi/jest-puppeteer-axe": "^1.4.0", - "@storybook/csf": "5.3.0-beta.19", + "@storybook/csf": "0.0.1", "@storybook/node-logger": "5.3.0-beta.19", "@types/jest-image-snapshot": "^2.8.0", "core-js": "^3.0.1", diff --git a/lib/api/package.json b/lib/api/package.json index 3de0fa8dade..28ba0a914b7 100644 --- a/lib/api/package.json +++ b/lib/api/package.json @@ -29,7 +29,7 @@ "@storybook/channels": "5.3.0-beta.19", "@storybook/client-logger": "5.3.0-beta.19", "@storybook/core-events": "5.3.0-beta.19", - "@storybook/csf": "5.3.0-beta.19", + "@storybook/csf": "0.0.1", "@storybook/router": "5.3.0-beta.19", "@storybook/theming": "5.3.0-beta.19", "core-js": "^3.0.1", diff --git a/lib/client-api/package.json b/lib/client-api/package.json index 83a103e1726..53ed8c72fae 100644 --- a/lib/client-api/package.json +++ b/lib/client-api/package.json @@ -32,7 +32,7 @@ "@storybook/channels": "5.3.0-beta.19", "@storybook/client-logger": "5.3.0-beta.19", "@storybook/core-events": "5.3.0-beta.19", - "@storybook/csf": "5.3.0-beta.19", + "@storybook/csf": "0.0.1", "core-js": "^3.0.1", "eventemitter3": "^4.0.0", "global": "^4.3.2", diff --git a/lib/codemod/package.json b/lib/codemod/package.json index b2b59ca5376..d1514542bb3 100644 --- a/lib/codemod/package.json +++ b/lib/codemod/package.json @@ -29,7 +29,7 @@ "dependencies": { "@hypnosphi/jscodeshift": "^0.6.4", "@mdx-js/mdx": "^1.5.1", - "@storybook/csf": "5.3.0-beta.19", + "@storybook/csf": "0.0.1", "@storybook/node-logger": "5.3.0-beta.19", "core-js": "^3.0.1", "cross-spawn": "^7.0.0", diff --git a/lib/core/package.json b/lib/core/package.json index 1c3b3256525..1935a7afa8b 100644 --- a/lib/core/package.json +++ b/lib/core/package.json @@ -37,7 +37,7 @@ "@storybook/client-api": "5.3.0-beta.19", "@storybook/client-logger": "5.3.0-beta.19", "@storybook/core-events": "5.3.0-beta.19", - "@storybook/csf": "5.3.0-beta.19", + "@storybook/csf": "0.0.1", "@storybook/node-logger": "5.3.0-beta.19", "@storybook/router": "5.3.0-beta.19", "@storybook/theming": "5.3.0-beta.19", diff --git a/lib/csf/README.md b/lib/csf/README.md deleted file mode 100644 index 1a00256d0d8..00000000000 --- a/lib/csf/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# Storybook CSF - -A minimal set of utility functions for dealing with Storybook [Component Story Format](https://storybook.js.org/docs/formats/component-story-format/). diff --git a/lib/csf/package.json b/lib/csf/package.json deleted file mode 100644 index eca8941066d..00000000000 --- a/lib/csf/package.json +++ /dev/null @@ -1,35 +0,0 @@ -{ - "name": "@storybook/csf", - "version": "5.3.0-beta.19", - "description": "", - "keywords": [ - "storybook" - ], - "homepage": "https://github.com/storybookjs/storybook/tree/master/lib/csf", - "bugs": { - "url": "https://github.com/storybookjs/storybook/issues" - }, - "repository": { - "type": "git", - "url": "https://github.com/storybookjs/storybook.git", - "directory": "lib/csf" - }, - "license": "MIT", - "files": [ - "dist/**/*", - "README.md", - "*.js", - "*.d.ts" - ], - "main": "dist/index.js", - "types": "dist/index.d.ts", - "scripts": { - "prepare": "node ../../scripts/prepare.js" - }, - "dependencies": { - "lodash": "^4.17.15" - }, - "publishConfig": { - "access": "public" - } -} diff --git a/lib/csf/src/index.test.ts b/lib/csf/src/index.test.ts deleted file mode 100644 index 27d0095039b..00000000000 --- a/lib/csf/src/index.test.ts +++ /dev/null @@ -1,91 +0,0 @@ -import { toId, storyNameFromExport, isExportStory } from '.'; - -describe('toId', () => { - [ - // name, kind, story, output - ['handles simple cases', 'kind', 'story', 'kind--story'], - ['handles basic substitution', 'a b$c?d😀e', '1-2:3', 'a-b-c-d😀e--1-2-3'], - ['handles runs of non-url chars', 'a?&*b', 'story', 'a-b--story'], - ['removes non-url chars from start and end', '?ab-', 'story', 'ab--story'], - ['downcases', 'KIND', 'STORY', 'kind--story'], - ['non-latin', 'Кнопки', 'нормальный', 'кнопки--нормальный'], - ['korean', 'kind', '바보 (babo)', 'kind--바보-babo'], - ['all punctuation', 'kind', 'unicorns,’–—―′¿`"<>()!.!!!{}[]%^&$*#&', 'kind--unicorns'], - ].forEach(([name, kind, story, output]) => { - it(name, () => { - expect(toId(kind, story)).toBe(output); - }); - }); - - it('does not allow kind with *no* url chars', () => { - expect(() => toId('?', 'asdf')).toThrow( - `Invalid kind '?', must include alphanumeric characters` - ); - }); - - it('does not allow empty kind', () => { - expect(() => toId('', 'asdf')).toThrow(`Invalid kind '', must include alphanumeric characters`); - }); - - it('does not allow story with *no* url chars', () => { - expect(() => toId('kind', '?')).toThrow( - `Invalid name '?', must include alphanumeric characters` - ); - }); - - it('does not allow empty story', () => { - expect(() => toId('kind', '')).toThrow(`Invalid name '', must include alphanumeric characters`); - }); -}); - -describe('storyNameFromExport', () => { - it('should format CSF exports with sensible defaults', () => { - const testCases = { - name: 'Name', - someName: 'Some Name', - someNAME: 'Some NAME', - some_custom_NAME: 'Some Custom NAME', - someName1234: 'Some Name 1234', - someName1_2_3_4: 'Some Name 1 2 3 4', - }; - Object.entries(testCases).forEach(([key, val]) => expect(storyNameFromExport(key)).toBe(val)); - }); -}); - -describe('isExportStory', () => { - it('should exclude __esModule', () => { - expect(isExportStory('__esModule', {})).toBeFalsy(); - }); - - it('should include all stories when there are no filters', () => { - expect(isExportStory('a', {})).toBeTruthy(); - }); - - it('should filter stories by arrays', () => { - expect(isExportStory('a', { includeStories: ['a'] })).toBeTruthy(); - expect(isExportStory('a', { includeStories: [] })).toBeFalsy(); - expect(isExportStory('a', { includeStories: ['b'] })).toBeFalsy(); - - expect(isExportStory('a', { excludeStories: ['a'] })).toBeFalsy(); - expect(isExportStory('a', { excludeStories: [] })).toBeTruthy(); - expect(isExportStory('a', { excludeStories: ['b'] })).toBeTruthy(); - - expect(isExportStory('a', { includeStories: ['a'], excludeStories: ['a'] })).toBeFalsy(); - expect(isExportStory('a', { includeStories: [], excludeStories: [] })).toBeFalsy(); - expect(isExportStory('a', { includeStories: ['a'], excludeStories: ['b'] })).toBeTruthy(); - }); - - it('should filter stories by regex', () => { - expect(isExportStory('a', { includeStories: /a/ })).toBeTruthy(); - expect(isExportStory('a', { includeStories: /.*/ })).toBeTruthy(); - expect(isExportStory('a', { includeStories: /b/ })).toBeFalsy(); - - expect(isExportStory('a', { excludeStories: /a/ })).toBeFalsy(); - expect(isExportStory('a', { excludeStories: /.*/ })).toBeFalsy(); - expect(isExportStory('a', { excludeStories: /b/ })).toBeTruthy(); - - expect(isExportStory('a', { includeStories: /a/, excludeStories: ['a'] })).toBeFalsy(); - expect(isExportStory('a', { includeStories: /.*/, excludeStories: /.*/ })).toBeFalsy(); - expect(isExportStory('a', { includeStories: /a/, excludeStories: /b/ })).toBeTruthy(); - }); -}); diff --git a/lib/csf/src/index.ts b/lib/csf/src/index.ts deleted file mode 100644 index 23a03a6cbc3..00000000000 --- a/lib/csf/src/index.ts +++ /dev/null @@ -1,69 +0,0 @@ -import startCase from 'lodash/startCase'; - -// Remove punctuation https://gist.github.com/davidjrice/9d2af51100e41c6c4b4a -export const sanitize = (string: string) => { - return ( - string - .toLowerCase() - // eslint-disable-next-line no-useless-escape - .replace(/[ ’–—―′¿'`~!@#$%^&*()_|+\-=?;:'",.<>\{\}\[\]\\\/]/gi, '-') - .replace(/-+/g, '-') - .replace(/^-+/, '') - .replace(/-+$/, '') - ); -}; - -const sanitizeSafe = (string: string, part: string) => { - const sanitized = sanitize(string); - if (sanitized === '') { - throw new Error(`Invalid ${part} '${string}', must include alphanumeric characters`); - } - return sanitized; -}; - -export const toId = (kind: string, name: string) => - `${sanitizeSafe(kind, 'kind')}--${sanitizeSafe(name, 'name')}`; - -// Transform the CSF named export into a readable story name -export const storyNameFromExport = (key: string) => startCase(key); - -type StoryDescriptor = string[] | RegExp; -export interface IncludeExcludeOptions { - includeStories?: StoryDescriptor; - excludeStories?: StoryDescriptor; -} - -function matches(storyKey: string, arrayOrRegex?: StoryDescriptor) { - if (Array.isArray(arrayOrRegex)) { - return arrayOrRegex.includes(storyKey); - } - return storyKey.match(arrayOrRegex); -} - -export function isExportStory( - key: string, - { includeStories, excludeStories }: IncludeExcludeOptions -) { - return ( - // https://babeljs.io/docs/en/babel-plugin-transform-modules-commonjs - key !== '__esModule' && - (!includeStories || matches(key, includeStories)) && - (!excludeStories || !matches(key, excludeStories)) - ); -} - -interface SeparatorOptions { - rootSeparator: string | RegExp; - groupSeparator: string | RegExp; -} - -export const parseKind = (kind: string, { rootSeparator, groupSeparator }: SeparatorOptions) => { - const [root, remainder] = kind.split(rootSeparator, 2); - const groups = (remainder || kind).split(groupSeparator).filter(i => !!i); - - // when there's no remainder, it means the root wasn't found/split - return { - root: remainder ? root : null, - groups, - }; -}; diff --git a/lib/csf/tsconfig.json b/lib/csf/tsconfig.json deleted file mode 100644 index a24ec639386..00000000000 --- a/lib/csf/tsconfig.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "extends": "../../tsconfig.json", - "compilerOptions": { - "rootDir": "./src" - }, - "include": ["src/**/*"], - "exclude": ["src/**.test.ts"] -} diff --git a/lib/router/package.json b/lib/router/package.json index daa280b27e9..75a70262a15 100644 --- a/lib/router/package.json +++ b/lib/router/package.json @@ -28,7 +28,7 @@ }, "dependencies": { "@reach/router": "^1.2.1", - "@storybook/csf": "5.3.0-beta.19", + "@storybook/csf": "0.0.1", "@types/reach__router": "^1.2.3", "core-js": "^3.0.1", "global": "^4.3.2", diff --git a/lib/source-loader/package.json b/lib/source-loader/package.json index a4af1c7dd26..1d4c9b4ee95 100644 --- a/lib/source-loader/package.json +++ b/lib/source-loader/package.json @@ -30,7 +30,7 @@ "dependencies": { "@storybook/addons": "5.3.0-beta.19", "@storybook/client-logger": "5.3.0-beta.19", - "@storybook/csf": "5.3.0-beta.19", + "@storybook/csf": "0.0.1", "core-js": "^3.0.1", "estraverse": "^4.2.0", "global": "^4.3.2", diff --git a/yarn.lock b/yarn.lock index 1379547e1ca..a4a07047f72 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3563,6 +3563,13 @@ resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-0.7.0.tgz#9a06f4f137ee84d7df0460c1fdb1135ffa6c50fd" integrity sha512-ONhaKPIufzzrlNbqtWFFd+jlnemX6lJAgq9ZeiZtS7I1PIf/la7CW4m83rTXRnVnsMbW2k56pGYu7AUFJD9Pow== +"@storybook/csf@0.0.1": + version "0.0.1" + resolved "https://registry.yarnpkg.com/@storybook/csf/-/csf-0.0.1.tgz#95901507dc02f0bc6f9ac8ee1983e2fc5bb98ce6" + integrity sha512-USTLkZze5gkel8MYCujSRBVIrUQ3YPBrLOx7GNk/0wttvVtlzWXAq9eLbQ4p/NicGxP+3T7KPEMVV//g+yubpw== + dependencies: + lodash "^4.17.15" + "@storybook/ember-cli-storybook@^0.2.0": version "0.2.0" resolved "https://registry.yarnpkg.com/@storybook/ember-cli-storybook/-/ember-cli-storybook-0.2.0.tgz#c9b0a2512266e9c1a9cb443048c8defa2f00c035" From 02e8186682c5d158c9516e9d37550866881f937c Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Mon, 9 Dec 2019 15:38:33 +0800 Subject: [PATCH 077/132] Add legacy exports to @storybook/router/utils --- lib/router/src/utils.ts | 3 +++ lib/ui/paths.js | 1 - 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/router/src/utils.ts b/lib/router/src/utils.ts index e3713abc3e4..97bac2a40ea 100644 --- a/lib/router/src/utils.ts +++ b/lib/router/src/utils.ts @@ -1,6 +1,9 @@ import qs from 'qs'; import memoize from 'memoizerific'; +// FIXME: Remove in SB 6.0 +export { toId, parseKind, sanitize } from '@storybook/csf'; + interface StoryData { viewMode?: string; storyId?: string; diff --git a/lib/ui/paths.js b/lib/ui/paths.js index 908c631d808..e14bef875a3 100644 --- a/lib/ui/paths.js +++ b/lib/ui/paths.js @@ -11,7 +11,6 @@ module.exports = { '@storybook/channels': dirname(resolve('@storybook/channels/package.json')), '@storybook/components': dirname(resolve('@storybook/components/package.json')), '@storybook/core-events': dirname(resolve('@storybook/core-events/package.json')), - '@storybook/csf': dirname(resolve('@storybook/csf/package.json')), '@storybook/router': dirname(resolve('@storybook/router/package.json')), '@storybook/theming': dirname(resolve('@storybook/theming/package.json')), '@storybook/ui': dirname(resolve('@storybook/ui/package.json')), From 971809db71aae056ebd94a518ac4cc4f0565206d Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Mon, 9 Dec 2019 16:45:55 +0800 Subject: [PATCH 078/132] Source-loader: Handle includeStories/excludeStories in CSF --- __mocks__/inject-decorator.ts.csf.txt | 4 +- .../inject-decorator.csf.test.js.snap | 10 ++- .../abstract-syntax-tree/traverse-helpers.js | 88 +++++++++++++++---- 3 files changed, 81 insertions(+), 21 deletions(-) diff --git a/__mocks__/inject-decorator.ts.csf.txt b/__mocks__/inject-decorator.ts.csf.txt index 27b5a65e36f..b3a3d900dcc 100644 --- a/__mocks__/inject-decorator.ts.csf.txt +++ b/__mocks__/inject-decorator.ts.csf.txt @@ -3,7 +3,9 @@ import { action } from "@storybook/addon-actions"; import { Button } from "@storybook/react/demo"; export default { - title: "Button" + title: "Button", + excludeStories: ["text"], + includeStories: /emoji.*/ }; export const text = () => ( diff --git a/lib/source-loader/src/server/abstract-syntax-tree/__snapshots__/inject-decorator.csf.test.js.snap b/lib/source-loader/src/server/abstract-syntax-tree/__snapshots__/inject-decorator.csf.test.js.snap index f686ff20b33..f9a49b512b4 100644 --- a/lib/source-loader/src/server/abstract-syntax-tree/__snapshots__/inject-decorator.csf.test.js.snap +++ b/lib/source-loader/src/server/abstract-syntax-tree/__snapshots__/inject-decorator.csf.test.js.snap @@ -5,13 +5,15 @@ exports[`inject-decorator positive - ts - csf includes storySource parameter in import { action } from \\"@storybook/addon-actions\\"; import { Button } from \\"@storybook/react/demo\\"; -export default {parameters: {\\"storySource\\":{\\"source\\":\\"import React from \\\\\\"react\\\\\\";\\\\nimport { action } from \\\\\\"@storybook/addon-actions\\\\\\";\\\\nimport { Button } from \\\\\\"@storybook/react/demo\\\\\\";\\\\n\\\\nexport default {\\\\n title: \\\\\\"Button\\\\\\"\\\\n};\\\\n\\\\nexport const text = () => (\\\\n \\\\n);\\\\n\\\\nexport const emoji = () => (\\\\n \\\\n);\\\\n\\\\nexport function emojiFn() {\\\\n return (\\\\n \\\\n )\\\\n};\\\\n\\",\\"locationsMap\\":{\\"button--text\\":{\\"startLoc\\":{\\"col\\":20,\\"line\\":9},\\"endLoc\\":{\\"col\\":1,\\"line\\":11},\\"startBody\\":{\\"col\\":20,\\"line\\":9},\\"endBody\\":{\\"col\\":1,\\"line\\":11}},\\"button--emoji\\":{\\"startLoc\\":{\\"col\\":21,\\"line\\":13},\\"endLoc\\":{\\"col\\":1,\\"line\\":19},\\"startBody\\":{\\"col\\":21,\\"line\\":13},\\"endBody\\":{\\"col\\":1,\\"line\\":19}},\\"button--emoji-fn\\":{\\"startLoc\\":{\\"col\\":7,\\"line\\":21},\\"endLoc\\":{\\"col\\":1,\\"line\\":29},\\"startBody\\":{\\"col\\":7,\\"line\\":21},\\"endBody\\":{\\"col\\":1,\\"line\\":29}}}},}, - title: \\"Button\\" +export default {parameters: {\\"storySource\\":{\\"source\\":\\"import React from \\\\\\"react\\\\\\";\\\\nimport { action } from \\\\\\"@storybook/addon-actions\\\\\\";\\\\nimport { Button } from \\\\\\"@storybook/react/demo\\\\\\";\\\\n\\\\nexport default {\\\\n title: \\\\\\"Button\\\\\\",\\\\n excludeStories: [\\\\\\"text\\\\\\"],\\\\n includeStories: /emoji.*/\\\\n};\\\\n\\\\nexport const text = () => (\\\\n \\\\n);\\\\n\\\\nexport const emoji = () => (\\\\n \\\\n);\\\\n\\\\nexport function emojiFn() {\\\\n return (\\\\n \\\\n )\\\\n};\\\\n\\",\\"locationsMap\\":{\\"button--text\\":{\\"startLoc\\":{\\"col\\":20,\\"line\\":11},\\"endLoc\\":{\\"col\\":1,\\"line\\":13},\\"startBody\\":{\\"col\\":20,\\"line\\":11},\\"endBody\\":{\\"col\\":1,\\"line\\":13}},\\"button--emoji\\":{\\"startLoc\\":{\\"col\\":21,\\"line\\":15},\\"endLoc\\":{\\"col\\":1,\\"line\\":21},\\"startBody\\":{\\"col\\":21,\\"line\\":15},\\"endBody\\":{\\"col\\":1,\\"line\\":21}},\\"button--emoji-fn\\":{\\"startLoc\\":{\\"col\\":7,\\"line\\":23},\\"endLoc\\":{\\"col\\":1,\\"line\\":31},\\"startBody\\":{\\"col\\":7,\\"line\\":23},\\"endBody\\":{\\"col\\":1,\\"line\\":31}}}},}, + title: \\"Button\\", + excludeStories: [\\"text\\"], + includeStories: /emoji.*/ }; -export const text = addSourceDecorator(() => ( +export const text = () => ( -), {__STORY__, __ADDS_MAP__,__MAIN_FILE_LOCATION__,__MODULE_DEPENDENCIES__,__LOCAL_DEPENDENCIES__,__SOURCE_PREFIX__,__IDS_TO_FRAMEWORKS__});; +); export const emoji = addSourceDecorator(() => ( diff --git a/examples/cra-kitchen-sink/src/stories/perf.stories.js b/examples/cra-kitchen-sink/src/stories/perf.stories.js deleted file mode 100644 index d0612b21af1..00000000000 --- a/examples/cra-kitchen-sink/src/stories/perf.stories.js +++ /dev/null @@ -1,24 +0,0 @@ -import React from 'react'; - -import { storiesOf } from '@storybook/react'; - -import { Button } from '@storybook/react/demo'; - -for (let i = 0; i < 1; i += 1) { - const randomDemoName = Math.random() - .toString(36) - .substring(7); - const stories = storiesOf(`Perf.${randomDemoName}`); - - for (let j = 0; j < 10; j += 1) { - stories - .add(`with text ${j}`, () => ) - .add(`with emoji ${j}`, () => ( - - )); - } -} From b11a3d700110b95a110273751b8fb601dd4eb31d Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Tue, 10 Dec 2019 12:02:20 +0100 Subject: [PATCH 095/132] FIX bad path-ref --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index c26090ad11c..68e6eda8ac0 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -56,8 +56,8 @@ jobs: name: Run chromatic on the pre-built cra-kitchen-sink example command: yarn chromatic --storybook-build-dir="built-storybooks/cra-kitchen-sink" --app-code="tg55gajmdt" - run: - name: Run chromatic on the pre-built cra-react-15 example - command: yarn chromatic --storybook-build-dir="built-storybooks/cra-react-15" --app-code="gxk7iqej3wt" + name: Run chromatic on the pre-built cra-react15 example + command: yarn chromatic --storybook-build-dir="built-storybooks/cra-react15" --app-code="gxk7iqej3wt" - run: name: Run chromatic on the pre-built cra-ts-essentials example command: yarn chromatic --storybook-build-dir="built-storybooks/cra-ts-essentials" --app-code="b311ypk6of" From 9aebb639126d55f55c098fb934970c346b363206 Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Tue, 10 Dec 2019 13:47:48 +0100 Subject: [PATCH 096/132] FIX rax axample --- .../rax-kitchen-sink/src/components/App/App.test.js | 2 +- .../rax-kitchen-sink/src/components/App/index.js | 4 +--- .../src/components/App/index.stylesheet | 8 ++++---- .../src/components/Welcome/Welcome.test.js | 2 +- .../src/components/Welcome/index.js | 7 ++----- .../src/stories/addon-centered.stories.js | 10 ++++------ .../rax-kitchen-sink/src/stories/index.stories.js | 13 +++---------- 7 files changed, 16 insertions(+), 30 deletions(-) diff --git a/examples/rax-kitchen-sink/src/components/App/App.test.js b/examples/rax-kitchen-sink/src/components/App/App.test.js index 719fbb24b85..4aab78399d6 100644 --- a/examples/rax-kitchen-sink/src/components/App/App.test.js +++ b/examples/rax-kitchen-sink/src/components/App/App.test.js @@ -1,6 +1,6 @@ import { createElement } from 'rax'; import renderer from 'rax-test-renderer'; -import App from './index'; +import { App } from './index'; test('App render correctly', () => { const tree = renderer.create().toJSON(); diff --git a/examples/rax-kitchen-sink/src/components/App/index.js b/examples/rax-kitchen-sink/src/components/App/index.js index 2b1568388e6..2cdfa966eee 100644 --- a/examples/rax-kitchen-sink/src/components/App/index.js +++ b/examples/rax-kitchen-sink/src/components/App/index.js @@ -3,7 +3,7 @@ import View from 'rax-view'; import Text from 'rax-text'; import styles from './index.stylesheet'; -const App = () => ( +export const App = () => ( Welcome to Rax @@ -13,5 +13,3 @@ const App = () => ( ); - -export default App; diff --git a/examples/rax-kitchen-sink/src/components/App/index.stylesheet b/examples/rax-kitchen-sink/src/components/App/index.stylesheet index b934c26b377..136c2936a77 100644 --- a/examples/rax-kitchen-sink/src/components/App/index.stylesheet +++ b/examples/rax-kitchen-sink/src/components/App/index.stylesheet @@ -2,13 +2,14 @@ flex: 1; justify-content: center; align-items: center; - width: 300; + background-color: #222; + color: white; + padding: 40px; } .appHeader { - background-color: #222; height: 160; - padding: 40; + padding: 40px; } .appBanner, .appIntro { @@ -23,5 +24,4 @@ .appIntro { margin-top: 40; font-size: 20; - line-height: 30; } diff --git a/examples/rax-kitchen-sink/src/components/Welcome/Welcome.test.js b/examples/rax-kitchen-sink/src/components/Welcome/Welcome.test.js index f06f49a3a2a..0881e2f6373 100644 --- a/examples/rax-kitchen-sink/src/components/Welcome/Welcome.test.js +++ b/examples/rax-kitchen-sink/src/components/Welcome/Welcome.test.js @@ -1,6 +1,6 @@ import { createElement } from 'rax'; import renderer from 'rax-test-renderer'; -import Welcome from './index'; +import { Welcome } from './index'; test('Welcome render correctly', () => { const tree = renderer.create().toJSON(); diff --git a/examples/rax-kitchen-sink/src/components/Welcome/index.js b/examples/rax-kitchen-sink/src/components/Welcome/index.js index 8715efacb67..b1d9aa9aff2 100644 --- a/examples/rax-kitchen-sink/src/components/Welcome/index.js +++ b/examples/rax-kitchen-sink/src/components/Welcome/index.js @@ -2,7 +2,6 @@ import { createElement } from 'rax'; import View from 'rax-view'; import Text from 'rax-text'; -// import Button from 'rax-button'; import Image from 'rax-image'; const Main = ({ children, ...props }) => ( @@ -24,12 +23,12 @@ const P = ({ children, ...props }) => ( ); const Title = ({ children, ...props }) => ( - + {children} ); -const Welcome = ({ showApp }) => ( +export const Welcome = ({ showApp }) => (
Welcome to storybook for Rax (

); - -export default Welcome; diff --git a/examples/rax-kitchen-sink/src/stories/addon-centered.stories.js b/examples/rax-kitchen-sink/src/stories/addon-centered.stories.js index 8c72523e63f..9cc99bf112f 100644 --- a/examples/rax-kitchen-sink/src/stories/addon-centered.stories.js +++ b/examples/rax-kitchen-sink/src/stories/addon-centered.stories.js @@ -1,7 +1,7 @@ import { createElement } from 'rax'; import Centered from '@storybook/addon-centered/rax'; import Text from 'rax-text'; -import App from '../components/App'; +import { App as AppComponent } from '../components/App'; export default { title: 'Addon/addon-centered', @@ -9,11 +9,9 @@ export default { }; export const Button = () => ( - + ); -Button.story = { name: 'Button' }; -export const app = () => ; -app.story = { name: 'App' }; +export const App = () => ; diff --git a/examples/rax-kitchen-sink/src/stories/index.stories.js b/examples/rax-kitchen-sink/src/stories/index.stories.js index 1d5ab0e256f..d8547241fc4 100644 --- a/examples/rax-kitchen-sink/src/stories/index.stories.js +++ b/examples/rax-kitchen-sink/src/stories/index.stories.js @@ -1,18 +1,11 @@ import { createElement } from 'rax'; import { linkTo } from '@storybook/addon-links'; -import App from '../components/App'; -import Welcome from '../components/Welcome'; +import { App as AppComponent } from '../components/App/index'; +import { Welcome } from '../components/Welcome/index'; export default { title: 'Basic', }; export const WelcomeScreen = () => ; -WelcomeScreen.story = { - name: 'Welcome screen', -}; - -export const app = () => ; -app.story = { - name: 'App', -}; +export const App = () => ; From 2b31785756d0eabf326ed04835d8dd5a1c277a07 Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Mon, 9 Dec 2019 17:57:24 +0100 Subject: [PATCH 097/132] ADD migration documentation for triconfig --- MIGRATION.md | 66 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) diff --git a/MIGRATION.md b/MIGRATION.md index 93f7f54e39a..11c2870237c 100644 --- a/MIGRATION.md +++ b/MIGRATION.md @@ -2,6 +2,7 @@ - [Migration](#migration) - [From version 5.2.x to 5.3.x](#from-version-52x-to-53x) + - [To tri-config](#to-triconfig) - [Create React App preset](#create-react-app-preset) - [Description doc block](#description-doc-block) - [React Native Async Storage](#react-native-async-storage) @@ -74,8 +75,73 @@ - [Packages renaming](#packages-renaming) - [Deprecated embedded addons](#deprecated-embedded-addons) + ## From version 5.2.x to 5.3.x +### To tri-config + +In storybook 5.3 3 new files for configuration were introduced, that replaced some previous files. + +These files are now soft-deprecated, (*they still work, but over time we will promote users to migrate*): + +- `config.js` has been renamed to `preview.js`. +- `addons.js` has been renamed to `manager.js`. +- `presets.js` has been renamed to `main.js`. + +#### Using main.js + +this is what a basic `main.js` looks like: + +```js +module.exports = { + stories: ['../**/*.stories.js'], + addons: [ + '@storybook/addon-docs/register', + ], +}; +``` + +You remove all "register" import from `addons.js` and place them inside the array. If this means `addons.js` is now empty for you, it's safe to remove. + +Next you remove the code that imports/requires all your stories from `config.js`, and change it to a glob-pattern and place that glob in the `stories` array. If this means `config.js` is empty, it's safe to remove. + +If you had a `presets.js` file before you can add the array of presets to the main.js file and remove `presets.js` like so: + +```js +module.exports = { + stories: ['../**/*.stories.js'], + presets: ['@storybook/addon-docs/preset'], +}; +``` + +#### Using preview.js + +If after migrating the imports/requires of your stories to `main.js` you're left with some code in `config.js` it's likely the usage of `useParameters` & `addDecorator`. + +This is fine, rename `config.js` to `preview.js`. + +This file can also be used to inject global stylesheets, fonts etc, into the preview bundle. + +#### Using manager.js + +If you are setting storybook options in `config.js`, especially `theme`, you should migrate it to `manager.js`: + +```js +import { addons } from '@storybook/addons'; +import { create } from '@storybook/theming/create'; + +const theme = create({ + base: 'light', + brandTitle: 'My custom title', +}); + +addons.setConfig({ + showRoots: true, + panelPosition: 'bottom', + theme, +}); +``` + ### Create React App preset You can now move to the new preset for [Create React App](https://create-react-app.dev/). The in-built preset for Create React App will be disabled in Storybook 6.0. From 058faefb5ff1de04e203db03172a254baef599ed Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Tue, 10 Dec 2019 14:08:17 +0100 Subject: [PATCH 098/132] FIX linting --- examples/rax-kitchen-sink/src/index.js | 2 +- examples/rax-kitchen-sink/src/stories/addon-jest.stories.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/rax-kitchen-sink/src/index.js b/examples/rax-kitchen-sink/src/index.js index 595e779605b..2d90540a8cb 100644 --- a/examples/rax-kitchen-sink/src/index.js +++ b/examples/rax-kitchen-sink/src/index.js @@ -1,4 +1,4 @@ import { createElement, render } from 'rax'; -import App from './components/App/index'; +import { App } from './components/App/index'; render(); diff --git a/examples/rax-kitchen-sink/src/stories/addon-jest.stories.js b/examples/rax-kitchen-sink/src/stories/addon-jest.stories.js index 3d350d1cde5..961f8b7e840 100644 --- a/examples/rax-kitchen-sink/src/stories/addon-jest.stories.js +++ b/examples/rax-kitchen-sink/src/stories/addon-jest.stories.js @@ -1,7 +1,7 @@ import { createElement } from 'rax'; import { withTests } from '@storybook/addon-jest'; -import App from '../components/App'; -import Welcome from '../components/Welcome'; +import { App } from '../components/App'; +import { Welcome } from '../components/Welcome'; // eslint-disable-next-line import results from '../../jest-test-results.json'; From a24690f530d54afafa6f99355bae32322a64f6c2 Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Tue, 10 Dec 2019 14:14:19 +0100 Subject: [PATCH 099/132] FIX review comments --- MIGRATION.md | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/MIGRATION.md b/MIGRATION.md index 11c2870237c..07c65bc3c7f 100644 --- a/MIGRATION.md +++ b/MIGRATION.md @@ -2,7 +2,7 @@ - [Migration](#migration) - [From version 5.2.x to 5.3.x](#from-version-52x-to-53x) - - [To tri-config](#to-triconfig) + - [To tri-config configuration](#to-triconfig-configuration) - [Create React App preset](#create-react-app-preset) - [Description doc block](#description-doc-block) - [React Native Async Storage](#react-native-async-storage) @@ -78,7 +78,7 @@ ## From version 5.2.x to 5.3.x -### To tri-config +### To tri-config configuration In storybook 5.3 3 new files for configuration were introduced, that replaced some previous files. @@ -90,7 +90,7 @@ These files are now soft-deprecated, (*they still work, but over time we will pr #### Using main.js -this is what a basic `main.js` looks like: +Now main.js is now the main point of configuration for Storybook. This is what a basic `main.js` looks like: ```js module.exports = { @@ -116,7 +116,7 @@ module.exports = { #### Using preview.js -If after migrating the imports/requires of your stories to `main.js` you're left with some code in `config.js` it's likely the usage of `useParameters` & `addDecorator`. +If after migrating the imports/requires of your stories to `main.js` you're left with some code in `config.js` it's likely the usage of `addParameters` & `addDecorator`. This is fine, rename `config.js` to `preview.js`. @@ -142,6 +142,9 @@ addons.setConfig({ }); ``` +This makes storybook load and use the theme in the manager directly. +This allows for richer theming in the future, and has a much better performance! + ### Create React App preset You can now move to the new preset for [Create React App](https://create-react-app.dev/). The in-built preset for Create React App will be disabled in Storybook 6.0. From 731477723bfff1d4b39f23e8e00f298600952ac6 Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Tue, 10 Dec 2019 23:34:47 +0800 Subject: [PATCH 100/132] Addon-docs: Update MDX compiler to fix knobs --- addons/docs/src/blocks/mdx.tsx | 9 ++++-- .../component-id.output.snapshot | 2 +- .../decorators.output.snapshot | 2 +- .../docs-only.output.snapshot | 2 +- .../meta-quotes-in-title.output.snapshot | 2 +- .../non-story-exports.output.snapshot | 2 +- .../parameters.output.snapshot | 2 +- .../__testfixtures__/previews.output.snapshot | 2 +- .../story-current.output.snapshot | 2 +- .../story-def-text-only.output.snapshot | 4 +-- .../story-definitions.output.snapshot | 2 +- .../story-function-var.output.snapshot | 4 +-- .../story-function.output.snapshot | 6 ++-- .../story-object.output.snapshot | 4 +-- .../story-references.output.snapshot | 2 +- .../title-template-string.output.snapshot | 2 +- .../__testfixtures__/vanilla.output.snapshot | 2 +- addons/docs/src/mdx/mdx-compiler-plugin.js | 30 ++++++++++++------- .../src/stories/addon-docs.stories.mdx | 5 ++-- 19 files changed, 50 insertions(+), 36 deletions(-) diff --git a/addons/docs/src/blocks/mdx.tsx b/addons/docs/src/blocks/mdx.tsx index 40f8eda8e20..ca522560219 100644 --- a/addons/docs/src/blocks/mdx.tsx +++ b/addons/docs/src/blocks/mdx.tsx @@ -7,8 +7,13 @@ import { styled } from '@storybook/theming'; import { DocsContext, DocsContextProps } from './DocsContext'; import { scrollToElement } from './utils'; -// Hacky utility for dealing with functions or values in MDX Story elements -export const makeStoryFn = (val: any) => (typeof val === 'function' ? val : () => val); +// Hacky utility for asserting identifiers in MDX Story elements +export const assertIsFn = (val: any) => { + if (typeof val !== 'function') { + throw new Error(`Expected story function, got: ${val}`); + } + return val; +}; // Hacky utilty for adding mdxStoryToId to the default context export const AddContext: FC = props => { diff --git a/addons/docs/src/mdx/__testfixtures__/component-id.output.snapshot b/addons/docs/src/mdx/__testfixtures__/component-id.output.snapshot index d92735dcf43..28cd4ed4165 100644 --- a/addons/docs/src/mdx/__testfixtures__/component-id.output.snapshot +++ b/addons/docs/src/mdx/__testfixtures__/component-id.output.snapshot @@ -2,7 +2,7 @@ exports[`docs-mdx-compiler-plugin component-id.mdx 1`] = ` "/* @jsx mdx */ -import { makeStoryFn, AddContext } from '@storybook/addon-docs/blocks'; +import { assertIsFn, AddContext } from '@storybook/addon-docs/blocks'; import { Button } from '@storybook/react/demo'; import { Story, Meta } from '@storybook/addon-docs/blocks'; diff --git a/addons/docs/src/mdx/__testfixtures__/decorators.output.snapshot b/addons/docs/src/mdx/__testfixtures__/decorators.output.snapshot index b2e131aa52a..bded3c333d2 100644 --- a/addons/docs/src/mdx/__testfixtures__/decorators.output.snapshot +++ b/addons/docs/src/mdx/__testfixtures__/decorators.output.snapshot @@ -2,7 +2,7 @@ exports[`docs-mdx-compiler-plugin decorators.mdx 1`] = ` "/* @jsx mdx */ -import { makeStoryFn, AddContext } from '@storybook/addon-docs/blocks'; +import { assertIsFn, AddContext } from '@storybook/addon-docs/blocks'; import { Button } from '@storybook/react/demo'; import { Story, Meta } from '@storybook/addon-docs/blocks'; diff --git a/addons/docs/src/mdx/__testfixtures__/docs-only.output.snapshot b/addons/docs/src/mdx/__testfixtures__/docs-only.output.snapshot index 99e33d86732..59f28b9c4b4 100644 --- a/addons/docs/src/mdx/__testfixtures__/docs-only.output.snapshot +++ b/addons/docs/src/mdx/__testfixtures__/docs-only.output.snapshot @@ -2,7 +2,7 @@ exports[`docs-mdx-compiler-plugin docs-only.mdx 1`] = ` "/* @jsx mdx */ -import { makeStoryFn, AddContext } from '@storybook/addon-docs/blocks'; +import { assertIsFn, AddContext } from '@storybook/addon-docs/blocks'; import { Meta } from '@storybook/addon-docs/blocks'; diff --git a/addons/docs/src/mdx/__testfixtures__/meta-quotes-in-title.output.snapshot b/addons/docs/src/mdx/__testfixtures__/meta-quotes-in-title.output.snapshot index 8ad52b84d1f..64bb0d0c760 100644 --- a/addons/docs/src/mdx/__testfixtures__/meta-quotes-in-title.output.snapshot +++ b/addons/docs/src/mdx/__testfixtures__/meta-quotes-in-title.output.snapshot @@ -2,7 +2,7 @@ exports[`docs-mdx-compiler-plugin meta-quotes-in-title.mdx 1`] = ` "/* @jsx mdx */ -import { makeStoryFn, AddContext } from '@storybook/addon-docs/blocks'; +import { assertIsFn, AddContext } from '@storybook/addon-docs/blocks'; import { Meta } from '@storybook/addon-docs/blocks'; diff --git a/addons/docs/src/mdx/__testfixtures__/non-story-exports.output.snapshot b/addons/docs/src/mdx/__testfixtures__/non-story-exports.output.snapshot index 9fd6046ac2a..39a4e7fab4a 100644 --- a/addons/docs/src/mdx/__testfixtures__/non-story-exports.output.snapshot +++ b/addons/docs/src/mdx/__testfixtures__/non-story-exports.output.snapshot @@ -2,7 +2,7 @@ exports[`docs-mdx-compiler-plugin non-story-exports.mdx 1`] = ` "/* @jsx mdx */ -import { makeStoryFn, AddContext } from '@storybook/addon-docs/blocks'; +import { assertIsFn, AddContext } from '@storybook/addon-docs/blocks'; import { Button } from '@storybook/react/demo'; import { Story, Meta } from '@storybook/addon-docs/blocks'; diff --git a/addons/docs/src/mdx/__testfixtures__/parameters.output.snapshot b/addons/docs/src/mdx/__testfixtures__/parameters.output.snapshot index f2b9bd7d556..600811ad42a 100644 --- a/addons/docs/src/mdx/__testfixtures__/parameters.output.snapshot +++ b/addons/docs/src/mdx/__testfixtures__/parameters.output.snapshot @@ -2,7 +2,7 @@ exports[`docs-mdx-compiler-plugin parameters.mdx 1`] = ` "/* @jsx mdx */ -import { makeStoryFn, AddContext } from '@storybook/addon-docs/blocks'; +import { assertIsFn, AddContext } from '@storybook/addon-docs/blocks'; import { Button } from '@storybook/react/demo'; import { Story, Meta } from '@storybook/addon-docs/blocks'; diff --git a/addons/docs/src/mdx/__testfixtures__/previews.output.snapshot b/addons/docs/src/mdx/__testfixtures__/previews.output.snapshot index 1da3fd972d0..cc9e55f146d 100644 --- a/addons/docs/src/mdx/__testfixtures__/previews.output.snapshot +++ b/addons/docs/src/mdx/__testfixtures__/previews.output.snapshot @@ -2,7 +2,7 @@ exports[`docs-mdx-compiler-plugin previews.mdx 1`] = ` "/* @jsx mdx */ -import { makeStoryFn, AddContext } from '@storybook/addon-docs/blocks'; +import { assertIsFn, AddContext } from '@storybook/addon-docs/blocks'; import { Button } from '@storybook/react/demo'; import { Preview, Story, Meta } from '@storybook/addon-docs/blocks'; diff --git a/addons/docs/src/mdx/__testfixtures__/story-current.output.snapshot b/addons/docs/src/mdx/__testfixtures__/story-current.output.snapshot index de143f0fa95..ba937af8a3e 100644 --- a/addons/docs/src/mdx/__testfixtures__/story-current.output.snapshot +++ b/addons/docs/src/mdx/__testfixtures__/story-current.output.snapshot @@ -2,7 +2,7 @@ exports[`docs-mdx-compiler-plugin story-current.mdx 1`] = ` "/* @jsx mdx */ -import { makeStoryFn, AddContext } from '@storybook/addon-docs/blocks'; +import { assertIsFn, AddContext } from '@storybook/addon-docs/blocks'; import { Story } from '@storybook/addon-docs/blocks'; diff --git a/addons/docs/src/mdx/__testfixtures__/story-def-text-only.output.snapshot b/addons/docs/src/mdx/__testfixtures__/story-def-text-only.output.snapshot index 80723e1154e..a37003d1567 100644 --- a/addons/docs/src/mdx/__testfixtures__/story-def-text-only.output.snapshot +++ b/addons/docs/src/mdx/__testfixtures__/story-def-text-only.output.snapshot @@ -2,7 +2,7 @@ exports[`docs-mdx-compiler-plugin story-def-text-only.mdx 1`] = ` "/* @jsx mdx */ -import { makeStoryFn, AddContext } from '@storybook/addon-docs/blocks'; +import { assertIsFn, AddContext } from '@storybook/addon-docs/blocks'; import { Story, Meta } from '@storybook/addon-docs/blocks'; @@ -32,7 +32,7 @@ function MDXContent({ components, ...props }) { MDXContent.isMDXComponent = true; -export const text = makeStoryFn('Plain text'); +export const text = () => 'Plain text'; text.story = {}; text.story.name = 'text'; text.story.parameters = { mdxSource: \\"'Plain text'\\" }; diff --git a/addons/docs/src/mdx/__testfixtures__/story-definitions.output.snapshot b/addons/docs/src/mdx/__testfixtures__/story-definitions.output.snapshot index 41028a2707c..a0b17d0ba01 100644 --- a/addons/docs/src/mdx/__testfixtures__/story-definitions.output.snapshot +++ b/addons/docs/src/mdx/__testfixtures__/story-definitions.output.snapshot @@ -2,7 +2,7 @@ exports[`docs-mdx-compiler-plugin story-definitions.mdx 1`] = ` "/* @jsx mdx */ -import { makeStoryFn, AddContext } from '@storybook/addon-docs/blocks'; +import { assertIsFn, AddContext } from '@storybook/addon-docs/blocks'; import { Button } from '@storybook/react/demo'; import { Story, Meta } from '@storybook/addon-docs/blocks'; diff --git a/addons/docs/src/mdx/__testfixtures__/story-function-var.output.snapshot b/addons/docs/src/mdx/__testfixtures__/story-function-var.output.snapshot index ef6586064fa..6f5d19b494d 100644 --- a/addons/docs/src/mdx/__testfixtures__/story-function-var.output.snapshot +++ b/addons/docs/src/mdx/__testfixtures__/story-function-var.output.snapshot @@ -2,7 +2,7 @@ exports[`docs-mdx-compiler-plugin story-function-var.mdx 1`] = ` "/* @jsx mdx */ -import { makeStoryFn, AddContext } from '@storybook/addon-docs/blocks'; +import { assertIsFn, AddContext } from '@storybook/addon-docs/blocks'; import { Meta, Story } from '@storybook/addon-docs/blocks'; export const basicFn = () => + + +## Props + + +``` + +## Inline Stories + +Storybook Docs renders all React stories inline on the page by default. If you want to render stories in an `iframe` so that they are better isolated. To do this, update `.storybook/preview.js`: + +```js +import { addParameters } from '@storybook/react'; + +addParameters({ + docs: { + inlineStories: false, + }, +}); +``` + +## More resources + +Want to learn more? Here are some more articles on Storybook Docs: + +- References: [DocsPage](../docs/docspage.md) / [MDX](../docs/mdx.md) / [FAQ](../docs/faq.md) / [Recipes](../docs/recipes.md) / [Theming](../docs/theming.md) +- Vision: [Storybook Docs sneak peak](https://medium.com/storybookjs/storybook-docs-sneak-peak-5be78445094a) +- Announcement: [DocsPage](https://medium.com/storybookjs/storybook-docspage-e185bc3622bf) +- Example: [Storybook Design System](https://github.com/storybookjs/design-system) From 3fcf4ec87aa3b3b14bf81a5b56c04f47fba95e53 Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Sat, 14 Dec 2019 12:03:26 +0800 Subject: [PATCH 131/132] SB docs point to ember framework docs --- addons/docs/README.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/addons/docs/README.md b/addons/docs/README.md index 3fc18942f30..1c36365a37b 100644 --- a/addons/docs/README.md +++ b/addons/docs/README.md @@ -131,8 +131,10 @@ Add the following to your Jest configuration: ### Be sure to check framework specific installation needs -- [Angular](./angular) +- [React](./react) (covered here) - [Vue](./vue) +- [Angular](./angular) +- [Ember](./ember) - [Web Components](./web-components) ## Preset options @@ -164,11 +166,10 @@ If you don't want to use the preset, and prefer to configure "the long way", fir ```js module.exports = { - addons: ['@storybook/addon-docs/register'] + addons: ['@storybook/addon-docs/register'], }; ``` - Then configure Storybook's webpack loader in `.storybook/main.js` to understand MDX story files and annotate TS/JS story files with source code using `source-loader`: ```js @@ -201,7 +202,7 @@ module.exports = { enforce: 'pre', }); return config; - } + }, }; ``` From a51ebffdc897026d93caf04dadf8247c837c7680 Mon Sep 17 00:00:00 2001 From: Michael Shilman Date: Sat, 14 Dec 2019 15:05:12 +0800 Subject: [PATCH 132/132] Add pocka to vue automention --- .github/automention.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/automention.yml b/.github/automention.yml index 177c7086be9..4e3688c40d4 100644 --- a/.github/automention.yml +++ b/.github/automention.yml @@ -7,7 +7,7 @@ 'app: react-native': ['benoitdion', 'gongreg'] 'app: react-native-server': ['benoitdion', 'gongreg'] 'app: svelte': ['rixo', 'cam-stitt', 'plumpNation'] -'app: vue': ['backbone87', 'elevatebart', 'pksunkara', 'Aaron-Pool'] +'app: vue': ['backbone87', 'elevatebart', 'pksunkara', 'Aaron-Pool', 'pocka'] 'app: web-components': ['daKmoR'] 'api: addons': ['ndelangen'] 'addon: a11y': ['CodeByAlex', 'Armanio', 'jsomsanith']