import { T9n } from 'features/T9n'

import {
  ScCurrency,
  ScPriceInfo,
  ScTitle,
  ScPrice,
  ScWatchDemo,
} from './styled'

export type PriceInfoType = {
  price: number,
  setIsOpenPopupVideo: (open: boolean) => void,
}

export const PriceInfo = ({ price, setIsOpenPopupVideo }: PriceInfoType) => (
  <ScPriceInfo>
    <ScTitle>
      <T9n t='price' />
    </ScTitle>
    <ScPrice>
      <ScCurrency>$</ScCurrency>
      {price}
    </ScPrice>
    <ScWatchDemo onClick={() => setIsOpenPopupVideo(true)}>
      <T9n t='watch_demo' />
    </ScWatchDemo>
  </ScPriceInfo>
)
