Skip to content
Open
Show file tree
Hide file tree
Changes from 2 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 @@ -41,6 +41,8 @@ import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import androidx.hilt.navigation.compose.hiltViewModel
import network.columba.app.viewmodel.OnboardingViewModel
import androidx.compose.ui.res.stringResource
import network.columba.app.R

/**
* Welcome screen shown on first launch for fresh installs.
Expand Down Expand Up @@ -208,7 +210,7 @@ fun WelcomeScreen(
enabled = !state.isSaving,
) {
Text(
text = "Skip",
text = stringResource(R.string.skip),
color = MaterialTheme.colorScheme.onSurfaceVariant,
)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ import network.columba.app.util.BatteryOptimizationManager
import network.columba.app.viewmodel.DebugViewModel
import network.columba.app.viewmodel.OnboardingViewModel
import kotlinx.coroutines.launch

import androidx.compose.ui.res.stringResource
import network.columba.app.R
/**
* Main onboarding screen with horizontal pager for multi-step setup.
* Guides users through identity setup, connectivity options, and permissions.
Expand Down Expand Up @@ -293,7 +294,7 @@ private fun TopBar(
modifier = Modifier.align(Alignment.CenterEnd),
) {
Text(
text = "Skip",
text = stringResource(R.string.skip),
color = MaterialTheme.colorScheme.onSurfaceVariant,
)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import network.columba.app.ui.screens.onboarding.OnboardingInterfaceType
import androidx.compose.ui.res.stringResource
import network.columba.app.R


/**
* Connectivity page - allows user to select which network interfaces to enable.
Expand Down Expand Up @@ -72,7 +75,7 @@ fun ConnectivityPage(

// Title
Text(
text = "How will you connect?",
text = stringResource(R.string.connection_methods),
style = MaterialTheme.typography.headlineMedium,
fontWeight = FontWeight.Bold,
color = MaterialTheme.colorScheme.onBackground,
Expand All @@ -83,7 +86,7 @@ fun ConnectivityPage(

// Subtitle
Text(
text = "Select the networks you'd like to use:",
text = stringResource(R.string.connection_methods_description),
style = MaterialTheme.typography.bodyLarge,
color = MaterialTheme.colorScheme.onSurfaceVariant,
textAlign = TextAlign.Center,
Expand All @@ -108,8 +111,8 @@ fun ConnectivityPage(
icon = Icons.Default.Bluetooth,
statusText =
when {
blePermissionsDenied -> "Permissions denied"
blePermissionsGranted -> "Permissions granted"
blePermissionsDenied -> stringResource(R.string.permission_denied)
blePermissionsGranted -> stringResource(R.string.permission_granted)
else -> null
},
statusIsError = blePermissionsDenied,
Expand Down Expand Up @@ -137,7 +140,7 @@ fun ConnectivityPage(

// Helper text
Text(
text = "You can configure these later in Settings",
text = stringResource(R.string.configure_in_settings),
style = MaterialTheme.typography.bodyMedium,
color = MaterialTheme.colorScheme.onSurfaceVariant,
textAlign = TextAlign.Center,
Expand All @@ -158,7 +161,7 @@ fun ConnectivityPage(
.height(56.dp),
shape = RoundedCornerShape(12.dp),
) {
Text("Back")
Text(stringResource(R.string.back))
}

Button(
Expand All @@ -169,7 +172,7 @@ fun ConnectivityPage(
.height(56.dp),
shape = RoundedCornerShape(12.dp),
) {
Text("Continue")
Text(stringResource(R.string.nextAction))
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.text.input.ImeAction
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import androidx.compose.ui.res.stringResource
import network.columba.app.R



/**
* Identity page - allows user to set their display name.
Expand Down Expand Up @@ -67,7 +71,7 @@ fun IdentityPage(

// Title
Text(
text = "Your Identity",
text = stringResource(R.string.your_identity),
style = MaterialTheme.typography.headlineMedium,
fontWeight = FontWeight.Bold,
color = MaterialTheme.colorScheme.onBackground,
Expand All @@ -78,7 +82,7 @@ fun IdentityPage(

// Subtitle
Text(
text = "Choose a display name others will see:",
text = stringResource(R.string.choose_your_name),
style = MaterialTheme.typography.bodyLarge,
color = MaterialTheme.colorScheme.onSurfaceVariant,
textAlign = TextAlign.Center,
Expand All @@ -90,8 +94,8 @@ fun IdentityPage(
OutlinedTextField(
value = displayName,
onValueChange = onDisplayNameChange,
label = { Text("Display Name") },
placeholder = { Text("Anonymous Peer") },
label = { Text(stringResource(R.string.display_name)) },
placeholder = { Text(stringResource(R.string.name_example)) },
singleLine = true,
modifier = Modifier.fillMaxWidth(),
keyboardOptions =
Expand All @@ -112,7 +116,7 @@ fun IdentityPage(

// Helper text
Text(
text = "You can change this anytime, or create multiple identities for different contexts.",
text = stringResource(R.string.name_change_description),
style = MaterialTheme.typography.bodyMedium,
color = MaterialTheme.colorScheme.onSurfaceVariant,
textAlign = TextAlign.Center,
Expand All @@ -133,7 +137,7 @@ fun IdentityPage(
.height(56.dp),
shape = RoundedCornerShape(12.dp),
) {
Text("Back")
Text(stringResource(R.string.back))
}

Button(
Expand All @@ -147,7 +151,7 @@ fun IdentityPage(
.height(56.dp),
shape = RoundedCornerShape(12.dp),
) {
Text("Continue")
Text(stringResource(R.string.nextAction))
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ import androidx.compose.ui.graphics.vector.ImageVector
import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import androidx.compose.ui.res.stringResource
import network.columba.app.R

/**
* Permissions page - explains and requests notification and battery permissions.
Expand Down Expand Up @@ -69,7 +71,7 @@ fun PermissionsPage(

// Title
Text(
text = "Stay Connected",
text = stringResource(R.string.stay_connected),
style = MaterialTheme.typography.headlineMedium,
fontWeight = FontWeight.Bold,
color = MaterialTheme.colorScheme.onBackground,
Expand All @@ -80,7 +82,7 @@ fun PermissionsPage(

// Subtitle
Text(
text = "Columba can notify you when:",
text = stringResource(R.string.can_notify_you, stringResource(R.string.app_name)),
style = MaterialTheme.typography.bodyLarge,
color = MaterialTheme.colorScheme.onSurfaceVariant,
textAlign = TextAlign.Center,
Expand All @@ -93,18 +95,18 @@ fun PermissionsPage(
modifier = Modifier.padding(horizontal = 32.dp),
verticalArrangement = Arrangement.spacedBy(4.dp),
) {
FeatureItem("New messages arrive")
FeatureItem("Someone adds you as a contact")
FeatureItem("Delivery confirmations are received")
FeatureItem(stringResource(R.string.item_new_messages))
FeatureItem(stringResource(R.string.item_some_add_contact))
FeatureItem(stringResource(R.string.item_delivery_confirmed))
}

Spacer(modifier = Modifier.height(24.dp))

// Notification permission card
PermissionCard(
icon = Icons.Default.Notifications,
title = "Notifications",
description = "Get alerts for new messages",
title = stringResource(R.string.notifications),
description = stringResource(R.string.notifications_description),
isGranted = notificationsGranted,
onEnable = onEnableNotifications,
)
Expand All @@ -114,9 +116,9 @@ fun PermissionsPage(
// Battery optimization card
PermissionCard(
icon = Icons.Default.BatteryChargingFull,
title = "Unrestricted Battery",
description = "Receive messages even when phone is idle",
secondaryDescription = "Prevents Android from pausing Columba",
title = stringResource(R.string.unrestricted_battery),
description = stringResource(R.string.unrestricted_battery_description),
secondaryDescription = stringResource(R.string.unrestricted_battery_secondDescription, stringResource(R.string.app_name)),
isGranted = batteryOptimizationExempt,
onEnable = onEnableBatteryOptimization,
)
Expand All @@ -136,7 +138,7 @@ fun PermissionsPage(
.height(56.dp),
shape = RoundedCornerShape(12.dp),
) {
Text("Back")
Text(stringResource(R.string.back))
}

Button(
Expand All @@ -147,7 +149,7 @@ fun PermissionsPage(
.height(56.dp),
shape = RoundedCornerShape(12.dp),
) {
Text("Continue")
Text(stringResource(R.string.nextAction))
}
}

Expand Down Expand Up @@ -274,7 +276,7 @@ private fun PermissionCard(
onClick = onEnable,
shape = RoundedCornerShape(8.dp),
) {
Text("Enable")
Text(stringResource(R.string.enable))
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import network.columba.app.R
import androidx.compose.ui.res.stringResource

/**
* Welcome page - introduces privacy-first messaging.
Expand Down Expand Up @@ -82,7 +83,7 @@ fun WelcomePage(

// Title
Text(
text = "Welcome to Columba",
text = stringResource(R.string.welcome_to, stringResource(R.string.app_name)),
style = MaterialTheme.typography.headlineMedium,
fontWeight = FontWeight.Bold,
color = MaterialTheme.colorScheme.onBackground,
Expand All @@ -93,7 +94,7 @@ fun WelcomePage(

// Subtitle
Text(
text = "A private messenger that requires:",
text = stringResource(R.string.messenger_requires),
style = MaterialTheme.typography.bodyLarge,
color = MaterialTheme.colorScheme.onSurfaceVariant,
textAlign = TextAlign.Center,
Expand All @@ -102,17 +103,17 @@ fun WelcomePage(
Spacer(modifier = Modifier.height(24.dp))

// Privacy features
PrivacyFeature(text = "No phone number")
PrivacyFeature(text = stringResource(R.string.no_phone_number))
Spacer(modifier = Modifier.height(12.dp))
PrivacyFeature(text = "No email address")
PrivacyFeature(text = stringResource(R.string.no_email_address))
Spacer(modifier = Modifier.height(12.dp))
PrivacyFeature(text = "No sign-up or accounts")
PrivacyFeature(text = stringResource(R.string.no_accounts))

Spacer(modifier = Modifier.height(32.dp))

// Identity explanation
Text(
text = "Your identity is generated and stored securely on your device. You control it completely.",
text = stringResource(R.string.welcome_security_description),
style = MaterialTheme.typography.bodyMedium,
color = MaterialTheme.colorScheme.onSurfaceVariant,
textAlign = TextAlign.Center,
Expand All @@ -131,7 +132,7 @@ fun WelcomePage(
shape = RoundedCornerShape(12.dp),
) {
Text(
text = "Get Started",
text = stringResource(R.string.get_started),
style = MaterialTheme.typography.titleMedium,
)
}
Expand All @@ -143,7 +144,7 @@ fun WelcomePage(
onClick = onRestoreFromBackup,
) {
Text(
text = "Restore from backup",
text = stringResource(R.string.restore_from_backup),
color = MaterialTheme.colorScheme.primary,
)
}
Expand Down
70 changes: 70 additions & 0 deletions app/src/main/res/values-ru/strings.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">Columba</string>
<string name="incoming_voice_call">Входящий аудиовызов</string>
<string name="call_answer">Ответить</string>
<string name="call_decline">Отклонить</string>
<string name="call_answer_content_description">Ответить на вызов</string>
<string name="call_decline_content_description">Отклонить вызов</string>
<string name="error_no_file_manager">На телефоне не найден файловый менеджер</string>
<string name="locate_on_map">Геолокация на карте</string>
<string name="service_restart_banner">Перезапуск сервиса Reticulum \u2026</string>
<string name="offline_banner_shutdown">Columba сейчас оффлайн</string>
<string name="offline_banner_error">Ошибка подключения</string>
<string name="offline_banner_reconnecting">Переподключение\u2026</string>
<string name="offline_banner_reconnect">Переподключиться</string>
<string name="offline_banner_reconnecting_description">Процесс переподключения</string>
<string name="delete_interface">Удалить интерфейс</string>
<string name="view_interface_details">Детали</string>
<string name="interface_actions">Действия</string>
<string name="edit_interface">Редактировать</string>
<string name="messenger_requires">"Приватный мессерждер, для которого: "</string>
<string name="welcome_to">Добро пожаловть в %1$s</string>
<string name="no_phone_number">Не нужен номер телефона</string>
<string name="no_email_address">Не нужен Email</string>
<string name="no_accounts">Не нужна авторизация или аккаунты</string>
<string name="welcome_security_description">Вашш профиль создается и надежно хранится на вашем устройстве. Только вы контролируете его</string>
Comment thread
greptile-apps[bot] marked this conversation as resolved.
Outdated
<string name="get_started">Начать</string>
<string name="restore_from_backup">Восстановить из бэкапа</string>
<string name="your_identity">Ваш профиль</string>
<string name="choose_your_name">Напишите ваш никнейм, который будет виден всем</string>
<string name="display_name">Никнейм</string>
<string name="name_example">Анонимная нода</string>
<string name="name_change_description">Вы можете сменить его в любое время или создать другие профили</string>
<string name="back">Назад</string>
<string name="nextAction">Далее</string>
<string name="connection_methods">Как вы хотите подключиться?</string>
<string name="connection_methods_description">Выберите типы сетей, которые вы будете использовать:</string>
<string name="permission_denied">Разрешение отклонено</string>
<string name="permission_granted">Разрешение предоставлено</string>
<string name="configure_in_settings">Вы можете изменить это в настройках</string>
<string name="stay_connected">Оставайтесь на связи</string>
<string name="can_notify_you">%1$s может оповестить вас когда:</string>
<string name="item_new_messages">Пришло новое сообщение</string>
<string name="item_some_add_contact">Кто-то добавил вас в контакты</string>
<string name="item_delivery_confirmed">Получено подтверждение о доставке сообщения</string>
<string name="notifications">Уведомления</string>
<string name="skip">Пропустить</string>
<string name="notifications_description">Получение уведомлений о новых сообщениях</string>
<string name="unrestricted_battery">Без ограничений батареи</string>
<string name="unrestricted_battery_description">Получение уведомлений в режиме ожидания</string>
<string name="unrestricted_battery_secondDescription">Защищает %1$s от остановки в фоне</string>
<string name="enable">Включить</string>
<string name="disable">Выключить</string>
<string name="setup_completed">Вы всё настроили!</string>
<string name="summary">Итого</string>
<string name="identity">Никнейм</string>
<string name="networks">Сети</string>
<string name="none_seleced">Ничего не выбранно</string>
<string name="enabled">Включены</string>
<string name="disabled">Выключены</string>
<string name="restricted">Ограниченно</string>
<string name="unrestricted">Нет ограничения</string>
<string name="battery">Батарея</string>
<string name="show_qr">Показать QR код</string>
<string name="show_qr_description">Поделитесь своим QR-кодом, чтобы другие могли добавить вас в контакты.</string>
<string name="configure_lora">Настроить LoRa</string>
<string name="start_messaging">Начать общение</string>
<string name="share_identity">Поделиться профилем</string>
<string name="share_invite_message">Добавьте меня через reticulum: \\n\\n%1$s\\n%2$s</string>
</resources>
Loading