Skip to content

Commit

Permalink
Merge remote-tracking branch 'zihu12_squawker/feat-customtrans'
Browse files Browse the repository at this point in the history
PR #319 Allow to specify custom LibreTranslate instances (thanks @zihu12).
  • Loading branch information
j-fbriere committed Jun 17, 2024
2 parents 6f4fc4b + 1d5167e commit f69516b
Show file tree
Hide file tree
Showing 11 changed files with 433 additions and 24 deletions.
3 changes: 3 additions & 0 deletions fastlane/metadata/android/en-US/changelogs/46.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@
* The released apk files also include apk files built for older Android KitKat (version 4.4.x).
* Fix issue #309 Toolbar icons are not aligned.
* PR #311 Add search button to profile view to find tweets from current user (thanks @alotbsol555).
* PR #319 Allow to specify custom LibreTranslate instances (thanks @zihu12).
The list can be reordered, instances can be added or removed from the list.
An API key can be set for each instance.
3 changes: 3 additions & 0 deletions fastlane/metadata/android/en-US/changelogs/default.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@
* The released apk files also include apk files built for older Android KitKat (version 4.4.x).
* Fix issue #309 Toolbar icons are not aligned.
* PR #311 Add search button to profile view to find tweets from current user (thanks @alotbsol555).
* PR #319 Allow to specify custom LibreTranslate instances (thanks @zihu12).
The list can be reordered, instances can be added or removed from the list.
An API key can be set for each instance.
2 changes: 2 additions & 0 deletions lib/constants.dart
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ const optionThemeMode = 'theme.mode';
const optionThemeTrueBlack = 'theme.true_black';
const optionThemeColorScheme = 'theme.color_scheme';

const optionTranslators = 'translators';

const optionTweetsHideSensitive = 'tweets.hide_sensitive';

