aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/atoms/layout/copyright.stories.tsx
blob: fa79d32127def8b48d00b7a71b6125a44522a7e2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
import { ComponentMeta, ComponentStory } from '@storybook/react';
import { CCBySA } from '../icons';
import { Copyright as CopyrightComponent } from './copyright';

/**
 * Copyright - Storybook Meta
 */
export default {
  title: 'Atoms/Layout',
  component: CopyrightComponent,
  argTypes: {
    dates: {
      description: 'The copyright dates.',
      type: {
        name: 'object',
        required: true,
        value: {},
      },
    },
    icon: {
      control: {
        type: null,
      },
      description: 'The copyright icon.',
      type: {
        name: 'string',
        required: true,
      },
    },
    owner: {
      control: {
        type: 'text',
      },
      description: 'The copyright owner',
      type: {
        name: 'string',
        required: true,
      },
    },
  },
} as ComponentMeta<typeof CopyrightComponent>;

const Template: ComponentStory<typeof CopyrightComponent> = (args) => (
  <CopyrightComponent {...args} />
);

/**
 * Layout Stories - Copyright
 */
export const Copyright = Template.bind({});
Copyright.args = {
  dates: {
    start: '2012',
    end: '2022',
  },
  icon: <CCBySA />,
  owner: 'Your name',
};