feat: translation (#389)

This commit is contained in:
Cody Tseng 2025-06-23 23:52:21 +08:00 committed by GitHub
parent e2e115ebeb
commit df9066eae0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
43 changed files with 1466 additions and 47 deletions

View file

@ -1,7 +1,13 @@
import AboutInfoDialog from '@/components/AboutInfoDialog'
import Donation from '@/components/Donation'
import SecondaryPageLayout from '@/layouts/SecondaryPageLayout'
import { toGeneralSettings, toPostSettings, toRelaySettings, toWallet } from '@/lib/link'
import {
toGeneralSettings,
toPostSettings,
toRelaySettings,
toTranslation,
toWallet
} from '@/lib/link'
import { cn } from '@/lib/utils'
import { useSecondaryPage } from '@/PageManager'
import { useNostr } from '@/providers/NostrProvider'
@ -11,6 +17,7 @@ import {
Copy,
Info,
KeyRound,
Languages,
PencilLine,
Server,
Settings2,
@ -42,6 +49,13 @@ const SettingsPage = forwardRef(({ index }: { index?: number }, ref) => {
</div>
<ChevronRight />
</SettingItem>
<SettingItem className="clickable" onClick={() => push(toTranslation())}>
<div className="flex items-center gap-4">
<Languages />
<div>{t('Translation')}</div>
</div>
<ChevronRight />
</SettingItem>
<SettingItem className="clickable" onClick={() => push(toWallet())}>
<div className="flex items-center gap-4">
<Wallet />