import type { Meta, StoryObj } from '@storybook/react';
import HistoryCard from './HistoryCard';
import './HistoryCard.scss';

const meta: Meta<typeof HistoryCard> = {
  title: 'Components/HistoryCard',
  component: HistoryCard,
  parameters: {
    layout: 'centered',
  },
  tags: ['autodocs'],
};

type Story = StoryObj<typeof HistoryCard>;

export const Approved: Story = {
  args: {
    comment:
      'Requested the element for review to use in a login to fireflink scripts',
    title: [
      <span className="bold">Nithin</span>,
      ' approved the Element on',
      <span className="bold"> 19 Dec 2023 </span>,
      '1.30 PM',
    ],
    state: 'approved',
    version: '1.0',
    variant: 'success',
    profileShortName: 'PB',
  },
};

export const Review: Story = {
  args: {
    ...Approved.args,
    comment:
      'Requested the element for review to use in a login to fireflink scripts',
    variant: 'warning',
    title: [
      <span className="bold">Sourab</span>,
      ' Requested The Element For Review For',
      <span className="bold"> Nithin </span>,
      'On',
      <span className="bold"> 19 Dec 2023 </span>,
      '1.30 PM',
    ],
  },
};

export default meta;
