feat(ui): More translations

This commit is contained in:
PapaTutuWawa 2024-03-30 22:02:36 +01:00
parent d7927d3ca9
commit af83d50f67
2 changed files with 5 additions and 22 deletions

View File

@ -174,7 +174,9 @@
"login": "Login" "login": "Login"
}, },
"home": { "home": {
"addAccount": "Add new account" "addAccount": "Add new account",
"searchNoResults": "No search results...",
"chat": "Chat"
}, },
"conversations": { "conversations": {
"speeddialNewChat": "New chat", "speeddialNewChat": "New chat",

View File

@ -258,23 +258,6 @@ class ConversationsPageState extends State<ConversationsPage>
_conversationKeys[item.jid] = key; _conversationKeys[item.jid] = key;
} }
// TODO: Port the rest
/*final row = ConversationsListRow(
item,
true,
enableAvatarOnTap: true,
isSelected: _selectedConversation?.jid == item.jid,
onPressed: () {
GetIt.I.get<ConversationBloc>().add(
RequestedConversationEvent(
item.jid,
item.title,
item.avatarPath,
),
);
},
key: key,
);*/
final row = ConversationCard( final row = ConversationCard(
conversation: item, conversation: item,
highlightWord: highlightWord, highlightWord: highlightWord,
@ -350,8 +333,7 @@ class ConversationsPageState extends State<ConversationsPage>
child: Text( child: Text(
hasSearchResults hasSearchResults
? ?
// TODO: i18n t.pages.home.searchNoResults
'No search results...'
: t.pages.conversations.noOpenChats, : t.pages.conversations.noOpenChats,
), ),
), ),
@ -475,8 +457,7 @@ class ConversationsPageState extends State<ConversationsPage>
), ),
floatingActionButton: FloatingActionButton.extended( floatingActionButton: FloatingActionButton.extended(
onPressed: () => Navigator.pushNamed(context, newConversationRoute), onPressed: () => Navigator.pushNamed(context, newConversationRoute),
// TODO: i18n label: Text(t.pages.home.chat),
label: const Text('Chat'),
icon: const Icon(Icons.chat_outlined), icon: const Icon(Icons.chat_outlined),
backgroundColor: Theme.of(context).colorScheme.secondaryContainer, backgroundColor: Theme.of(context).colorScheme.secondaryContainer,
foregroundColor: Theme.of(context).colorScheme.onSecondaryContainer, foregroundColor: Theme.of(context).colorScheme.onSecondaryContainer,