Properties plugin

The `properties` plugin provides a button to list the properties of the PDF document.

Install

npm install '@react-pdf-viewer/properties';
The `properties` plugin is included in the toolbar and default-layout plugins

Usage

1. Import the plugin and styles
import { propertiesPlugin } from '@react-pdf-viewer/properties';
// Import styles
import '@react-pdf-viewer/properties/lib/styles/index.css';
2. Create the plugin instance
const propertiesPluginInstance = propertiesPlugin();
The plugin instance `propertiesPluginInstance` provides the following properties:
PropertyTypeDescriptionFrom
`ShowProperties``ReactElement`Customizable button to list the properties2.0.0
`ShowPropertiesButton``ReactElement`The default button to list the properties2.0.0
`ShowPropertiesMenuItem``ReactElement`The default menu item to list the properties2.0.0
3. Register the plugin
Register the `properties` plugin instance:
<Viewer plugins={[propertiesPluginInstance]} />

See also

Changelog

v2.0.0
  • First release