const optionUserTrendsLocations = 'trends.locations';
Expand Down
8 changes: 8 additions & 0 deletions lib/generated/intl/messages_en.dart
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ class MessageLookup extends MessageLookupByLibrary {
"an_update_for_fritter_is_available":
MessageLookupByLibrary.simpleMessage(
"An update for Squawker is available! 🚀"),
"api_key": MessageLookupByLibrary.simpleMessage("API key"),
"app_info": MessageLookupByLibrary.simpleMessage("App Info"),
"are_you_sure": MessageLookupByLibrary.simpleMessage("Are you sure?"),
"are_you_sure_you_want_to_delete_the_subscription_group_name_of_group":
Expand Down Expand Up @@ -285,6 +286,8 @@ class MessageLookup extends MessageLookupByLibrary {
"let_the_developers_know_if_something_is_broken":
MessageLookupByLibrary.simpleMessage(
"Let the developers know if something\'s broken"),
"libre_translate_host":
MessageLookupByLibrary.simpleMessage("LibreTranslate host"),
"licenses": MessageLookupByLibrary.simpleMessage("Licenses"),
"light": MessageLookupByLibrary.simpleMessage("Light"),
"live": MessageLookupByLibrary.simpleMessage("LIVE"),
Expand Down Expand Up @@ -481,6 +484,11 @@ class MessageLookup extends MessageLookupByLibrary {
MessageLookupByLibrary.simpleMessage(
"To import subscriptions from an existing Twitter/X account, enter your username below."),
"toggle_all": MessageLookupByLibrary.simpleMessage("Toggle All"),
"translator_label": MessageLookupByLibrary.simpleMessage("Translator"),
"translators_description": MessageLookupByLibrary.simpleMessage(
"Use custom LibreTranslate instances"),
"translators_label":
MessageLookupByLibrary.simpleMessage("Translators"),
"trending": MessageLookupByLibrary.simpleMessage("Trending"),
"trends": MessageLookupByLibrary.simpleMessage("Trends"),
"true_black": MessageLookupByLibrary.simpleMessage("True Black?"),
Expand Down
8 changes: 8 additions & 0 deletions lib/generated/intl/messages_fr.dart
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ class MessageLookup extends MessageLookupByLibrary {
"an_update_for_fritter_is_available":
MessageLookupByLibrary.simpleMessage(
"Une mise à jour pour Squawker est disponible ! 🚀"),
"api_key": MessageLookupByLibrary.simpleMessage("Clé d\'API"),
"app_info": MessageLookupByLibrary.simpleMessage("Infos sur l’app"),
"are_you_sure": MessageLookupByLibrary.simpleMessage("Êtes-vous sûr ?"),
"are_you_sure_you_want_to_delete_the_subscription_group_name_of_group":
Expand Down Expand Up @@ -297,6 +298,8 @@ class MessageLookup extends MessageLookupByLibrary {
"let_the_developers_know_if_something_is_broken":
MessageLookupByLibrary.simpleMessage(
"Faites savoir aux développeurs si quelque chose est défectueux"),
"libre_translate_host":
MessageLookupByLibrary.simpleMessage("Hôte LibreTranslate"),
"licenses": MessageLookupByLibrary.simpleMessage("Licences"),
"light": MessageLookupByLibrary.simpleMessage("Clair"),
"live": MessageLookupByLibrary.simpleMessage("EN DIRECT"),
Expand Down Expand Up @@ -498,6 +501,11 @@ class MessageLookup extends MessageLookupByLibrary {
MessageLookupByLibrary.simpleMessage(
"Pour importer des abonnements depuis un compte Twitter/X existant, saisissez votre nom d\'utilisateur ci-dessous."),
"toggle_all": MessageLookupByLibrary.simpleMessage("Tout basculer"),
"translator_label": MessageLookupByLibrary.simpleMessage("Traducteur"),
"translators_description": MessageLookupByLibrary.simpleMessage(
"Spécifier les hôtes LibreTranslate"),
"translators_label":
MessageLookupByLibrary.simpleMessage("Traducteurs"),
"trending": MessageLookupByLibrary.simpleMessage("Tendances"),
"trends": MessageLookupByLibrary.simpleMessage("Tendances"),
"true_black": MessageLookupByLibrary.simpleMessage("Vrai noir ?"),
Expand Down
50 changes: 50 additions & 0 deletions lib/generated/l10n.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 10 additions & 0 deletions lib/l10n/intl_en.arb
Original file line number Diff line number Diff line change
Expand Up @@ -571,6 +571,16 @@
"@allow_background_play_other_apps_label": {},
"allow_background_play_other_apps_description": "Allow other apps to play in the background",
"@allow_background_play_other_apps_description": {},
"translators_label": "Translators",
"@translators_label": {},
"translators_description": "Use custom LibreTranslate instances",
"@translators_description": {},
"translator_label": "Translator",
"@translator_label": {},
"libre_translate_host": "LibreTranslate host",
"@libre_translate_host": {},
"api_key": "API key",
"@api_key": {},
"proxy_label": "Proxy",
"@proxy_label": {},
"proxy_description": "Proxy for all requests",
Expand Down
10 changes: 10 additions & 0 deletions lib/l10n/intl_fr.arb
Original file line number Diff line number Diff line change
Expand Up @@ -601,6 +601,16 @@
"@allow_background_play_other_apps_label": {},
"allow_background_play_other_apps_description": "Permettre aux apps externes de jouer en arrière-plan",
"@allow_background_play_other_apps_description": {},
"translators_label": "Traducteurs",
"@translators_label": {},
"translators_description": "Spécifier les hôtes LibreTranslate",
"@translators_description": {},
"translator_label": "Traducteur",
"@translator_label": {},
"libre_translate_host": "Hôte LibreTranslate",
"@libre_translate_host": {},
"api_key": "Clé d'API",
"@api_key": {},
"proxy_label": "Proxy",
"@proxy_label": {},
"proxy_description": "Proxy pour toutes les requêtes",
Expand Down
2 changes: 1 addition & 1 deletion lib/profile/profile.dart
Original file line number Diff line number Diff line change
Expand Up @@ -526,7 +526,7 @@ class _ProfileScreenBodyState extends State<ProfileScreenBody> with TickerProvid
IconButton(
icon: const Icon(Symbols.search),
color: Colors.white,
onPressed: () => pushNamedRoute(context, routeSearch, SearchArguments(1, focusInputOnOpen: true, query: 'from:@${(user.screenName!)} ')),
onPressed: () => pushNamedRoute(context, routeSearch, SearchArguments(1, focusInputOnOpen: true, query: 'from:@${user.screenName!} ')),
),
FollowButton(user: UserSubscription.fromUser(user), color: Colors.white),
],
Expand Down
Loading

0 comments on commit f69516b

Please sign in to comment.