-
-
Notifications
You must be signed in to change notification settings - Fork 22
Add to QuickNav slider for changing page #156
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds a page scrubber feature to the QuickNav component, allowing users to quickly preview and navigate between pages in a notebook. The implementation includes drag-based page preview with visual feedback and the ability to return to the original page.
- Added a horizontal page slider component with draggable thumb for page navigation
- Integrated page preview functionality that shows cached page bitmaps while scrubbing
- Updated bitmap loading logic to support both exact and relaxed matching for preview scenarios
Reviewed Changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| QuickNav.kt | Integrates the new page scrubber UI and connects it to DrawCanvas preview/commit flows |
| PageScrubber.kt | New component implementing the horizontal slider with draggable thumb and return button |
| persistBitmap.kt | Enhanced bitmap loading with requireExactMatch parameter and newest-file fallback logic |
| backgrounds.kt | Added drawCenteredLabelBox utility for displaying text labels on canvas |
| PageView.kt | Exposed loadBitmapFromStorage with additional parameters for preview functionality |
| DrawCanvas.kt | Added MutableSharedFlow signals for save/preview/commit page operations |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
app/src/main/java/com/ethran/notable/editor/drawing/backgrounds.kt
Outdated
Show resolved
Hide resolved
|
TODO:
|
…EditorControlTower`. Also moved logic regarding keeping current page to `EditorState`. --AI-- Key changes include: - Moving gesture action logic from `EditorGestureReceiver` to `EditorControlTower`. - Shifting undo/redo handling from `Toolbar` and gestures to `EditorControlTower`. - Relocating page navigation functions (`goToNextPage`, `goToPreviousPage`) from `EditorView` into `EditorState` and calling them from the control tower. - Removing direct `EditorState` dependencies from `EditorGestureReceiver` and `SelectedBitmap`, which now interact with the control tower.
…ickNav` composable to improve readability and separation of concerns.
There was a problem hiding this comment.
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 17 out of 17 changed files in this pull request and generated 12 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
app/src/main/java/com/ethran/notable/editor/state/EditorState.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/com/ethran/notable/editor/EditorControlTower.kt
Outdated
Show resolved
Hide resolved
|
Bug: scribble mode is not turned off in quick nav. |
|
Bug: back button does not work |
|
Bug: previous are created during changing page, resulting in incorrect image saved. |
There was a problem hiding this comment.
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 18 out of 19 changed files in this pull request and generated 5 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
app/src/main/java/com/ethran/notable/editor/state/EditorState.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/com/ethran/notable/editor/EditorControlTower.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/com/ethran/notable/editor/EditorControlTower.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/com/ethran/notable/editor/EditorControlTower.kt
Outdated
Show resolved
Hide resolved
Ethran
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok
No description provided.