Skip to content

Commit 58a1a9c

Browse files
committed
feat: Implement adaptive Settings layout and cross-platform database backup
- Implement an adaptive master-detail layout for Settings using `ListDetailPaneScaffold` to support responsive phone and tablet layouts. - Reorganize Settings into category-based navigation (Theme, Security, Backup, Info) with dedicated master (`SettingsMasterScreen`) and detail (`SettingsDetailScreen`) components. - Introduce cross-platform database backup (import/export) support with platform-specific file pickers for Android, iOS, JVM, and wasmJs. - Create new `feature:backup` modules (`domain` and `ui`) to encapsulate backup logic and platform-agnostic file transfer using Okio. - Restructure Settings state management by adding `SettingsCategoriesViewModel` and updating `SettingsViewModel` to handle category-specific actions and backup operations. - Introduce `AdaptiveInteractor` support for synchronizing settings category selection across adaptive panes. - Move file explorer data logic from `core:data:file-explorer` to `feature:file-explorer:data`. - Add comprehensive UI test coverage for the backup feature and expand adaptive settings tests. - Upgrade Kotlin to `2.3.10` and update related dependencies (Paging, Compose, etc.) and build configurations. - Optimize iOS build tooling by disabling release framework tasks in the `ui:test` module during development. - Update `CHANGELOG.md` to reflect version `8.5.2` changes.
1 parent 5ca1eaa commit 58a1a9c

99 files changed

Lines changed: 2051 additions & 513 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/kmp.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,9 @@ jobs:
3636
with:
3737
path: ~/.konan
3838
key: kotlin-${{ steps.kotlin-version.outputs.version }}
39-
- name: Build
39+
- name: Quick build
40+
run: ./gradle/build_quick.sh
41+
- name: Full build
4042
run: ./gradlew build
4143
- name: Archive build-output artifacts
4244
if: always()

CHANGELOG.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,24 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [8.5.2] - 2026-02-06
9+
10+
### Features
11+
- Implement adaptive master-detail Settings layout with category-based navigation and dedicated master/detail screens
12+
- Add cross-platform database backup import/export support with platform-specific file pickers (Android, iOS, JVM, wasmJs)
13+
14+
### Refactoring
15+
- Reorganize modules by introducing `feature/backup` and moving file-explorer data into `feature/file-explorer/data`
16+
- Restructure Settings presentation flow with new settings categories state/view models and updated router contracts
17+
18+
### Tests
19+
- Add backup feature UI test coverage and cross-platform temporary backup-path test utilities
20+
- Expand adaptive/settings test coverage across Android host tests and desktop UI tests
21+
22+
### Chores
23+
- Upgrade Kotlin to `2.3.10` and refresh related dependency/build configuration
24+
- Update iOS/build tooling and quick-build script settings (including increased Kotlin/Native memory options)
25+
826
## [8.5.1] - 2026-01-27
927

1028
### Features

