modal.tsx 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. 'use client'
  2. import type { FC } from 'react'
  3. import React from 'react'
  4. import { useTranslation } from 'react-i18next'
  5. import UpgradeBtn from '../upgrade-btn'
  6. import Modal from '../../base/modal'
  7. import Usage from './usage'
  8. import s from './style.module.css'
  9. import cn from '@/utils/classnames'
  10. import GridMask from '@/app/components/base/grid-mask'
  11. type Props = {
  12. show: boolean
  13. onHide: () => void
  14. }
  15. const AnnotationFullModal: FC<Props> = ({
  16. show,
  17. onHide,
  18. }) => {
  19. const { t } = useTranslation()
  20. return (
  21. <Modal
  22. isShow={show}
  23. onClose={onHide}
  24. closable
  25. className='!p-0'
  26. >
  27. <GridMask wrapperClassName='rounded-lg' canvasClassName='rounded-lg' gradientClassName='rounded-lg'>
  28. <div className='mt-6 px-7 py-6 border-2 border-solid border-transparent rounded-lg shadow-md flex flex-col transition-all duration-200 ease-in-out cursor-pointer'>
  29. <div className='flex justify-between items-center'>
  30. <div className={cn(s.textGradient, 'leading-[27px] text-[18px] font-semibold')}>
  31. <div>{t('billing.annotatedResponse.fullTipLine1')}</div>
  32. <div>{t('billing.annotatedResponse.fullTipLine2')}</div>
  33. </div>
  34. </div>
  35. <Usage className='mt-4' />
  36. <div className='mt-7 flex justify-end'>
  37. <UpgradeBtn loc={'annotation-create'} />
  38. </div>
  39. </div>
  40. </GridMask>
  41. </Modal>
  42. )
  43. }
  44. export default React.memo(AnnotationFullModal)