refactor: remove liquid glass feature entirely (closes #385)#518
refactor: remove liquid glass feature entirely (closes #385)#518rainxchzed merged 3 commits intomainfrom
Conversation
…, and platform helpers
….1 what's-new across locales
WalkthroughThis PR comprehensively removes the Liquid Glass visual effect feature from the entire application, including build dependencies, repository contracts, state management across all feature screens, composition locals for state passing, UI component modifiers, string resources in all supported languages, and release notes documenting the removal. ChangesLiquid Glass Feature Removal
Estimated code review effort🎯 4 (Complex) | ⏱️ ~75 minutes The PR spans the entire application architecture (build configuration, domain, data, state management, navigation, UI components across six feature modules) with heterogeneous changes affecting dependencies, API signatures, state fields, initialization logic, and UI modifier chains. While individual changes follow a consistent pattern (removal of liquid-glass references), the breadth across multiple feature modules, localization files, and interconnected layer removals demands careful verification that all liquid-glass usages are eliminated and dependent code properly simplified. Possibly related PRs
Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
|
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (2)
core/presentation/src/commonMain/composeResources/files/whatsnew/ja/16.json (1)
1-41:⚠️ Potential issue | 🟠 MajorThe Japanese what's-new entry for version 1.8.1 is valid, but the PR has incomplete locale coverage.
The JSON syntax is correct and the Liquid Glass removal entry properly documents the fix for the dark-mode icon visibility issue (
#385). However, verification reveals that 8 of 13 locale files are missing this entry: Turkish (tr), Korean (ko), Russian (ru), Simplified Chinese (zh-CN), Polish (pl), Bengali (bn), Arabic (ar), and Hindi (hi). Since the PR summary claims the what's-new entry was "added for 1.8.1 across locales," these missing entries should be added to the other locale files to match the stated scope.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@core/presentation/src/commonMain/composeResources/files/whatsnew/ja/16.json` around lines 1 - 41, The PR added the Japanese 1.8.1 what's-new JSON (versionCode 16 / versionName "1.8.1") but omitted the same entry in eight locales; add an equivalent whatsnew JSON section (preserving "versionCode": 16, "versionName": "1.8.1", "showAsSheet": true and a FIXED section containing the Liquid Glass removal bullet) to the missing locale files for Turkish (tr), Korean (ko), Russian (ru), Simplified Chinese (zh-CN), Polish (pl), Bengali (bn), Arabic (ar) and Hindi (hi); if proper translations for the bullet "リキッドグラス効果を削除しました — ダークモードでは透明な背景にアイコンが見えなくなることがありました。全体的にすっきりした、コントラストの高い UI になりました。" are not available, include the English description or a clear translated equivalent, and ensure JSON syntax matches the existing structure (sections array with type "FIXED" and bullets array).feature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/DetailsRoot.kt (1)
816-828:⚠️ Potential issue | 🟡 Minor | ⚡ Quick winRemove the dead gradient — it is fully overdrawn by the solid background.
The modifier chain on
DetailsTopbarcurrently applies two chained.background()calls:.background(Brush.linearGradient(...)) // lines 822-827 (pre-existing) .background(MaterialTheme.colorScheme.surfaceContainerHighest) // line 828 (new)GPU overdraw occurs when the GPU renders pixels that are subsequently covered by other pixels, meaning that the drawn pixels are not visible in the final frame. Since
surfaceContainerHighestis a fully opaque Material3 token, the gradient is never visible — it is painted and then immediately overdrawn on every frame. TheBrushimport (Line 57) also becomes orphaned once the gradient is removed.🛠️ Proposed fix — drop the redundant gradient background and unused import
-import androidx.compose.ui.graphics.Brush import androidx.compose.ui.graphics.Colormodifier = Modifier .shadow( elevation = 6.dp, ambientColor = MaterialTheme.colorScheme.surfaceTint, spotColor = MaterialTheme.colorScheme.primary.copy(alpha = 0.3f), - ).background( - Brush.linearGradient( - 0f to MaterialTheme.colorScheme.surface.copy(alpha = 0.9f), - 0.5f to MaterialTheme.colorScheme.surfaceVariant.copy(alpha = 0.7f), - 1f to MaterialTheme.colorScheme.surface.copy(alpha = 0.85f), - ), ).background(MaterialTheme.colorScheme.surfaceContainerHighest),🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@feature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/DetailsRoot.kt` around lines 816 - 828, The chained modifier on DetailsTopbar currently paints a linear gradient then immediately covers it with MaterialTheme.colorScheme.surfaceContainerHighest causing GPU overdraw; remove the intermediate .background(Brush.linearGradient(...)) call from the modifier chain in DetailsRoot (the .shadow(...).background(Brush.linearGradient(...)).background(MaterialTheme.colorScheme.surfaceContainerHighest) sequence) so only the shadow and the final opaque background remain, and also remove the now-unused Brush import at the top of the file.
🧹 Nitpick comments (1)
feature/home/presentation/src/commonMain/kotlin/zed/rainxch/home/presentation/components/HomeFilterChips.kt (1)
55-60: ⚡ Quick winRename LiquidGlass-prefixed composables to neutral names.
After removing the liquid feature path,
LiquidGlassCategoryChips/LiquidGlassCategoryChipnames are misleading. Renaming now will reduce future confusion and API drift.♻️ Proposed rename sketch
-fun LiquidGlassCategoryChips( +fun HomeCategoryChips( @@ -private fun LiquidGlassCategoryChip( +private fun HomeCategoryChip(- LiquidGlassCategoryChips( + HomeCategoryChips(Also applies to: 278-284
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@feature/home/presentation/src/commonMain/kotlin/zed/rainxch/home/presentation/components/HomeFilterChips.kt` around lines 55 - 60, Rename the LiquidGlass-prefixed composables to neutral names: change LiquidGlassCategoryChips to CategoryChips and LiquidGlassCategoryChip to CategoryChip (and update all usages and imports accordingly, including the occurrences around the other reference at lines 278-284). Locate the declarations/definitions of LiquidGlassCategoryChips and LiquidGlassCategoryChip and rename the functions, then update any places that call these functions or reference them in previews/tests to use the new names to avoid API drift and misleading feature-specific naming.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Outside diff comments:
In `@core/presentation/src/commonMain/composeResources/files/whatsnew/ja/16.json`:
- Around line 1-41: The PR added the Japanese 1.8.1 what's-new JSON (versionCode
16 / versionName "1.8.1") but omitted the same entry in eight locales; add an
equivalent whatsnew JSON section (preserving "versionCode": 16, "versionName":
"1.8.1", "showAsSheet": true and a FIXED section containing the Liquid Glass
removal bullet) to the missing locale files for Turkish (tr), Korean (ko),
Russian (ru), Simplified Chinese (zh-CN), Polish (pl), Bengali (bn), Arabic (ar)
and Hindi (hi); if proper translations for the bullet "リキッドグラス効果を削除しました —
ダークモードでは透明な背景にアイコンが見えなくなることがありました。全体的にすっきりした、コントラストの高い UI になりました。" are not
available, include the English description or a clear translated equivalent, and
ensure JSON syntax matches the existing structure (sections array with type
"FIXED" and bullets array).
In
`@feature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/DetailsRoot.kt`:
- Around line 816-828: The chained modifier on DetailsTopbar currently paints a
linear gradient then immediately covers it with
MaterialTheme.colorScheme.surfaceContainerHighest causing GPU overdraw; remove
the intermediate .background(Brush.linearGradient(...)) call from the modifier
chain in DetailsRoot (the
.shadow(...).background(Brush.linearGradient(...)).background(MaterialTheme.colorScheme.surfaceContainerHighest)
sequence) so only the shadow and the final opaque background remain, and also
remove the now-unused Brush import at the top of the file.
---
Nitpick comments:
In
`@feature/home/presentation/src/commonMain/kotlin/zed/rainxch/home/presentation/components/HomeFilterChips.kt`:
- Around line 55-60: Rename the LiquidGlass-prefixed composables to neutral
names: change LiquidGlassCategoryChips to CategoryChips and
LiquidGlassCategoryChip to CategoryChip (and update all usages and imports
accordingly, including the occurrences around the other reference at lines
278-284). Locate the declarations/definitions of LiquidGlassCategoryChips and
LiquidGlassCategoryChip and rename the functions, then update any places that
call these functions or reference them in previews/tests to use the new names to
avoid API drift and misleading feature-specific naming.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 364f7885-e595-432b-bfc6-c00e79edf5f5
📒 Files selected for processing (76)
composeApp/build.gradle.ktscomposeApp/src/commonMain/kotlin/zed/rainxch/githubstore/Main.ktcomposeApp/src/commonMain/kotlin/zed/rainxch/githubstore/MainState.ktcomposeApp/src/commonMain/kotlin/zed/rainxch/githubstore/MainViewModel.ktcomposeApp/src/commonMain/kotlin/zed/rainxch/githubstore/app/navigation/AppNavigation.ktcomposeApp/src/commonMain/kotlin/zed/rainxch/githubstore/app/navigation/BottomNavigation.ktcore/data/src/commonMain/kotlin/zed/rainxch/core/data/repository/TweaksRepositoryImpl.ktcore/domain/src/commonMain/kotlin/zed/rainxch/core/domain/repository/TweaksRepository.ktcore/presentation/build.gradle.ktscore/presentation/src/androidMain/kotlin/zed/rainxch/core/presentation/utils/isLiquidFrostAvailable.android.ktcore/presentation/src/commonMain/composeResources/files/whatsnew/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/ar/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/bn/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/es/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/fr/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/hi/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/it/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/ja/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/ko/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/pl/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/ru/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/tr/16.jsoncore/presentation/src/commonMain/composeResources/files/whatsnew/zh-CN/16.jsoncore/presentation/src/commonMain/composeResources/values-ar/strings-ar.xmlcore/presentation/src/commonMain/composeResources/values-bn/strings-bn.xmlcore/presentation/src/commonMain/composeResources/values-es/strings-es.xmlcore/presentation/src/commonMain/composeResources/values-fr/strings-fr.xmlcore/presentation/src/commonMain/composeResources/values-hi/strings-hi.xmlcore/presentation/src/commonMain/composeResources/values-it/strings-it.xmlcore/presentation/src/commonMain/composeResources/values-ja/strings-ja.xmlcore/presentation/src/commonMain/composeResources/values-ko/strings-ko.xmlcore/presentation/src/commonMain/composeResources/values-pl/strings-pl.xmlcore/presentation/src/commonMain/composeResources/values-ru/strings-ru.xmlcore/presentation/src/commonMain/composeResources/values-tr/strings-tr.xmlcore/presentation/src/commonMain/composeResources/values-zh-rCN/strings-zh-rCN.xmlcore/presentation/src/commonMain/composeResources/values/strings.xmlcore/presentation/src/commonMain/kotlin/zed/rainxch/core/presentation/locals/LocalBottomNavigationLiquid.ktcore/presentation/src/commonMain/kotlin/zed/rainxch/core/presentation/utils/isLiquidFrostAvailable.ktcore/presentation/src/jvmMain/kotlin/zed/rainxch/core/presentation/utils/isLiquidFrostAvailable.jvm.ktfeature/apps/presentation/build.gradle.ktsfeature/apps/presentation/src/commonMain/kotlin/zed/rainxch/apps/presentation/AppsRoot.ktfeature/apps/presentation/src/commonMain/kotlin/zed/rainxch/apps/presentation/AppsState.ktfeature/apps/presentation/src/commonMain/kotlin/zed/rainxch/apps/presentation/AppsViewModel.ktfeature/details/presentation/build.gradle.ktsfeature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/DetailsRoot.ktfeature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/DetailsState.ktfeature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/DetailsViewModel.ktfeature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/components/SmartInstallButton.ktfeature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/components/sections/About.ktfeature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/components/sections/Header.ktfeature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/components/sections/Logs.ktfeature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/components/sections/Owner.ktfeature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/components/sections/Stats.ktfeature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/components/sections/WhatsNew.ktfeature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/utils/LocalTopbarLiquidState.ktfeature/home/presentation/build.gradle.ktsfeature/home/presentation/src/commonMain/kotlin/zed/rainxch/home/presentation/HomeRoot.ktfeature/home/presentation/src/commonMain/kotlin/zed/rainxch/home/presentation/HomeState.ktfeature/home/presentation/src/commonMain/kotlin/zed/rainxch/home/presentation/HomeViewModel.ktfeature/home/presentation/src/commonMain/kotlin/zed/rainxch/home/presentation/components/HomeFilterChips.ktfeature/home/presentation/src/commonMain/kotlin/zed/rainxch/home/presentation/locals/LocalHomeTopBarLiquid.ktfeature/profile/presentation/build.gradle.ktsfeature/profile/presentation/src/commonMain/kotlin/zed/rainxch/profile/presentation/ProfileRoot.ktfeature/profile/presentation/src/commonMain/kotlin/zed/rainxch/profile/presentation/ProfileState.ktfeature/profile/presentation/src/commonMain/kotlin/zed/rainxch/profile/presentation/ProfileViewModel.ktfeature/search/presentation/build.gradle.ktsfeature/search/presentation/src/commonMain/kotlin/zed/rainxch/search/presentation/SearchRoot.ktfeature/search/presentation/src/commonMain/kotlin/zed/rainxch/search/presentation/SearchState.ktfeature/search/presentation/src/commonMain/kotlin/zed/rainxch/search/presentation/SearchViewModel.ktfeature/tweaks/presentation/build.gradle.ktsfeature/tweaks/presentation/src/commonMain/kotlin/zed/rainxch/tweaks/presentation/TweaksAction.ktfeature/tweaks/presentation/src/commonMain/kotlin/zed/rainxch/tweaks/presentation/TweaksRoot.ktfeature/tweaks/presentation/src/commonMain/kotlin/zed/rainxch/tweaks/presentation/TweaksState.ktfeature/tweaks/presentation/src/commonMain/kotlin/zed/rainxch/tweaks/presentation/TweaksViewModel.ktfeature/tweaks/presentation/src/commonMain/kotlin/zed/rainxch/tweaks/presentation/components/sections/Appearance.ktgradle/libs.versions.toml
💤 Files with no reviewable changes (54)
- feature/profile/presentation/src/commonMain/kotlin/zed/rainxch/profile/presentation/ProfileViewModel.kt
- feature/tweaks/presentation/src/commonMain/kotlin/zed/rainxch/tweaks/presentation/TweaksRoot.kt
- composeApp/src/commonMain/kotlin/zed/rainxch/githubstore/app/navigation/AppNavigation.kt
- core/presentation/src/commonMain/composeResources/values-it/strings-it.xml
- feature/profile/presentation/src/commonMain/kotlin/zed/rainxch/profile/presentation/ProfileState.kt
- core/presentation/src/commonMain/composeResources/values-ko/strings-ko.xml
- composeApp/src/commonMain/kotlin/zed/rainxch/githubstore/MainViewModel.kt
- feature/profile/presentation/src/commonMain/kotlin/zed/rainxch/profile/presentation/ProfileRoot.kt
- core/presentation/src/commonMain/composeResources/values-zh-rCN/strings-zh-rCN.xml
- feature/apps/presentation/src/commonMain/kotlin/zed/rainxch/apps/presentation/AppsRoot.kt
- core/presentation/src/commonMain/composeResources/values/strings.xml
- core/presentation/src/commonMain/kotlin/zed/rainxch/core/presentation/utils/isLiquidFrostAvailable.kt
- feature/home/presentation/src/commonMain/kotlin/zed/rainxch/home/presentation/HomeViewModel.kt
- core/presentation/build.gradle.kts
- feature/tweaks/presentation/src/commonMain/kotlin/zed/rainxch/tweaks/presentation/components/sections/Appearance.kt
- core/data/src/commonMain/kotlin/zed/rainxch/core/data/repository/TweaksRepositoryImpl.kt
- core/presentation/src/commonMain/kotlin/zed/rainxch/core/presentation/locals/LocalBottomNavigationLiquid.kt
- core/presentation/src/jvmMain/kotlin/zed/rainxch/core/presentation/utils/isLiquidFrostAvailable.jvm.kt
- feature/search/presentation/build.gradle.kts
- core/presentation/src/commonMain/composeResources/values-tr/strings-tr.xml
- composeApp/build.gradle.kts
- core/presentation/src/androidMain/kotlin/zed/rainxch/core/presentation/utils/isLiquidFrostAvailable.android.kt
- feature/tweaks/presentation/src/commonMain/kotlin/zed/rainxch/tweaks/presentation/TweaksAction.kt
- feature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/components/sections/WhatsNew.kt
- composeApp/src/commonMain/kotlin/zed/rainxch/githubstore/MainState.kt
- feature/home/presentation/src/commonMain/kotlin/zed/rainxch/home/presentation/locals/LocalHomeTopBarLiquid.kt
- feature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/utils/LocalTopbarLiquidState.kt
- feature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/DetailsViewModel.kt
- core/domain/src/commonMain/kotlin/zed/rainxch/core/domain/repository/TweaksRepository.kt
- feature/home/presentation/build.gradle.kts
- feature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/DetailsState.kt
- feature/apps/presentation/build.gradle.kts
- feature/search/presentation/src/commonMain/kotlin/zed/rainxch/search/presentation/SearchState.kt
- core/presentation/src/commonMain/composeResources/values-pl/strings-pl.xml
- feature/profile/presentation/build.gradle.kts
- core/presentation/src/commonMain/composeResources/values-es/strings-es.xml
- feature/home/presentation/src/commonMain/kotlin/zed/rainxch/home/presentation/HomeState.kt
- core/presentation/src/commonMain/composeResources/values-fr/strings-fr.xml
- composeApp/src/commonMain/kotlin/zed/rainxch/githubstore/Main.kt
- feature/details/presentation/build.gradle.kts
- feature/tweaks/presentation/build.gradle.kts
- core/presentation/src/commonMain/composeResources/values-hi/strings-hi.xml
- feature/search/presentation/src/commonMain/kotlin/zed/rainxch/search/presentation/SearchViewModel.kt
- feature/apps/presentation/src/commonMain/kotlin/zed/rainxch/apps/presentation/AppsState.kt
- core/presentation/src/commonMain/composeResources/values-ru/strings-ru.xml
- feature/tweaks/presentation/src/commonMain/kotlin/zed/rainxch/tweaks/presentation/TweaksViewModel.kt
- feature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/components/sections/Header.kt
- core/presentation/src/commonMain/composeResources/values-bn/strings-bn.xml
- feature/tweaks/presentation/src/commonMain/kotlin/zed/rainxch/tweaks/presentation/TweaksState.kt
- gradle/libs.versions.toml
- core/presentation/src/commonMain/composeResources/values-ar/strings-ar.xml
- core/presentation/src/commonMain/composeResources/values-ja/strings-ja.xml
- feature/apps/presentation/src/commonMain/kotlin/zed/rainxch/apps/presentation/AppsViewModel.kt
- feature/details/presentation/src/commonMain/kotlin/zed/rainxch/details/presentation/components/sections/About.kt
Closes #385
Why
Liquid Glass was the cause of #385 — in dark mode, the topbar action icons could become invisible against transparent backgrounds. Per the issue, the user wanted icons to display correctly. Rather than patching the contrast bug, we're removing the feature entirely as part of a larger UI refactor that wants a cleaner, higher-contrast surface across the app.
The effect was provided by the third-party library `io.github.fletchmckee:liquid:1.1.1` and gated behind a user-toggleable setting (`Settings → Appearance → Liquid Glass Effect`). Removal touches every screen that opted in.
What's gone
What stays
Diff stats
`76 files changed, 163 insertions(+), 830 deletions(-)` — net -667 LoC. Three commits: deps + helpers, UI strip, strings + what's-new.
Test plan
Summary by CodeRabbit