Skip to content

Commit 95f8029

Browse files
committed
fix: settings UX, a11y and microcopy polish
- Privacy audit log empty state now shows a purpose-written message instead of reusing the home-screen preference summary (which described the feature rather than the empty state). - Theme manager: the dark/light variant indicator icon was the only signal of a theme's mode and had no contentDescription, so TalkBack announced nothing. Add 'Dark theme' / 'Light theme' labels. - Learned entries: guard the Words / Phrase pairs / Phrase triples groups so an empty category no longer renders a dangling header with no rows beneath it. - Microcopy: reword the sync-import success summary to count-neutral past tense ('1 inserted' not '1 inserts'); make 'Check for Updates' sentence case to match the rest of the app.
1 parent d76f3f8 commit 95f8029

4 files changed

Lines changed: 16 additions & 7 deletions

File tree

app/src/main/kotlin/dev/patrickgold/florisboard/app/settings/dictionary/LearnedEntriesScreen.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ fun LearnedEntriesScreen() = FlorisScreen {
9999
)
100100
} else {
101101
LazyColumn(contentPadding = PaddingValues(bottom = 32.dp)) {
102-
item {
102+
if (current.words.isNotEmpty()) item {
103103
PreferenceGroup(title = stringRes(R.string.settings__learned_entries__words_title)) {
104104
current.words.forEach { entry ->
105105
JetPrefListItem(
@@ -118,7 +118,7 @@ fun LearnedEntriesScreen() = FlorisScreen {
118118
}
119119
}
120120
}
121-
item {
121+
if (current.bigrams.isNotEmpty()) item {
122122
PreferenceGroup(title = stringRes(R.string.settings__learned_entries__bigrams_title)) {
123123
current.bigrams.forEach { entry ->
124124
JetPrefListItem(
@@ -135,7 +135,7 @@ fun LearnedEntriesScreen() = FlorisScreen {
135135
}
136136
}
137137
}
138-
item {
138+
if (current.trigrams.isNotEmpty()) item {
139139
PreferenceGroup(title = stringRes(R.string.settings__learned_entries__trigrams_title)) {
140140
current.trigrams.forEach { entry ->
141141
JetPrefListItem(

app/src/main/kotlin/dev/patrickgold/florisboard/app/settings/privacy/PrivacyAuditScreen.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ fun PrivacyAuditScreen() = FlorisScreen {
113113
modifier = Modifier.padding(horizontal = 16.dp, vertical = 8.dp),
114114
icon = Icons.Default.Shield,
115115
title = stringRes(R.string.settings__privacy_audit__empty),
116-
message = stringRes(R.string.settings__privacy_audit__home_summary),
116+
message = stringRes(R.string.settings__privacy_audit__empty_message),
117117
)
118118
} else {
119119
for (record in records.asReversed().take(MAX_DISPLAYED_RECORDS)) {

app/src/main/kotlin/dev/patrickgold/florisboard/app/settings/theme/ThemeManagerScreen.kt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,13 @@ fun ThemeManagerScreen(action: ThemeManagerScreenAction?) = FlorisScreen {
145145
} else {
146146
Icons.Default.LightMode
147147
},
148-
contentDescription = null,
148+
contentDescription = stringRes(
149+
if (config.isNightTheme) {
150+
R.string.settings__theme_manager__variant_dark
151+
} else {
152+
R.string.settings__theme_manager__variant_light
153+
},
154+
),
149155
tint = grayColor,
150156
)
151157
},

app/src/main/res/values/strings.xml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -422,7 +422,7 @@
422422
<string name="settings__sync__export_success_summary" comment="Sync export success summary">{count} personal dictionary entries were sealed for paired devices.</string>
423423
<string name="settings__sync__export_success_summary_fallback" comment="Sync export success fallback summary">The selected sync file was updated.</string>
424424
<string name="settings__sync__import_success" comment="Sync import success title">Sync file imported</string>
425-
<string name="settings__sync__import_success_summary" comment="Sync import success summary">Applied {inserted} inserts, {updated} updates, and {deleted} deletes.</string>
425+
<string name="settings__sync__import_success_summary" comment="Sync import success summary">Applied {inserted} inserted, {updated} updated, and {deleted} removed.</string>
426426
<string name="settings__sync__import_success_summary_fallback" comment="Sync import success fallback summary">The selected sync file was merged into this device.</string>
427427
<string name="settings__sync__transfer_failure" comment="Sync transfer failure title">Sync file could not be processed</string>
428428
<string name="settings__sync__transfer_failure_summary" comment="Sync transfer failure summary">No dictionary data changed. {error_message}</string>
@@ -537,6 +537,8 @@
537537
<string name="settings__theme_manager__title_manage" comment="Title of the theme manager screen for managing installed and custom themes">Manage installed themes</string>
538538
<string name="settings__theme_manager__empty_title">No themes available</string>
539539
<string name="settings__theme_manager__empty_message">Bundled themes should appear here. If this stays empty, reinstall SwiftFloris or import a trusted theme extension.</string>
540+
<string name="settings__theme_manager__variant_dark" comment="Accessibility label for the dark-theme indicator icon">Dark theme</string>
541+
<string name="settings__theme_manager__variant_light" comment="Accessibility label for the light-theme indicator icon">Light theme</string>
540542
<string name="pref__theme__source_assets" comment="Label for the theme source field">Bundled SwiftFloris assets</string>
541543
<string name="pref__theme__source_internal" comment="Label for the theme source field">App-private storage</string>
542544
<string name="pref__theme__source_external" comment="Label for the theme source field">External document provider</string>
@@ -1077,6 +1079,7 @@
10771079
<string name="settings__privacy_audit__group_records" comment="Preference group title">Recent activity</string>
10781080
<string name="settings__privacy_audit__summary_title" comment="Preference title showing the audit summary line">Audit log</string>
10791081
<string name="settings__privacy_audit__empty" comment="Shown when no records exist">No recorded activity yet.</string>
1082+
<string name="settings__privacy_audit__empty_message" comment="Empty-state body shown when no audit records exist">SwiftFloris hasn\'t made any cross-process calls on this device yet. Addon, MCP, and translation activity will appear here as it happens.</string>
10801083
<string name="settings__privacy_audit__export" comment="Action title">Copy log as JSON</string>
10811084
<string name="settings__privacy_audit__export__summary" comment="Action summary">Copies the full audit bundle to the clipboard so you can paste it anywhere — it never leaves the device on its own.</string>
10821085
<string name="settings__privacy_audit__export_toast" comment="Toast after copying">Audit log copied to the clipboard.</string>
@@ -1858,7 +1861,7 @@
18581861
<string name="ext__view__delete_in_progress_summary">Keep this screen open while SwiftFloris removes the extension and refreshes installed themes.</string>
18591862
<string name="ext__view__delete_failure">Could not delete extension</string>
18601863
<string name="ext__view__delete_failure_summary">The extension is still installed. Review the error, then retry after leaving screens that use this extension. Details: {error_message}</string>
1861-
<string name="ext__check_updates__title">Check for Updates</string>
1864+
<string name="ext__check_updates__title">Check for updates</string>
18621865

18631866
<!-- Action strings -->
18641867
<string name="action__add">Add</string>

0 commit comments

Comments
 (0)