ol-close-button.tsx 427 B

123456789101112131415
  1. import { CloseButton, CloseButtonProps } from 'react-bootstrap'
  2. import { useTranslation } from 'react-i18next'
  3. import { forwardRef } from 'react'
  4. const OLCloseButton = forwardRef<HTMLButtonElement, CloseButtonProps>(
  5. (props, ref) => {
  6. const { t } = useTranslation()
  7. return <CloseButton ref={ref} aria-label={t('close')} {...props} />
  8. }
  9. )
  10. OLCloseButton.displayName = 'OLCloseButton'
  11. export default OLCloseButton