Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed the "Send feedback" option from Help tab. #4013

Merged
merged 1 commit into from
Oct 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ class HelpFragmentTest : BaseActivityTest() {
clickOnHowToUpdateContent()
assertHowToUpdateContentIsExpanded()
clickOnHowToUpdateContent()
clickOnSendFeedback()
}
LeakAssertions.assertNoLeaks()
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,6 @@ class HelpRobot : BaseRobot() {
isVisible(TextId(string.update_content_description))
}

fun clickOnSendFeedback() {
clickOn(ViewId(id.activity_help_feedback_text_view))
}

private fun helpTextFormat(vararg stringIds: Int) =
stringIds.joinToString(separator = "\n", transform = context::getString)
}
28 changes: 0 additions & 28 deletions core/src/main/java/org/kiwix/kiwixmobile/core/help/HelpFragment.kt
Original file line number Diff line number Diff line change
Expand Up @@ -17,28 +17,20 @@
*/
package org.kiwix.kiwixmobile.core.help

import android.content.Intent
import android.net.Uri
import android.os.Bundle
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import androidx.appcompat.app.AppCompatActivity
import androidx.appcompat.widget.Toolbar
import androidx.core.net.toUri
import androidx.recyclerview.widget.DividerItemDecoration
import org.kiwix.kiwixmobile.core.R
import org.kiwix.kiwixmobile.core.base.BaseActivity
import org.kiwix.kiwixmobile.core.base.BaseFragment
import org.kiwix.kiwixmobile.core.compat.CompatHelper.Companion.queryIntentActivitiesCompat
import org.kiwix.kiwixmobile.core.compat.ResolveInfoFlagsCompat
import org.kiwix.kiwixmobile.core.databinding.FragmentHelpBinding
import org.kiwix.kiwixmobile.core.error.DiagnosticReportActivity
import org.kiwix.kiwixmobile.core.extensions.ActivityExtensions.start
import org.kiwix.kiwixmobile.core.extensions.toast
import org.kiwix.kiwixmobile.core.main.CoreMainActivity
import org.kiwix.kiwixmobile.core.utils.CONTACT_EMAIL_ADDRESS
import org.kiwix.kiwixmobile.core.utils.LanguageUtils.Companion.getCurrentLocale
import org.kiwix.kiwixmobile.core.utils.SharedPreferenceUtil
import javax.inject.Inject

