DocSpace-client/packages/asc-web-components/badge/badge.stories.js

47 lines
995 B
JavaScript
Raw Normal View History

import React from "react";
2019-07-03 13:23:53 +00:00
2021-03-01 21:32:59 +00:00
import Badge from "./";
export default {
title: "Components/Badge",
component: Badge,
parameters: {
docs: {
description: {
component: "Used for buttons, numbers or status markers next to icons.",
},
},
},
2021-03-01 21:32:59 +00:00
};
const Template = (args) => <Badge {...args} />;
const NumberTemplate = (args) => <Badge {...args} />;
const TextTemplate = (args) => <Badge {...args} />;
const MixedTemplate = (args) => <Badge {...args} />;
export const Default = Template.bind({});
Default.args = {
label: 24,
};
export const NumberBadge = NumberTemplate.bind({});
NumberBadge.argTypes = {
label: { control: "number" },
};
NumberBadge.args = {
label: 3,
};
export const TextBadge = TextTemplate.bind({});
TextBadge.argTypes = {
label: { control: "text" },
};
TextBadge.args = {
label: "New",
};
export const MixedBadge = MixedTemplate.bind({});
MixedBadge.argTypes = {
label: { control: "text" },
};
MixedBadge.args = {
label: "Ver.2",
};