SoftwareDriven.PdfJs.Blazor 1.0.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package SoftwareDriven.PdfJs.Blazor --version 1.0.0                
NuGet\Install-Package SoftwareDriven.PdfJs.Blazor -Version 1.0.0                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="SoftwareDriven.PdfJs.Blazor" Version="1.0.0" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add SoftwareDriven.PdfJs.Blazor --version 1.0.0                
#r "nuget: SoftwareDriven.PdfJs.Blazor, 1.0.0"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install SoftwareDriven.PdfJs.Blazor as a Cake Addin
#addin nuget:?package=SoftwareDriven.PdfJs.Blazor&version=1.0.0

// Install SoftwareDriven.PdfJs.Blazor as a Cake Tool
#tool nuget:?package=SoftwareDriven.PdfJs.Blazor&version=1.0.0                

SoftwareDriven.PdfJs.Blazor is a wrapper for Mozilla PDF.js (refer to https://mozilla.github.io/pdf.js/) including a viewer with page navigation, rotation, zoom and find. The viewer also supports print on all browsers and devices. The JS code is an adopted mixture of the PDF.js examples enriched with JS to Blazor interop.

The viewer style by default is:

overflow: auto; position: absolute; width: 100%; height: 100%

Therefore, you may have to place the viewer in a suitable container. You can overwrite the "Style" property but be careful not to break the placement of the underlying print container.

Printing support needs to load the document for a second time and can be disabled using the "SupportPrint" property to reduce traffic overhead.

On first load and when the page changed, an event is fired ("DocumentChanged");

Create a reference to the viewer to access the following functions:

  • FirstPage()
  • LastPage()
  • PreviousPage()
  • NextPage()
  • RotateLeft()
  • RotateRight()
  • ZoomToScale(double scale)
  • ZoomToPageWidth()
  • Print()
  • Find(string query)
Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.3.0 242 8/8/2024
1.2.0 121 8/8/2024
1.1.0 93 8/7/2024
1.0.0 81 8/4/2024