@react-pdf-kit/viewer 2.0.1-rc.3 → 2.1.0-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +49 -84
- package/dist/components/RPController.js +73 -74
- package/dist/components/RPPages.js +544 -545
- package/dist/components/layout/toolbar/SearchTool.js +96 -93
- package/dist/contexts/InitialStateContext.js +6 -8
- package/dist/types/utils/hooks/useWatermark.d.ts +1 -1
- package/dist/types/utils/types.d.ts +1 -1
- package/dist/utils/highlight.js +36 -36
- package/dist/utils/hooks/useHighlight.js +40 -78
- package/dist/utils/hooks/useLicense.js +1 -1
- package/dist/utils/hooks/usePrint.js +93 -82
- package/dist/utils/hooks/useWatermark.js +39 -57
- package/dist/utils/injectPrintCSS.js +2 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<div align="center">
|
|
2
|
-
<a href="https://www.react-pdf
|
|
2
|
+
<a href="https://www.react-pdf.dev/" target="_blank">
|
|
3
3
|
<picture>
|
|
4
4
|
<source srcset="https://raw.githubusercontent.com/pdf-viewer-react/react-pdf/2308e7d88cde64bf343f1509150ebf6c91a15664/assets/img/react-pdf_cover.webp" width="100%">
|
|
5
5
|
<img alt="React PDF" src="https://raw.githubusercontent.com/pdf-viewer-react/react-pdf/2308e7d88cde64bf343f1509150ebf6c91a15664/assets/img/react-pdf_cover.webp" width="100%">
|
|
@@ -9,28 +9,28 @@
|
|
|
9
9
|
|
|
10
10
|
<br/>
|
|
11
11
|
<div align="center">
|
|
12
|
-
Works seamlessly on your React
|
|
12
|
+
Works seamlessly on your React.js websites. Fast, Customizable and Web Responsive PDF viewer. Save you weeks of development time.
|
|
13
13
|
</div>
|
|
14
14
|
<br/>
|
|
15
15
|
|
|
16
16
|
<div align="center">
|
|
17
17
|
|
|
18
|
-
[React PDF
|
|
18
|
+
[React PDF Home][reactpdf] - [License](#page_facing_up-license) - [Documentation][reactpdf-docs]
|
|
19
19
|
|
|
20
|
-
[][npm]
|
|
21
21
|
[][twitter]
|
|
22
22
|
|
|
23
23
|
</div>
|
|
24
24
|
|
|
25
|
-
# :star: Why React PDF
|
|
25
|
+
# :star: Why React PDF
|
|
26
26
|
|
|
27
|
-
- **Save Weeks of Development Time**: React PDF
|
|
27
|
+
- **Save Weeks of Development Time**: React PDF simplifies PDF integration with ready-to-use tools, minimizing the need for custom development and saving you valuable time.
|
|
28
28
|
- **Tailored for React.js**: React PDF is native to React.js, ensuring smooth integration into your projects.
|
|
29
29
|
- **Customizability at Its Core**: Built with flexibility in mind, allowing you to match your application’s unique style and functionality.
|
|
30
30
|
- **High-Performance & Rapid Rendering**: Optimized for rendering large PDFs efficiently, React PDF delivers lightning-fast load times with features like virtual scrolling.
|
|
31
|
-
- **Accessibility**: Designed with inclusivity in mind, React PDF
|
|
32
|
-
- **Modern Browser Compatibility**:
|
|
33
|
-
- **Active Development & Support**: With regular updates and a responsive support team, React PDF
|
|
31
|
+
- **Accessibility**: Designed with inclusivity in mind, React PDF supports ARIA attributes, catering to diverse user bases.
|
|
32
|
+
- **Modern Browser Compatibility**: Works seamlessly across modern browsers, eliminating compatibility headaches.
|
|
33
|
+
- **Active Development & Support**: With regular updates and a responsive support team, React PDF evolves to meet developer needs.
|
|
34
34
|
|
|
35
35
|
# 📜 Background
|
|
36
36
|
|
|
@@ -47,58 +47,35 @@ As developers ourselves, we faced many issues such as browser incompatibility an
|
|
|
47
47
|
- 📂 **Document Management Tools**, including features like downloading and printing.
|
|
48
48
|
- 👁️ **Accessibility Support** to built-in support for ARIA attributes and tooltips, catering to diverse user bases.
|
|
49
49
|
|
|
50
|
-
For the full feature set, visit [React PDF
|
|
50
|
+
For the full feature set, visit [React PDF Features](https://www.react-pdf.dev/features?utm_source=github).
|
|
51
51
|
|
|
52
52
|
# :zap: Quick Start Guide
|
|
53
53
|
|
|
54
|
-
Here’s how to get started with React PDF
|
|
54
|
+
Here’s how to get started with React PDF in your React.js project:
|
|
55
55
|
|
|
56
|
-
## 1. Check
|
|
56
|
+
## 1. Check Prerequisites
|
|
57
57
|
|
|
58
|
-
Here are the basic system requirements to run the React PDF
|
|
58
|
+
Here are the basic system requirements to run the React PDF component:
|
|
59
59
|
|
|
60
60
|
- React version: >= 18.0
|
|
61
|
-
- React version: >= 19.0
|
|
62
61
|
|
|
63
|
-
If you are working with a React framework such as Next
|
|
62
|
+
If you are working with a React framework such as Next and Gatsby, React PDF can run smoothly as long as you are using React 18 and above.
|
|
64
63
|
|
|
65
|
-
React PDF also works well with other React.js UI libraries such as MUI, Ant Design and Chakra UI.
|
|
64
|
+
React PDF viewer also works well with other React.js UI libraries such as MUI, Ant Design and Chakra UI.
|
|
66
65
|
|
|
67
|
-
Although React PDF
|
|
66
|
+
Although React PDF can run on most JavaScript module bundlers, it is more vigorously tested on Vite and Webpack.
|
|
68
67
|
|
|
69
68
|
_Remark: <br/>- If using TypeScript, it requires >= TypeScript 4.6._
|
|
70
69
|
|
|
71
70
|
### Browser support
|
|
72
71
|
|
|
73
|
-
Starting from [`@react-pdf-kit/viewer@^2.0.0`](https://www.npmjs.com/package/@react-pdf-kit/viewer), we officially support PDF.js 5 and default to PDF.js `5.4.530`.
|
|
74
|
-
|
|
75
|
-
As newer PDF.js versions rely on more modern browser APIs, minimum supported browser versions have changed. Please review the compatibility details below before choosing a PDF.js version.
|
|
76
|
-
|
|
77
|
-
#### Default (PDF.js 5.4.530)
|
|
78
|
-
|
|
79
|
-
React PDF Kit v2.0.0 defaults to PDF.js `5.4.530`.
|
|
80
|
-
|
|
81
72
|
| Chrome | Firefox | Edge | Safari | Safari iOS | Chrome Android |
|
|
82
73
|
| ------ | ------- | ---- | ------ | ---------- | -------------- |
|
|
83
|
-
|
|
|
84
|
-
|
|
85
|
-
<Aside>
|
|
86
|
-
It's currently not recommended to use a PDF.js worker version beyond `5.4.530` because it will support fewer browser versions.
|
|
87
|
-
</Aside>
|
|
88
|
-
|
|
89
|
-
#### Using PDF.js 4.10.38
|
|
90
|
-
|
|
91
|
-
If you need broader browser compatibility, you can continue using PDF.js `4.10.38`, which supports:
|
|
92
|
-
|
|
93
|
-
| Chrome | Firefox | Edge | Safari | Safari iOS | Chrome Android |
|
|
94
|
-
| ------ | ------- | ---- | ------ | ---------- | -------------- |
|
|
95
|
-
| 119+ | 115+ | 115+ | 17.4+ | 17.4+ | 126+ |
|
|
96
|
-
|
|
97
|
-
To change the version of PDF.js used, refer to [Dependency Override](https://docs.react-pdf-kit.dev/usage-guide/overriding-dependency?utm_source=github&utm_medium=referral) guide.
|
|
74
|
+
| 115+ | 115+ | 115+ | 16.5+ | 16.5+ | 126+ |
|
|
98
75
|
|
|
99
76
|
## 2. Install the Package
|
|
100
77
|
|
|
101
|
-
There are a few ways you can install React PDF
|
|
78
|
+
There are a few ways you can install React PDF, namely `bun`, `npm`, `pnpm` or `yarn`.
|
|
102
79
|
|
|
103
80
|
### Using bun:
|
|
104
81
|
|
|
@@ -133,42 +110,50 @@ yarn add @react-pdf-kit/viewer
|
|
|
133
110
|
pnpm add @react-pdf-kit/viewer
|
|
134
111
|
```
|
|
135
112
|
|
|
136
|
-
For more information on how to use different package managers, please visit our [installation guide](https://docs.react-pdf
|
|
113
|
+
For more information on how to use different package managers, please visit our [installation guide](https://docs.react-pdf.dev/introduction/getting-started.html#installation?utm_source=github).
|
|
137
114
|
|
|
138
115
|
## 3. Import and Use the Component
|
|
139
116
|
|
|
140
117
|
The following structure demonstrates how to build a React PDF viewer by importing and assembling components. This modular approach gives you the flexibility to customize the viewer as needed.
|
|
141
118
|
|
|
142
119
|
```tsx
|
|
143
|
-
<RPConfig>
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
120
|
+
<RPConfig>
|
|
121
|
+
{' '}
|
|
122
|
+
{/* Configuration license and pdfjs-dist worker */}
|
|
123
|
+
<RPProvider>
|
|
124
|
+
{' '}
|
|
125
|
+
{/* Viewer context provider */}
|
|
126
|
+
<RPTheme>
|
|
127
|
+
{' '}
|
|
128
|
+
{/* Theme customization (optional) */}
|
|
129
|
+
<RPDefaultLayout>
|
|
130
|
+
{' '}
|
|
131
|
+
{/* Default layout container */}
|
|
132
|
+
<RPPages /> {/* PDF pages renderer */}
|
|
133
|
+
</RPDefaultLayout>
|
|
134
|
+
</RPTheme>
|
|
135
|
+
</RPProvider>
|
|
151
136
|
</RPConfig>
|
|
152
137
|
```
|
|
153
138
|
|
|
154
|
-
_Remark: For more information on each component, please refer to [Component](https://docs.react-pdf
|
|
139
|
+
_Remark: For more information on each component, please refer to [Component](https://docs.react-pdf.dev/components/overview?utm_source=github)._
|
|
155
140
|
|
|
156
141
|
### Basic Usage
|
|
157
142
|
|
|
158
|
-
The most basic usage of React PDF viewer needs four components, namely: `RPConfig`, `RPProvider`, `
|
|
143
|
+
The most basic usage of React PDF viewer needs four components, namely: `RPConfig`, `RPProvider`, `RPDefaultLayout`, and `RPPages`.
|
|
159
144
|
|
|
160
145
|
Here's how to implement a basic PDF viewer in a React application:
|
|
161
146
|
|
|
162
147
|
```jsx
|
|
163
|
-
import { RPProvider,
|
|
148
|
+
import { RPProvider, RPDefaultLayout, RPPages, RPConfig } from '@react-pdf-kit/viewer'
|
|
164
149
|
|
|
165
150
|
const App = () => {
|
|
166
151
|
return (
|
|
167
152
|
<RPConfig>
|
|
168
153
|
<RPProvider src="https://cdn.codewithmosh.com/image/upload/v1721763853/guides/web-roadmap.pdf">
|
|
169
|
-
<
|
|
154
|
+
<RPDefaultLayout style={{ height: '660px' }}>
|
|
170
155
|
<RPPages />
|
|
171
|
-
</
|
|
156
|
+
</RPDefaultLayout>
|
|
172
157
|
</RPProvider>
|
|
173
158
|
</RPConfig>
|
|
174
159
|
)
|
|
@@ -176,13 +161,13 @@ const App = () => {
|
|
|
176
161
|
export default App
|
|
177
162
|
```
|
|
178
163
|
|
|
179
|
-
The PDF viewer will automatically adjust to fit its container's dimensions. You can control the size by setting the `style` prop on `
|
|
164
|
+
The PDF viewer will automatically adjust to fit its container's dimensions. You can control the size by setting the `style` prop on `RPDefaultLayout`. For more information on using React PDF, visit our [basic usage guide](https://docs.react-pdf.dev/introduction/basic-usage?utm_source=github)
|
|
180
165
|
|
|
181
166
|
You may also check out our [Starter Toolkit](#pushpin-starter-toolkit) for examples to get you started.
|
|
182
167
|
|
|
183
168
|
### 4. Customize with Hooks and Props
|
|
184
169
|
|
|
185
|
-
To enhance React PDF
|
|
170
|
+
To enhance React PDF further, we offer built-in hooks and props that let you fine-tune functionality, adjust appearance, and integrate custom behaviors into your application.
|
|
186
171
|
|
|
187
172
|
For detailed usage, refer to our [Documentation][reactpdf-docs].
|
|
188
173
|
|
|
@@ -191,31 +176,11 @@ For detailed usage, refer to our [Documentation][reactpdf-docs].
|
|
|
191
176
|
Here are some sample projects to get started on React PDF quickly:
|
|
192
177
|
|
|
193
178
|
1. [React (webpack) - JavaScript](https://github.com/react-pdf-kit/starter-rp-react-js-webpack)
|
|
194
|
-
2. [React (webpack) - TypeScript](https://github.com/
|
|
179
|
+
2. [React (webpack) - TypeScript](https://github.com/reactpdf/pdf-viewer-react/starter-rp-react-ts-webpack)
|
|
195
180
|
3. [React (vite) - JavaScript](https://github.com/react-pdf-kit/starter-rp-react-js-vite)
|
|
196
181
|
4. [React (vite) - TypeScript](https://github.com/react-pdf-kit/starter-rp-react-ts-vite)
|
|
197
|
-
5. [
|
|
198
|
-
6. [Next
|
|
199
|
-
7. [Next.js - TypeScript (App Router)](https://github.com/react-pdf-kit/starter-rp-nextjs-app-router-ts)
|
|
200
|
-
8. [Next.js - JavaScript (Pages Router)](https://github.com/react-pdf-kit/starter-rp-nextjs-pages-router-js)
|
|
201
|
-
9. [Next.js - TypeScript (Pages Router)](https://github.com/react-pdf-kit/starter-rp-nextjs-pages-router-ts)
|
|
202
|
-
10. [Next.js - TypeScript - Turborepo](https://github.com/react-pdf-kit/starter-rp-next-ts-turborepo)
|
|
203
|
-
11. [Remix - JavaScript](https://github.com/react-pdf-kit/starter-rp-remix-js)
|
|
204
|
-
12. [Remix - TypeScript](https://github.com/react-pdf-kit/starter-rp-remix-ts)
|
|
205
|
-
13. [Gatsby - JavaScript](https://github.com/react-pdf-kit/starter-rp-gatsby-js)
|
|
206
|
-
14. [Gatsby - TypeScript](https://github.com/react-pdf-kit/starter-rp-gatsby-ts)
|
|
207
|
-
15. [Docusaurus - JavaScript](https://github.com/react-pdf-kit/starter-rp-docusaurus-js)
|
|
208
|
-
16. [Docusaurus - TypeScript](https://github.com/react-pdf-kit/starter-rp-docusaurus-ts)
|
|
209
|
-
17. [Electron - JavaScript](https://github.com/react-pdf-kit/starter-rp-electron-js-vite)
|
|
210
|
-
18. [Electron - TypeScript](https://github.com/react-pdf-kit/starter-rp-electron-ts-vite)
|
|
211
|
-
19. [React Router - JavaScript](https://github.com/react-pdf-kit/starter-rp-react-router-js)
|
|
212
|
-
20. [React Router - TypeScript](https://github.com/react-pdf-kit/starter-rp-react-router-ts)
|
|
213
|
-
21. [TanStack - JavaScript](https://github.com/react-pdf-kit/starter-rp-tanstack-router-js)
|
|
214
|
-
22. [TanStack - TypeScript](https://github.com/react-pdf-kit/starter-rp-tanstack-router-ts)
|
|
215
|
-
|
|
216
|
-
# 📝 Changelog
|
|
217
|
-
|
|
218
|
-
Check out our latest release [v2.0.0 (20 February 2026)](https://docs.react-pdf-kit.dev/introduction/changelog/#v200-20-february-2026?utm_source=github&utm_medium=referral)
|
|
182
|
+
5. [Next - JavaScript](https://github.com/react-pdf-kit/starter-rp-next-js)
|
|
183
|
+
6. [Next - TypeScript](https://github.com/react-pdf-kit/starter-rp-next-ts)
|
|
219
184
|
|
|
220
185
|
# :raising_hand: Need Help?
|
|
221
186
|
|
|
@@ -223,9 +188,9 @@ We are more than happy to help you. If you have any questions, run into any erro
|
|
|
223
188
|
|
|
224
189
|
# :page_facing_up: License
|
|
225
190
|
|
|
226
|
-
React PDF
|
|
191
|
+
React PDF is distributed under our proprietary license. Please refer to our [License page](https://www.react-pdf.dev/license-agreement?utm_source=github) file for more details.
|
|
227
192
|
|
|
228
|
-
If you would like to use React PDF commercially, please purchase a license from [our website][reactpdf] or reach out to us directly at [
|
|
193
|
+
If you would like to use React PDF commercially, please purchase a license from [our website][reactpdf] or reach out to us directly at [david@react-pdf.dev](mailto:david@react-pdf.dev).
|
|
229
194
|
|
|
230
195
|
# Acknowledgement
|
|
231
196
|
|
|
@@ -233,7 +198,7 @@ If you would like to use React PDF commercially, please purchase a license from
|
|
|
233
198
|
- [Img Shields](https://shields.io)
|
|
234
199
|
- [React.js](https://reactjs.org/)
|
|
235
200
|
|
|
236
|
-
[reactpdf]: https://www.react-pdf
|
|
237
|
-
[reactpdf-docs]: https://docs.react-pdf
|
|
201
|
+
[reactpdf]: https://www.react-pdf.dev
|
|
202
|
+
[reactpdf-docs]: https://docs.react-pdf.dev
|
|
238
203
|
[npm]: https://www.npmjs.com/package/@react-pdf-kit/viewer
|
|
239
204
|
[twitter]: https://www.x.com/ReactPDF
|
|
@@ -1,34 +1,34 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { useState as o
|
|
3
|
-
import { P as
|
|
4
|
-
import { DarkModeProvider as
|
|
5
|
-
import { ViewMode as
|
|
6
|
-
import { RotateProvider as
|
|
7
|
-
import { LayerProvider as
|
|
8
|
-
import { ZoomProvider as
|
|
9
|
-
import { ViewModeProvider as
|
|
10
|
-
import { ScrollModeProvider as
|
|
11
|
-
import { VirtualScrollProvider as
|
|
12
|
-
import { VirtualGridProvider as
|
|
13
|
-
import { SelectionModeProvider as
|
|
14
|
-
import { InitialStateProvider as
|
|
15
|
-
import { FullScreenProvider as
|
|
16
|
-
import { FileInputProvider as
|
|
17
|
-
import { PrintProvider as
|
|
18
|
-
import { DropFileZoneProvider as
|
|
19
|
-
import { ThumbnailProvider as
|
|
20
|
-
import { SearchProvider as
|
|
21
|
-
import { LayoutContainerContext as
|
|
22
|
-
import { DimensionPagesProvider as
|
|
23
|
-
import { LocalizationProvider as
|
|
24
|
-
import { HighlightProvider as
|
|
25
|
-
import { useWatermark as
|
|
26
|
-
import { DownloadProvider as
|
|
27
|
-
import { SmoothScrollProvider as
|
|
28
|
-
import { ElementPageProvider as
|
|
29
|
-
import { PagesRotateProvider as
|
|
30
|
-
import { RenderQueueProvider as
|
|
31
|
-
import { GlobalCurrentPageProvider as
|
|
2
|
+
import { useState as o } from "react";
|
|
3
|
+
import { P as w } from "../PaginationContext-9217cab4.js";
|
|
4
|
+
import { DarkModeProvider as D } from "../contexts/DarkModeContext.js";
|
|
5
|
+
import { ViewMode as E, ScrollMode as F, SelectionMode as G } from "../utils/types.js";
|
|
6
|
+
import { RotateProvider as I } from "../contexts/RotationContext.js";
|
|
7
|
+
import { LayerProvider as T } from "../contexts/LayerContext.js";
|
|
8
|
+
import { ZoomProvider as b } from "../contexts/ZoomContext.js";
|
|
9
|
+
import { ViewModeProvider as k } from "../contexts/ViewModeContext.js";
|
|
10
|
+
import { ScrollModeProvider as x } from "../contexts/ScrollModeContext.js";
|
|
11
|
+
import { VirtualScrollProvider as y } from "../contexts/VirtualScrollContext.js";
|
|
12
|
+
import { VirtualGridProvider as _ } from "../contexts/VirtualGridContext.js";
|
|
13
|
+
import { SelectionModeProvider as z } from "../contexts/SelectionModeContext.js";
|
|
14
|
+
import { InitialStateProvider as A } from "../contexts/InitialStateContext.js";
|
|
15
|
+
import { FullScreenProvider as N } from "../contexts/FullScreenContext.js";
|
|
16
|
+
import { FileInputProvider as Z } from "../contexts/FileInputContext.js";
|
|
17
|
+
import { PrintProvider as j } from "../contexts/PrintContext.js";
|
|
18
|
+
import { DropFileZoneProvider as H } from "../contexts/DropFileZoneContext.js";
|
|
19
|
+
import { ThumbnailProvider as O } from "../contexts/ThumbnailsContext.js";
|
|
20
|
+
import { SearchProvider as Q } from "../contexts/SearchContext.js";
|
|
21
|
+
import { LayoutContainerContext as U } from "../contexts/LayoutContainerContext.js";
|
|
22
|
+
import { DimensionPagesProvider as W } from "../contexts/DimensionPagesContext.js";
|
|
23
|
+
import { LocalizationProvider as X } from "../contexts/LocalizationContext.js";
|
|
24
|
+
import { HighlightProvider as q } from "../contexts/HighlightContext.js";
|
|
25
|
+
import { useWatermark as B } from "../utils/hooks/useWatermark.js";
|
|
26
|
+
import { DownloadProvider as J } from "../contexts/DownloadContext.js";
|
|
27
|
+
import { SmoothScrollProvider as K } from "../contexts/SmoothScrollContext.js";
|
|
28
|
+
import { ElementPageProvider as Y } from "../contexts/ElementPageContext.js";
|
|
29
|
+
import { PagesRotateProvider as $ } from "../contexts/PagesRotateContext.js";
|
|
30
|
+
import { RenderQueueProvider as rr } from "../contexts/RenderQueueProvider.js";
|
|
31
|
+
import { GlobalCurrentPageProvider as or } from "../contexts/GlobalCurrentPage.js";
|
|
32
32
|
import "../contexts/RPDocumentContext.js";
|
|
33
33
|
import "../utils/hooks/useLoadPdf.js";
|
|
34
34
|
import "pdfjs-dist";
|
|
@@ -65,60 +65,59 @@ import "../utils/const.js";
|
|
|
65
65
|
import "../utils/getElementPositionInPage.js";
|
|
66
66
|
import "../utils/Queue.js";
|
|
67
67
|
import "../utils/renderPage.js";
|
|
68
|
-
const
|
|
68
|
+
const so = (t) => {
|
|
69
69
|
const {
|
|
70
|
-
children:
|
|
71
|
-
darkMode:
|
|
72
|
-
onDarkModeChange:
|
|
73
|
-
initialRotation:
|
|
74
|
-
textLayer:
|
|
75
|
-
initialPage:
|
|
76
|
-
initialViewMode:
|
|
77
|
-
initialThumbnailsVisible:
|
|
78
|
-
initialSearch:
|
|
79
|
-
initialScale:
|
|
80
|
-
initialScrollMode:
|
|
81
|
-
locale:
|
|
82
|
-
localization:
|
|
83
|
-
downloadFilename:
|
|
84
|
-
initialSelectionMode:
|
|
70
|
+
children: m,
|
|
71
|
+
darkMode: n = !1,
|
|
72
|
+
onDarkModeChange: l,
|
|
73
|
+
initialRotation: d = 0,
|
|
74
|
+
textLayer: p = !0,
|
|
75
|
+
initialPage: a = 1,
|
|
76
|
+
initialViewMode: c = E.SINGLE_PAGE,
|
|
77
|
+
initialThumbnailsVisible: f = !1,
|
|
78
|
+
initialSearch: P,
|
|
79
|
+
initialScale: h,
|
|
80
|
+
initialScrollMode: v = F.VERTICAL_SCROLLING,
|
|
81
|
+
locale: s = "en_US",
|
|
82
|
+
localization: u,
|
|
83
|
+
downloadFilename: S,
|
|
84
|
+
initialSelectionMode: M = G.TEXT,
|
|
85
85
|
interactiveForm: R = !0
|
|
86
|
-
} =
|
|
87
|
-
return
|
|
88
|
-
|
|
86
|
+
} = t, [g, C] = o(null), [i, L] = o(null), [e, V] = o(null);
|
|
87
|
+
return B(e), /* @__PURE__ */ r(
|
|
88
|
+
A,
|
|
89
89
|
{
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
initialViewMode: f,
|
|
90
|
+
initialScale: h,
|
|
91
|
+
initialPage: a,
|
|
92
|
+
initialScrollMode: v,
|
|
93
|
+
initialRotation: d,
|
|
94
|
+
initialViewMode: c,
|
|
96
95
|
interactiveForm: R,
|
|
97
|
-
children: /* @__PURE__ */ r(
|
|
98
|
-
|
|
96
|
+
children: /* @__PURE__ */ r(K, { children: /* @__PURE__ */ r(X, { locale: s, localization: u, children: /* @__PURE__ */ r(_, { children: /* @__PURE__ */ r(y, { children: /* @__PURE__ */ r(k, { children: /* @__PURE__ */ r(x, { children: /* @__PURE__ */ r(z, { initialSelectionMode: M, children: /* @__PURE__ */ r(I, { children: /* @__PURE__ */ r($, { children: /* @__PURE__ */ r(T, { textLayer: p, children: /* @__PURE__ */ r(
|
|
97
|
+
U.Provider,
|
|
99
98
|
{
|
|
100
99
|
value: {
|
|
101
|
-
container:
|
|
100
|
+
container: g,
|
|
102
101
|
contentRef: i,
|
|
103
|
-
pagesRef:
|
|
104
|
-
setContainer:
|
|
105
|
-
setContentRef:
|
|
106
|
-
setPagesRef:
|
|
102
|
+
pagesRef: e,
|
|
103
|
+
setContainer: C,
|
|
104
|
+
setContentRef: L,
|
|
105
|
+
setPagesRef: V
|
|
107
106
|
},
|
|
108
|
-
children: /* @__PURE__ */ r(
|
|
109
|
-
|
|
107
|
+
children: /* @__PURE__ */ r(or, { children: /* @__PURE__ */ r(b, { children: /* @__PURE__ */ r(W, { children: /* @__PURE__ */ r(w, { children: /* @__PURE__ */ r(
|
|
108
|
+
D,
|
|
110
109
|
{
|
|
111
|
-
darkMode:
|
|
112
|
-
onDarkModeChange:
|
|
113
|
-
children: /* @__PURE__ */ r(
|
|
114
|
-
|
|
110
|
+
darkMode: n,
|
|
111
|
+
onDarkModeChange: l,
|
|
112
|
+
children: /* @__PURE__ */ r(Q, { initialSearch: P, children: /* @__PURE__ */ r(q, { children: /* @__PURE__ */ r(Y, { children: /* @__PURE__ */ r(rr, { children: /* @__PURE__ */ r(
|
|
113
|
+
O,
|
|
115
114
|
{
|
|
116
|
-
initialThumbnailsVisible:
|
|
117
|
-
children: /* @__PURE__ */ r(
|
|
118
|
-
|
|
115
|
+
initialThumbnailsVisible: f,
|
|
116
|
+
children: /* @__PURE__ */ r(H, { children: /* @__PURE__ */ r(N, { elementRef: i, children: /* @__PURE__ */ r(j, { children: /* @__PURE__ */ r(
|
|
117
|
+
J,
|
|
119
118
|
{
|
|
120
|
-
downloadFilename:
|
|
121
|
-
children: /* @__PURE__ */ r(
|
|
119
|
+
downloadFilename: S,
|
|
120
|
+
children: /* @__PURE__ */ r(Z, { children: m })
|
|
122
121
|
}
|
|
123
122
|
) }) }) })
|
|
124
123
|
}
|
|
@@ -131,5 +130,5 @@ const go = (m) => {
|
|
|
131
130
|
);
|
|
132
131
|
};
|
|
133
132
|
export {
|
|
134
|
-
|
|
133
|
+
so as RPController
|
|
135
134
|
};
|