CONTRIBUTING.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,7 @@ private fun ScreenContent(
225225
4. **Preview functions**: Add `@Preview` for visual components
226226
5. **Remember wisely**: Use `remember` for expensive calculations
227227
6. **Keys in lists**: Provide stable keys for LazyColumn/LazyRow
228+
7. **Adaptive drag handle**: Prefer method references for pane expansion, e.g. `paneExpansionDragHandle = ThreePaneScaffoldScope::VerticalPaneExpansionDragHandle` (use a lambda in Kotlin/Wasm actuals to avoid the current composable function reference compiler issue).
228229

229230
### ViewModel Style
230231

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ Supported platforms:
4040
|:------------------:|:-------:|:---:|:------------:|:---:|
4141
| database |||||
4242
| encryption |||| |
43-
| ui |||| |
43+
| backup |||| |
4444

4545
Check out [CONTRIBUTING.md](/CONTRIBUTING.md) if you want to develop missing features.
4646

app/android/build.gradle.kts

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ android {
2323
applicationId = "com.softartdev.noteroom"
2424
minSdk = libs.versions.minSdk.get().toInt()
2525
targetSdk = libs.versions.targetSdk.get().toInt()
26-
versionCode = 851
27-
versionName = "8.5.1"
26+
versionCode = 852
27+
versionName = "8.5.2"
2828
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
2929
testInstrumentationRunnerArguments["clearPackageData"] = "true"
3030
vectorDrawables.useSupportLibrary = true
@@ -72,14 +72,16 @@ dependencies {
7272
implementation(project(project.property("CORE_DATA_DB_MODULE").toString()))
7373
implementation(projects.core.presentation)
7474
implementation(projects.ui.shared)
75+
implementation(projects.feature.backup.domain)
76+
implementation(projects.feature.backup.ui)
7577
implementation(kotlin("reflect", libs.versions.kotlin.get()))
7678
implementation(libs.androidx.core.splashscreen)
7779
implementation(libs.androidx.appcompat)
7880
implementation(libs.androidx.activity.compose)
79-
implementation(compose.ui)
80-
implementation(compose.material3)
81-
implementation(compose.preview)
82-
debugImplementation(compose.uiTooling)
81+
implementation(libs.compose.ui)
82+
implementation(libs.compose.material3)
83+
implementation(libs.compose.ui.tooling.preview)
84+
debugImplementation(libs.compose.ui.tooling)
8385
debugImplementation(libs.androidx.compose.test.manifest)
8486
implementation(libs.androidx.navigation.compose)
8587
implementation(libs.material.theme.prefs)
@@ -108,7 +110,7 @@ dependencies {
108110
androidTestUtil(libs.androidx.test.orchestrator)
109111
androidTestImplementation(libs.espresso.core)
110112
androidTestImplementation(libs.espresso.device)
111-
androidTestImplementation(compose.desktop.uiTestJUnit4)
113+
androidTestImplementation(libs.compose.ui.test.junit4)
112114
androidTestImplementation(libs.turbine)
113115
androidTestImplementation(libs.leakCanary.android.instrumentation)
114116
lintChecks(libs.android.security.lint)

app/android/src/androidTest/java/com/softartdev/notedelight/ui/AndroidUiTests.kt

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import androidx.test.ext.junit.runners.AndroidJUnit4
66
import androidx.test.filters.FlakyTest
77
import androidx.test.filters.LargeTest
88
import com.softartdev.notedelight.MainActivity
9+
import com.softartdev.notedelight.di.backupTestModule
910
import leakcanary.DetectLeaksAfterTestSuccess
1011
import leakcanary.TestDescriptionHolder
1112
import org.junit.After
@@ -14,6 +15,8 @@ import org.junit.Rule
1415
import org.junit.Test
1516
import org.junit.rules.RuleChain
1617
import org.junit.runner.RunWith
18+
import org.koin.core.context.loadKoinModules
19+
import org.koin.core.context.unloadKoinModules
1720

1821
@LargeTest
1922
@FlakyTest
@@ -57,6 +60,13 @@ class AndroidUiTests : AbstractJvmUiTests() {
5760
@Test
5861
override fun localeTest() = super.localeTest()
5962

63+
@Test
64+
override fun backupFeatureTest() {
65+
loadKoinModules(backupTestModule)
66+
super.backupFeatureTest()
67+
unloadKoinModules(backupTestModule)
68+
}
69+
6070
override fun pressBack() = Espresso.pressBack()
6171

6272
override fun closeSoftKeyboard() = Espresso.closeSoftKeyboard()

app/android/src/androidTest/java/com/softartdev/notedelight/ui/RotationTest.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,4 +49,4 @@ class RotationTest {
4949

5050
onDevice().setScreenOrientation(ScreenOrientation.PORTRAIT)
5151
}
52-
}
52+
}

app/android/src/androidTest/java/com/softartdev/notedelight/ui/SignInTest.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,4 @@ class SignInTest {
3535

3636
@Test
3737
fun signInTest() = SignInTestCase(composeUiTest, Espresso::closeSoftKeyboard).invoke()
38-
}
38+
}

app/android/src/androidTest/java/com/softartdev/notedelight/ui/SignInToSettingsTest.kt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,9 @@ class SignInToSettingsTest {
3434
private val composeUiTest: ComposeUiTest = reflect(composeTestRule)
3535

3636
@Test
37-
fun signInToSettingsTest() = SignInToSettingsTestCase(composeUiTest, Espresso::closeSoftKeyboard).invoke()
37+
fun signInToSettingsTest() = SignInToSettingsTestCase(
38+
composeUiTest,
39+
Espresso::closeSoftKeyboard,
40+
Espresso::pressBack,
41+
).invoke()
3842
}
39-

app/android/src/androidTest/java/com/softartdev/notedelight/ui/SignOutTest.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,4 +39,4 @@ class SignOutTest {
3939

4040
assertTrue(composeTestRule.activityRule.scenario.state.isAtLeast(DESTROYED))
4141
}
42-
}
42+
}

0 commit comments

Comments
 (0)