Skip to content

[Reading Lists] New bottom sheet dialog to save unsave - #6771

Merged
dbrant merged 78 commits into
rl-collections-feature-branchfrom
rl-new-save-unsave-experience
Aug 13, 2026
Merged

[Reading Lists] New bottom sheet dialog to save unsave#6771
dbrant merged 78 commits into
rl-collections-feature-branchfrom
rl-new-save-unsave-experience

Conversation

@Williamrai

@Williamrai Williamrai commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

What does this do?

  • adds new SaveArticleSheetDialog to save and unsave articles to collections and default list
  • Adds autoHidingLazyColumnScrollbar Modifier
  • removes "Add/Move/Remove" from LongPressMenu

Phabricator:
https://phabricator.wikimedia.org/T430375

Williamrai and others added 30 commits July 8, 2026 16:05
…paring with old XML version. Will be removed once migration is complete.

- creates ReadingListsComposeFragment, creates a compose screen, wires searchActionMode and overflowMenu, adds TODO's
- Add a one-to-many Room relation between ReadingList and ReadingListPage.
- implements DAO functions returning Flow to reactively observe reading list data
- adds ReadingListsUiState an ui state for the screen and ReadingListRow for handling list row and page row UI
- implements in-memory filtering for complex queries that cannot be evaluated directly by ROOM
- update MessageCard compose UI to match XML MessageCard
- updates ReadingListsViewModel.kt to support new onboarding state
- restructure ReadingListsComposeScreen.kt to support onboarding state
- adds searchActive flow to detect search action mode in order to hide onboarding state
- adds multi selection mode
- adds overflow menu callback actions
- adds multiSelection callback actions
- updates UI to support multi selection mode and pull to refresh action
- code fixes
- adds Dropdown menu actions
- adds two queries to simplifying and efficiently retrieving reading list with pages
- adds helper function toReadingList to filter pages queued for deletion
- improves ReadingListItemActionsDialog newInstance function by passing what it actually uses instead of lists
- creates ContainingList data class to save id and title of the lists that contains the page. This is used for the added PageRow actions
- code fixes and UI updates
- adds offline toggle action in ReadingListPageRow
- adds logic to show snackbar message when total list reaches max limit
- bug fixes: deleting list from the ReadingList detail screen did not show undo snackbar when coming back to the main list screen
… saved. Introduces RecentPreviewSavedState which holds two values one for showing snackbar and the other for badge.

- updates ui and code
…out updates

- subscribes LoggedInEvent, LoggedOutEvent and LoggedOutInBackgroundEvent
… getNewRecommendedPagesFlow and

splits its own combine with related preferences
- ui fixes: scroll to first item when discover card appears
- updates the viewModel logic to support this separation
…cEvent is emitted when sync is completed to dismiss the refresh spinner
- code updates to support the new search behavior
Williamrai and others added 11 commits August 5, 2026 10:35
…perience

# Conflicts:
#	app/src/main/res/values-qq/strings.xml
#	app/src/main/res/values/strings.xml
… adds lifecycle aware flow collection of ArticleSavedOrDeletedEvent to update save button whenever user adds or removes the article

- adds codes to derive decision to save only when it's not saved
…oved and displays a snackbar message, except when the article is removed from its only saved list (the default list)
…r "Saved" for overflow menu callbacks and long press menu callbak and replace it with a single request
…perience

# Conflicts:
#	app/src/main/res/values-qq/strings.xml
- removes move and add from ReadingListItemActionsDialog
- adds string resources
- code fixes
@Williamrai
Williamrai changed the base branch from main to rl-collections-feature-branch August 11, 2026 15:42
- thumb height is now proportional to fraction of the lazy column content and uses the native scrollIndicatorState
…experience

# Conflicts:
#	app/src/main/res/values-qq/strings.xml
#	app/src/main/res/values/strings.xml
@Williamrai Williamrai added Ready for Review and removed WIP Work in progress labels Aug 12, 2026
@Williamrai
Williamrai requested a balanced review from Copilot August 12, 2026 14:10

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Introduces a unified bottom sheet for saving articles and managing collection membership across the app.

Changes:

  • Adds the Compose save/unsave sheet and supporting ViewModel.
  • Replaces legacy save, move, and remove flows across article surfaces.
  • Updates reading-list actions, resources, and scrollbar behavior.

Reviewed changes

