From 3aba3bc97559707e24e90b1c47a07052b33f9704 Mon Sep 17 00:00:00 2001 From: Benoit Martins Date: Tue, 1 Jul 2025 17:58:09 +0200 Subject: [PATCH] Add a link to the user guide in the help view --- .../book-open-text.imageset/Contents.json | 21 ++++++++++++ .../book-open-text.svg | 1 + .../Localizable/cs.lproj/Localizable.strings | 3 ++ .../Localizable/en.lproj/Localizable.strings | 3 ++ .../Localizable/fr.lproj/Localizable.strings | 3 ++ .../Localizable/uk.lproj/Localizable.strings | 3 ++ .../UI/Main/Help/Fragments/HelpFragment.swift | 33 +++++++++++++++++++ 7 files changed, 67 insertions(+) create mode 100644 Linphone/Assets.xcassets/book-open-text.imageset/Contents.json create mode 100644 Linphone/Assets.xcassets/book-open-text.imageset/book-open-text.svg diff --git a/Linphone/Assets.xcassets/book-open-text.imageset/Contents.json b/Linphone/Assets.xcassets/book-open-text.imageset/Contents.json new file mode 100644 index 000000000..5b7cf375f --- /dev/null +++ b/Linphone/Assets.xcassets/book-open-text.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "book-open-text.svg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Linphone/Assets.xcassets/book-open-text.imageset/book-open-text.svg b/Linphone/Assets.xcassets/book-open-text.imageset/book-open-text.svg new file mode 100644 index 000000000..533dd41c3 --- /dev/null +++ b/Linphone/Assets.xcassets/book-open-text.imageset/book-open-text.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/Localizable/cs.lproj/Localizable.strings b/Linphone/Localizable/cs.lproj/Localizable.strings index 5cbae19b0..32fe2cf8f 100644 --- a/Linphone/Localizable/cs.lproj/Localizable.strings +++ b/Linphone/Localizable/cs.lproj/Localizable.strings @@ -186,6 +186,8 @@ "help_about_advanced_title" = "Pokročilé"; "help_about_check_for_update" = "Kontrola aktualizací"; "help_about_privacy_policy_title" = "Zásady ochrany soukromí"; +"help_about_user_guide_title" = "Průvodce Linphone"; +"help_about_user_guide_subtitle" = "Naučte se krok za krokem ovládat všechny funkce aplikace."; "help_about_version_title" = "Verze"; "help_dialog_update_available_title" = "Je dostupná nová aktualizace"; "help_quit_title" = "Ukončit aplikaci"; @@ -500,6 +502,7 @@ "ZRTP" = "ZRTP"; "website_download_url" = "https://linphone.org/linphone-softphone"; "website_open_source_licences_usage_url" = "https://wiki.linphone.org/xwiki/wiki/public/view/Linphone/Third%20party%20components%20/"; +"website_user_guide_url" = "https://linphone.org/en/docs/"; "website_privacy_policy_url" = "https://linphone.org/en/privacy-policy"; "website_terms_and_conditions_url" = "https://www.linphone.org/en/terms-of-use"; "website_translate_weblate_url" = "https://weblate.linphone.org/"; diff --git a/Linphone/Localizable/en.lproj/Localizable.strings b/Linphone/Localizable/en.lproj/Localizable.strings index 765b398e7..8b3824f94 100644 --- a/Linphone/Localizable/en.lproj/Localizable.strings +++ b/Linphone/Localizable/en.lproj/Localizable.strings @@ -281,6 +281,8 @@ "help_about_privacy_policy_subtitle" = "What information Linphone collects and uses"; "help_about_privacy_policy_title" = "Privacy policy"; "help_about_title" = "About Linphone"; +"help_about_user_guide_title" = "Linphone user guide"; +"help_about_user_guide_subtitle" = "Learn how to master all app features, step by step."; "help_about_version_title" = "Version"; "help_dialog_update_available_message" = "A new version %@ is available. Do you want to update?"; "help_dialog_update_available_title" = "Update available"; @@ -504,6 +506,7 @@ "website_contact_url" = "https://linphone.org/contact"; "website_download_url" = "https://linphone.org/linphone-softphone"; "website_open_source_licences_usage_url" = "https://wiki.linphone.org/xwiki/wiki/public/view/Linphone/Third%20party%20components%20/"; +"website_user_guide_url" = "https://linphone.org/en/docs/"; "website_privacy_policy_url" = "https://linphone.org/en/privacy-policy"; "website_terms_and_conditions_url" = "https://www.linphone.org/en/terms-of-use"; "website_translate_weblate_url" = "https://weblate.linphone.org/"; diff --git a/Linphone/Localizable/fr.lproj/Localizable.strings b/Linphone/Localizable/fr.lproj/Localizable.strings index 0dade4119..907950da3 100644 --- a/Linphone/Localizable/fr.lproj/Localizable.strings +++ b/Linphone/Localizable/fr.lproj/Localizable.strings @@ -281,6 +281,8 @@ "help_about_privacy_policy_subtitle" = "Quelles informations Linphone collecte et utilise"; "help_about_privacy_policy_title" = "Politique de confidentialité"; "help_about_title" = "À propos de Linphone"; +"help_about_user_guide_title" = "Guide utilisateur Linphone"; +"help_about_user_guide_subtitle" = "Apprenez à maîtriser toutes les fonctionnalités de l'application, pas à pas."; "help_about_version_title" = "Version"; "help_dialog_update_available_message" = "Une nouvelle version %@ est disponible. Voulez-vous mettre à jour ?"; "help_dialog_update_available_title" = "Mise à jour disponible"; @@ -504,6 +506,7 @@ "website_contact_url" = "https://linphone.org/contact"; "website_download_url" = "https://linphone.org/linphone-softphone"; "website_open_source_licences_usage_url" = "https://wiki.linphone.org/xwiki/wiki/public/view/Linphone/Third%20party%20components%20/"; +"website_user_guide_url" = "https://linphone.org/docs/"; "website_privacy_policy_url" = "https://linphone.org/en/privacy-policy"; "website_terms_and_conditions_url" = "https://www.linphone.org/en/terms-of-use"; "website_translate_weblate_url" = "https://weblate.linphone.org/"; diff --git a/Linphone/Localizable/uk.lproj/Localizable.strings b/Linphone/Localizable/uk.lproj/Localizable.strings index d413f3641..b7bc5531f 100644 --- a/Linphone/Localizable/uk.lproj/Localizable.strings +++ b/Linphone/Localizable/uk.lproj/Localizable.strings @@ -100,6 +100,8 @@ "generic_address_picker_suggestions_list_title" = "Пропозиції"; "help_about_advanced_title" = "Розширений"; "help_about_check_for_update" = "Перевірити оновлення"; +"help_about_user_guide_title" = "Linphone посібник користувача"; +"help_about_user_guide_subtitle" = "Дізнайтеся, як опанувати всі функції програми крок за кроком."; "help_about_version_title" = "Версія"; "help_dialog_update_available_title" = "Доступне оновлення"; "help_error_checking_version_toast_message" = "Під час перевірки оновлень сталася помилка"; @@ -403,6 +405,7 @@ "settings_calls_calibrate_echo_canceller_done" = "%@ мс"; "welcome_page_1_message" = "**Захищений**, **з відкритим вихідним кодом** та **французький** застосунок для спілкування."; "help_dialog_update_available_message" = "Доступна нова версія %@. Бажаєте оновити?"; +"website_user_guide_url" = "https://linphone.org/en/docs/"; "website_privacy_policy_url" = "https://linphone.org/en/privacy-policy"; "welcome_page_3_message" = "**Безкоштовний** застосунок з відкритим кодом з **2001 року**."; "welcome_page_subtitle" = "в %@"; diff --git a/Linphone/UI/Main/Help/Fragments/HelpFragment.swift b/Linphone/UI/Main/Help/Fragments/HelpFragment.swift index 1c4b0cd58..e93324f50 100644 --- a/Linphone/UI/Main/Help/Fragments/HelpFragment.swift +++ b/Linphone/UI/Main/Help/Fragments/HelpFragment.swift @@ -75,6 +75,39 @@ struct HelpFragment: View { .frame(maxWidth: .infinity, alignment: .leading) .padding(.bottom, 5) + Button { + if let url = URL(string: NSLocalizedString("website_user_guide_url", comment: "")) { + UIApplication.shared.open(url) + } + } label: { + HStack { + Image("book-open-text") + .renderingMode(.template) + .resizable() + .foregroundStyle(Color.orangeMain500) + .frame(width: 30, height: 30) + + VStack { + Text("help_about_user_guide_title") + .default_text_style_700(styleSize: 14) + .frame(maxWidth: .infinity, alignment: .leading) + .multilineTextAlignment(.leading) + + Text("help_about_user_guide_subtitle") + .default_text_style(styleSize: 14) + .frame(maxWidth: .infinity, alignment: .leading) + .multilineTextAlignment(.leading) + } + .padding(.horizontal, 5) + + Image("arrow-square-out") + .renderingMode(.template) + .resizable() + .foregroundStyle(Color.grayMain2c600) + .frame(width: 25, height: 25) + } + } + Button { if let url = URL(string: NSLocalizedString("website_privacy_policy_url", comment: "")) { UIApplication.shared.open(url)