Repository navigation
Clarify preserved progress when merging duplicate books #76
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -359,20 +359,20 @@ function MergePicker({ session, book, books, onDone, onClose }) { | |
| const q = norm(query) | ||
| const shown = q ? others.filter((b) => [b.title, b.author, b.filename].some((v) => norm(v).includes(q))) : others | ||
| if (selected) { | ||
| const what = selected.stats ? 'progress, clippings and reading stats' : 'progress and clippings' | ||
| return ( | ||
| <ActionSheet title={`Merge "${selected.book.title || selected.book.filename || 'Untitled book'}" into this book?`} actionLabel="Merge" pendingLabel="Merging…" onClose={() => setSelected(null)} onConfirm={async () => { | ||
| <ActionSheet title={`Merge with "${selected.book.title || selected.book.filename || 'Untitled book'}"?`} actionLabel="Merge" pendingLabel="Merging…" onClose={() => setSelected(null)} onConfirm={async () => { | ||
| await api.merge(session, selected.book.document, book.document, selected.stats) | ||
| onDone() | ||
| }}> | ||
| Its {what} move here, and future syncs of it land here too. | ||
| <span className="block">The farthest-along reading position from either copy is kept. Clippings and service matches are combined.</span> | ||
| <span className="mt-2 block">{selected.stats ? 'Reading stats are combined too.' : 'Reading stats are not combined.'} Future syncs from either copy update this book.</span> | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Explain which stats remain visible when combining is disabled. With stats disabled, the selected copy’s per-book stats are stored but excluded from this book’s stats, including future uploads under that copy’s document ID. “Future syncs from either copy update this book” does not explain that exception. Clarify it before confirmation. (raw.githubusercontent.com)
|
||
| </ActionSheet> | ||
| ) | ||
| } | ||
| return ( | ||
| <Sheet title="Merge a duplicate into this book" onClose={onClose}> | ||
| <Sheet title="Merge duplicate books" onClose={onClose}> | ||
| <p className="mt-2 text-sm/6 text-stone-500"> | ||
| When two readers identify the same book differently, it shows up twice. Pick the copy to fold into this one. | ||
| Choose another copy of this book to merge. The farthest-along reading position is kept, whichever copy it comes from. Clippings and service matches are combined. | ||
| </p> | ||
| <label className="mt-3 flex items-center gap-2 text-sm text-stone-600"> | ||
| <input type="checkbox" checked={stats} onChange={(e) => setStats(e.target.checked)} className="size-4 accent-brand-500" /> | ||
|
|
||
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.
Script executed:
Repository: crosspoint-reader/crosspoint-sync
Length of output: 12314
Script executed:
Repository: crosspoint-reader/crosspoint-sync
Length of output: 4453
Script executed:
Repository: crosspoint-reader/crosspoint-sync
Length of output: 10124
Script executed:
Repository: crosspoint-reader/crosspoint-sync
Length of output: 8423
Disclose conflicts in both merge dialogs.
If both books have a clipping with the same ID or a match for the same service, the merge keeps this book’s record. The selected book’s note or match can be lost.
Suggested wording