You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/react-pdf/README.md
+2-2
Original file line number
Diff line number
Diff line change
@@ -470,7 +470,7 @@ Loads a document passed using `file` prop.
470
470
| onSourceError | Function called in case of an error while retrieving document source from `file` prop. | n/a |`(error) => alert('Error while retrieving document source! ' + error.message)`|
471
471
| onSourceSuccess | Function called when document source is successfully retrieved from `file` prop. | n/a |`() => alert('Document source retrieved!')`|
472
472
| options | An object in which additional parameters to be passed to PDF.js can be defined. Most notably:<ul><li>`cMapUrl`;</li><li>`httpHeaders` - custom request headers, e.g. for authorization);</li><li>`withCredentials` - a boolean to indicate whether or not to include cookies in the request (defaults to `false`)</li></ul>For a full list of possible parameters, check [PDF.js documentation on DocumentInitParameters](https://mozilla.github.io/pdf.js/api/draft/module-pdfjsLib.html#~DocumentInitParameters). **Note**: Make sure to define options object outside of your React component, and use `useMemo` if you can't. | n/a |`{ cMapUrl: '/cmaps/' }`|
473
-
| renderMode | Rendering mode of the document. Can be `"canvas"`, `"custom"`, `"none"` or `"svg"`. If set to `"custom"`, `customRenderer` must also be provided.<br />**Warning**: SVG render mode is no longer maintained and may be removed in the future. |`"canvas"`|`"svg"`|
473
+
| renderMode | Rendering mode of the document. Can be `"canvas"`, `"custom"`, `"none"` or `"svg"`. If set to `"custom"`, `customRenderer` must also be provided.<br />**Warning**: SVG render mode is deprecated and will be removed in the future.|`"canvas"`|`"svg"`|
474
474
| rotate | Rotation of the document in degrees. If provided, will change rotation globally, even for the pages which were given `rotate` prop of their own. `90` = rotated to the right, `180` = upside down, `270` = rotated to the left. | n/a |`90`|
475
475
476
476
### Page
@@ -512,7 +512,7 @@ Displays a page. Should be placed inside `<Document />`. Alternatively, it can h
512
512
| pdf | pdf object obtained from `<Document />`'s `onLoadSuccess` callback function. | (automatically obtained from parent `<Document />`) |`pdf`|
513
513
| renderAnnotationLayer | Whether annotations (e.g. links) should be rendered. |`true`|`false`|
514
514
| renderForms | Whether forms should be rendered. `renderAnnotationLayer` prop must be set to `true`. |`false`|`true`|
515
-
| renderMode | Rendering mode of the document. Can be `"canvas"`, `"custom"`, `"none"` or `"svg"`. If set to `"custom"`, `customRenderer` must also be provided.<br />**Warning**: SVG render mode is no longer maintained and may be removed in the future. |`"canvas"`|`"svg"`|
515
+
| renderMode | Rendering mode of the document. Can be `"canvas"`, `"custom"`, `"none"` or `"svg"`. If set to `"custom"`, `customRenderer` must also be provided.<br />**Warning**: SVG render mode is deprecated and will be removed in the future.|`"canvas"`|`"svg"`|
516
516
| renderTextLayer | Whether a text layer should be rendered. |`true`|`false`|
517
517
| rotate | Rotation of the page in degrees. `90` = rotated to the right, `180` = upside down, `270` = rotated to the left. | Page's default setting, usually `0`|`90`|
0 commit comments