Expand Down Expand Up @@ -74,8 +66,6 @@ abstract class HelpFragment : BaseFragment() {
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
super.onViewCreated(view, savedInstanceState)
val activity = requireActivity() as AppCompatActivity
fragmentHelpBinding?.activityHelpFeedbackTextView?.setOnClickListener { sendFeedback() }
fragmentHelpBinding?.activityHelpFeedbackImageView?.setOnClickListener { sendFeedback() }
fragmentHelpBinding?.activityHelpDiagnosticImageView?.setOnClickListener {
sendDiagnosticReport()
}
Expand All @@ -102,24 +92,6 @@ abstract class HelpFragment : BaseFragment() {
requireActivity().start<DiagnosticReportActivity>()
}

private fun sendFeedback() {
val emailIntent = Intent(Intent.ACTION_SENDTO).apply {
data = (
"mailto:${Uri.encode(CONTACT_EMAIL_ADDRESS)}" +
"?subject=" +
Uri.encode("Feedback in ${getCurrentLocale(requireActivity()).displayLanguage}")
).toUri()
}
val packageManager = requireActivity().packageManager
val activities =
packageManager.queryIntentActivitiesCompat(emailIntent, ResolveInfoFlagsCompat.EMPTY)
if (activities.isNotEmpty()) {
startActivity(Intent.createChooser(emailIntent, "Send Feedback via Email"))
} else {
activity.toast(getString(R.string.no_email_application_installed, CONTACT_EMAIL_ADDRESS))
}
}

override fun onDestroyView() {
super.onDestroyView()
fragmentHelpBinding = null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
package org.kiwix.kiwixmobile.core.utils

const val TAG_KIWIX = "kiwix"
const val CONTACT_EMAIL_ADDRESS = "android@kiwix.org"

// Request stuff
const val REQUEST_STORAGE_PERMISSION = 1
Expand Down
10 changes: 0 additions & 10 deletions core/src/main/res/drawable/ic_feedback_blue_24dp.xml

This file was deleted.

37 changes: 3 additions & 34 deletions core/src/main/res/layout/fragment_help.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,37 +9,6 @@

<include layout="@layout/layout_standard_app_bar" />

<ImageView
android:id="@+id/activity_help_feedback_image_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:contentDescription="@string/send_feedback"
android:padding="@dimen/activity_horizontal_margin"
android:src="@drawable/ic_feedback_blue_24dp"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/app_bar" />

<TextView
android:id="@+id/activity_help_feedback_text_view"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:drawablePadding="@dimen/activity_horizontal_margin"
android:text="@string/send_feedback"
android:gravity="start|center"
android:minHeight="@dimen/material_minimum_height_and_width"
android:textAppearance="?android:attr/textAppearanceMedium"
app:layout_constraintBottom_toBottomOf="@id/activity_help_feedback_image_view"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@id/activity_help_feedback_image_view"
app:layout_constraintTop_toTopOf="@id/activity_help_feedback_image_view" />

<View
android:id="@+id/activity_help_feedback_divider"
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="?android:attr/listDivider"
app:layout_constraintTop_toBottomOf="@id/activity_help_feedback_image_view" />

<ImageView
android:id="@+id/activity_help_diagnostic_image_view"
android:layout_width="wrap_content"
Expand All @@ -48,7 +17,7 @@
android:padding="@dimen/activity_horizontal_margin"
android:src="@drawable/ic_feedback_orange_24dp"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/activity_help_feedback_divider" />
app:layout_constraintTop_toBottomOf="@+id/app_bar" />

<TextView
android:id="@+id/activity_help_diagnostic_text_view"
Expand All @@ -73,13 +42,13 @@


<androidx.recyclerview.widget.RecyclerView
tools:listitem="@layout/item_help"
android:id="@+id/activity_help_recycler_view"
android:layout_width="match_parent"
android:layout_height="0dp"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/activity_help_diagnostic_divider" />
app:layout_constraintTop_toBottomOf="@id/activity_help_diagnostic_divider"
tools:listitem="@layout/item_help" />
</androidx.constraintlayout.widget.ConstraintLayout>
2 changes: 0 additions & 2 deletions core/src/main/res/values-ar/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@
<string name="pref_credits_title">الإحالات</string>
<string name="tts_lang_not_supported">لغة هذه الصفحة غير مدعومة، أو لم تُثبت البيانات المناسبة للغة. قد لا تتم قراءة المقالة بشكل صحيح.</string>
<string name="no_reader_application_installed">تعذر العثور على تطبيق مثبت لهذا النوع من الملفات</string>
<string name="no_email_application_installed">الرجاء تثبيت موفر خدمة البريد الإلكتروني أو مراسلتنا عبر البريد الإلكتروني على %1s</string>
<string name="no_app_found_to_select_bookmark_file">لا يوجد تطبيق لتحديد ملف علامة مرجعية</string>
<string name="no_section_info">لم يتم العثور على عناوين محتوى</string>
<string name="request_storage">للوصول إلى المحتوى بلا اتصال، نحتاج إلى الوصول إلى وحدة التخزين</string>
Expand Down Expand Up @@ -218,7 +217,6 @@
<string name="table_of_contents">جدول المحتويات</string>
<string name="select_languages">اختر اللغات</string>
<string name="save_languages">حفظ اللغات</string>
<string name="send_feedback">إرسال تعليق</string>
<string name="expand">وسع</string>
<string name="history">التاريخ</string>
<string name="history_from_current_book">اعرض التاريخ من جميع الكتب</string>
Expand Down
1 change: 0 additions & 1 deletion core/src/main/res/values-ast/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,6 @@
<string name="table_of_contents">Índiz</string>
<string name="select_languages">Escoyer llingües</string>
<string name="save_languages">Guardar llingües</string>
<string name="send_feedback">Unviar opiniones</string>
<string name="expand">Espander</string>
<string name="history">Historial</string>
<string name="history_from_current_book">Ver l’Historial de Tolos Llibros</string>
Expand Down
1 change: 0 additions & 1 deletion core/src/main/res/values-br/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,6 @@
<string name="table_of_contents">Taolenn</string>
<string name="select_languages">Dibab ar yezhoù</string>
<string name="save_languages">Enrollañ ar yezhoù</string>
<string name="send_feedback">Kas un ali</string>
<string name="expand">Dispakañ</string>
<string name="history">Istor</string>
<string name="history_from_current_book">Gwelet istor an holl levrioù</string>
Expand Down
1 change: 0 additions & 1 deletion core/src/main/res/values-ckb/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,6 @@
<string name="table_of_contents">پێڕستی ناوەڕۆکەکان</string>
<string name="select_languages">زمانەکان ھەڵبژێرە</string>
<string name="save_languages">زمانەکان پاشەکەوت بکە</string>
<string name="send_feedback">ڕەخنە و پێشنیار بنێرە</string>
<string name="expand">فراوان بکەوە</string>
<string name="history">مێژوو</string>
<string name="history_from_current_book">بینینی مێژووی ھەموو کتێبەکان</string>
Expand Down
1 change: 0 additions & 1 deletion core/src/main/res/values-cs/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,6 @@
<string name="table_of_contents">Obsah</string>
<string name="select_languages">Vyberte jazyky</string>
<string name="save_languages">Uložit jazyky</string>
<string name="send_feedback">Pošlete zpětnou vazbu</string>
<string name="expand">Rozšířit</string>
<string name="history">Historie</string>
<string name="history_from_current_book">Zobrazit historii ze všech knih</string>
Expand Down
1 change: 0 additions & 1 deletion core/src/main/res/values-da/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,6 @@
<string name="table_of_contents">Indholdsfortegnelse</string>
<string name="select_languages">Vælg sprog</string>
<string name="save_languages">Gem sprog</string>
<string name="send_feedback">Giv en tilbagemelding</string>
<string name="expand">Udvid</string>
<string name="history">Historik</string>
<string name="search_bookmarks">Søg i bogmærker</string>
Expand Down
2 changes: 0 additions & 2 deletions core/src/main/res/values-dag/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@
<string name="pref_credits_title">Viɛnyɛla</string>
<string name="tts_lang_not_supported">Balli zaŋ n-ti yaɣili ŋɔ nyɛla bɛ ni bi saɣi n-ti shɛli. Din tooi niŋ ka lahabali ŋɔ bi tooi karim viɛnyɛla.</string>
<string name="no_reader_application_installed">Haikuweza kupata\n programu iliyosakinishwa kwa aina hii ya faili</string>
<string name="no_email_application_installed">Tafadhali sakinisha\n mtoa huduma wa barua pepe au tutumie barua pepe kwa %1s</string>
<string name="no_section_info">Lahabaya zuɣu nyɛla din kani</string>
<string name="request_storage">A yi bori ni a ka pɔhim zuɣu ka nyari lahabali ti bori soli a deei niŋ shee</string>
<string name="request_write_storage">A yi bori ni a deei zim mazagaya ti bori la sabbu soli tibu a kambɔŋ ni</string>
Expand Down Expand Up @@ -206,7 +205,6 @@
<string name="table_of_contents">Teebuli zaŋ n-ti lahabaya</string>
<string name="select_languages">Amí ichi ku ma chí</string>
<string name="save_languages">Amí ichí ku ma ko ma ja</string>
<string name="send_feedback">Tahimi labisigu</string>
<string name="expand">Yɛligima</string>
<string name="history">Taarihi</string>
<string name="history_from_current_book">Lihi mi taarihi kundunim ni</string>
Expand Down
2 changes: 0 additions & 2 deletions core/src/main/res/values-de/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@
<string name="pref_credits_title">Danksagungen</string>
<string name="tts_lang_not_supported">Die Sprache dieser Seite wird nicht unterstützt. Der Artikel kann möglicherweise nicht richtig vorgelesen werden.</string>
<string name="no_reader_application_installed">Es konnte keine installierte Anwendung für diesen Dateityp gefunden werden</string>
<string name="no_email_application_installed">Bitten installieren Sie eine Mailanwendung oder schreiben Sie uns eine E-Mail an %1s</string>
<string name="no_app_found_to_select_bookmark_file">Keine App zum Auswählen einer Lesezeichendatei gefunden</string>
<string name="no_section_info">Keine Inhaltsheader gefunden</string>
<string name="request_storage">Um auf Offlineinhalt zuzugreifen, müssen wir auf Ihren Speicher zugreifen.</string>
Expand Down Expand Up @@ -226,7 +225,6 @@
<string name="table_of_contents">Inhaltsverzeichnis</string>
<string name="select_languages">Sprachen auswählen</string>
<string name="save_languages">Sprachen speichern</string>
<string name="send_feedback">Rückmeldung senden</string>
<string name="expand">Ausklappen</string>
<string name="history">Verlauf</string>
<string name="history_from_current_book">Zeige die Verlaufsgeschichte aller Bücher</string>
Expand Down
1 change: 0 additions & 1 deletion core/src/main/res/values-diq/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,6 @@
<string name="table_of_contents">Tabloy zerreki</string>
<string name="select_languages">Zıwan weçine</string>
<string name="save_languages">Zıwana qeyd kerê</string>
<string name="send_feedback">Verpers bırışe</string>
<string name="expand">Hera kerê</string>
<string name="history">Veror</string>
<string name="history_from_current_book">Kıtaba pêroyın ra verori bımocne</string>
Expand Down
1 change: 0 additions & 1 deletion core/src/main/res/values-eo/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,6 @@
<string name="table_of_contents">Enhavtabelo</string>
<string name="select_languages">Elekti lingvojn</string>
<string name="save_languages">Konservi lingvojn</string>
<string name="send_feedback">Sendi rimarkojn</string>
<string name="expand">Etendi</string>
<string name="history">Historio</string>
<string name="history_from_current_book" fuzzy="true">Historio el la aktuala libro</string>
Expand Down
2 changes: 0 additions & 2 deletions core/src/main/res/values-es/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,6 @@
<string name="pref_credits_title">Créditos</string>
<string name="tts_lang_not_supported">El idioma de esta página no está soportado. El artículo puede no ser leído correctamente.</string>
<string name="no_reader_application_installed">No se pudo encontrar una aplicación instalada para este tipo de archivo</string>
<string name="no_email_application_installed">Por favor instale un servicio de correo electrónico, o envíe un correo electrónico a %1s</string>
<string name="no_section_info">No se encontraron cabeceras de contenido</string>
<string name="request_storage">Para acceder a contenido sin conexión necesitamos tener acceso a tu almacenamiento</string>
<string name="request_write_storage">Para descargar archivos zim, necesitamos acceso de escritura a su almacenamiento</string>
Expand Down Expand Up @@ -218,7 +217,6 @@
<string name="table_of_contents">Sumario</string>
<string name="select_languages">Seleccionar idiomas</string>
<string name="save_languages">Guardar idiomas</string>
<string name="send_feedback">Enviar comentarios</string>
<string name="expand">Desplegar</string>
<string name="history">Historial</string>
<string name="history_from_current_book">Ver historial de todos los libros</string>
Expand Down
2 changes: 0 additions & 2 deletions core/src/main/res/values-eu/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@
<string name="pref_credits_title">Kredituak</string>
<string name="tts_lang_not_supported">Orrialde honetako hizkuntza ez da onartzen. Baliteke artikulua ezin ongi irakurtzea.</string>
<string name="no_reader_application_installed">Ezin izan da aurkitu mota honetako artxiborako instalatutako aplikazioa</string>
<string name="no_email_application_installed">Instalatu posta elektronikoko zerbitzu-hornitzaile bat edo bidal iezaguzu mezu bat hona: %1s</string>
<string name="no_app_found_to_select_bookmark_file">Ez da aurkitu aplikaziorik laster-markaren fitxategi bat hautatzeko</string>
<string name="no_section_info">Ez da edukiaren goibururik aurkitu</string>
<string name="request_storage">Konexiorik gabeko edukian sartzeko zure biltegira sartu behar gara.</string>
Expand Down Expand Up @@ -214,7 +213,6 @@
<string name="table_of_contents">Eduki-taula</string>
<string name="select_languages">Hizkuntzak aukeratu</string>
<string name="save_languages">Gorde hizkuntzak</string>
<string name="send_feedback">Bidali iritzia</string>
<string name="expand">Zabaldu</string>
<string name="history">Historia</string>
<string name="history_from_current_book">Ikusi liburu guztien historia</string>
Expand Down
1 change: 0 additions & 1 deletion core/src/main/res/values-fa/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,6 @@
<string name="go_to_next_page">به صفحهٔ بعد برو</string>
<string name="select_languages">انتخاب زبان‌ها</string>
<string name="save_languages">ذخیرهٔ زبان‌ها</string>
<string name="send_feedback">ارسال بازخورد</string>
<string name="expand">گسترش</string>
<string name="history">تاریخچه</string>
<string name="search_history" fuzzy="true">تاریخچهٔ جستجو</string>
Expand Down
1 change: 0 additions & 1 deletion core/src/main/res/values-fi/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,6 @@
<string name="table_of_contents">Sisällysluettelo</string>
<string name="select_languages">Valitse kielet</string>
<string name="save_languages">Tallenna kielet</string>
<string name="send_feedback">Lähetä palautetta</string>
<string name="expand">Laajenna</string>
<string name="history">Historia</string>
<string name="history_from_current_book">Näytä historia kaikista kirjoista</string>
Expand Down
2 changes: 0 additions & 2 deletions core/src/main/res/values-fr/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,6 @@
<string name="pref_credits_title">Remerciements</string>
<string name="tts_lang_not_supported">La langue de cette page n’est pas prise en charge. L’article peut ne pas être lu correctement.</string>
<string name="no_reader_application_installed">Impossible de trouver une application installée pour ce type de fichier</string>
<string name="no_email_application_installed">Veuillez installer un fournisseur de service de messagerie ou envoyez-nous un courriel à %1s</string>
<string name="no_app_found_to_select_bookmark_file">Aucune application trouvée pour sélectionner un fichier de signet</string>
<string name="no_section_info">Aucun entête de contenu trouvé</string>
<string name="request_storage">Pour accéder au contenu hors connexion, nous avons besoin d’un accès à votre espace de stockage</string>
Expand Down Expand Up @@ -233,7 +232,6 @@
<string name="table_of_contents">Table des matières</string>
<string name="select_languages">Sélectionner les langues</string>
<string name="save_languages">Sauvegarder les langues</string>
<string name="send_feedback">Envoyer un avis</string>
<string name="expand">Développer</string>
<string name="history">Historique</string>
<string name="history_from_current_book">Afficher l’historique de tous les livres</string>
Expand Down
1 change: 0 additions & 1 deletion core/src/main/res/values-gpe/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@
<string name="pref_credits_title">Credits</string>
<string name="tts_lang_not_supported">De language of dis page no dey support. Maybe de article no go fi read well.</string>
<string name="no_reader_application_installed">Eno fi find sam installed application for dis type of file</string>
<string name="no_email_application_installed">Abeg make you install sam email service provider anaa make you email we for %1s</string>
<string name="no_section_info">Eno fi find Content Headers</string>
<string name="request_storage">So say you go fi access offline content you dey hia access give your storage</string>
<string name="request_write_storage">So say you go fi download zim files we dey hia write access give your storage</string>
Expand Down
Loading
Loading