saleor-dashboard/src/storybook/stories/components/MoneyRange.tsx
Krzysztof Wolski a82de30309
Add circleci config and enhance our linters (#519)
* Add circleci config

* Season linting config

* Apply code style
2020-05-14 11:30:32 +02:00

24 lines
659 B
TypeScript

import MoneyRange, { MoneyRangeProps } from "@saleor/components/MoneyRange";
import { storiesOf } from "@storybook/react";
import React from "react";
import CardDecorator from "../../CardDecorator";
import Decorator from "../../Decorator";
const props: MoneyRangeProps = {
from: {
amount: 5.2,
currency: "USD"
},
to: {
amount: 10.6,
currency: "USD"
}
};
storiesOf("Generics / Money range", module)
.addDecorator(CardDecorator)
.addDecorator(Decorator)
.add("from", () => <MoneyRange {...props} to={undefined} />)
.add("to", () => <MoneyRange {...props} from={undefined} />)
.add("range", () => <MoneyRange {...props} />);