37 lines
1.0 KiB
TypeScript
37 lines
1.0 KiB
TypeScript
import type { Meta, StoryObj } from '@storybook/react-vite';
|
|
import { EventCardSkeleton } from '@/components/events/event-card.skeleton';
|
|
import { EventCardView } from '@/components/events/event-card.view';
|
|
|
|
const meta = {
|
|
title: 'Events/EventCard',
|
|
component: EventCardView,
|
|
} satisfies Meta<typeof EventCardView>;
|
|
|
|
export default meta;
|
|
type Story = StoryObj<typeof meta>;
|
|
|
|
export const Primary: Story = {
|
|
args: {
|
|
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'),
|
|
onJoinEvent: () => { },
|
|
},
|
|
};
|
|
|
|
export const Loading: Story = {
|
|
render: () => <EventCardSkeleton />,
|
|
args: {
|
|
type: 'official',
|
|
coverImage: '',
|
|
eventName: '',
|
|
description: '',
|
|
startTime: new Date(0),
|
|
endTime: new Date(0),
|
|
onJoinEvent: () => { },
|
|
},
|
|
};
|