Skip to content

Commit

Permalink
feat: tweaked storybook version, updated title format, and hoping thi…
Browse files Browse the repository at this point in the history
…s will help with fonts?
  • Loading branch information
CesarBenavides777 committed Feb 21, 2021
1 parent 40c83a8 commit c71ec21
Show file tree
Hide file tree
Showing 57 changed files with 1,766 additions and 1,286 deletions.
2 changes: 1 addition & 1 deletion .jest-test-results.json

Large diffs are not rendered by default.

5 changes: 5 additions & 0 deletions conf/storybook/magaer-head.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<style type="text/css">
[href='http://localhost:54979/'] {
display: none !important;
}
</style>
9 changes: 3 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,13 @@
"@rollup/plugin-json": "4.0.3",
"@semantic-release/github": "^7.2.0",
"@storybook/addon-a11y": "5.3.18",
"@storybook/addon-actions": "^6.1.11",
"@storybook/addon-actions": "5.3.18",
"@storybook/addon-docs": "5.3.18",
"@storybook/addon-essentials": "^6.1.11",
"@storybook/addon-jest": "5.3.18",
"@storybook/addon-knobs": "5.3.18",
"@storybook/addon-links": "^6.1.11",
"@storybook/addon-storysource": "5.3.18",
"@storybook/node-logger": "^6.1.11",
"@storybook/preset-create-react-app": "^3.1.5",
"@storybook/react": "^6.1.11",
"@storybook/addon-viewport": "^6.1.17",
"@storybook/react": "5.3.18",
"@testing-library/jest-dom": "5.11.1",
"@testing-library/react": "10.4.7",
"axios": "^0.21.0",
Expand Down
4 changes: 2 additions & 2 deletions src/ContentComponents/Hero/Hero.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ const videoSrc = {
const headline2Text =
"Optional body subtitle ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.";

storiesOf("Content Components/Hero", module)
storiesOf("Content Components | Hero", module)
.addDecorator(withSmartKnobs())
.add("w/Knobs", () => (
<div className="sb-no-padding">
Expand All @@ -57,7 +57,7 @@ storiesOf("Content Components/Hero", module)
</div>
));

storiesOf("Content Components/Hero", module)
storiesOf("Content Components | Hero", module)
.add("50/50, Image Right", () => (
<div className="sb-no-padding">
<Hero
Expand Down
2 changes: 1 addition & 1 deletion src/ContentComponents/Shell/Shell.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { storiesOf } from "@storybook/react";
import { withSmartKnobs } from "storybook-addon-smart-knobs";
import { Shell } from "./";

storiesOf("Content Components/Shell", module)
storiesOf("Content Components | Shell", module)
.addDecorator(withSmartKnobs())
.add("Full Width", () => <Shell>Full Width</Shell>)
.add("Contained", () => <Shell contained>contained coontent</Shell>);
2 changes: 1 addition & 1 deletion src/ContentComponents/Tabs/Tabs.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { ContentCard } from "../../components/ContentCard";
import { Grid } from "../../components/Grid";
import * as mockContentCardData from "../../components/ContentCard/mockData/mockContentCardData.json";

storiesOf("Content Components/Tabs", module)
storiesOf("Content Components | Tabs", module)
.add("2 Tabs", () => (
<div className="sb-no-padding">
<Tabs ariaLabel="example tabs">
Expand Down
2 changes: 1 addition & 1 deletion src/Overview/DesignTokens/DesignTokens.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { Layout } from "./Layout";
import { Color } from "./Color";
import { TypographyToken } from "./TypographyToken";

storiesOf("overview/Design Tokens", module)
storiesOf("overview | Design Tokens", module)
.add("Layout", () => <Layout />)
.add("Color", () => <Color />)
.add("Typography", () => <TypographyToken />);
2 changes: 1 addition & 1 deletion src/Overview/Overview.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ import React from "react";
import { storiesOf } from "@storybook/react";
import { Overview } from "./Overview";

storiesOf("overview/Introduction", module).add("Introduction", () => (
storiesOf("overview | Introduction", module).add("Introduction", () => (
<Overview />
));
2 changes: 1 addition & 1 deletion src/components/AccentIcon/AccentIcon.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const parameters = {
jest: ["AccentIcon"]
};

storiesOf("components/AccentIcon", module)
storiesOf("components | AccentIcon", module)
.addParameters(parameters)
.addDecorator(
withSmartKnobs({ ignoreProps: ["icon", "accent", "accentColor"] })
Expand Down
2 changes: 1 addition & 1 deletion src/components/Accordion/Accordion.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ const AccordionExampleTwo = (
/>
</Accordion>
);
storiesOf("components/Accordion", module)
storiesOf("components | Accordion", module)
.addParameters(parameters)
.add("Default", () => AccordionExample)
.add("Accordion contained in a 320px wide <div>", () => (
Expand Down
2 changes: 1 addition & 1 deletion src/components/Address/Address.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const store = {
zip: "78756"
};

storiesOf("components/Address", module)
storiesOf("components | Address", module)
.addParameters(parameters)
.addDecorator(withSmartKnobs({ ignoreProps: [] }))
.add("Default", () => (
Expand Down
20 changes: 9 additions & 11 deletions src/components/Badge/Badge.stories.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,16 @@
import React from 'react';
import { storiesOf } from '@storybook/react';
import { withSmartKnobs } from 'storybook-addon-smart-knobs';
import React from "react";
import { storiesOf } from "@storybook/react";
import { withSmartKnobs } from "storybook-addon-smart-knobs";

import { Badge } from './';
import { Badge } from "./";

const parameters = {
component: Badge,
componentSubtitle: 'Utilize <Badge /> to present a notification badge',
jest: ['Badge'],
componentSubtitle: "Utilize <Badge /> to present a notification badge",
jest: ["Badge"]
};

storiesOf('components/Badge', module)
storiesOf("components | Badge", module)
.addParameters(parameters)
.addDecorator(
withSmartKnobs({ ignoreProps: [] }),
)
.add('Default', () => <Badge count={1} />);
.addDecorator(withSmartKnobs({ ignoreProps: [] }))
.add("Default", () => <Badge count={1} />);
2 changes: 1 addition & 1 deletion src/components/Breadcrumbs/Breadcrumbs.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from "react";
import { storiesOf } from "@storybook/react";
import { Breadcrumbs } from "./";

const storyTitle = "components/Breadcrumbs"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator
const storyTitle = "components | Breadcrumbs"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator

const parameters = {
component: Breadcrumbs,
Expand Down
34 changes: 18 additions & 16 deletions src/components/Button/Button.stories.js
Original file line number Diff line number Diff line change
@@ -1,27 +1,29 @@
import React from 'react';
import { storiesOf } from '@storybook/react';
import { withSmartKnobs } from 'storybook-addon-smart-knobs';
import { select, boolean } from '@storybook/addon-knobs';
import { Button } from './';
import iconArray from '../Icon/helpers/getIconArray';
import React from "react";
import { storiesOf } from "@storybook/react";
import { withSmartKnobs } from "storybook-addon-smart-knobs";
import { select, boolean } from "@storybook/addon-knobs";
import { Button } from "./";
import iconArray from "../Icon/helpers/getIconArray";

const parameters = {
component: Button,
componentSubtitle: 'The <Button /> tag defines a clickable button',
jest: ['Button'],
componentSubtitle: "The <Button /> tag defines a clickable button",
jest: ["Button"]
};

const optionalIconArray = ['', ...iconArray];
const optionalIconArray = ["", ...iconArray];

storiesOf('components/Button', module)
storiesOf("components | Button", module)
.addParameters(parameters)
.addDecorator(withSmartKnobs({ ignoreProps: ['disabled', 'iconLeft', 'iconRight'] }))
.add('Default', (() => (
.addDecorator(
withSmartKnobs({ ignoreProps: ["disabled", "iconLeft", "iconRight"] })
)
.add("Default", () => (
<Button
disabled={boolean('disabled', false)}
iconLeft={select('iconLeft', optionalIconArray, '')}
iconRight={select('iconRight', optionalIconArray, '')}
disabled={boolean("disabled", false)}
iconLeft={select("iconLeft", optionalIconArray, "")}
iconRight={select("iconRight", optionalIconArray, "")}
>
Label
</Button>
)));
));
2 changes: 1 addition & 1 deletion src/components/Carousel/Carousel.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { withSmartKnobs } from "storybook-addon-smart-knobs";
import Carousel from "./Carousel";
import { Typography } from "../Typography";

const storyTitle = "components/Carousel"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator
const storyTitle = "components | Carousel"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator

const parameters = {
component: Carousel,
Expand Down
2 changes: 1 addition & 1 deletion src/components/Collapse/Collapse.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ const CollapseUseExampleComponentWithCheckbox = ({
);
};

storiesOf("components/Collapse", module)
storiesOf("components | Collapse", module)
.addParameters(parameters)
.addDecorator(withKnobs())
.add("Button Trigger", () => (
Expand Down
2 changes: 1 addition & 1 deletion src/components/ContentCard/ContentCard.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@ const parameters = {
jest: ["CotentCard"]
};

storiesOf("components/ContentCard", module)
storiesOf("components | ContentCard", module)
.addParameters(parameters)
.add("Default", () => <Grid grid={4}>{cards}</Grid>);
2 changes: 1 addition & 1 deletion src/components/ContentPanels/ContentPanels.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ const ContentPanelsExample = () => {
);
};

storiesOf("components/ContentPanels", module)
storiesOf("components | ContentPanels", module)
.addParameters(parameters)
.addDecorator(withSmartKnobs({ ignoreProps: [] }))
.add("Default", () => (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const parameters = {
jest: ["CulturalIndicator"]
};

storiesOf("components/CulturalIndicator", module)
storiesOf("components | CulturalIndicator", module)
.addParameters(parameters)
.addDecorator(withSmartKnobs({ ignoreProps: "onClick" }))
.add("Default", () => (
Expand Down
2 changes: 1 addition & 1 deletion src/components/DataLayer/DataLayer.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const exampleObj = '{ "cart": { "productId": "12345" }}';
const exampleArray =
'{ "eventInfo": { "eventName": "Find a store", "eventAction": "Show More" }}';

storiesOf("components/DataLayer", module)
storiesOf("components | DataLayer", module)
.addParameters(parameters)
.add("Default", () => (
<div>
Expand Down
2 changes: 1 addition & 1 deletion src/components/DescriptionList/DescriptionList.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { storiesOf } from "@storybook/react";
import { withSmartKnobs } from "storybook-addon-smart-knobs";
import { DescriptionList } from "./";

const storyTitle = "components/DescriptionList"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator
const storyTitle = "components | DescriptionList"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator

const DescriptionListParameters = {
component: DescriptionList,
Expand Down
2 changes: 1 addition & 1 deletion src/components/Dialog/Dialog.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const parameters = {
jest: ["Dialog"]
};

storiesOf("components/Dialog", module)
storiesOf("components | Dialog", module)
.addParameters(parameters)
.addDecorator(withSmartKnobs({ ignoreProps: ["type", "children"] }))
.add("Modal", () => (
Expand Down
2 changes: 1 addition & 1 deletion src/components/Footer/Footer.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { storiesOf } from "@storybook/react";
import { withSmartKnobs } from "storybook-addon-smart-knobs";
import { Footer } from "./";

const storyTitle = "components/Footer"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator
const storyTitle = "components | Footer"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator

const FooterParameters = {
component: Footer,
Expand Down
2 changes: 1 addition & 1 deletion src/components/FormFields/Checkbox/Checkbox.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { withSmartKnobs } from "storybook-addon-smart-knobs";
import { boolean } from "@storybook/addon-knobs";
import { Checkbox } from "./";

const storyTitle = "components/Form Fields/Checkbox"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator
const storyTitle = "components | Form Fields/Checkbox"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator

const CheckboxParameters = {
component: Checkbox,
Expand Down
2 changes: 1 addition & 1 deletion src/components/FormFields/Dropdown/Dropdown.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ const DropdownOptions = [
// }
// ];

storiesOf("components/Form Fields/Dropdown", module)
storiesOf("components | Form Fields/Dropdown", module)
.addParameters(DropdownParameters)
.addDecorator(
withSmartKnobs({ ignoreProps: ["children", "storybookErrorPreview"] })
Expand Down
2 changes: 1 addition & 1 deletion src/components/FormFields/Fieldset/Fieldset.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { RadioButton } from "../RadioButton";
import { Checkbox } from "../Checkbox";
import { Image } from "../../Image";

const storyTitle = "components/Form Fields/Fieldset";
const storyTitle = "components | Form Fields/Fieldset";

const FieldsetParameters = {
component: Fieldset,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { RadioButton } from "./";
import { Image } from "../../Image";
import { Button } from "../../Button";

const storyTitle = "components/Form Fields/Radio Button"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator
const storyTitle = "components | Form Fields/Radio Button"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator

const RadioButtonParameters = {
component: RadioButton,
Expand Down
2 changes: 1 addition & 1 deletion src/components/FormFields/Range/Range.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import withFormik from "storybook-formik";
import { withSmartKnobs } from "storybook-addon-smart-knobs";
import { Range } from "./";

const storyTitle = "components/Form Fields/Range"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator
const storyTitle = "components | Form Fields/Range"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator

const CheckboxParameters = {
component: Range,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const parameters = {
jest: ["SegmentedControl"]
};

storiesOf("components/Form Fields/SegmentedControl", module)
storiesOf("components | Form Fields/SegmentedControl", module)
.addParameters(parameters)
.addDecorator(withSmartKnobs({}))
.addDecorator(withFormik)
Expand Down
2 changes: 1 addition & 1 deletion src/components/FormFields/TextField/TextField.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const TextFieldParameters = {
jest: ["TextField"]
};

storiesOf("components/Form Fields/Text Field", module)
storiesOf("components | Form Fields/Text Field", module)
.addParameters(TextFieldParameters)
.addDecorator(
withSmartKnobs({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const parameters = {
jest: ["ToggleSwitch"]
};

storiesOf("components/Form Fields/ToggleSwitch", module)
storiesOf("components | Form Fields/ToggleSwitch", module)
.addParameters(parameters)
.addDecorator(
withSmartKnobs({
Expand Down
2 changes: 1 addition & 1 deletion src/components/Grid/Grid.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { withSmartKnobs } from "storybook-addon-smart-knobs";
import { select } from "@storybook/addon-knobs";
import { Grid } from "./";

const storyTitle = "components/Grid"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator
const storyTitle = "components | Grid"; // Stories can be organized in a nested structure using ”/” as a separator, and can be given a top-level heading using a ”|” root separator

const parameters = {
component: Grid,
Expand Down
4 changes: 2 additions & 2 deletions src/components/Icon/Icon.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const parameters = {
jest: ["Icon"]
};

storiesOf("components/Icon", module)
storiesOf("components | Icon", module)
.addParameters(parameters)
.add("Labels", () => (
<div className="sb-icon-container labels">
Expand All @@ -36,7 +36,7 @@ storiesOf("components/Icon", module)
))}
</div>
));
storiesOf("components/Icon", module)
storiesOf("components | Icon", module)
.addParameters(parameters)
.addDecorator(withSmartKnobs())
.add("With Badge", () => <Icon name="notification-default" badgeCount={1} />);
Expand Down
2 changes: 1 addition & 1 deletion src/components/IconButton/IconButton.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const parameters = {
jest: ["IconButton"]
};

storiesOf("components/IconButton", module)
storiesOf("components | IconButton", module)
.addParameters(parameters)
.addDecorator(withSmartKnobs({ ignoreProps: ["disabled", "icon"] }))
.add("Default", () => (
Expand Down
Loading

0 comments on commit c71ec21

Please sign in to comment.