Skip to content

Commit e2ff124

Browse files
authored
chore: update translation (#7666)
1 parent edd59cf commit e2ff124

File tree

6 files changed

+61
-34
lines changed

6 files changed

+61
-34
lines changed

frontend/appflowy_flutter/lib/mobile/presentation/home/setting/settings_popup_menu.dart

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ enum _MobileSettingsPopupMenuItem {
1616
members,
1717
trash,
1818
help,
19+
helpAndDocumentation,
1920
}
2021

2122
class HomePageSettingsPopupMenu extends StatelessWidget {
@@ -62,10 +63,16 @@ class HomePageSettingsPopupMenu extends StatelessWidget {
6263
text: LocaleKeys.settings_popupMenuItem_trash.tr(),
6364
),
6465
const PopupMenuDivider(height: 0.5),
66+
_buildItem(
67+
value: _MobileSettingsPopupMenuItem.helpAndDocumentation,
68+
svg: FlowySvgs.help_and_documentation_s,
69+
text: LocaleKeys.settings_popupMenuItem_helpAndDocumentation.tr(),
70+
),
71+
const PopupMenuDivider(height: 0.5),
6572
_buildItem(
6673
value: _MobileSettingsPopupMenuItem.help,
6774
svg: FlowySvgs.message_support_s,
68-
text: LocaleKeys.settings_popupMenuItem_helpAndSupport.tr(),
75+
text: LocaleKeys.settings_popupMenuItem_getSupport.tr(),
6976
),
7077
],
7178
onSelected: (_MobileSettingsPopupMenuItem value) {
@@ -82,6 +89,9 @@ class HomePageSettingsPopupMenu extends StatelessWidget {
8289
case _MobileSettingsPopupMenuItem.help:
8390
_openHelpPage(context);
8491
break;
92+
case _MobileSettingsPopupMenuItem.helpAndDocumentation:
93+
_openHelpAndDocumentationPage(context);
94+
break;
8595
}
8696
},
8797
child: const Padding(
@@ -123,6 +133,10 @@ class HomePageSettingsPopupMenu extends StatelessWidget {
123133
void _openSettingsPage(BuildContext context) {
124134
context.push(MobileHomeSettingPage.routeName);
125135
}
136+
137+
void _openHelpAndDocumentationPage(BuildContext context) {
138+
afLaunchUrlString('https://appflowy.com/guide');
139+
}
126140
}
127141

128142
class _PopupButton extends StatelessWidget {

frontend/appflowy_flutter/lib/workspace/presentation/widgets/float_bubble/question_bubble.dart

Lines changed: 26 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ class _BubbleActionListState extends State<BubbleActionList> {
8686
),
8787
buildChild: (controller) {
8888
return FlowyTooltip(
89-
message: LocaleKeys.questionBubble_help.tr(),
89+
message: LocaleKeys.questionBubble_getSupport.tr(),
9090
child: MouseRegion(
9191
cursor: SystemMouseCursors.click,
9292
child: GestureDetector(
@@ -121,29 +121,34 @@ class _BubbleActionListState extends State<BubbleActionList> {
121121
if (action is BubbleActionWrapper) {
122122
switch (action.inner) {
123123
case BubbleAction.whatsNews:
124-
afLaunchUrlString("https://www.appflowy.io/what-is-new");
124+
afLaunchUrlString('https://www.appflowy.io/what-is-new');
125125
break;
126-
case BubbleAction.help:
127-
afLaunchUrlString("https://discord.gg/9Q2xaN37tV");
126+
case BubbleAction.getSupport:
127+
afLaunchUrlString('https://discord.gg/9Q2xaN37tV');
128128
break;
129129
case BubbleAction.debug:
130130
_DebugToast().show();
131131
break;
132132
case BubbleAction.shortcuts:
133133
afLaunchUrlString(
134-
"https://docs.appflowy.io/docs/appflowy/product/shortcuts",
134+
'https://docs.appflowy.io/docs/appflowy/product/shortcuts',
135135
);
136136
break;
137137
case BubbleAction.markdown:
138138
afLaunchUrlString(
139-
"https://docs.appflowy.io/docs/appflowy/product/markdown",
139+
'https://docs.appflowy.io/docs/appflowy/product/markdown',
140140
);
141141
break;
142142
case BubbleAction.github:
143143
afLaunchUrlString(
144144
'https://github.com/AppFlowy-IO/AppFlowy/issues/new/choose',
145145
);
146146
break;
147+
case BubbleAction.helpAndDocumentation:
148+
afLaunchUrlString(
149+
'https://appflowy.com/guide',
150+
);
151+
break;
147152
}
148153
}
149154

@@ -155,7 +160,7 @@ class _BubbleActionListState extends State<BubbleActionList> {
155160

156161
class _DebugToast {
157162
void show() async {
158-
String debugInfo = "";
163+
String debugInfo = '';
159164
debugInfo += await _getDeviceInfo();
160165
debugInfo += await _getDocumentPath();
161166
await Clipboard.setData(ClipboardData(text: debugInfo));
@@ -168,20 +173,21 @@ class _DebugToast {
168173
final deviceInfo = await deviceInfoPlugin.deviceInfo;
169174

170175
return deviceInfo.data.entries
171-
.fold('', (prev, el) => "$prev${el.key}: ${el.value}\n");
176+
.fold('', (prev, el) => '$prev${el.key}: ${el.value}\n');
172177
}
173178

174179
Future<String> _getDocumentPath() async {
175180
return appFlowyApplicationDataDirectory().then((directory) {
176181
final path = directory.path.toString();
177-
return "Document: $path\n";
182+
return 'Document: $path\n';
178183
});
179184
}
180185
}
181186

182187
enum BubbleAction {
183188
whatsNews,
184-
help,
189+
helpAndDocumentation,
190+
getSupport,
185191
debug,
186192
shortcuts,
187193
markdown,
@@ -204,8 +210,10 @@ extension QuestionBubbleExtension on BubbleAction {
204210
switch (this) {
205211
case BubbleAction.whatsNews:
206212
return LocaleKeys.questionBubble_whatsNew.tr();
207-
case BubbleAction.help:
208-
return LocaleKeys.questionBubble_help.tr();
213+
case BubbleAction.helpAndDocumentation:
214+
return LocaleKeys.questionBubble_helpAndDocumentation.tr();
215+
case BubbleAction.getSupport:
216+
return LocaleKeys.questionBubble_getSupport.tr();
209217
case BubbleAction.debug:
210218
return LocaleKeys.questionBubble_debug_name.tr();
211219
case BubbleAction.shortcuts:
@@ -221,7 +229,12 @@ extension QuestionBubbleExtension on BubbleAction {
221229
switch (this) {
222230
case BubbleAction.whatsNews:
223231
return const FlowySvg(FlowySvgs.star_s);
224-
case BubbleAction.help:
232+
case BubbleAction.helpAndDocumentation:
233+
return const FlowySvg(
234+
FlowySvgs.help_and_documentation_s,
235+
size: Size.square(16.0),
236+
);
237+
case BubbleAction.getSupport:
225238
return const FlowySvg(FlowySvgs.message_support_s);
226239
case BubbleAction.debug:
227240
return const FlowySvg(FlowySvgs.debug_s);

frontend/appflowy_flutter/lib/workspace/presentation/widgets/float_bubble/social_media_section.dart

Lines changed: 10 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,13 @@ class SocialMediaSection extends CustomActionCell {
2525
action: SocialMediaWrapper(social),
2626
itemHeight: ActionListSizes.itemHeight,
2727
onSelected: (action) {
28-
switch (action.inner) {
29-
case SocialMedia.reddit:
30-
afLaunchUrlString(
31-
'https://www.reddit.com/r/AppFlowy/',
32-
);
33-
case SocialMedia.twitter:
34-
afLaunchUrlString(
35-
'https://x.com/appflowy',
36-
);
37-
case SocialMedia.forum:
38-
afLaunchUrlString('https://forum.appflowy.io/');
39-
}
28+
final url = switch (action.inner) {
29+
SocialMedia.reddit => 'https://www.reddit.com/r/AppFlowy/',
30+
SocialMedia.twitter => 'https://x.com/appflowy',
31+
SocialMedia.forum => 'https://forum.appflowy.com/',
32+
};
33+
34+
afLaunchUrlString(url);
4035
},
4136
);
4237
},
@@ -85,11 +80,11 @@ extension QuestionBubbleExtension on SocialMedia {
8580
String get name {
8681
switch (this) {
8782
case SocialMedia.forum:
88-
return "Community Forum";
83+
return 'Community Forum';
8984
case SocialMedia.twitter:
90-
return "Twitter – @appflowy";
85+
return 'Twitter – @appflowy';
9186
case SocialMedia.reddit:
92-
return "Reddit – r/appflowy";
87+
return 'Reddit – r/appflowy';
9388
}
9489
}
9590

Lines changed: 3 additions & 0 deletions
Loading

frontend/resources/translations/el-GR.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -723,7 +723,7 @@
723723
},
724724
"url": {
725725
"launch": "Άνοιγμα συνδέσμου στο πρόγραμμα περιήγησης",
726-
"copy": "Copy link to clipboard",
726+
"copy": "Copied link to clipboard",
727727
"textFieldHint": "Enter a URL",
728728
"copiedNotification": "Copied to clipboard!"
729729
},
@@ -1403,4 +1403,4 @@
14031403
}
14041404
}
14051405
}
1406-
}
1406+
}

frontend/resources/translations/en.json

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,8 @@
307307
"questionBubble": {
308308
"shortcuts": "Shortcuts",
309309
"whatsNew": "What's new?",
310-
"help": "Help & Support",
310+
"helpAndDocumentation": "Help & documentation",
311+
"getSupport": "Get support",
311312
"markdown": "Markdown",
312313
"debug": {
313314
"name": "Debug Info",
@@ -507,7 +508,8 @@
507508
"settings": "Settings",
508509
"members": "Members",
509510
"trash": "Trash",
510-
"helpAndSupport": "Help & Support"
511+
"helpAndDocumentation": "Help & documentation",
512+
"getSupport": "Get Support"
511513
},
512514
"sites": {
513515
"title": "Sites",
@@ -1645,7 +1647,7 @@
16451647
},
16461648
"url": {
16471649
"launch": "Open link in browser",
1648-
"copy": "Copy link to clipboard",
1650+
"copy": "Copied link to clipboard",
16491651
"textFieldHint": "Enter a URL",
16501652
"copiedNotification": "Copied to clipboard!"
16511653
},

0 commit comments

Comments
 (0)