Internationalize remaining TODO-marked UI text in Expo app

This commit is contained in:
Adolfo Reyna
2026-02-20 22:30:20 -05:00
parent a8d21d31f8
commit 06e620dbf6
16 changed files with 230 additions and 69 deletions

View File

@@ -9,6 +9,7 @@ import ProfileHeader from '../components/ProfileHeader.js';
import AsyncStorage from '@react-native-async-storage/async-storage';
import { useSnapshot } from 'valtio';
import GlobalState from '../contexts/GlobalState.js';
import i18n from "../i18nMessages.js";
const PROFILE_LOG_PREFIX = '[Profile]';
const logProfile = (...args) => {
@@ -203,18 +204,18 @@ let Profile = ({ navigation, route }) => {
navigation.navigate('NewPost', {toProfile: profile._id})
}} />
</View>
<Button style={{paddingLeft:12, backgroundColor:"#fff"}} title="Images" icon={tag == 'images' ? 'remove' : "image"} mode="outlined" onPress={()=>{
<Button style={{paddingLeft:12, backgroundColor:"#fff"}} title={i18n.t("message.images")} icon={tag == 'images' ? 'remove' : "image"} mode="outlined" onPress={()=>{
if(tag == 'images') return setTag('');
setTag('images');
}}>{tag == 'images' ? "Images" : ''}</Button>
<Button style={{paddingLeft:12, backgroundColor:"#fff"}} title="Media" icon={tag == 'media' ? 'remove' : "subscriptions"} mode="outlined" onPress={()=>{
}}>{tag == 'images' ? i18n.t("message.images") : ''}</Button>
<Button style={{paddingLeft:12, backgroundColor:"#fff"}} title={i18n.t("message.media")} icon={tag == 'media' ? 'remove' : "subscriptions"} mode="outlined" onPress={()=>{
if(tag == 'media') return setTag('');
setTag('media');
}}>{tag == 'media' ? "Media" : ''}</Button>
<Button style={{paddingLeft:12, backgroundColor:"#fff"}} title="Embedded" icon={tag == 'embedded' ? 'remove' : "folder"} mode="outlined" onPress={()=>{
}}>{tag == 'media' ? i18n.t("message.media") : ''}</Button>
<Button style={{paddingLeft:12, backgroundColor:"#fff"}} title={i18n.t("message.embedded")} icon={tag == 'embedded' ? 'remove' : "folder"} mode="outlined" onPress={()=>{
if(tag == 'embedded') return setTag('');
setTag('embedded');
}}>{tag == 'embedded' ? "Files" : ''}</Button>
}}>{tag == 'embedded' ? i18n.t("message.files") : ''}</Button>
</View>
{isOwnedGroup ? (
<View style={styles.deleteGroupRow}>
@@ -226,7 +227,7 @@ let Profile = ({ navigation, route }) => {
disabled={isDeletingGroup}
onPress={handleDeleteGroup}
>
Delete Group
{i18n.t("message.deleteGroup")}
</Button>
</View>
) : <></>}