Copilot reviewed 38 out of 38 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
app/src/main/res/values/strings.xml Adds sheet text and collection counts.
app/src/main/res/values/dimens.xml Adds sheet peek height.
app/src/main/res/values-qq/strings.xml Adds localization descriptions.
app/src/main/res/menu/menu_reading_list_page_toggle.xml Removes obsolete menu.
app/src/main/res/menu/menu_places_long_press.xml Removes legacy collection actions.
app/src/main/res/menu/menu_long_press.xml Removes legacy collection actions.
app/src/main/res/layout/view_reading_list_page_actions.xml Consolidates collection management action.
app/src/main/res/drawable/ic_add_circle_24dp.xml Adds collection-add icon.
app/src/main/java/org/wikipedia/search/SearchResultLongPressHandler.kt Routes search saves to the sheet.
app/src/main/java/org/wikipedia/search/SearchResultCallback.kt Simplifies the save callback.
app/src/main/java/org/wikipedia/search/SearchFragment.kt Opens the sheet from search.
app/src/main/java/org/wikipedia/readinglist/SaveArticleSheetViewModel.kt Implements save and collection operations.
app/src/main/java/org/wikipedia/readinglist/SaveArticleSheetDialog.kt Hosts the new bottom sheet.
app/src/main/java/org/wikipedia/readinglist/ReadingListsViewModel.kt Tracks default-list membership.
app/src/main/java/org/wikipedia/readinglist/ReadingListsFragment.kt Opens collection management.
app/src/main/java/org/wikipedia/readinglist/ReadingListItemActionsView.kt Consolidates item actions.
app/src/main/java/org/wikipedia/readinglist/ReadingListItemActionsDialog.kt Displays collection membership action.
app/src/main/java/org/wikipedia/readinglist/ReadingListFragment.kt Integrates the new sheet.
app/src/main/java/org/wikipedia/readinglist/LongPressMenu.kt Unifies long-press save behavior.
app/src/main/java/org/wikipedia/readinglist/compose/SaveArticleSheetContent.kt Defines the Compose sheet UI.
app/src/main/java/org/wikipedia/random/RandomActivity.kt Uses the sheet for random articles.
app/src/main/java/org/wikipedia/places/PlacesFragment.kt Uses the sheet from Places.
app/src/main/java/org/wikipedia/page/PageFragment.kt Uses the sheet from article actions.
app/src/main/java/org/wikipedia/page/PageContainerLongPressHandler.kt Uses the sheet for links.
app/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.kt Uses the sheet from previews.
app/src/main/java/org/wikipedia/main/MainFragment.kt Routes feed save requests.
app/src/main/java/org/wikipedia/games/onthisday/OnThisDayGameViewModel.kt Removes duplicated saved-page state.
app/src/main/java/org/wikipedia/games/onthisday/OnThisDayGameResultFragment.kt Uses the sheet in game results.
app/src/main/java/org/wikipedia/games/onthisday/OnThisDayGameArticleBottomSheet.kt Uses database-backed save state.
app/src/main/java/org/wikipedia/feed/view/ListItemView.kt Simplifies feed save callbacks.
app/src/main/java/org/wikipedia/feed/topread/TopReadFragment.kt Opens the sheet from top reads.
app/src/main/java/org/wikipedia/feed/onthisday/OnThisDayPagesViewHolder.kt Opens the sheet from events.
app/src/main/java/org/wikipedia/feed/news/NewsFragment.kt Opens the sheet from news.
app/src/main/java/org/wikipedia/feed/HomeFragment.kt Replaces direct feed save handling.
app/src/main/java/org/wikipedia/feed/ForYouCard.kt Updates saved menu labeling.
app/src/main/java/org/wikipedia/feed/didyouknow/DidYouKnowActivity.kt Opens the sheet from Did You Know.
app/src/main/java/org/wikipedia/compose/extensions/Modifier.kt Adds an auto-hiding scrollbar.
app/src/main/java/org/wikipedia/compose/components/menu/PageOverflowMenuViewModel.kt Unifies overflow save actions.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +113 to +118
} catch (exception: IOException) {
// A network error (or being offline) during the redirect resolution is not a big deal,
// and we can just proceed with the original title.
L.e(exception)
null
}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Kind of agree.

Comment thread app/src/main/java/org/wikipedia/readinglist/ReadingListFragment.kt Outdated
Comment thread app/src/main/java/org/wikipedia/readinglist/compose/SaveArticleSheetContent.kt Outdated
- code/ui fixes
- add code-review skill for testing (experiment)

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 39 out of 39 changed files in this pull request and generated 2 comments.

)

private fun saveArticle() {
viewModelScope.launch(exceptionHandler) {

@Williamrai Williamrai Aug 13, 2026

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

based on product leaving this as is, and see if we get user reports.


val pageTitle = savedStateHandle.get<PageTitle>(Constants.ARG_TITLE)!!

private val savedPageTitle = MutableStateFlow(pageTitle)

@Williamrai Williamrai Aug 13, 2026

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

based on product leaving this as is, and see if we get user reports.

@dbrant
dbrant merged commit 57c2353 into rl-collections-feature-branch Aug 13, 2026
1 check passed
@dbrant
dbrant deleted the rl-new-save-unsave-experience branch August 13, 2026 19:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

3 participants