Skip to content

feat: improve the review ahead dialog - #21709

Open
david-allison wants to merge 6 commits into
ankidroid:mainfrom
david-allison:Improve-the-Review-ahead-dialog
Open

feat: improve the review ahead dialog#21709
david-allison wants to merge 6 commits into
ankidroid:mainfrom
david-allison:Improve-the-Review-ahead-dialog

Conversation

@david-allison

@david-allison david-allison commented Sep 3, 2026

Copy link
Copy Markdown
Member

Note

Assisted-by: Claude Fable 5.1
This PR is a fixup of:

Purpose / Description

  • improve wording and title
  • handle leading zeroes
  • validate on a '0' date
  • add a day/days suffix
  • disables 'create' if invalid

Fixes

Approach

Fixup the linked PR, then add my own changes and improvements.

I initially refactored the debounce code into a class, but after a manual test, 300ms was far too much latency and the DB calls were effectively instant.

How Has This Been Tested?

SDK 37 Google Pixel 9 Pro

image

Checklist

  • You have a descriptive commit message with a short title (first line, max 50 chars).
  • You have commented your code, particularly in hard-to-understand areas
  • You have performed a self-review of your own code
  • UI changes: include screenshots of all affected screens (in particular showing any new or changed strings)
  • UI Changes: You have tested your change using the Google Accessibility Scanner

@david-allison david-allison added the Needs Second Approval Has one approval, one more approval to merge label Sep 3, 2026
@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Important

Maintainers: This PR contains Strings changes

  1. Sync Translations before merging this PR and wait for the action to complete
  2. Review and merge the auto-generated PR in order to sync all user-submitted translations
  3. Sync Translations again and merge the PR so the huge automated string changes caused by merging this PR are by themselves and easy to review

@david-allison

Copy link
Copy Markdown
Member Author

@ZornHadNoChoice if you have feedback, it'd be very well-received!

@ZornHadNoChoice

Copy link
Copy Markdown
Collaborator

The title "Review ahead" is bold instead of being big like other dialogs.

@david-allison david-allison added the Needs Author Reply Waiting for a reply from the original author label Sep 4, 2026
@david-allison

Copy link
Copy Markdown
Member Author

Holdover from the original change, I thought it was intentional.

Thanks!!

Galal-20 and others added 6 commits September 4, 2026 13:29
Title: "Review ahead"
Description: "Review cards due in the next:"
Positive button: "Create"

Part of 20600

Co-authored-by: David Allison <62114487+david-allison@users.noreply.github.com>
Assisted-by: Claude Fable 5.1 [rebase and commit split]
Part of 20600

Co-authored-by: David Allison <62114487+david-allison@users.noreply.github.com>
Assisted-by: Claude Fable 5.1 [rebase and commit split]
Unsigned, at most 5 digits and no leading zeros, reusing
NonLeadingZeroInputFilter from 20520.

Part of 20600

Co-authored-by: David Allison <62114487+david-allison@users.noreply.github.com>
Assisted-by: Claude Fable 5.1 [rebase and commit split]
Search the deck as the user types and show an inline error with the
button disabled, instead of an error dialog after submission.

Part of 20600

Co-authored-by: David Allison <62114487+david-allison@users.noreply.github.com>
Assisted-by: Claude Fable 5.1
Matches the number dialogs from 20520: below the minimum shows
"Minimum value is 1", while an empty field only disables 'Create'.

Part of 20600

Assisted-by: Claude Fable 5.1
The stored default may match no cards; without this, tapping 'Create'
immediately still produced the error dialog.

Fixes 20600

Assisted-by: Claude Fable 5.1
@david-allison
david-allison force-pushed the Improve-the-Review-ahead-dialog branch from 6ca4b73 to 8ac6e61 Compare September 4, 2026 12:31
@david-allison

Copy link
Copy Markdown
Member Author
image

@david-allison david-allison removed the Needs Author Reply Waiting for a reply from the original author label Sep 4, 2026

@lukstbit lukstbit left a comment

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.

LGTM, with the note below on wording.

if (contextMenuOption == STUDY_TAGS) {
TR.sentenceCase.chooseTags
} else if (contextMenuOption == STUDY_AHEAD) {
getString(R.string.dialog_positive_create)

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.

Using the previous "Ok" label reads better IMO:

Review cards due in the next 5 days? => Ok // reads more natural
Review cards due in the next 5 days? => Create // I understand we create a custom study session but feels out of place

Even if we keep the "Create" label we become inconsistent: Review ahead and Review forgotten cards have issues to be changed to "Create" while the options Preview new cards, Increase today's new card limit and Increase today's review card limit will use "Ok"(and for all 3 options it's the same discussion as above).

@ZornHadNoChoice

@lukstbit

lukstbit commented Sep 7, 2026

Copy link
Copy Markdown
Member

I rushed a bit, something that is not that ok: this dialog uses a title while all other options do not use a title.

@lukstbit lukstbit added Needs Author Reply Waiting for a reply from the original author Pending Merge Things with approval that are waiting future merge (e.g. targets a future release, CI wait, etc) and removed Needs Second Approval Has one approval, one more approval to merge labels Sep 7, 2026
@david-allison

Copy link
Copy Markdown
Member Author

@lukstbit Zorn specifically asked for a title, would you want me to split out this change so we can discuss adding titles to each of the dialogs?

@lukstbit

lukstbit commented Sep 7, 2026

Copy link
Copy Markdown
Member

Zorn specifically asked for a title, would you want me to split out this change so we can discuss adding titles to each of the dialogs?

Let's merge this as it is now and then create an issue to discuss about the consistency of all the dialogs under custom study, title/positive button label.

@david-allison david-allison added the Needs reviewer reply Waiting for a reply from another reviewer label Sep 7, 2026
@david-allison

david-allison commented Sep 7, 2026

Copy link
Copy Markdown
Member Author

I could quickly knock out the title change, but we're too close to a release window, so we'd be inconsistent. I'll split it out for later

Will wait for @ZornHadNoChoice on the other thoughts. This isn't a dialog I use

@ZornHadNoChoice

Copy link
Copy Markdown
Collaborator

In my original issue, I suggested removing the Preview new cards, Increase today's new card limit and Increase today's review card limit dialogs completely. That's why I didn't make sub-issues for them.

The other 3 dialogs have issues where I suggested having a title and renaming the button to "Create".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Needs Author Reply Waiting for a reply from the original author Needs reviewer reply Waiting for a reply from another reviewer Pending Merge Things with approval that are waiting future merge (e.g. targets a future release, CI wait, etc) Strings

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Improve the Review ahead dialog

4 participants