Simpler server addons

This commit is contained in:
Jon Palmer 2020-02-22 10:01:27 -05:00
parent 4703c15e55
commit 69653e02d7
8 changed files with 6 additions and 17 deletions

View File

@ -1,6 +1,6 @@
{ {
"title": "Kitchen Sink", "title": "Kitchen Sink",
"addons": ["a11y", "knobs", "actions", "links"], "addons": ["knobs", "actions"],
"parameters": { "parameters": {
"backgrounds": [ "backgrounds": [
{ "name": "light", "value": "#eeeeee" }, { "name": "light", "value": "#eeeeee" },

View File

@ -1,16 +1,12 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP // Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`json-to-csf-compiler kitchen_sink.json 1`] = ` exports[`json-to-csf-compiler kitchen_sink.json 1`] = `
"import { withA11y } from '@storybook/addon-a11y'; "import { array, boolean, color, date, number, object, select, text, withKnobs } from '@storybook/addon-knobs';
import { withLinks } from '@storybook/addon-links';
import { array, boolean, color, date, number, object, select, text, withKnobs } from '@storybook/addon-knobs';
import { withActions } from '@storybook/addon-actions'; import { withActions } from '@storybook/addon-actions';
export default { export default {
title: 'Kitchen Sink', title: 'Kitchen Sink',
decorators: [ decorators: [
withA11y,
withLinks,
withKnobs withKnobs
], ],
parameters: { parameters: {

View File

@ -1,6 +1,5 @@
{ {
"title": "Welcome", "title": "Welcome",
"addons": ["links"],
"stories": [ "stories": [
{ {
"name": "Welcome", "name": "Welcome",

View File

@ -1,13 +1,9 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP // Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`json-to-csf-compiler links.json 1`] = ` exports[`json-to-csf-compiler links.json 1`] = `
"import { withLinks } from '@storybook/addon-links'; "
export default { export default {
title: 'Welcome', title: 'Welcome',
decorators: [
withLinks
],
}; };
export const Welcome = () => {}; export const Welcome = () => {};

View File

@ -1,7 +1,7 @@
import { addParameters, addDecorator } from '@storybook/server'; import { addParameters, addDecorator } from '@storybook/server';
import { withA11y } from '@storybook/addon-a11y'; import { withLinks } from '@storybook/addon-links';
addDecorator(withA11y); addDecorator(withLinks);
const port = process.env.SERVER_PORT || 1337; const port = process.env.SERVER_PORT || 1337;

View File

@ -1,6 +1,5 @@
{ {
"title": "Addons/a11y", "title": "Addons/a11y",
"addons": ["a11y"],
"parameters": { "parameters": {
"options": { "selectedPanel": "storybook/a11y/panel" } "options": { "selectedPanel": "storybook/a11y/panel" }
}, },

View File

@ -1,6 +1,6 @@
{ {
"title": "Kitchen Sink", "title": "Kitchen Sink",
"addons": ["a11y", "knobs", "actions", "links"], "addons": ["knobs", "actions"],
"parameters": { "parameters": {
"backgrounds": [ "backgrounds": [
{ "name": "light", "value": "#eeeeee" }, { "name": "light", "value": "#eeeeee" },

View File

@ -1,6 +1,5 @@
{ {
"title": "Welcome", "title": "Welcome",
"addons": ["links"],
"stories": [ "stories": [
{ {
"name": "Welcome", "name": "Welcome",