mirror of
https://github.com/twofas/2fas-android.git
synced 2025-01-05 14:05:30 +01:00
Optional save choice on browser request
This commit is contained in:
parent
c9f55a5e4e
commit
23c29eec67
@ -7,8 +7,11 @@ import androidx.activity.compose.setContent
|
||||
import androidx.compose.foundation.ExperimentalFoundationApi
|
||||
import androidx.compose.foundation.background
|
||||
import androidx.compose.foundation.clickable
|
||||
import androidx.compose.foundation.layout.Row
|
||||
import androidx.compose.foundation.layout.Spacer
|
||||
import androidx.compose.foundation.layout.fillMaxWidth
|
||||
import androidx.compose.foundation.layout.padding
|
||||
import androidx.compose.foundation.layout.width
|
||||
import androidx.compose.foundation.lazy.LazyColumn
|
||||
import androidx.compose.foundation.lazy.items
|
||||
import androidx.compose.material3.MaterialTheme
|
||||
@ -16,6 +19,7 @@ import androidx.compose.material3.Scaffold
|
||||
import androidx.compose.material3.Text
|
||||
import androidx.compose.runtime.Composable
|
||||
import androidx.compose.runtime.collectAsState
|
||||
import androidx.compose.ui.Alignment
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.platform.LocalContext
|
||||
import androidx.compose.ui.res.stringResource
|
||||
@ -29,6 +33,7 @@ import com.twofasapp.data.session.SettingsRepository
|
||||
import com.twofasapp.design.theme.ThemeState
|
||||
import com.twofasapp.designsystem.MainAppTheme
|
||||
import com.twofasapp.designsystem.TwTheme
|
||||
import com.twofasapp.designsystem.common.TwSwitch
|
||||
import com.twofasapp.designsystem.common.TwTopAppBar
|
||||
import com.twofasapp.resources.R
|
||||
import com.twofasapp.services.domain.model.Service
|
||||
@ -85,10 +90,46 @@ class BrowserExtensionRequestActivity : BaseComponentActivity() {
|
||||
}
|
||||
|
||||
LazyColumn(modifier = modifier) {
|
||||
item { HeaderItem(browserName = uiState.browserName, payload.domain, modifier = Modifier.animateItemPlacement()) }
|
||||
item {
|
||||
HeaderItem(
|
||||
browserName = uiState.browserName,
|
||||
domain = payload.domain,
|
||||
modifier = Modifier.animateItemPlacement()
|
||||
)
|
||||
}
|
||||
|
||||
item {
|
||||
Row(
|
||||
modifier = Modifier
|
||||
.fillMaxWidth()
|
||||
.padding(bottom = 12.dp)
|
||||
.clickable {
|
||||
viewModel.updateSaveMyChoice(uiState.saveMyChoice.not())
|
||||
}
|
||||
.padding(horizontal = 16.dp, vertical = 4.dp),
|
||||
verticalAlignment = Alignment.CenterVertically,
|
||||
) {
|
||||
Text(
|
||||
text = stringResource(id = R.string.browser__save_choice),
|
||||
color = TwTheme.color.onSurfacePrimary,
|
||||
style = TwTheme.typo.body1,
|
||||
modifier = Modifier.weight(1f)
|
||||
)
|
||||
Spacer(modifier = Modifier.width(8.dp))
|
||||
TwSwitch(
|
||||
checked = uiState.saveMyChoice,
|
||||
onCheckedChange = { viewModel.updateSaveMyChoice(it) },
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
if (uiState.suggestedServices.isNotEmpty()) {
|
||||
item { SectionItem(title = stringResource(id = R.string.extension__services_suggested_header), modifier = Modifier.animateItemPlacement()) }
|
||||
item {
|
||||
SectionItem(
|
||||
title = stringResource(id = R.string.extension__services_suggested_header),
|
||||
modifier = Modifier.animateItemPlacement()
|
||||
)
|
||||
}
|
||||
items(uiState.suggestedServices, key = { it.id }) {
|
||||
|
||||
ServiceItem(
|
||||
@ -132,7 +173,7 @@ class BrowserExtensionRequestActivity : BaseComponentActivity() {
|
||||
text = stringResource(id = R.string.browser__request_source_description).format(browserName, domain),
|
||||
modifier = modifier
|
||||
.fillMaxWidth()
|
||||
.padding(start = 72.dp, end = 16.dp, top = 24.dp, bottom = 24.dp),
|
||||
.padding(16.dp),
|
||||
style = MaterialTheme.typography.bodyMedium.copy(color = TwTheme.color.onSurfacePrimary)
|
||||
)
|
||||
}
|
||||
|
@ -6,4 +6,5 @@ data class BrowserExtensionRequestUiState(
|
||||
val browserName: String = "",
|
||||
val suggestedServices: List<Service> = emptyList(),
|
||||
val otherServices: List<Service> = emptyList(),
|
||||
val saveMyChoice: Boolean = false,
|
||||
)
|
@ -10,7 +10,6 @@ import com.twofasapp.services.domain.AssignServiceDomainCase
|
||||
import com.twofasapp.services.domain.GetServicesCase
|
||||
import com.twofasapp.services.domain.model.Service
|
||||
import kotlinx.coroutines.flow.MutableStateFlow
|
||||
import kotlinx.coroutines.flow.asStateFlow
|
||||
import kotlinx.coroutines.flow.first
|
||||
import kotlinx.coroutines.flow.update
|
||||
import kotlinx.coroutines.launch
|
||||
@ -23,8 +22,7 @@ internal class BrowserExtensionRequestViewModel(
|
||||
private val browserExtRepository: BrowserExtRepository,
|
||||
) : BaseViewModel() {
|
||||
|
||||
private val _uiState = MutableStateFlow(BrowserExtensionRequestUiState())
|
||||
val uiState = _uiState.asStateFlow()
|
||||
val uiState = MutableStateFlow(BrowserExtensionRequestUiState())
|
||||
|
||||
fun init(
|
||||
extensionId: String,
|
||||
@ -38,7 +36,7 @@ internal class BrowserExtensionRequestViewModel(
|
||||
val suggestedServices =
|
||||
matchedServices.plus(DomainMatcher.findServicesSuggestedForDomain(services, domain).minus(matchedServices.toSet()))
|
||||
|
||||
_uiState.update { state ->
|
||||
uiState.update { state ->
|
||||
state.copy(
|
||||
browserName = browsers.find { it.id == extensionId }?.name.orEmpty(),
|
||||
suggestedServices = suggestedServices,
|
||||
@ -55,9 +53,15 @@ internal class BrowserExtensionRequestViewModel(
|
||||
onFinish: () -> Unit
|
||||
) {
|
||||
viewModelScope.launch(dispatchers.io()) {
|
||||
assignServiceDomainCase(service, domain)
|
||||
if (uiState.value.saveMyChoice) {
|
||||
assignServiceDomainCase(service, domain)
|
||||
}
|
||||
browserExtRepository.deleteTokenRequest(requestId)
|
||||
onFinish.invoke()
|
||||
}
|
||||
}
|
||||
|
||||
fun updateSaveMyChoice(checked: Boolean) {
|
||||
uiState.update { it.copy(saveMyChoice = checked) }
|
||||
}
|
||||
}
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: de-DE, German (Germany)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:24 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -802,4 +802,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: es-ES, Spanish (Spain)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -792,14 +792,15 @@
|
||||
<string name="guides__select_provide_guide_cta">Aplicar ahora</string>
|
||||
<string name="color__pink">Rosa</string>
|
||||
<string name="color__brown">Marrón</string>
|
||||
<string name="tokens__other_methods_header">Other methods?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">Camera is unavailable. Check apps\' access permission in System Settings</string>
|
||||
<string name="tokens__other_methods_header">¿Otros métodos?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">La cámara no está disponible. Comprueba el permiso de acceso en Configuración del sistema</string>
|
||||
<!-- This key contains part of the tokens__camera_is_unavailable_app_permission key, which will be underlined in the app to look like a link to System Settings -->
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">System Settings</string>
|
||||
<string name="commons__text_short_title">The provided text is too short (min. %d chars)</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">Configuración del sistema</string>
|
||||
<string name="commons__text_short_title">El texto proporcionado es demasiado corto (mín. %d caracteres)</string>
|
||||
<!-- This key should contain a part of the tokens__add_manual_advanced_description which is written in bold in the app -->
|
||||
<string name="tokens__add_manual_advanced_description_highlight">is not recommended</string>
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="tokens__add_manual_advanced_description_highlight">No está recomendable</string>
|
||||
<string name="guides__guide_init_title">Guía 2FAS</string>
|
||||
<string name="guides__guide_title">2FAS para %s</string>
|
||||
<string name="guides__guide_universal_title">Guía universal de 2FA</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: fr-FR, French (France)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:24 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -802,4 +802,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: id-ID, Indonesian (Indonesia)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -15,8 +15,8 @@
|
||||
<string name="NSCameraUsageDescription">Digunakan untuk memindai kode-QR</string>
|
||||
<string name="NSFaceIDUsageDescription">Anda dapat membuka kunci aplikasi menggunakan Face ID</string>
|
||||
<!-- MARK: - App -->
|
||||
<string name="app__name">2FAS Autentikasi</string>
|
||||
<string name="commons__2fas">2FA Autentikasi (Aplikasi 2FAS)</string>
|
||||
<string name="app__name">2FAS Authenticator\u0020</string>
|
||||
<string name="commons__2fas">2FA Authenticator (2FAS App)</string>
|
||||
<string name="commons__OK">OKE</string>
|
||||
<string name="commons__add">Menambahkan</string>
|
||||
<!-- MARK: - Commons -->
|
||||
@ -407,7 +407,7 @@
|
||||
<string name="settings__5_minutes">5 menit</string>
|
||||
<string name="settings__10_minutes">10 menit</string>
|
||||
<string name="settings__limit_of_trials">Upaya gagal maksimal</string>
|
||||
<string name="settings__pin_4_digits">kode 4 digit</string>
|
||||
<string name="settings__pin_4_digits">Kode 4 digit</string>
|
||||
<string name="settings__pin_6_digits">Kode 6 digit</string>
|
||||
<string name="settings__biometric_authentication">Otentikasi Biometrik</string>
|
||||
<string name="settings__donations">Donasi</string>
|
||||
@ -530,7 +530,7 @@
|
||||
<string name="externalimport_google_authenticator">Google Authenticator</string>
|
||||
<string name="externalimport_aegis">Aegis</string>
|
||||
<string name="externalimport_raivo">Raivo OTP</string>
|
||||
<string name="android__app_name">Autentikasi 2FAS</string>
|
||||
<string name="android__app_name">2FAS Auth</string>
|
||||
<string name="commons__yes">Ya</string>
|
||||
<string name="commons__no">Tidak</string>
|
||||
<string name="commons__search">Pencarian</string>
|
||||
@ -538,7 +538,7 @@
|
||||
<string name="permissions__camera_permission">Izin Kamera</string>
|
||||
<string name="permissions__camera_permission_description">Izin kamera diperlukan untuk memindai Kode QR. Jika anda ingin menggunakan fitur ini, buka Informasi aplikasi dan izin dan Aktifkan Kamera.</string>
|
||||
<string name="security__disable_pin">Nonaktifkan PIN</string>
|
||||
<string name="security__enter_your_new_pin">Masukkan %s PIN baru Anda</string>
|
||||
<string name="security__enter_your_new_pin">Masukkan %s PIN baru anda</string>
|
||||
<string name="security__pin_error_incorrect">PIN salah! Silakan coba lagi</string>
|
||||
<string name="settings__biometrics">Biometrik</string>
|
||||
<string name="settings__support">Dukungan 2FAS</string>
|
||||
@ -774,7 +774,7 @@
|
||||
<string name="externalimport__authenticatorpro_success_msg">File teks ini memungkinkan pengimporan token dari Authenticator Pro.</string>
|
||||
<string name="externalimport__authenticatorpro_title">Mengimpor token 2FA dari aplikasi Authenticator Pro</string>
|
||||
<string name="externalimport__authenticatorpro_msg">Ekspor akun anda dari Authenticator Pro ke file teks tidak terenkripsi dan unggah menggunakan tombol \"Pilih file teks\". Ingatlah untuk menghapus file setelah impor berhasil.</string>
|
||||
<string name="externalimport__authenticatorpro">Autentikasi Pro</string>
|
||||
<string name="externalimport__authenticatorpro">Authenticator Pro</string>
|
||||
<string name="externalimport__choose_txt_cta">Pilih file teks</string>
|
||||
<string name="fingerprint__biometric_invalidated">Login biometrik dinonaktifkan karena perubahan dalam pengaturan sidik jari sistem</string>
|
||||
<string name="tokens__last_pass_import">Mengimpor token 2FA dari aplikasi LastPass</string>
|
||||
@ -796,4 +796,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: it-IT, Italian (Italy)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -785,21 +785,22 @@
|
||||
<string name="fingerprint__biometric_invalidated">L\'accesso biometrico è stato disattivato a causa di cambiamenti alle impostazioni di sicurezza e privacy del sistema.</string>
|
||||
<string name="tokens__last_pass_import">Importazione di token 2FA dall\'app LastPass</string>
|
||||
<string name="tokens__last_pass_import_subtitle">Questo codice QR permette di importare i token da LastPass</string>
|
||||
<string name="tokens__add_with_guide">Guide me</string>
|
||||
<string name="guides__select_title">Browse services</string>
|
||||
<string name="guides__select_description">Select service to pair with the 2FAS app</string>
|
||||
<string name="guides__select_provide_guide">Do you want to provide 2FA guides for your service?</string>
|
||||
<string name="guides__select_provide_guide_cta">Apply now</string>
|
||||
<string name="color__pink">Pink</string>
|
||||
<string name="color__brown">Brown</string>
|
||||
<string name="tokens__other_methods_header">Other methods?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">Camera is unavailable. Check apps\' access permission in System Settings</string>
|
||||
<string name="tokens__add_with_guide">Guidami</string>
|
||||
<string name="guides__select_title">Sfoglia servizi</string>
|
||||
<string name="guides__select_description">Seleziona servizio da abbinare all\'app 2FAS</string>
|
||||
<string name="guides__select_provide_guide">Vuoi fornire la guida 2FA per il tuo servizio?</string>
|
||||
<string name="guides__select_provide_guide_cta">Applica ora</string>
|
||||
<string name="color__pink">Rosa</string>
|
||||
<string name="color__brown">Marrone</string>
|
||||
<string name="tokens__other_methods_header">Altri metodi?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">La fotocamera non è disponibile. Controlla i permessi di accesso delle app nelle impostazioni di sistema</string>
|
||||
<!-- This key contains part of the tokens__camera_is_unavailable_app_permission key, which will be underlined in the app to look like a link to System Settings -->
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">System Settings</string>
|
||||
<string name="commons__text_short_title">The provided text is too short (min. %d chars)</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">Impostazioni di sistema</string>
|
||||
<string name="commons__text_short_title">Il testo fornito è troppo corto (min. %d caratteri)</string>
|
||||
<!-- This key should contain a part of the tokens__add_manual_advanced_description which is written in bold in the app -->
|
||||
<string name="tokens__add_manual_advanced_description_highlight">is not recommended</string>
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="tokens__add_manual_advanced_description_highlight">non è raccomandato</string>
|
||||
<string name="guides__guide_init_title">Guida a 2FAS</string>
|
||||
<string name="guides__guide_title">2FAS per %s</string>
|
||||
<string name="guides__guide_universal_title">Guida universale alla 2FA</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: nl-NL, Dutch (Netherlands)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:24 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -802,4 +802,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: pl-PL, Polish (Poland)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -798,14 +798,15 @@
|
||||
<string name="guides__select_provide_guide_cta">Zgłoś się</string>
|
||||
<string name="color__pink">Różowy</string>
|
||||
<string name="color__brown">Brązowy</string>
|
||||
<string name="tokens__other_methods_header">Other methods?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">Camera is unavailable. Check apps\' access permission in System Settings</string>
|
||||
<string name="tokens__other_methods_header">Inne metody?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">Kamera jest niedostępna. Sprawdź uprawnienia dostępu aplikacji w Ustawieniach systemowych</string>
|
||||
<!-- This key contains part of the tokens__camera_is_unavailable_app_permission key, which will be underlined in the app to look like a link to System Settings -->
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">System Settings</string>
|
||||
<string name="commons__text_short_title">The provided text is too short (min. %d chars)</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">Ustawienia systemowe</string>
|
||||
<string name="commons__text_short_title">Podany tekst jest zbyt krótki (min. %d znaków)</string>
|
||||
<!-- This key should contain a part of the tokens__add_manual_advanced_description which is written in bold in the app -->
|
||||
<string name="tokens__add_manual_advanced_description_highlight">nie jest zalecana</string>
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="guides__guide_init_title">Przewodnik 2FAS</string>
|
||||
<string name="guides__guide_title">2FAS dla %s</string>
|
||||
<string name="guides__guide_universal_title">Uniwersalny przewodnik 2FAS</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: pt-BR, Brazilian Portuguese
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:24 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -799,7 +799,8 @@
|
||||
<string name="commons__text_short_title">O texto fornecido é muito curto (min. %d chars)</string>
|
||||
<!-- This key should contain a part of the tokens__add_manual_advanced_description which is written in bold in the app -->
|
||||
<string name="tokens__add_manual_advanced_description_highlight">Não é recomendado</string>
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="guides__guide_init_title">Guia 2FAS</string>
|
||||
<string name="guides__guide_title">2FAS para %s</string>
|
||||
<string name="guides__guide_universal_title">Guia Universal 2FAS</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: pt-PT, Portuguese (Portugal)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -802,4 +802,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: uk-UA, Ukrainian (Ukraine)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -805,7 +805,8 @@
|
||||
<string name="commons__text_short_title">Наданий текст занадто короткий (мін. %d символів)</string>
|
||||
<!-- This key should contain a part of the tokens__add_manual_advanced_description which is written in bold in the app -->
|
||||
<string name="tokens__add_manual_advanced_description_highlight">не рекомендовано</string>
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="guides__guide_init_title">Посібник 2FAS</string>
|
||||
<string name="guides__guide_title">2FAS для %s</string>
|
||||
<string name="guides__guide_universal_title">Універсальний посібник 2FA</string>
|
||||
<string name="browser__save_choice">Зберегти мій вибір</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: en, English
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:24 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -802,4 +802,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -15,7 +15,7 @@ kotlinCoroutines = "1.7.3"
|
||||
kotlinKsp = "1.9.0-1.0.13"
|
||||
ktlint = "3.12.0"
|
||||
ktor = "2.3.3"
|
||||
material3 = "1.2.0-alpha04"
|
||||
material3 = "1.2.0-alpha05"
|
||||
room = "2.5.2"
|
||||
viewModel = "2.6.1"
|
||||
junit = "4.13.2"
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: de-DE, German (Germany)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:24 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -802,4 +802,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: es-ES, Spanish (Spain)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -792,14 +792,15 @@
|
||||
<string name="guides__select_provide_guide_cta">Aplicar ahora</string>
|
||||
<string name="color__pink">Rosa</string>
|
||||
<string name="color__brown">Marrón</string>
|
||||
<string name="tokens__other_methods_header">Other methods?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">Camera is unavailable. Check apps\' access permission in System Settings</string>
|
||||
<string name="tokens__other_methods_header">¿Otros métodos?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">La cámara no está disponible. Comprueba el permiso de acceso en Configuración del sistema</string>
|
||||
<!-- This key contains part of the tokens__camera_is_unavailable_app_permission key, which will be underlined in the app to look like a link to System Settings -->
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">System Settings</string>
|
||||
<string name="commons__text_short_title">The provided text is too short (min. %d chars)</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">Configuración del sistema</string>
|
||||
<string name="commons__text_short_title">El texto proporcionado es demasiado corto (mín. %d caracteres)</string>
|
||||
<!-- This key should contain a part of the tokens__add_manual_advanced_description which is written in bold in the app -->
|
||||
<string name="tokens__add_manual_advanced_description_highlight">is not recommended</string>
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="tokens__add_manual_advanced_description_highlight">No está recomendable</string>
|
||||
<string name="guides__guide_init_title">Guía 2FAS</string>
|
||||
<string name="guides__guide_title">2FAS para %s</string>
|
||||
<string name="guides__guide_universal_title">Guía universal de 2FA</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: fr-FR, French (France)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:24 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -802,4 +802,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: id-ID, Indonesian (Indonesia)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -15,8 +15,8 @@
|
||||
<string name="NSCameraUsageDescription">Digunakan untuk memindai kode-QR</string>
|
||||
<string name="NSFaceIDUsageDescription">Anda dapat membuka kunci aplikasi menggunakan Face ID</string>
|
||||
<!-- MARK: - App -->
|
||||
<string name="app__name">2FAS Autentikasi</string>
|
||||
<string name="commons__2fas">2FA Autentikasi (Aplikasi 2FAS)</string>
|
||||
<string name="app__name">2FAS Authenticator\u0020</string>
|
||||
<string name="commons__2fas">2FA Authenticator (2FAS App)</string>
|
||||
<string name="commons__OK">OKE</string>
|
||||
<string name="commons__add">Menambahkan</string>
|
||||
<!-- MARK: - Commons -->
|
||||
@ -407,7 +407,7 @@
|
||||
<string name="settings__5_minutes">5 menit</string>
|
||||
<string name="settings__10_minutes">10 menit</string>
|
||||
<string name="settings__limit_of_trials">Upaya gagal maksimal</string>
|
||||
<string name="settings__pin_4_digits">kode 4 digit</string>
|
||||
<string name="settings__pin_4_digits">Kode 4 digit</string>
|
||||
<string name="settings__pin_6_digits">Kode 6 digit</string>
|
||||
<string name="settings__biometric_authentication">Otentikasi Biometrik</string>
|
||||
<string name="settings__donations">Donasi</string>
|
||||
@ -530,7 +530,7 @@
|
||||
<string name="externalimport_google_authenticator">Google Authenticator</string>
|
||||
<string name="externalimport_aegis">Aegis</string>
|
||||
<string name="externalimport_raivo">Raivo OTP</string>
|
||||
<string name="android__app_name">Autentikasi 2FAS</string>
|
||||
<string name="android__app_name">2FAS Auth</string>
|
||||
<string name="commons__yes">Ya</string>
|
||||
<string name="commons__no">Tidak</string>
|
||||
<string name="commons__search">Pencarian</string>
|
||||
@ -538,7 +538,7 @@
|
||||
<string name="permissions__camera_permission">Izin Kamera</string>
|
||||
<string name="permissions__camera_permission_description">Izin kamera diperlukan untuk memindai Kode QR. Jika anda ingin menggunakan fitur ini, buka Informasi aplikasi dan izin dan Aktifkan Kamera.</string>
|
||||
<string name="security__disable_pin">Nonaktifkan PIN</string>
|
||||
<string name="security__enter_your_new_pin">Masukkan %s PIN baru Anda</string>
|
||||
<string name="security__enter_your_new_pin">Masukkan %s PIN baru anda</string>
|
||||
<string name="security__pin_error_incorrect">PIN salah! Silakan coba lagi</string>
|
||||
<string name="settings__biometrics">Biometrik</string>
|
||||
<string name="settings__support">Dukungan 2FAS</string>
|
||||
@ -774,7 +774,7 @@
|
||||
<string name="externalimport__authenticatorpro_success_msg">File teks ini memungkinkan pengimporan token dari Authenticator Pro.</string>
|
||||
<string name="externalimport__authenticatorpro_title">Mengimpor token 2FA dari aplikasi Authenticator Pro</string>
|
||||
<string name="externalimport__authenticatorpro_msg">Ekspor akun anda dari Authenticator Pro ke file teks tidak terenkripsi dan unggah menggunakan tombol \"Pilih file teks\". Ingatlah untuk menghapus file setelah impor berhasil.</string>
|
||||
<string name="externalimport__authenticatorpro">Autentikasi Pro</string>
|
||||
<string name="externalimport__authenticatorpro">Authenticator Pro</string>
|
||||
<string name="externalimport__choose_txt_cta">Pilih file teks</string>
|
||||
<string name="fingerprint__biometric_invalidated">Login biometrik dinonaktifkan karena perubahan dalam pengaturan sidik jari sistem</string>
|
||||
<string name="tokens__last_pass_import">Mengimpor token 2FA dari aplikasi LastPass</string>
|
||||
@ -796,4 +796,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: it-IT, Italian (Italy)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -785,21 +785,22 @@
|
||||
<string name="fingerprint__biometric_invalidated">L\'accesso biometrico è stato disattivato a causa di cambiamenti alle impostazioni di sicurezza e privacy del sistema.</string>
|
||||
<string name="tokens__last_pass_import">Importazione di token 2FA dall\'app LastPass</string>
|
||||
<string name="tokens__last_pass_import_subtitle">Questo codice QR permette di importare i token da LastPass</string>
|
||||
<string name="tokens__add_with_guide">Guide me</string>
|
||||
<string name="guides__select_title">Browse services</string>
|
||||
<string name="guides__select_description">Select service to pair with the 2FAS app</string>
|
||||
<string name="guides__select_provide_guide">Do you want to provide 2FA guides for your service?</string>
|
||||
<string name="guides__select_provide_guide_cta">Apply now</string>
|
||||
<string name="color__pink">Pink</string>
|
||||
<string name="color__brown">Brown</string>
|
||||
<string name="tokens__other_methods_header">Other methods?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">Camera is unavailable. Check apps\' access permission in System Settings</string>
|
||||
<string name="tokens__add_with_guide">Guidami</string>
|
||||
<string name="guides__select_title">Sfoglia servizi</string>
|
||||
<string name="guides__select_description">Seleziona servizio da abbinare all\'app 2FAS</string>
|
||||
<string name="guides__select_provide_guide">Vuoi fornire la guida 2FA per il tuo servizio?</string>
|
||||
<string name="guides__select_provide_guide_cta">Applica ora</string>
|
||||
<string name="color__pink">Rosa</string>
|
||||
<string name="color__brown">Marrone</string>
|
||||
<string name="tokens__other_methods_header">Altri metodi?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">La fotocamera non è disponibile. Controlla i permessi di accesso delle app nelle impostazioni di sistema</string>
|
||||
<!-- This key contains part of the tokens__camera_is_unavailable_app_permission key, which will be underlined in the app to look like a link to System Settings -->
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">System Settings</string>
|
||||
<string name="commons__text_short_title">The provided text is too short (min. %d chars)</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">Impostazioni di sistema</string>
|
||||
<string name="commons__text_short_title">Il testo fornito è troppo corto (min. %d caratteri)</string>
|
||||
<!-- This key should contain a part of the tokens__add_manual_advanced_description which is written in bold in the app -->
|
||||
<string name="tokens__add_manual_advanced_description_highlight">is not recommended</string>
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="tokens__add_manual_advanced_description_highlight">non è raccomandato</string>
|
||||
<string name="guides__guide_init_title">Guida a 2FAS</string>
|
||||
<string name="guides__guide_title">2FAS per %s</string>
|
||||
<string name="guides__guide_universal_title">Guida universale alla 2FA</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: nl-NL, Dutch (Netherlands)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:24 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -802,4 +802,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: pl-PL, Polish (Poland)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -798,14 +798,15 @@
|
||||
<string name="guides__select_provide_guide_cta">Zgłoś się</string>
|
||||
<string name="color__pink">Różowy</string>
|
||||
<string name="color__brown">Brązowy</string>
|
||||
<string name="tokens__other_methods_header">Other methods?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">Camera is unavailable. Check apps\' access permission in System Settings</string>
|
||||
<string name="tokens__other_methods_header">Inne metody?</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission">Kamera jest niedostępna. Sprawdź uprawnienia dostępu aplikacji w Ustawieniach systemowych</string>
|
||||
<!-- This key contains part of the tokens__camera_is_unavailable_app_permission key, which will be underlined in the app to look like a link to System Settings -->
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">System Settings</string>
|
||||
<string name="commons__text_short_title">The provided text is too short (min. %d chars)</string>
|
||||
<string name="tokens__camera_is_unavailable_app_permission_underline">Ustawienia systemowe</string>
|
||||
<string name="commons__text_short_title">Podany tekst jest zbyt krótki (min. %d znaków)</string>
|
||||
<!-- This key should contain a part of the tokens__add_manual_advanced_description which is written in bold in the app -->
|
||||
<string name="tokens__add_manual_advanced_description_highlight">nie jest zalecana</string>
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="guides__guide_init_title">Przewodnik 2FAS</string>
|
||||
<string name="guides__guide_title">2FAS dla %s</string>
|
||||
<string name="guides__guide_universal_title">Uniwersalny przewodnik 2FAS</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: pt-BR, Brazilian Portuguese
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:24 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -799,7 +799,8 @@
|
||||
<string name="commons__text_short_title">O texto fornecido é muito curto (min. %d chars)</string>
|
||||
<!-- This key should contain a part of the tokens__add_manual_advanced_description which is written in bold in the app -->
|
||||
<string name="tokens__add_manual_advanced_description_highlight">Não é recomendado</string>
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="guides__guide_init_title">Guia 2FAS</string>
|
||||
<string name="guides__guide_title">2FAS para %s</string>
|
||||
<string name="guides__guide_universal_title">Guia Universal 2FAS</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: pt-PT, Portuguese (Portugal)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -802,4 +802,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: uk-UA, Ukrainian (Ukraine)
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:25 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -805,7 +805,8 @@
|
||||
<string name="commons__text_short_title">Наданий текст занадто короткий (мін. %d символів)</string>
|
||||
<!-- This key should contain a part of the tokens__add_manual_advanced_description which is written in bold in the app -->
|
||||
<string name="tokens__add_manual_advanced_description_highlight">не рекомендовано</string>
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="guides__guide_init_title">Посібник 2FAS</string>
|
||||
<string name="guides__guide_title">2FAS для %s</string>
|
||||
<string name="guides__guide_universal_title">Універсальний посібник 2FA</string>
|
||||
<string name="browser__save_choice">Зберегти мій вибір</string>
|
||||
</resources>
|
||||
|
@ -5,7 +5,7 @@
|
||||
Release: Working copy
|
||||
Locale: en, English
|
||||
Exported by: rafakob
|
||||
Exported at: Sat, 19 Aug 2023 15:04:24 -0700
|
||||
Exported at: Fri, 25 Aug 2023 14:42:13 -0700
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- InfoPlist.strings
|
||||
@ -802,4 +802,5 @@
|
||||
<string name="guides__guide_init_title">2FAS guide</string>
|
||||
<string name="guides__guide_title">2FAS for %s</string>
|
||||
<string name="guides__guide_universal_title">Universal 2FA Guide</string>
|
||||
<string name="browser__save_choice">Save my choice</string>
|
||||
</resources>
|
||||
|
@ -52,8 +52,8 @@ fun ServiceIcon(
|
||||
) {
|
||||
Box(
|
||||
modifier = Modifier
|
||||
.width(45.dp)
|
||||
.height(28.dp)
|
||||
.width(28.dp)
|
||||
.height(18.dp)
|
||||
.clip(RoundedCornerShape(16.dp))
|
||||
.background(TwTheme.color.background)
|
||||
.align(Alignment.Center),
|
||||
@ -63,7 +63,7 @@ fun ServiceIcon(
|
||||
text = service.labelText.orEmpty().uppercase(),
|
||||
color = MaterialTheme.colorScheme.onSurface,
|
||||
textAlign = TextAlign.Center,
|
||||
style = TwTheme.typo.body3.copy(fontWeight = FontWeight.Bold, fontSize = dpToSp(dp = 22.dp), lineHeight = dpToSp(dp = 32.dp)),
|
||||
style = TwTheme.typo.body3.copy(fontWeight = FontWeight.Bold, fontSize = dpToSp(dp = 14.dp), lineHeight = dpToSp(dp = 20.dp)),
|
||||
modifier = Modifier.align(Alignment.Center)
|
||||
)
|
||||
}
|
||||
@ -128,39 +128,4 @@ fun ServiceCompact(
|
||||
fun Tint?.toColor(default: Tint = Tint.Default): Color {
|
||||
val tint = this ?: default
|
||||
return Color.parse(if (isNight()) tint.hexDark else tint.hex)
|
||||
}
|
||||
|
||||
@Preview(showSystemUi = true)
|
||||
@Composable
|
||||
fun ServiceCompact() {
|
||||
ServiceIcon(
|
||||
service = Service(
|
||||
id = 0,
|
||||
name = "",
|
||||
secret = "",
|
||||
authType = Service.AuthType.TOTP,
|
||||
otp = Service.Otp(
|
||||
link = null,
|
||||
label = "",
|
||||
account = "",
|
||||
issuer = null,
|
||||
digits = 0,
|
||||
period = 0,
|
||||
hotpCounter = 0,
|
||||
algorithm = Service.Algorithm.SHA1
|
||||
),
|
||||
badge = null,
|
||||
selectedImageType = Service.ImageType.IconCollection,
|
||||
labelText = null,
|
||||
labelBackgroundColor = Tint.Default,
|
||||
iconCollectionId = "",
|
||||
groupId = null,
|
||||
assignedDomains = emptyList(),
|
||||
isDeleted = false,
|
||||
backupSyncStatus = BackupSyncStatus.SYNCED,
|
||||
updatedAt = 0,
|
||||
serviceTypeId = null,
|
||||
source = Service.Source.Link,
|
||||
)
|
||||
)
|
||||
}
|
Loading…
Reference in New Issue
Block a user