import React from 'react'
import { CircleDate } from './circle/CircleDate'
import { FlatDate } from './flat/FlatDate'
import { TextCalendarDate } from './text-calendar/TextCalendarDate'
import { TextDate } from './text/TextDate'
import { OutlineDate } from './outline/OutlineDate'

const itemStyles = {
  calendarFlat: FlatDate,
  calendarText: TextCalendarDate,
  circle: CircleDate,
  text: TextDate,
  outlines: OutlineDate
}

interface itemStyles {
  calendarFlat: string
  calendarText: string
  circle: string
  text: string
  outlines: string
}

interface Props {
  style: keyof typeof itemStyles,
  day: number,
  month: number
}

export const AnniversaryDate = ({ style, day, month }: Props) => {

  let StyledItem = itemStyles.hasOwnProperty(style) ? itemStyles[style] : itemStyles.text
  return (
    <StyledItem 
      day={day}
      month={month} />
  )
}

