'use client' import { useTranslation } from 'react-i18next' import Link from 'next/link' import dayjs from 'dayjs' import { RiCloseLine } from '@remixicon/react' import s from './index.module.css' import classNames from '@/utils/classnames' import Modal from '@/app/components/base/modal' import type { LangGeniusVersionResponse } from '@/models/common' import { IS_CE_EDITION } from '@/config' import LogoSite from '@/app/components/base/logo/logo-site' type IAccountSettingProps = { langeniusVersionInfo: LangGeniusVersionResponse onCancel: () => void } const buttonClassName = ` shrink-0 flex items-center h-8 px-3 rounded-lg border border-gray-200 text-xs text-gray-800 font-medium ` export default function AccountAbout({ langeniusVersionInfo, onCancel, }: IAccountSettingProps) { const { t } = useTranslation() const isLatest = langeniusVersionInfo.current_version === langeniusVersionInfo.latest_version return ( { }} className={s.modal} >
Version {langeniusVersionInfo?.current_version}
© {dayjs().year()} LangGenius, Inc., Contributors.
{ IS_CE_EDITION ? Open Source License : <> Privacy Policy, Terms of Service }
{ isLatest ? t('common.about.latestAvailable', { version: langeniusVersionInfo.latest_version }) : t('common.about.nowAvailable', { version: langeniusVersionInfo.latest_version }) }
{t('common.about.changeLog')} { !isLatest && !IS_CE_EDITION && ( {t('common.about.updateNow')} ) }
) }