[WIP] MS-1451 Module selection rework - #1790
Draft
luhmirin-s wants to merge 6 commits into
Draft
Conversation
There was a problem hiding this comment.
Pull request overview
Reworks “module selection” by replacing the legacy dashboard module-selection screen with a new :feature:module-selector bottom-sheet dialog, while also relocating the settings-password dialog into :infra:ui-base for reuse. This aligns module selection with a dedicated feature module and updates navigation/resources accordingly.
Changes:
- Added new
:feature:module-selectormodule (UI, ViewModel, adapter, layouts) and wired it into the dashboard navigation graph. - Moved/centralized
SettingsPasswordDialogFragmentinto:infra:ui-basewith a new dialog layout + updated imports/usages. - Updated shared resources (strings + widget styles) and removed the legacy dashboard module-selection implementation and its tests/resources.
Reviewed changes
Copilot reviewed 46 out of 47 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| settings.gradle.kts | Includes the new :feature:module-selector module in the Gradle settings. |
| infra/ui-base/src/test/java/com/simprints/infra/uibase/password/SettingsPasswordDialogFragmentTest.kt | Adds an (ignored) test scaffold for the moved password dialog. |
| infra/ui-base/src/main/res/layout/dialog_settings_password_input.xml | Adds the password input dialog layout used by the moved fragment. |
| infra/ui-base/src/main/java/com/simprints/infra/uibase/password/SettingsPasswordDialogFragment.kt | Moves/repackages the password dialog into infra:ui-base and updates binding usage. |
| infra/ui-base/build.gradle.kts | Enables ViewBinding via buildFeatures.viewBinding. |
| infra/resources/src/main/res/values/styles-widget.xml | Adds a Simprints switch widget style + updates filled text input start icon tint. |
| infra/resources/src/main/res/values/strings.xml | Adds module-selector UI strings (title, errors, labels). |
| infra/resources/src/main/res/values-om/strings.xml | Adds Oromo translations for module-selector strings (partial). |
| infra/resources/src/main/res/values-fr/strings.xml | Adds French translations for module-selector strings. |
| infra/resources/src/main/res/values-am/strings.xml | Adds Amharic translations for module-selector strings. |
| infra/resources/src/main/res/values-am-rET/strings.xml | Adds Amharic (ET) translations for module-selector strings. |
| feature/module-selector/src/main/res/layout/dialog_module_selector.xml | Adds bottom-sheet dialog layout for module selection (list, search, toggle, lock overlay). |
| feature/module-selector/src/main/res/layout/dialog_module_selector_item.xml | Adds list-row layout for selectable modules. |
| feature/module-selector/src/main/res/drawable/ic_overlay_lock.xml | Adds lock overlay icon for the module selector. |
| feature/module-selector/src/main/java/com/simprints/feature/moduleselector/ModuleSelectorDialogViewModel.kt | Implements selection/filtering/lock logic + saving and sync triggering. |
| feature/module-selector/src/main/java/com/simprints/feature/moduleselector/ModuleSelectorDialogFragment.kt | Implements the bottom-sheet UI wiring (binding, adapter, state/effects collection). |
| feature/module-selector/src/main/java/com/simprints/feature/moduleselector/ModuleSelectorDialogContract.kt | Defines dialog state/effects/actions models. |
| feature/module-selector/src/main/java/com/simprints/feature/moduleselector/adapter/ModuleSelectorViewHolder.kt | Binds module/no-results rows and click handling. |
| feature/module-selector/src/main/java/com/simprints/feature/moduleselector/adapter/ModuleSelectorItem.kt | Defines adapter item models (Module, NoResult). |
| feature/module-selector/src/main/java/com/simprints/feature/moduleselector/adapter/ModuleSelectorAdapter.kt | Adds RecyclerView adapter with AsyncListDiffer. |
| feature/module-selector/src/main/AndroidManifest.xml | Adds an (empty) manifest for the new feature module. |
| feature/module-selector/build.gradle.kts | Declares the new feature module and its infra dependencies. |
| feature/module-selector/.gitignore | Ignores the module’s build output. |
| feature/dashboard/src/test/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/tools/ModuleQueryFilterTest.kt | Removes legacy module-query filter unit tests. |
| feature/dashboard/src/test/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/ModuleSelectionViewModelTest.kt | Removes legacy module-selection ViewModel tests. |
| feature/dashboard/src/test/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/ModuleSelectionFragmentTest.kt | Removes legacy module-selection fragment test. |
| feature/dashboard/src/test/java/com/simprints/feature/dashboard/settings/password/SettingsPasswordDialogFragmentTest.kt | Removes the old password-dialog test from dashboard. |
| feature/dashboard/src/main/res/xml/module_selection_chip.xml | Removes legacy module-selection chip resource. |
| feature/dashboard/src/main/res/navigation/graph_dashboard.xml | Switches module selection destination to the new dialog in :feature:module-selector. |
| feature/dashboard/src/main/res/layout/item_module.xml | Removes legacy module item layout. |
| feature/dashboard/src/main/res/layout/fragment_sync_module_selection.xml | Removes legacy module-selection fragment layout. |
| feature/dashboard/src/main/res/drawable/ic_close_chip.xml | Removes legacy chip close icon. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/tools/ModuleQueryFilter.kt | Removes legacy query filtering logic. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/tools/ModuleChipHelper.kt | Removes legacy chip rendering helper. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/tools/ChipClickListener.kt | Removes legacy chip click listener interface. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/ModuleSelectionViewModel.kt | Removes legacy ViewModel implementation. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/ModuleSelectionQueryListener.kt | Removes legacy query listener. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/ModuleSelectionFragment.kt | Removes legacy module-selection fragment implementation. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/exceptions/TooManyModulesSelectedException.kt | Removes legacy exception type. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/exceptions/NoModuleSelectedException.kt | Removes legacy exception type. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/adapter/ModuleViewHolder.kt | Removes legacy adapter implementation. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/adapter/ModuleSelectionListener.kt | Removes legacy adapter listener. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/syncinfo/moduleselection/adapter/ModuleAdapter.kt | Removes legacy adapter. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/SettingsFragment.kt | Updates import to use the moved infra:ui-base password dialog. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/settings/about/AboutFragment.kt | Updates import to use the moved infra:ui-base password dialog. |
| feature/dashboard/src/main/java/com/simprints/feature/dashboard/logout/syncdecline/LogoutSyncDeclineFragment.kt | Updates import to use the moved infra:ui-base password dialog. |
| feature/dashboard/build.gradle.kts | Adds dependency on :feature:module-selector. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
luhmirin-s
force-pushed
the
feature/MS-1451-module-selection-rework
branch
from
August 17, 2026 12:38
bba87ea to
ec2e75d
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
JIRA ticket
Will be released in: 2027.1.0
TBD, for now just running the copilot review
Notable changes
ModuleSelectorMvi.ktcontains definitions of the UI state, action and side effects present on the screenModuleSelectorViewModel.kthandles the UI actions in vm.onAction() and updates the state or emits side-effects accordinglyModuleSelectorFragment.ktcollects vm.state shared flow and renders the layout, collects vm.effects for side effects and sends user actions from view listeners to VM via vm.onAction().Testing guidance
Additional work checklist