diff --git a/app/soapbox/components/translate-button.tsx b/app/soapbox/components/translate-button.tsx index d6059411c..e46855eb8 100644 --- a/app/soapbox/components/translate-button.tsx +++ b/app/soapbox/components/translate-button.tsx @@ -6,7 +6,7 @@ import { translateStatus, undoStatusTranslation } from 'soapbox/actions/statuses import { useAppDispatch, useAppSelector, useFeatures, useInstance } from 'soapbox/hooks'; import { isLocal } from 'soapbox/utils/accounts'; -import { Stack } from './ui'; +import { Icon, Stack } from './ui'; import type { Account, Status } from 'soapbox/types/entities'; @@ -44,16 +44,21 @@ const TranslateButton: React.FC = ({ status }) => { if (!features.translations || !renderTranslate || !supportsLanguages) return null; + const buttonClassName = 'flex items-center gap-0.5 w-fit px-2 py-1 border-gray-600 hover:border-gray-700 dark:hover:border-gray-500 border-solid border text-gray-600 hover:text-gray-700 dark:hover:text-gray-500 text-start text-sm rounded-full'; + if (status.translation) { const languageNames = new Intl.DisplayNames([intl.locale], { type: 'language' }); const languageName = languageNames.of(status.language!); const provider = status.translation.get('provider'); return ( - - + + + + - @@ -61,7 +66,8 @@ const TranslateButton: React.FC = ({ status }) => { } return ( - );