|
| 1 | +import { Meta, StoryObj } from "@storybook/react" |
| 2 | + |
| 3 | +import ContributorsComponent, { type Contributor } from "." |
| 4 | + |
| 5 | +const meta = { |
| 6 | + title: "Molecules / Display Content / Contributors", |
| 7 | + component: ContributorsComponent, |
| 8 | + parameters: { |
| 9 | + layout: "fullscreen", |
| 10 | + }, |
| 11 | + decorators: [ |
| 12 | + (Story) => ( |
| 13 | + <article className="max-w-3xl scroll-mt-24"> |
| 14 | + <Story /> |
| 15 | + </article> |
| 16 | + ), |
| 17 | + ], |
| 18 | +} satisfies Meta<typeof ContributorsComponent> |
| 19 | + |
| 20 | +export default meta |
| 21 | + |
| 22 | +type Story = StoryObj<typeof meta> |
| 23 | + |
| 24 | +const mockContributors: Contributor[] = [ |
| 25 | + { |
| 26 | + login: "carlfairclough", |
| 27 | + name: "Carl Fairclough", |
| 28 | + avatar_url: "https://avatars1.githubusercontent.com/u/4670881?v=4", |
| 29 | + profile: "http://carlfairclough.me", |
| 30 | + contributions: ["design", "code", "bug"], |
| 31 | + }, |
| 32 | + { |
| 33 | + login: "RichardMcSorley", |
| 34 | + name: "Richard McSorley", |
| 35 | + avatar_url: "https://avatars2.githubusercontent.com/u/6407008?v=4", |
| 36 | + profile: "https://github.com/RichardMcSorley", |
| 37 | + contributions: ["code"], |
| 38 | + }, |
| 39 | + { |
| 40 | + login: "ajsantander", |
| 41 | + name: "Alejandro Santander", |
| 42 | + avatar_url: "https://avatars2.githubusercontent.com/u/550409?v=4", |
| 43 | + profile: "http://ajsantander.github.io/", |
| 44 | + contributions: ["content"], |
| 45 | + }, |
| 46 | + { |
| 47 | + login: "Lililashka", |
| 48 | + name: "Lililashka", |
| 49 | + avatar_url: "https://avatars1.githubusercontent.com/u/28689401?v=4", |
| 50 | + profile: "http://impermanence.co", |
| 51 | + contributions: ["design", "bug"], |
| 52 | + }, |
| 53 | + { |
| 54 | + login: "chriseth", |
| 55 | + name: "chriseth", |
| 56 | + avatar_url: "https://avatars2.githubusercontent.com/u/9073706?v=4", |
| 57 | + profile: "https://github.com/chriseth", |
| 58 | + contributions: ["content", "review"], |
| 59 | + }, |
| 60 | + { |
| 61 | + login: "fzeoli", |
| 62 | + name: "Franco Zeoli", |
| 63 | + avatar_url: "https://avatars2.githubusercontent.com/u/232174?v=4", |
| 64 | + profile: "https://nomiclabs.io", |
| 65 | + contributions: ["content", "review"], |
| 66 | + }, |
| 67 | + { |
| 68 | + login: "P1X3L0V4", |
| 69 | + name: "Anna Karpińska", |
| 70 | + avatar_url: "https://avatars2.githubusercontent.com/u/3372341?v=4", |
| 71 | + profile: "https://github.com/P1X3L0V4", |
| 72 | + contributions: ["translation"], |
| 73 | + }, |
| 74 | + { |
| 75 | + login: "vrde", |
| 76 | + name: "vrde", |
| 77 | + avatar_url: "https://avatars1.githubusercontent.com/u/134680?v=4", |
| 78 | + profile: "https://github.com/vrde", |
| 79 | + contributions: ["content"], |
| 80 | + }, |
| 81 | + { |
| 82 | + login: "AlexandrouR", |
| 83 | + name: "Rousos Alexandros", |
| 84 | + avatar_url: "https://avatars1.githubusercontent.com/u/21177075?v=4", |
| 85 | + profile: "https://github.com/AlexandrouR", |
| 86 | + contributions: ["content"], |
| 87 | + }, |
| 88 | + { |
| 89 | + login: "eswarasai", |
| 90 | + name: "Eswara Sai", |
| 91 | + avatar_url: "https://avatars2.githubusercontent.com/u/5172086?v=4", |
| 92 | + profile: "https://eswarasai.com", |
| 93 | + contributions: ["code"], |
| 94 | + }, |
| 95 | +] |
| 96 | + |
| 97 | +export const Contributors: Story = { |
| 98 | + args: { |
| 99 | + contributors: mockContributors, |
| 100 | + }, |
| 101 | +} |
0 commit comments