fix(reader): show KOReader progress-synced as a top-right hint (#4461) (#4463)

KOReader sync displayed the "Reading Progress Synced" notification as a
centered info toast that blocks the text for fast readers, while Readest's
own cloud sync uses an unobtrusive top-right hint.

Route the notification through the same 'hint' event (HintInfo, top-right,
~2s auto-dismiss) that useProgressSync uses, instead of the centered 'toast'.
This covers both KOSync paths that apply remote progress (the auto-apply
receive/silent flow and the conflict-resolved "use remote" flow); the
interactive conflict-resolution dialog is unchanged.

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Huang Xin
2026-06-05 00:03:19 +08:00
committed by GitHub
parent 93b3c4373a
commit d8fbf5fe08
@@ -152,10 +152,9 @@ export const useKOSync = (bookKey: string) => {
view.goToFraction(remoteFraction);
}
}
eventDispatcher.dispatch('toast', {
eventDispatcher.dispatch('hint', {
bookKey,
message: _('Reading Progress Synced'),
type: 'info',
timeout: 2000,
});
};