Files
cms-server/client/cms/src/stories/events/event-grid.stories.tsx
Noa Virellia f12e7ac3c1
Some checks failed
Client CMS Check Build (NixCN CMS) TeamCity build failed
Backend Check Build (NixCN CMS) TeamCity build finished
feat(client): add KYC for event joining
Signed-off-by: Noa Virellia <noa@requiem.garden>
2026-02-05 19:12:57 +08:00

74 lines
2.5 KiB
TypeScript

import type { Meta, StoryObj } from '@storybook/react-vite';
import { EventGridSkeleton } from '@/components/events/event-grid.skeleton';
import { EventGridView } from '@/components/events/event-grid.view';
import { Button } from '@/components/ui/button';
import { Skeleton as UiSkeleton } from '@/components/ui/skeleton';
const meta = {
title: 'Events/EventGrid',
component: EventGridView,
} satisfies Meta<typeof EventGridView>;
export default meta;
type Story = StoryObj<typeof meta>;
export const Primary: Story = {
args: {
events: [
{
eventId: '1',
requireKyc: true,
isJoined: false,
type: 'official',
coverImage: 'https://github.com/NixOS/nixos-artwork/blob/master/wallpapers/nix-wallpaper-watersplash.png?raw=true',
eventName: 'Nix CN Conference 26.05',
description: 'Event Description',
startTime: new Date('2026-06-13T04:00:00.000Z'),
endTime: new Date('2026-06-14T04:00:00.000Z'),
},
{
eventId: '2',
requireKyc: true,
isJoined: false,
type: 'official',
coverImage: 'https://github.com/NixOS/nixos-artwork/blob/master/wallpapers/nix-wallpaper-moonscape.png?raw=true',
eventName: 'Nix CN Conference 26.05',
description: 'Event Description',
startTime: new Date('2026-06-13T04:00:00.000Z'),
endTime: new Date('2026-06-14T04:00:00.000Z'),
},
{
eventId: '3',
requireKyc: true,
isJoined: false,
type: 'official',
coverImage: 'https://github.com/NixOS/nixos-artwork/blob/master/wallpapers/nix-wallpaper-nineish-catppuccin-latte.png?raw=true',
eventName: 'Nix CN Conference 26.05',
description: 'Event Description',
startTime: new Date('2026-06-13T04:00:00.000Z'),
endTime: new Date('2026-06-14T04:00:00.000Z'),
},
{
eventId: '4',
requireKyc: true,
isJoined: false,
type: 'official',
coverImage: 'https://github.com/NixOS/nixos-artwork/blob/master/wallpapers/nixos-wallpaper-catppuccin-macchiato.png?raw=true',
eventName: 'Nix CN Conference 26.05',
description: 'Event Description',
startTime: new Date('2026-06-13T04:00:00.000Z'),
endTime: new Date('2026-06-14T04:00:00.000Z'),
},
],
assembleFooter: () => <Button className="w-full"></Button>,
},
};
export const Skeleton: Story = {
render: () => <EventGridSkeleton />,
args: {
events: [],
assembleFooter: () => <UiSkeleton className="w-full" />,
},
};