Added
ng2-pdfjs-viewer/signals: a new entry point that projects viewer state — current
page, zoom, total pages, search matches, read-aloud progress, annotation-editor
state, sidebar, metadata, form data, and the view-mode strings — as read-only
Angular signals. CallpdfViewerSignals(viewer, { injector })and read
signals.page(),signals.totalPages(),signals.loaded()in a template, or
buildcomputed/effecton top. Aimed at zoneless / OnPush apps. Requires
Angular 16+; the base package's>=10peer range is unchanged.- AI assistant streaming:
PdfAiAssistant.ask()andcomplete()take an optional
onTokencallback and stream the answer token-by-token over Server-Sent Events,
falling back to a single response when the endpoint doesn't stream. The built-in
chat panel renders the answer as it arrives.
Fixed
onPagesInitnow fires once the document's pages initialize - it carries the
page count and was declared but never emitted. This is what makes the new
signals entry point'sloaded()andtotalPages()populate.