@pdf-viewer/react 1.5.0-rc.0 → 1.5.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.
Files changed (58) hide show
  1. package/dist/{RPDefaultLayout-36b2f311.js → RPDefaultLayout-414d32fc.js} +620 -634
  2. package/dist/components/RPController.js +1 -1
  3. package/dist/components/RPPages.js +1 -1
  4. package/dist/components/RPProvider.js +1 -1
  5. package/dist/components/layout/LayoutContainer.js +1 -1
  6. package/dist/components/layout/RPDefaultLayout.js +1 -1
  7. package/dist/components/layout/sidebar/RPSidebar.js +1 -1
  8. package/dist/components/layout/sidebar/Thumbnail.js +1 -1
  9. package/dist/components/layout/sidebar/Thumbnails.js +1 -1
  10. package/dist/components/layout/toolbar/DocumentDialog.js +1 -1
  11. package/dist/components/layout/toolbar/FileDownloadTool.js +1 -1
  12. package/dist/components/layout/toolbar/MenuItem.js +1 -1
  13. package/dist/components/layout/toolbar/MenuSeparator.js +1 -1
  14. package/dist/components/layout/toolbar/MostPageTool.js +2 -2
  15. package/dist/components/layout/toolbar/OtherTool.js +2 -2
  16. package/dist/components/layout/toolbar/Paginate.js +1 -1
  17. package/dist/components/layout/toolbar/PrintTool.js +1 -1
  18. package/dist/components/layout/toolbar/RPToolbar.js +1 -1
  19. package/dist/components/layout/toolbar/RPToolbarEnd.js +1 -1
  20. package/dist/components/layout/toolbar/RotateTool.js +1 -1
  21. package/dist/components/layout/toolbar/ScrollModeTool.js +1 -1
  22. package/dist/components/layout/toolbar/SearchTool.js +1 -1
  23. package/dist/components/layout/toolbar/SelectionModeTool.js +1 -1
  24. package/dist/components/layout/toolbar/ViewModeTool.js +1 -1
  25. package/dist/components/layout/toolbar/ZoomTool.js +2 -2
  26. package/dist/components/page/AnnotationLayer.js +1 -1
  27. package/dist/components/page/CanvasLayer.js +1 -1
  28. package/dist/components/page/DualPage.js +1 -1
  29. package/dist/components/page/RPPage.js +1 -1
  30. package/dist/components/page/SinglePage.js +1 -1
  31. package/dist/components/page/TextHighlightLayer.js +1 -1
  32. package/dist/components/page/TextLayer.js +1 -1
  33. package/dist/components/ui/Checkbox.js +14 -13
  34. package/dist/components/ui/DropDown.js +1 -1
  35. package/dist/components/ui/LoadingIndicator.js +1 -1
  36. package/dist/components/ui/RPTooltip.js +689 -331
  37. package/dist/contexts/PaginationContext.js +1 -1
  38. package/dist/contexts/PrintContext.js +1 -1
  39. package/dist/contexts/SearchContext.js +1 -1
  40. package/dist/contexts/ThumbnailsContext.js +1 -1
  41. package/dist/index-2e540713.js +23 -0
  42. package/dist/index-353ec0a6.js +172 -0
  43. package/dist/index-5ff5dbd0.js +1675 -0
  44. package/dist/index-71898eb9.js +139 -0
  45. package/dist/main.js +1 -1
  46. package/dist/utils/hooks/useFileDownload.js +1 -1
  47. package/dist/utils/hooks/useLicense.js +1 -1
  48. package/dist/utils/hooks/usePaginate.js +1 -1
  49. package/dist/utils/hooks/usePresentPage.js +1 -1
  50. package/dist/utils/hooks/usePrint.js +1 -1
  51. package/dist/utils/hooks/useScrollToPage.js +1 -1
  52. package/dist/utils/hooks/useSearch.js +1 -1
  53. package/dist/utils/hooks/useThumbnail.js +1 -1
  54. package/dist/utils/hooks/useVirtualReactWindow.js +1 -1
  55. package/package.json +1 -1
  56. package/dist/index-1cb41342.js +0 -307
  57. package/dist/index-7279fb4e.js +0 -1557
  58. package/dist/index-aa2d3884.js +0 -140
@@ -1,13 +1,13 @@
1
- import { jsx as a, Fragment as Se, jsxs as D } from "react/jsx-runtime";
1
+ import { jsx as i, Fragment as xe, jsxs as D } from "react/jsx-runtime";
2
2
  import * as U from "react";
3
- import { useRef as M, useEffect as A, useCallback as L, useState as $, createContext as Ke, useContext as Xe, useMemo as F, forwardRef as We, useImperativeHandle as ln, createElement as Ge, PureComponent as nr, Component as rr, memo as or } from "react";
3
+ import { useRef as M, useEffect as A, useCallback as L, useState as $, createContext as Ke, useContext as Xe, useMemo as F, forwardRef as We, useImperativeHandle as ln, createElement as Ve, PureComponent as nr, Component as rr, memo as or } from "react";
4
4
  import { ChevronUpIcon as Me } from "./components/icons/ChevronUpIcon.js";
5
- import { UIButton as ee } from "./components/ui/Button.js";
5
+ import { UIButton as Q } from "./components/ui/Button.js";
6
6
  import { UIInput as dn } from "./components/ui/Input.js";
7
7
  import { useScrollModeContext as Ee } from "./contexts/ScrollModeContext.js";
8
8
  import { useDocumentContext as K } from "./contexts/RPDocumentContext.js";
9
9
  import { useDarkModeContext as ir } from "./contexts/DarkModeContext.js";
10
- import { ViewMode as Ze, ScrollMode as X, AnnotationSubType as kt, SelectionMode as ar, ZoomLevel as it } from "./utils/types.js";
10
+ import { ViewMode as Ze, ScrollMode as ee, AnnotationSubType as kt, SelectionMode as ar, ZoomLevel as it } from "./utils/types.js";
11
11
  import { useRotationContext as Ye } from "./contexts/RotationContext.js";
12
12
  import { useLayerContext as sr } from "./contexts/LayerContext.js";
13
13
  import { useZoomContext as Je } from "./contexts/ZoomContext.js";
@@ -28,22 +28,22 @@ import { useDimensionPagesContext as tt } from "./contexts/DimensionPagesContext
28
28
  import { useLocalizationContext as ue } from "./contexts/LocalizationContext.js";
29
29
  import { useHighlightContext as vr } from "./contexts/HighlightContext.js";
30
30
  import { useDownloadContext as _r } from "./contexts/DownloadContext.js";
31
- import { useSmoothScrollContext as xt } from "./contexts/SmoothScrollContext.js";
31
+ import { useSmoothScrollContext as St } from "./contexts/SmoothScrollContext.js";
32
32
  import { useLoaderContext as mn } from "./contexts/LoaderContext.js";
33
33
  import "./contexts/LicenseContext.js";
34
34
  import "./components/RPConfig.js";
35
35
  import { ThumbnailIcon as wr } from "./components/icons/Thumbnail.js";
36
36
  import { c as re } from "./clsx-0c6e471a.js";
37
- import { LoaderIcon as St } from "./components/icons/LoaderIcon.js";
37
+ import { LoaderIcon as xt } from "./components/icons/LoaderIcon.js";
38
38
  import { useInfiniteScroll as br } from "./utils/hooks/useInfiniteScroll.js";
39
39
  import { RPSplitter as Cr } from "./components/layout/sidebar/RPSplitter.js";
40
40
  import { useToolbarComponentContext as _e, ToolbarComponentProvider as Tr } from "./contexts/ToolbarComponentContext.js";
41
41
  import { useIconContext as pe, IconProvider as Pr } from "./contexts/IconContext.js";
42
42
  import q from "./components/ui/RPTooltip.js";
43
- import { Container as xr } from "./components/layout/Container.js";
44
- import { WrapperLayout as Sr } from "./components/layout/WrapperLayout.js";
45
- import { RPDropFileZone as Ir } from "./components/RPDropFileZone.js";
46
- import { useViewportContext as ye, ViewportProvider as yr } from "./contexts/ViewportContext.js";
43
+ import { Container as Sr } from "./components/layout/Container.js";
44
+ import { WrapperLayout as xr } from "./components/layout/WrapperLayout.js";
45
+ import { RPDropFileZone as yr } from "./components/RPDropFileZone.js";
46
+ import { useViewportContext as Ie, ViewportProvider as Ir } from "./contexts/ViewportContext.js";
47
47
  import { useThemeContext as Lr } from "./contexts/ThemeContext.js";
48
48
  import { SimpleLinkService as Rr } from "./utils/link_service.js";
49
49
  import { annotationsEvents as Nr, annotationEventsHandler as Er, handleClick as Mt, handleAnnotationWidget as Or, handleAnnotationLink as Dr, bindLayerEvents as zr, unbindLayerEvents as Wt } from "./utils/annotations.js";
@@ -51,18 +51,19 @@ import { _ as Ar, U as Fr } from "./Popover-b7402893.js";
51
51
  import { useMousePressed as kr } from "./utils/hooks/useMousePressed.js";
52
52
  import { useGrabScroll as Mr } from "./utils/hooks/useGrabScroll.js";
53
53
  import { usePinch as Wr } from "./utils/hooks/usePinch.js";
54
- import { useDebounce as It } from "./utils/hooks/useDebounce.js";
54
+ import { useDebounce as yt } from "./utils/hooks/useDebounce.js";
55
55
  import { getPositionFromPage as Hr, getPageFromPosition as $r } from "./utils/calculatePage.js";
56
56
  import { getThumbnailViewport as Ht } from "./utils/getThumbnailViewport.js";
57
57
  import { smoothScrollTo as at } from "./utils/smoothScrollTo.js";
58
- import { appConsole as Gr } from "./utils/appConsole.js";
58
+ import { appConsole as Vr } from "./utils/appConsole.js";
59
59
  import { FileUploadTool as fn } from "./components/layout/toolbar/FileUploadTool.js";
60
- import { DarkModeTool as Vr } from "./components/layout/toolbar/DarkModeTool.js";
60
+ import { DarkModeTool as Gr } from "./components/layout/toolbar/DarkModeTool.js";
61
61
  import { ThreeDotIcon as Ur } from "./components/icons/ThreeDotIcon.js";
62
62
  import { UIDropDown as gn } from "./components/ui/DropDown.js";
63
- import { e as qr, a as yt, P as He, c as ke, g as Lt, i as Zr, k as Br, f as jr } from "./index-1cb41342.js";
64
- import { D as Kr, u as st } from "./index-aa2d3884.js";
65
- import { a as Xr, u as Yr, F as Jr, b as Qr, G as Be } from "./index-7279fb4e.js";
63
+ import { u as It, P as He, c as ke, a as Lt, S as qr } from "./index-353ec0a6.js";
64
+ import { c as Zr, e as Br, b as jr } from "./index-71898eb9.js";
65
+ import { a as st } from "./index-2e540713.js";
66
+ import { a as Kr, u as Xr, F as Yr, D as Jr, b as Qr, G as Be } from "./index-5ff5dbd0.js";
66
67
  import { h as eo } from "./component-1da194e8.js";
67
68
  import { CloseIcon as vn } from "./components/icons/CloseIcon.js";
68
69
  import { dateFormatter as $t } from "./utils/dateFormatter.js";
@@ -80,14 +81,17 @@ import { GoToDownIcon as wn } from "./components/icons/GoToDownIcon.js";
80
81
  import { SelectionModeTool as lo } from "./components/layout/toolbar/SelectionModeTool.js";
81
82
  import { ZoomInIcon as uo } from "./components/icons/ZoomInIcon.js";
82
83
  import { ZoomOutIcon as po } from "./components/icons/ZoomOutIcon.js";
83
- import { PAGE_PADDING as Gt } from "./utils/constants.js";
84
+ import { PAGE_PADDING as Vt } from "./utils/constants.js";
84
85
  import { getZoomLevel as ho } from "./utils/getZoomLevel.js";
85
86
  import { SearchIcon as mo } from "./components/icons/SearchIcon.js";
86
- import { UICheckbox as Vt } from "./components/ui/Checkbox.js";
87
+ import { UICheckbox as Gt } from "./components/ui/Checkbox.js";
87
88
  import { ClearIcon as fo } from "./components/icons/ClearIcon.js";
88
89
  import { InfoIcon as Ut } from "./components/icons/InfoIcon.js";
89
- import './assets/RPDefaultLayout.css';const $e = (e, t) => e.reduce((n, o, r) => r < t ? n + o : n, 0), ct = (e, t) => Math.round(e.left) === Math.round(t.left) && Math.round(e.top) === Math.round(t.top), bn = () => {
90
- const { viewMode: e } = Qe(), { scrollMode: t } = Ee(), { virtualScrollRef: n, virtualScrollableElementRef: o, pageScrollElementRef: r } = et(), { setFocusedPage: i } = ie(), c = M(), { columnCount: s } = un(), { widths: l, heights: u } = tt(), d = M(t), f = M(e), h = M(s), { targetScrollPosition: g, smoothScrolling: w } = xt();
90
+ import './assets/RPDefaultLayout.css';const $e = (e, t) => e.reduce((n, o, r) => r < t ? n + o : n, 0), ct = (e, t) => {
91
+ const n = Math.round(e.left) === Math.round(t.left) && Math.round(e.top) === Math.round(t.top), o = Math.round(e.left) >= Math.round(t.left) && Math.round(e.top) >= Math.round(t.top);
92
+ return n || o;
93
+ }, bn = () => {
94
+ const { viewMode: e } = Qe(), { scrollMode: t } = Ee(), { virtualScrollRef: n, virtualScrollableElementRef: o, pageScrollElementRef: r } = et(), { setFocusedPage: a } = ie(), c = M(), { columnCount: s } = un(), { widths: l, heights: u } = tt(), d = M(t), f = M(e), h = M(s), { targetScrollPosition: g, smoothScrolling: w } = St();
91
95
  A(() => {
92
96
  n != null && n.scrollToItem && (c.current = n);
93
97
  }, [n]), A(() => {
@@ -107,12 +111,12 @@ import './assets/RPDefaultLayout.css';const $e = (e, t) => e.reduce((n, o, r) =>
107
111
  (T) => at(r, p, T)
108
112
  );
109
113
  }
110
- const x = {
114
+ const S = {
111
115
  left: 0,
112
116
  top: 0
113
117
  };
114
- return g.current = x, r == null ? void 0 : r.scrollTo({
115
- ...x,
118
+ return g.current = S, r == null ? void 0 : r.scrollTo({
119
+ ...S,
116
120
  behavior: m
117
121
  });
118
122
  },
@@ -125,19 +129,19 @@ import './assets/RPDefaultLayout.css';const $e = (e, t) => e.reduce((n, o, r) =>
125
129
  }, [s]), { scrollToPage: L(
126
130
  (_, m = "smooth") => {
127
131
  const P = _ - 1;
128
- let x = P, p = 0;
129
- if (f.current === Ze.DUAL_PAGE && d.current === X.PAGE_SCROLLING) {
132
+ let S = P, p = 0;
133
+ if (f.current === Ze.DUAL_PAGE && d.current === ee.PAGE_SCROLLING) {
130
134
  b(_, m);
131
135
  return;
132
136
  }
133
- if (d.current === X.PAGE_SCROLLING) {
134
- i(_);
137
+ if (d.current === ee.PAGE_SCROLLING) {
138
+ a(_);
135
139
  return;
136
140
  }
137
141
  if (!c.current || !o)
138
142
  return;
139
143
  const T = o;
140
- if (w.current = !0, d.current === X.HORIZONTAL_SCROLLING) {
144
+ if (w.current = !0, d.current === ee.HORIZONTAL_SCROLLING) {
141
145
  p = P;
142
146
  const N = {
143
147
  left: $e(l, p),
@@ -152,10 +156,10 @@ import './assets/RPDefaultLayout.css';const $e = (e, t) => e.reduce((n, o, r) =>
152
156
  });
153
157
  }
154
158
  if (f.current === Ze.DUAL_PAGE) {
155
- p = P % 2, x = Math.floor(P / 2);
159
+ p = P % 2, S = Math.floor(P / 2);
156
160
  const N = {
157
161
  left: $e(l, p),
158
- top: $e(u, x)
162
+ top: $e(u, S)
159
163
  };
160
164
  return ct(N, {
161
165
  left: T.scrollLeft,
@@ -167,7 +171,7 @@ import './assets/RPDefaultLayout.css';const $e = (e, t) => e.reduce((n, o, r) =>
167
171
  }
168
172
  const C = {
169
173
  left: 0,
170
- top: $e(u, x)
174
+ top: $e(u, S)
171
175
  };
172
176
  return g.current = C, ct(C, {
173
177
  left: T.scrollLeft,
@@ -181,14 +185,14 @@ import './assets/RPDefaultLayout.css';const $e = (e, t) => e.reduce((n, o, r) =>
181
185
  o,
182
186
  s,
183
187
  b,
184
- i,
188
+ a,
185
189
  at,
186
190
  u,
187
191
  l
188
192
  ]
189
193
  ) };
190
194
  }, go = (e = 1) => {
191
- const [t, n] = $(e), [o, r] = $(0), { scrollToPage: i } = bn(), c = M(1), { viewMode: s } = Qe(), { scrollMode: l } = Ee(), u = It(t, 100), d = L(
195
+ const [t, n] = $(e), [o, r] = $(0), { scrollToPage: a } = bn(), c = M(1), { viewMode: s } = Qe(), { scrollMode: l } = Ee(), u = yt(t, 100), d = L(
192
196
  (b) => {
193
197
  if (!/^[0-9]*$/g.test(b.toString()) || !b)
194
198
  return { success: !1, currentPage: c.current };
@@ -199,9 +203,9 @@ import './assets/RPDefaultLayout.css';const $e = (e, t) => e.reduce((n, o, r) =>
199
203
  ), f = L(d, [d]), h = L(
200
204
  (b) => {
201
205
  const v = d(b);
202
- return v.success && i(v.currentPage), v;
206
+ return v.success && a(v.currentPage), v;
203
207
  },
204
- [d, i]
208
+ [d, a]
205
209
  ), g = L(() => {
206
210
  let b = t - 1;
207
211
  h(b);
@@ -232,19 +236,19 @@ import './assets/RPDefaultLayout.css';const $e = (e, t) => e.reduce((n, o, r) =>
232
236
  }
233
237
  }), ie = () => {
234
238
  const e = Xe(Cn);
235
- return typeof (e == null ? void 0 : e.focusedPage) > "u" && Gr.error("Please use this hooks inside children component of RPProvider"), e;
236
- }, Ts = ({ children: e }) => {
237
- const { pdf: t } = K(), { focusedPage: n, totalPages: o, setFocusedPage: r, setTotalPages: i, goToPage: c, nextPage: s, prevPage: l } = go();
239
+ return typeof (e == null ? void 0 : e.focusedPage) > "u" && Vr.error("Please use this hooks inside children component of RPProvider"), e;
240
+ }, Ps = ({ children: e }) => {
241
+ const { pdf: t } = K(), { focusedPage: n, totalPages: o, setFocusedPage: r, setTotalPages: a, goToPage: c, nextPage: s, prevPage: l } = go();
238
242
  return A(() => {
239
- t != null && t.numPages && (i(t.numPages), r(1));
240
- }, [t, i, r]), /* @__PURE__ */ a(
243
+ t != null && t.numPages && (a(t.numPages), r(1));
244
+ }, [t, a, r]), /* @__PURE__ */ i(
241
245
  Cn.Provider,
242
246
  {
243
247
  value: {
244
248
  focusedPage: n,
245
249
  totalPages: o,
246
250
  setFocusedPage: r,
247
- setTotalPages: i,
251
+ setTotalPages: a,
248
252
  nextPage: s,
249
253
  prevPage: l,
250
254
  goToPage: c
@@ -258,7 +262,7 @@ const vo = () => {
258
262
  loadedPages: 0,
259
263
  totalPages: 0,
260
264
  percentage: 0
261
- }), [r, i] = $(!1), [c, s] = $(!1), [l, u] = $(null), d = M(!1);
265
+ }), [r, a] = $(!1), [c, s] = $(!1), [l, u] = $(null), d = M(!1);
262
266
  A(() => {
263
267
  d.current;
264
268
  }, [d]);
@@ -267,7 +271,7 @@ const vo = () => {
267
271
  const P = document.querySelector(".rp-print-zone");
268
272
  P && P.remove();
269
273
  }, []), h = L(() => {
270
- d.current = !1, i(!1), s(!1), u(null), o({
274
+ d.current = !1, a(!1), s(!1), u(null), o({
271
275
  loadedPages: 0,
272
276
  totalPages: 0,
273
277
  percentage: 0
@@ -276,23 +280,23 @@ const vo = () => {
276
280
  d.current = !0;
277
281
  }, w = async ({
278
282
  scratchCanvas: P,
279
- pdfDocument: x,
283
+ pdfDocument: S,
280
284
  pageNumber: p,
281
285
  viewerPdfPage: T,
282
286
  printResolution: C,
283
- optionalContentConfigPromise: S,
287
+ optionalContentConfigPromise: x,
284
288
  printAnnotationStoragePromise: N
285
289
  }) => {
286
290
  if (d.current) {
287
291
  h();
288
292
  return;
289
293
  }
290
- const y = C / hr.PDF;
291
- P.width = Math.floor(T.width * y), P.height = Math.floor(T.height * y);
294
+ const I = C / hr.PDF;
295
+ P.width = Math.floor(T.width * I), P.height = Math.floor(T.height * I);
292
296
  const O = P.getContext("2d");
293
297
  O.save(), O.fillStyle = "rgb(255, 255, 255)", O.fillRect(0, 0, P.width, P.height), O.restore();
294
298
  const [R, k] = await Promise.all([
295
- x.getPage(p),
299
+ S.getPage(p),
296
300
  N
297
301
  ]);
298
302
  if (d.current) {
@@ -301,65 +305,65 @@ const vo = () => {
301
305
  }
302
306
  const z = {
303
307
  canvasContext: O,
304
- transform: [y, 0, 0, y, 0, 0],
308
+ transform: [I, 0, 0, I, 0, 0],
305
309
  viewport: R.getViewport({ scale: 1, rotation: T.rotation }),
306
310
  intent: "print",
307
311
  annotationMode: mr.ENABLE_STORAGE,
308
- optionalContentConfigPromise: S,
312
+ optionalContentConfigPromise: x,
309
313
  printAnnotationStorage: k
310
314
  };
311
315
  try {
312
316
  return R.render(z).promise;
313
- } catch (I) {
314
- throw I instanceof fr || console.error(I), I;
317
+ } catch (y) {
318
+ throw y instanceof fr || console.error(y), y;
315
319
  }
316
320
  }, b = L(() => {
317
321
  const P = window.print;
318
- return new Promise((x) => {
319
- const p = (S) => {
322
+ return new Promise((S) => {
323
+ const p = (x) => {
320
324
  setTimeout(() => {
321
- P.call(window), setTimeout(() => S(), 20);
325
+ P.call(window), setTimeout(() => x(), 20);
322
326
  }, 0);
323
327
  };
324
328
  if (document.querySelector(".rp-print-zone")) {
325
- p(x);
329
+ p(S);
326
330
  return;
327
331
  }
328
332
  const C = new MutationObserver(() => {
329
- document.querySelector(".rp-print-zone") && (p(x), C.disconnect());
333
+ document.querySelector(".rp-print-zone") && (p(S), C.disconnect());
330
334
  });
331
335
  C.observe(document.body, { childList: !0, subtree: !0 });
332
336
  });
333
337
  }, []), v = async (P) => {
334
- const x = document.createElement("img"), p = document.createElement("div");
338
+ const S = document.createElement("img"), p = document.createElement("div");
335
339
  return p.classList.add("rp-print-page"), await new Promise((T, C) => {
336
- P.toBlob((S) => {
337
- S ? (x.src = URL.createObjectURL(S), x.onload = () => {
338
- URL.revokeObjectURL(x.src), T();
339
- }, x.onerror = C) : C(new Error("Failed to create blob"));
340
+ P.toBlob((x) => {
341
+ x ? (S.src = URL.createObjectURL(x), S.onload = () => {
342
+ URL.revokeObjectURL(S.src), T();
343
+ }, S.onerror = C) : C(new Error("Failed to create blob"));
340
344
  });
341
345
  }).catch(() => {
342
- }), p.appendChild(x), p;
343
- }, _ = (P, x) => {
346
+ }), p.appendChild(S), p;
347
+ }, _ = (P, S) => {
344
348
  const p = document.createElement("div");
345
349
  p.classList.add("rp-print-zone");
346
- const T = document.createElement("style"), C = x.get(1);
350
+ const T = document.createElement("style"), C = S.get(1);
347
351
  if (C) {
348
- const { width: S, height: N } = C == null ? void 0 : C.page.getViewport({ scale: 1 });
349
- T.innerHTML = `@page { size: ${S}px ${N}px }`;
352
+ const { width: x, height: N } = C == null ? void 0 : C.page.getViewport({ scale: 1 });
353
+ T.innerHTML = `@page { size: ${x}px ${N}px }`;
350
354
  }
351
355
  return p.appendChild(T), p.append(...P), p;
352
356
  }, m = L(async () => {
353
357
  if (!e)
354
358
  return;
355
359
  h();
356
- const P = document.createElement("canvas"), x = [];
360
+ const P = document.createElement("canvas"), S = [];
357
361
  try {
358
362
  e.isPureXfa && console.warn("[rp] XFA Form is not supported at the moment.");
359
363
  const T = e.getOptionalContentConfig({ intent: "print" }), C = Promise.resolve(
360
364
  e.annotationStorage.print ?? void 0
361
- ), S = t.size;
362
- for (const [y, O] of t) {
365
+ ), x = t.size;
366
+ for (const [I, O] of t) {
363
367
  if (d.current) {
364
368
  h();
365
369
  return;
@@ -368,7 +372,7 @@ const vo = () => {
368
372
  if (await w({
369
373
  scratchCanvas: P,
370
374
  pdfDocument: e,
371
- pageNumber: y,
375
+ pageNumber: I,
372
376
  viewerPdfPage: R,
373
377
  printResolution: 150,
374
378
  optionalContentConfigPromise: T,
@@ -378,11 +382,11 @@ const vo = () => {
378
382
  return;
379
383
  }
380
384
  const k = await v(P);
381
- x.push(k);
382
- const z = parseFloat((x.length / S * 100).toFixed(2));
385
+ S.push(k);
386
+ const z = parseFloat((S.length / x * 100).toFixed(2));
383
387
  o({
384
- loadedPages: y,
385
- totalPages: S,
388
+ loadedPages: I,
389
+ totalPages: x,
386
390
  percentage: z
387
391
  });
388
392
  }
@@ -390,8 +394,8 @@ const vo = () => {
390
394
  h();
391
395
  return;
392
396
  }
393
- const N = _(x, t);
394
- document.body.appendChild(N), document.documentElement.classList.add("rp-print-html-printing"), document.body.classList.add("rp-print-body-printing"), i(!0), await b();
397
+ const N = _(S, t);
398
+ document.body.appendChild(N), document.documentElement.classList.add("rp-print-html-printing"), document.body.classList.add("rp-print-body-printing"), a(!0), await b();
395
399
  } catch (p) {
396
400
  s(!0), p instanceof Error && u(p);
397
401
  } finally {
@@ -430,8 +434,8 @@ const vo = () => {
430
434
  console.error("Error in setOnError callback:", t);
431
435
  }
432
436
  }
433
- }), Ps = ({ children: e }) => {
434
- const [t, n] = $(null), [o, r] = $(null), { print: i, cancel: c, progress: s, isComplete: l, isError: u, error: d } = vo(), f = L((v) => {
437
+ }), Ss = ({ children: e }) => {
438
+ const [t, n] = $(null), [o, r] = $(null), { print: a, cancel: c, progress: s, isComplete: l, isError: u, error: d } = vo(), f = L((v) => {
435
439
  v && typeof v == "function" && r(() => v);
436
440
  }, []), h = (v) => {
437
441
  d && v(d);
@@ -453,21 +457,21 @@ const vo = () => {
453
457
  const w = () => {
454
458
  o && (o(), r(null));
455
459
  }, b = {
456
- print: i,
460
+ print: a,
457
461
  cancel: c,
458
462
  setOnProgress: g,
459
463
  setOnComplete: f,
460
464
  setOnError: h,
461
465
  progress: s
462
466
  };
463
- return /* @__PURE__ */ a(Tn.Provider, { value: b, children: e });
467
+ return /* @__PURE__ */ i(Tn.Provider, { value: b, children: e });
464
468
  }, nt = () => {
465
469
  const e = Xe(Tn);
466
470
  if (!e)
467
471
  throw new Error("usePrintContext must be used within a PrintProvider");
468
472
  return e;
469
473
  }, _o = () => {
470
- const [e, t] = $({}), { pages: n } = K(), { rotate: o } = Ye(), r = F(() => Object.keys(e).length, [e]), i = L(
474
+ const [e, t] = $({}), { pages: n } = K(), { rotate: o } = Ye(), r = F(() => Object.keys(e).length, [e]), a = L(
471
475
  (s) => {
472
476
  if (!n.size || s > n.size)
473
477
  return;
@@ -508,8 +512,8 @@ const vo = () => {
508
512
  [n, o]
509
513
  );
510
514
  A(() => {
511
- i(10);
512
- }, [i]);
515
+ a(10);
516
+ }, [a]);
513
517
  const c = L(
514
518
  (s) => {
515
519
  if (!n)
@@ -542,7 +546,7 @@ const vo = () => {
542
546
  },
543
547
  [n, o]
544
548
  );
545
- return { thumbnailPages: e, addPage: c, addToPage: i, thumbnailLength: r };
549
+ return { thumbnailPages: e, addPage: c, addToPage: a, thumbnailLength: r };
546
550
  }, Pn = Ke({
547
551
  thumbnailPages: {},
548
552
  addPage: (e) => {
@@ -553,41 +557,41 @@ const vo = () => {
553
557
  setActive: (e) => {
554
558
  },
555
559
  active: !1
556
- }), xn = () => Xe(Pn), xs = ({
560
+ }), Sn = () => Xe(Pn), xs = ({
557
561
  children: e,
558
562
  initialThumbnailsVisible: t
559
563
  }) => {
560
- const { thumbnailPages: n, addPage: o, addToPage: r, thumbnailLength: i } = _o(), [c, s] = $(t);
561
- return /* @__PURE__ */ a(
564
+ const { thumbnailPages: n, addPage: o, addToPage: r, thumbnailLength: a } = _o(), [c, s] = $(t);
565
+ return /* @__PURE__ */ i(
562
566
  Pn.Provider,
563
567
  {
564
- value: { thumbnailPages: n, addPage: o, addToPage: r, thumbnailLength: i, active: c, setActive: s },
568
+ value: { thumbnailPages: n, addPage: o, addToPage: r, thumbnailLength: a, active: c, setActive: s },
565
569
  children: e
566
570
  }
567
571
  );
568
572
  }, wo = (e = {}, t = "") => {
569
- const [n, o] = $(t), [r, i] = $(!1), { pdf: c, pages: s } = K(), l = tt(), u = M(!n), { currentZoom: d } = Je(), [f, h] = $([]), { setFocusedPage: g } = ie(), [w, b] = $(0), { pageScrollElementRef: v, virtualScrollableElementRef: _ } = et(), { scrollMode: m } = Ee(), { pagesRef: P } = Te(), [x, p] = $(null), T = M({}), C = F(() => w === 0 ? null : f[w - 1], [w, f]), S = F(() => f.length, [f]);
573
+ const [n, o] = $(t), [r, a] = $(!1), { pdf: c, pages: s } = K(), l = tt(), u = M(!n), { currentZoom: d } = Je(), [f, h] = $([]), { setFocusedPage: g } = ie(), [w, b] = $(0), { pageScrollElementRef: v, virtualScrollableElementRef: _ } = et(), { scrollMode: m } = Ee(), { pagesRef: P } = Te(), [S, p] = $(null), T = M({}), C = F(() => w === 0 ? null : f[w - 1], [w, f]), x = F(() => f.length, [f]);
570
574
  A(() => {
571
575
  if (!C || !s)
572
576
  return;
573
577
  const R = _ || v;
574
578
  if (!R || !P)
575
579
  return;
576
- const k = s.get(C.page), z = P.clientHeight / 2, I = P.clientWidth / 2;
580
+ const k = s.get(C.page), z = P.clientHeight / 2, y = P.clientWidth / 2;
577
581
  let E = 0, W = 0;
578
- m === X.PAGE_SCROLLING && g(C.page), m === X.VERTICAL_SCROLLING && (E = l.heights.slice(0, C.page - 1).reduce((j, B) => j + B, 0)), m === X.HORIZONTAL_SCROLLING && (W = l.widths.slice(0, C.page - 1).reduce((j, B) => j + B, 0));
579
- let V;
582
+ m === ee.PAGE_SCROLLING && g(C.page), m === ee.VERTICAL_SCROLLING && (E = l.heights.slice(0, C.page - 1).reduce((j, B) => j + B, 0)), m === ee.HORIZONTAL_SCROLLING && (W = l.widths.slice(0, C.page - 1).reduce((j, B) => j + B, 0));
583
+ let G;
580
584
  if (!k)
581
585
  return;
582
- const Z = T.current[C.page], Y = k.page.getViewport({ scale: 1 });
583
- V = new Pt.TextLayer({
584
- viewport: Y,
586
+ const Z = T.current[C.page], X = k.page.getViewport({ scale: 1 });
587
+ G = new Pt.TextLayer({
588
+ viewport: X,
585
589
  textContentSource: Z,
586
590
  container: document.createElement("div")
587
- }), V.render().then(() => {
588
- const j = V.textDivs[C.start.idx], [B] = pn([C], Z, V.textDivs), te = l.widths[C.page - 1], ae = l.heights[C.page - 1], J = document.createElement("div"), ne = document.createElement("div");
589
- j.style.position = "absolute", j.style.color = "transparent", ne.style.position = "absolute", ne.style.top = "0", ne.style.setProperty("--scale-factor", `${d}`), J.style.position = "relative", J.style.width = `${te}px`, J.style.height = `${ae}px`, J.style.zIndex = "-1", J.appendChild(j), ne.appendChild(J), P.prepend(ne);
590
- const he = B.element.getBoundingClientRect(), ce = ne.getBoundingClientRect(), Oe = he.top - ce.top, we = he.left - ce.left, me = E + Oe - z + he.height / 2, le = W + we - I + he.width / 2, De = {
591
+ }), G.render().then(() => {
592
+ const j = G.textDivs[C.start.idx], [B] = pn([C], Z, G.textDivs), te = l.widths[C.page - 1], ae = l.heights[C.page - 1], Y = document.createElement("div"), ne = document.createElement("div");
593
+ j.style.position = "absolute", j.style.color = "transparent", ne.style.position = "absolute", ne.style.top = "0", ne.style.setProperty("--scale-factor", `${d}`), Y.style.position = "relative", Y.style.width = `${te}px`, Y.style.height = `${ae}px`, Y.style.zIndex = "-1", Y.appendChild(j), ne.appendChild(Y), P.prepend(ne);
594
+ const he = B.element.getBoundingClientRect(), ce = ne.getBoundingClientRect(), Oe = he.top - ce.top, we = he.left - ce.left, me = E + Oe - z + he.height / 2, le = W + we - y + he.width / 2, De = {
591
595
  left: Math.max(le, 0),
592
596
  top: Math.max(me, 0)
593
597
  };
@@ -606,18 +610,18 @@ const vo = () => {
606
610
  P
607
611
  ]);
608
612
  const N = L(() => {
609
- b((R) => S ? R + 1 > S ? 1 : R + 1 : 0);
610
- }, [S]), y = L(() => {
611
- b((R) => S ? R - 1 <= 0 ? S : R - 1 : 0);
612
- }, [S]), O = L(async (R) => {
613
+ b((R) => x ? R + 1 > x ? 1 : R + 1 : 0);
614
+ }, [x]), I = L(() => {
615
+ b((R) => x ? R - 1 <= 0 ? x : R - 1 : 0);
616
+ }, [x]), O = L(async (R) => {
613
617
  if (!R)
614
618
  return {};
615
619
  const k = R.numPages, z = {};
616
- for (let I = 1; I <= k; I++) {
620
+ for (let y = 1; y <= k; y++) {
617
621
  if (u.current)
618
622
  throw "close pop over";
619
- const E = await R.getPage(I);
620
- z[I.toString()] = await E.getTextContent();
623
+ const E = await R.getPage(y);
624
+ z[y.toString()] = await E.getTextContent();
621
625
  }
622
626
  return z;
623
627
  }, []);
@@ -626,35 +630,35 @@ const vo = () => {
626
630
  u.current = !0, h([]), b(0);
627
631
  return;
628
632
  }
629
- u.current = !1, i(!0), h([]), b(0), O(c).then((R) => {
633
+ u.current = !1, a(!0), h([]), b(0), O(c).then((R) => {
630
634
  T.current = R;
631
- const z = Object.keys(R).reduce((I, E) => {
635
+ const z = Object.keys(R).reduce((y, E) => {
632
636
  const W = ur(
633
637
  [n],
634
638
  R[E],
635
639
  Number(E) - 1,
636
640
  e
637
- ).map((V, Z) => ({ ...V, page: Number(E), pageMatchIdx: Z }));
638
- return [...I, ...W];
641
+ ).map((G, Z) => ({ ...G, page: Number(E), pageMatchIdx: Z }));
642
+ return [...y, ...W];
639
643
  }, []);
640
644
  h(z), b(z.length ? 1 : 0);
641
645
  }).catch(() => {
642
646
  h([]), b(0);
643
- }).finally(() => i(!1));
647
+ }).finally(() => a(!1));
644
648
  }, [n, O, c, e]), {
645
649
  search: n,
646
650
  setSearch: o,
647
651
  loading: r,
648
652
  matches: f,
649
- totalMatches: S,
653
+ totalMatches: x,
650
654
  currentMatchPosition: w,
651
655
  currentMatch: C,
652
656
  nextMatch: N,
653
- prevMatch: y,
654
- currentMatchElement: x,
657
+ prevMatch: I,
658
+ currentMatchElement: S,
655
659
  setCurrentMatchElement: p
656
660
  };
657
- }, Sn = Ke({
661
+ }, xn = Ke({
658
662
  search: "",
659
663
  setSearch: (e) => {
660
664
  },
@@ -672,13 +676,13 @@ const vo = () => {
672
676
  currentMatchElement: null,
673
677
  setCurrentMatchElement: (e) => {
674
678
  }
675
- }), Ss = ({
679
+ }), ys = ({
676
680
  children: e,
677
681
  initialSearch: t
678
682
  }) => {
679
683
  const [n, o] = $({}), {
680
684
  loading: r,
681
- setSearch: i,
685
+ setSearch: a,
682
686
  totalMatches: c,
683
687
  currentMatchPosition: s,
684
688
  currentMatch: l,
@@ -689,14 +693,14 @@ const vo = () => {
689
693
  currentMatchElement: g,
690
694
  setCurrentMatchElement: w
691
695
  } = wo(n, t);
692
- return /* @__PURE__ */ a(
693
- Sn.Provider,
696
+ return /* @__PURE__ */ i(
697
+ xn.Provider,
694
698
  {
695
699
  value: {
696
700
  searchOptions: n,
697
701
  setSearchOptions: o,
698
702
  loading: r,
699
- setSearch: i,
703
+ setSearch: a,
700
704
  totalMatches: c,
701
705
  currentMatchPosition: s,
702
706
  currentMatch: l,
@@ -710,7 +714,7 @@ const vo = () => {
710
714
  children: e
711
715
  }
712
716
  );
713
- }, In = () => Xe(Sn), de = {
717
+ }, yn = () => Xe(xn), de = {
714
718
  "rp-pages": "_rp-pages_1776r_1",
715
719
  "rp-pages-horizontal-scroll": "_rp-pages-horizontal-scroll_1776r_7",
716
720
  "rp-pages-container": "_rp-pages-container_1776r_11",
@@ -724,11 +728,11 @@ const vo = () => {
724
728
  "rp-page": "_rp-page_h7a2q_1",
725
729
  "rp-loader-wrapper": "_rp-loader-wrapper_h7a2q_14"
726
730
  }, bo = (e) => {
727
- const { pageNumber: t, onLoaded: n, onLoading: o } = e, r = M(null), { pages: i } = K(), { rotate: c } = Ye(), s = M(), { currentZoom: l } = Je();
731
+ const { pageNumber: t, onLoaded: n, onLoading: o } = e, r = M(null), { pages: a } = K(), { rotate: c } = Ye(), s = M(), { currentZoom: l } = Je();
728
732
  return A(() => {
729
- if (!i || l === 0)
733
+ if (!a || l === 0)
730
734
  return;
731
- const u = i.get(t);
735
+ const u = a.get(t);
732
736
  if (r.current && u) {
733
737
  const d = r.current;
734
738
  d.hidden = !0;
@@ -748,12 +752,12 @@ const vo = () => {
748
752
  var d;
749
753
  (d = s.current) == null || d.cancel();
750
754
  };
751
- }, [i, t, c, l, o, n]), /* @__PURE__ */ a("canvas", { "data-rp": `page-${t}-canvas`, ref: r });
755
+ }, [a, t, c, l, o, n]), /* @__PURE__ */ i("canvas", { "data-rp": `page-${t}-canvas`, ref: r });
752
756
  }, dt = {
753
757
  "rp-text-layer": "_rp-text-layer_kwwfn_1",
754
758
  "rp-text-layer-text": "_rp-text-layer-text_kwwfn_9"
755
759
  }, Co = (e) => {
756
- const { pageNumber: t } = e, { pages: n } = K(), o = M(null), { matches: r, currentMatch: i, setCurrentMatchElement: c } = In(), [s, l] = $(
760
+ const { pageNumber: t } = e, { pages: n } = K(), o = M(null), { matches: r, currentMatch: a, setCurrentMatchElement: c } = yn(), [s, l] = $(
757
761
  []
758
762
  ), u = M(), d = M(), f = M(), h = F(() => r.filter((w) => w.pageIndex === t - 1), [r, t]), g = L(
759
763
  (w, b, v = !1) => {
@@ -768,16 +772,16 @@ const vo = () => {
768
772
  );
769
773
  return A(() => {
770
774
  var v;
771
- if ((v = f.current) == null || v.classList.remove("selected"), !s.length || !i || i.pageIndex !== t - 1)
775
+ if ((v = f.current) == null || v.classList.remove("selected"), !s.length || !a || a.pageIndex !== t - 1)
772
776
  return;
773
777
  const w = h.findIndex(
774
- (_) => JSON.stringify(_) === JSON.stringify(i)
778
+ (_) => JSON.stringify(_) === JSON.stringify(a)
775
779
  );
776
780
  if (w === -1)
777
781
  return;
778
782
  const b = s.find((_) => _.index === w);
779
783
  b && (f.current = b.element, c(b.element), b.element.classList.add("selected"));
780
- }, [i, s, h]), A(() => {
784
+ }, [a, s, h]), A(() => {
781
785
  const w = n.get(t);
782
786
  if (!w || !o.current)
783
787
  return;
@@ -808,7 +812,7 @@ const vo = () => {
808
812
  });
809
813
  const b = (v = u.current) == null ? void 0 : v.textDivs;
810
814
  b && d.current && g(d.current, b, !0);
811
- }, [g]), /* @__PURE__ */ a(
815
+ }, [g]), /* @__PURE__ */ i(
812
816
  "div",
813
817
  {
814
818
  "data-rp": `page-${t}-textLayer`,
@@ -820,13 +824,13 @@ const vo = () => {
820
824
  "rp-annotation-layer": "_rp-annotation-layer_o0ksd_1"
821
825
  };
822
826
  let Po = "https://unpkg.com/pdfjs-dist@4.4.168/web/images/";
823
- const xo = (e) => {
824
- const { pageNumber: t } = e, n = M(null), { pages: o, pdf: r } = K(), i = M(), [c, s] = $(), { setFocusedPage: l, goToPage: u } = ie(), { scrollMode: d } = Ee(), { print: f } = nt(), { download: h } = Un(), g = F(() => o.get(t), [o, t]), w = F(() => g == null ? void 0 : g.page.getViewport(), [g]);
827
+ const So = (e) => {
828
+ const { pageNumber: t } = e, n = M(null), { pages: o, pdf: r } = K(), a = M(), [c, s] = $(), { setFocusedPage: l, goToPage: u } = ie(), { scrollMode: d } = Ee(), { print: f } = nt(), { download: h } = Un(), g = F(() => o.get(t), [o, t]), w = F(() => g == null ? void 0 : g.page.getViewport(), [g]);
825
829
  A(() => {
826
- i.current && (i.current.div.replaceChildren(), i.current = void 0);
830
+ a.current && (a.current.div.replaceChildren(), a.current = void 0);
827
831
  }, [r]), A(() => {
828
832
  g && g.page.getAnnotations().then((v) => {
829
- i.current = void 0, s(v), n.current && (n.current.innerText = "");
833
+ a.current = void 0, s(v), n.current && (n.current.innerText = "");
830
834
  });
831
835
  }, [g]);
832
836
  const b = L(
@@ -834,7 +838,7 @@ const xo = (e) => {
834
838
  !c || !r || (Nr(v), Er(v, r, c).then((_) => {
835
839
  var m, P;
836
840
  ((m = _ == null ? void 0 : _.data) == null ? void 0 : m.action) === "Print" ? f() : ((P = _ == null ? void 0 : _.data) == null ? void 0 : P.action) === "SaveAs" && h();
837
- }), d === X.PAGE_SCROLLING ? Mt(v, c, r, (_) => l(_.pageIndex + 1)) : Mt(v, c, r, (_) => u(_.pageIndex + 1)));
841
+ }), d === ee.PAGE_SCROLLING ? Mt(v, c, r, (_) => l(_.pageIndex + 1)) : Mt(v, c, r, (_) => u(_.pageIndex + 1)));
838
842
  },
839
843
  [r, c, u, l, d, f, h]
840
844
  );
@@ -842,28 +846,28 @@ const xo = (e) => {
842
846
  if (!g || !c)
843
847
  return;
844
848
  const v = g.page.getViewport();
845
- if (i.current) {
846
- i.current.update({
849
+ if (a.current) {
850
+ a.current.update({
847
851
  viewport: v.clone({ dontFlip: !0 })
848
852
  });
849
853
  return;
850
854
  }
851
855
  const _ = /* @__PURE__ */ new Map([]);
852
- for (const x of c) {
853
- const { annotationType: p } = x;
856
+ for (const S of c) {
857
+ const { annotationType: p } = S;
854
858
  switch (p) {
855
859
  case kt.Link:
856
- Dr(x);
860
+ Dr(S);
857
861
  break;
858
862
  case kt.Widget:
859
- Or(x, v, _);
863
+ Or(S, v, _);
860
864
  break;
861
865
  }
862
866
  }
863
867
  const m = new AbortController();
864
868
  return (async () => {
865
869
  var T;
866
- i.current && (i.current.div.replaceChildren(), i.current = void 0), n.current && (n.current.innerText = ""), i.current = new gr({
870
+ a.current && (a.current.div.replaceChildren(), a.current = void 0), n.current && (n.current.innerText = ""), a.current = new gr({
867
871
  div: n.current,
868
872
  accessibilityManager: void 0,
869
873
  annotationCanvasMap: void 0,
@@ -872,13 +876,13 @@ const xo = (e) => {
872
876
  page: g.page,
873
877
  viewport: v.clone({ dontFlip: !0 })
874
878
  }), n.current && Wt(n.current, b);
875
- const x = await (r == null ? void 0 : r.hasJSActions()), p = await (r == null ? void 0 : r.getFieldObjects());
879
+ const S = await (r == null ? void 0 : r.hasJSActions()), p = await (r == null ? void 0 : r.getFieldObjects());
876
880
  if (m.signal.aborted)
877
881
  throw "abort";
878
- return (T = i.current) == null ? void 0 : T.render({
882
+ return (T = a.current) == null ? void 0 : T.render({
879
883
  annotations: c,
880
884
  annotationStorage: r == null ? void 0 : r.annotationStorage,
881
- hasJSActions: x,
885
+ hasJSActions: S,
882
886
  fieldObjects: p,
883
887
  div: n.current,
884
888
  viewport: v.clone({ dontFlip: !0 }),
@@ -891,13 +895,13 @@ const xo = (e) => {
891
895
  });
892
896
  })().then(() => {
893
897
  n.current && zr(n.current, b);
894
- }).catch((x) => {
895
- if (x !== "abort")
896
- throw x;
898
+ }).catch((S) => {
899
+ if (S !== "abort")
900
+ throw S;
897
901
  }), () => {
898
902
  m.abort("clear"), n.current && Wt(n.current, b);
899
903
  };
900
- }, [r, c, b]), /* @__PURE__ */ a(
904
+ }, [r, c, b]), /* @__PURE__ */ i(
901
905
  "div",
902
906
  {
903
907
  "data-rp": `page-${t}-annotationLayer`,
@@ -909,8 +913,8 @@ const xo = (e) => {
909
913
  }, ut = {
910
914
  "rp-text-highlight-layer": "_rp-text-highlight-layer_1470i_1",
911
915
  "rp-text-highlight-layer-text": "_rp-text-highlight-layer-text_1470i_9"
912
- }, So = ({ pageNumber: e }) => {
913
- const t = M(null), n = M(), o = M(), { pages: r } = K(), { highlightMatches: i } = vr(), c = F(() => i.filter((u) => u.pageIndex === e - 1), [i]), s = L(
916
+ }, xo = ({ pageNumber: e }) => {
917
+ const t = M(null), n = M(), o = M(), { pages: r } = K(), { highlightMatches: a } = vr(), c = F(() => a.filter((u) => u.pageIndex === e - 1), [a]), s = L(
914
918
  (l, u, d = !1) => {
915
919
  d && hn(l, u), pr(c, l, u);
916
920
  },
@@ -947,7 +951,7 @@ const xo = (e) => {
947
951
  });
948
952
  const u = (d = n.current) == null ? void 0 : d.textDivs;
949
953
  u && o.current && s(o.current, u, !0);
950
- }, [s]), /* @__PURE__ */ a(Se, { children: /* @__PURE__ */ a(
954
+ }, [s]), /* @__PURE__ */ i(xe, { children: /* @__PURE__ */ i(
951
955
  "div",
952
956
  {
953
957
  "data-rp": `page-${e}-textHighlightLayer`,
@@ -956,16 +960,16 @@ const xo = (e) => {
956
960
  }
957
961
  ) });
958
962
  }, Nt = We((e, t) => {
959
- const { pageNumber: n, style: o, ...r } = e, { pages: i } = K(), { rotate: c } = Ye(), { textLayer: s } = sr(), { currentZoom: l } = Je(), u = M(i.get(n)), [d, f] = $(!1), h = M(null), [g, w] = $({
963
+ const { pageNumber: n, style: o, ...r } = e, { pages: a } = K(), { rotate: c } = Ye(), { textLayer: s } = sr(), { currentZoom: l } = Je(), u = M(a.get(n)), [d, f] = $(!1), h = M(null), [g, w] = $({
960
964
  width: 0,
961
965
  height: 0
962
966
  });
963
967
  ln(t, () => h.current), A(() => {
964
- if (i && (u.current = i.get(n), u.current)) {
968
+ if (a && (u.current = a.get(n), u.current)) {
965
969
  const m = u.current.page.getViewport({ scale: l, rotation: c });
966
970
  w(m);
967
971
  }
968
- }, [i, n, c, l]);
972
+ }, [a, n, c, l]);
969
973
  const b = F(() => {
970
974
  switch (c) {
971
975
  case 90:
@@ -981,7 +985,7 @@ const xo = (e) => {
981
985
  }, []), _ = L(() => {
982
986
  f(!1);
983
987
  }, []);
984
- return /* @__PURE__ */ a(
988
+ return /* @__PURE__ */ i(
985
989
  "div",
986
990
  {
987
991
  ref: h,
@@ -1004,11 +1008,11 @@ const xo = (e) => {
1004
1008
  },
1005
1009
  className: lt["rp-page"],
1006
1010
  children: [
1007
- /* @__PURE__ */ a(bo, { onLoading: v, onLoaded: _, pageNumber: n }),
1008
- d && /* @__PURE__ */ a("div", { className: lt["rp-loader-wrapper"], children: /* @__PURE__ */ a(St, {}) }),
1009
- s && /* @__PURE__ */ a(Co, { pageNumber: n }),
1010
- /* @__PURE__ */ a(So, { pageNumber: n }),
1011
- /* @__PURE__ */ a(xo, { pageNumber: n })
1011
+ /* @__PURE__ */ i(bo, { onLoading: v, onLoaded: _, pageNumber: n }),
1012
+ d && /* @__PURE__ */ i("div", { className: lt["rp-loader-wrapper"], children: /* @__PURE__ */ i(xt, {}) }),
1013
+ s && /* @__PURE__ */ i(Co, { pageNumber: n }),
1014
+ /* @__PURE__ */ i(xo, { pageNumber: n }),
1015
+ /* @__PURE__ */ i(So, { pageNumber: n })
1012
1016
  ]
1013
1017
  }
1014
1018
  )
@@ -1025,30 +1029,30 @@ function bt(e, t) {
1025
1029
  return n.__proto__ = o, n;
1026
1030
  }, bt(e, t);
1027
1031
  }
1028
- function Io(e, t) {
1032
+ function yo(e, t) {
1029
1033
  e.prototype = Object.create(t.prototype), e.prototype.constructor = e, bt(e, t);
1030
1034
  }
1031
1035
  var Zt = Number.isNaN || function(t) {
1032
1036
  return typeof t == "number" && t !== t;
1033
1037
  };
1034
- function yo(e, t) {
1038
+ function Io(e, t) {
1035
1039
  return !!(e === t || Zt(e) && Zt(t));
1036
1040
  }
1037
1041
  function Lo(e, t) {
1038
1042
  if (e.length !== t.length)
1039
1043
  return !1;
1040
1044
  for (var n = 0; n < e.length; n++)
1041
- if (!yo(e[n], t[n]))
1045
+ if (!Io(e[n], t[n]))
1042
1046
  return !1;
1043
1047
  return !0;
1044
1048
  }
1045
1049
  function pt(e, t) {
1046
1050
  t === void 0 && (t = Lo);
1047
- var n, o = [], r, i = !1;
1051
+ var n, o = [], r, a = !1;
1048
1052
  function c() {
1049
1053
  for (var s = [], l = 0; l < arguments.length; l++)
1050
1054
  s[l] = arguments[l];
1051
- return i && n === this && t(s, o) || (r = e.apply(this, s), i = !0, n = this, o = s), r;
1055
+ return a && n === this && t(s, o) || (r = e.apply(this, s), a = !0, n = this, o = s), r;
1052
1056
  }
1053
1057
  return c;
1054
1058
  }
@@ -1105,15 +1109,15 @@ var Oo = 150, Do = function(t) {
1105
1109
  t.data;
1106
1110
  var o = t.rowIndex;
1107
1111
  return o + ":" + n;
1108
- }, Ve = null, Ue = null, qe = null;
1109
- process.env.NODE_ENV !== "production" && typeof window < "u" && typeof window.WeakSet < "u" && (Ve = /* @__PURE__ */ new WeakSet(), Ue = /* @__PURE__ */ new WeakSet(), qe = /* @__PURE__ */ new WeakSet());
1112
+ }, Ge = null, Ue = null, qe = null;
1113
+ process.env.NODE_ENV !== "production" && typeof window < "u" && typeof window.WeakSet < "u" && (Ge = /* @__PURE__ */ new WeakSet(), Ue = /* @__PURE__ */ new WeakSet(), qe = /* @__PURE__ */ new WeakSet());
1110
1114
  function zo(e) {
1111
- var t, n = e.getColumnOffset, o = e.getColumnStartIndexForOffset, r = e.getColumnStopIndexForStartIndex, i = e.getColumnWidth, c = e.getEstimatedTotalHeight, s = e.getEstimatedTotalWidth, l = e.getOffsetForColumnAndAlignment, u = e.getOffsetForRowAndAlignment, d = e.getRowHeight, f = e.getRowOffset, h = e.getRowStartIndexForOffset, g = e.getRowStopIndexForStartIndex, w = e.initInstanceProps, b = e.shouldResetStyleCacheOnItemSizeChange, v = e.validateProps;
1115
+ var t, n = e.getColumnOffset, o = e.getColumnStartIndexForOffset, r = e.getColumnStopIndexForStartIndex, a = e.getColumnWidth, c = e.getEstimatedTotalHeight, s = e.getEstimatedTotalWidth, l = e.getOffsetForColumnAndAlignment, u = e.getOffsetForRowAndAlignment, d = e.getRowHeight, f = e.getRowOffset, h = e.getRowStartIndexForOffset, g = e.getRowStopIndexForStartIndex, w = e.initInstanceProps, b = e.shouldResetStyleCacheOnItemSizeChange, v = e.validateProps;
1112
1116
  return t = /* @__PURE__ */ function(_) {
1113
- Io(m, _);
1114
- function m(x) {
1117
+ yo(m, _);
1118
+ function m(S) {
1115
1119
  var p;
1116
- return p = _.call(this, x) || this, p._instanceProps = w(p.props, qt(p)), p._resetIsScrollingTimeoutId = null, p._outerRef = void 0, p.state = {
1120
+ return p = _.call(this, S) || this, p._instanceProps = w(p.props, qt(p)), p._resetIsScrollingTimeoutId = null, p._outerRef = void 0, p.state = {
1117
1121
  instance: qt(p),
1118
1122
  isScrolling: !1,
1119
1123
  horizontalScrollDirection: "forward",
@@ -1121,63 +1125,63 @@ function zo(e) {
1121
1125
  scrollTop: typeof p.props.initialScrollTop == "number" ? p.props.initialScrollTop : 0,
1122
1126
  scrollUpdateWasRequested: !1,
1123
1127
  verticalScrollDirection: "forward"
1124
- }, p._callOnItemsRendered = void 0, p._callOnItemsRendered = pt(function(T, C, S, N, y, O, R, k) {
1128
+ }, p._callOnItemsRendered = void 0, p._callOnItemsRendered = pt(function(T, C, x, N, I, O, R, k) {
1125
1129
  return p.props.onItemsRendered({
1126
1130
  overscanColumnStartIndex: T,
1127
1131
  overscanColumnStopIndex: C,
1128
- overscanRowStartIndex: S,
1132
+ overscanRowStartIndex: x,
1129
1133
  overscanRowStopIndex: N,
1130
- visibleColumnStartIndex: y,
1134
+ visibleColumnStartIndex: I,
1131
1135
  visibleColumnStopIndex: O,
1132
1136
  visibleRowStartIndex: R,
1133
1137
  visibleRowStopIndex: k
1134
1138
  });
1135
- }), p._callOnScroll = void 0, p._callOnScroll = pt(function(T, C, S, N, y) {
1139
+ }), p._callOnScroll = void 0, p._callOnScroll = pt(function(T, C, x, N, I) {
1136
1140
  return p.props.onScroll({
1137
- horizontalScrollDirection: S,
1141
+ horizontalScrollDirection: x,
1138
1142
  scrollLeft: T,
1139
1143
  scrollTop: C,
1140
1144
  verticalScrollDirection: N,
1141
- scrollUpdateWasRequested: y
1145
+ scrollUpdateWasRequested: I
1142
1146
  });
1143
1147
  }), p._getItemStyle = void 0, p._getItemStyle = function(T, C) {
1144
- var S = p.props, N = S.columnWidth, y = S.direction, O = S.rowHeight, R = p._getItemStyleCache(b && N, b && y, b && O), k = T + ":" + C, z;
1148
+ var x = p.props, N = x.columnWidth, I = x.direction, O = x.rowHeight, R = p._getItemStyleCache(b && N, b && I, b && O), k = T + ":" + C, z;
1145
1149
  if (R.hasOwnProperty(k))
1146
1150
  z = R[k];
1147
1151
  else {
1148
- var I = n(p.props, C, p._instanceProps), E = y === "rtl";
1152
+ var y = n(p.props, C, p._instanceProps), E = I === "rtl";
1149
1153
  R[k] = z = {
1150
1154
  position: "absolute",
1151
- left: E ? void 0 : I,
1152
- right: E ? I : void 0,
1155
+ left: E ? void 0 : y,
1156
+ right: E ? y : void 0,
1153
1157
  top: f(p.props, T, p._instanceProps),
1154
1158
  height: d(p.props, T, p._instanceProps),
1155
- width: i(p.props, C, p._instanceProps)
1159
+ width: a(p.props, C, p._instanceProps)
1156
1160
  };
1157
1161
  }
1158
1162
  return z;
1159
- }, p._getItemStyleCache = void 0, p._getItemStyleCache = pt(function(T, C, S) {
1163
+ }, p._getItemStyleCache = void 0, p._getItemStyleCache = pt(function(T, C, x) {
1160
1164
  return {};
1161
1165
  }), p._onScroll = function(T) {
1162
- var C = T.currentTarget, S = C.clientHeight, N = C.clientWidth, y = C.scrollLeft, O = C.scrollTop, R = C.scrollHeight, k = C.scrollWidth;
1166
+ var C = T.currentTarget, x = C.clientHeight, N = C.clientWidth, I = C.scrollLeft, O = C.scrollTop, R = C.scrollHeight, k = C.scrollWidth;
1163
1167
  p.setState(function(z) {
1164
- if (z.scrollLeft === y && z.scrollTop === O)
1168
+ if (z.scrollLeft === I && z.scrollTop === O)
1165
1169
  return null;
1166
- var I = p.props.direction, E = y;
1167
- if (I === "rtl")
1170
+ var y = p.props.direction, E = I;
1171
+ if (y === "rtl")
1168
1172
  switch (Xt()) {
1169
1173
  case "negative":
1170
- E = -y;
1174
+ E = -I;
1171
1175
  break;
1172
1176
  case "positive-descending":
1173
- E = k - N - y;
1177
+ E = k - N - I;
1174
1178
  break;
1175
1179
  }
1176
1180
  E = Math.max(0, Math.min(E, k - N));
1177
- var W = Math.max(0, Math.min(O, R - S));
1181
+ var W = Math.max(0, Math.min(O, R - x));
1178
1182
  return {
1179
1183
  isScrolling: !0,
1180
- horizontalScrollDirection: z.scrollLeft < y ? "forward" : "backward",
1184
+ horizontalScrollDirection: z.scrollLeft < I ? "forward" : "backward",
1181
1185
  scrollLeft: E,
1182
1186
  scrollTop: W,
1183
1187
  verticalScrollDirection: z.scrollTop < O ? "forward" : "backward",
@@ -1203,60 +1207,60 @@ function zo(e) {
1203
1207
  var P = m.prototype;
1204
1208
  return P.scrollTo = function(p) {
1205
1209
  var T = p.scrollLeft, C = p.scrollTop;
1206
- T !== void 0 && (T = Math.max(0, T)), C !== void 0 && (C = Math.max(0, C)), this.setState(function(S) {
1207
- return T === void 0 && (T = S.scrollLeft), C === void 0 && (C = S.scrollTop), S.scrollLeft === T && S.scrollTop === C ? null : {
1208
- horizontalScrollDirection: S.scrollLeft < T ? "forward" : "backward",
1210
+ T !== void 0 && (T = Math.max(0, T)), C !== void 0 && (C = Math.max(0, C)), this.setState(function(x) {
1211
+ return T === void 0 && (T = x.scrollLeft), C === void 0 && (C = x.scrollTop), x.scrollLeft === T && x.scrollTop === C ? null : {
1212
+ horizontalScrollDirection: x.scrollLeft < T ? "forward" : "backward",
1209
1213
  scrollLeft: T,
1210
1214
  scrollTop: C,
1211
1215
  scrollUpdateWasRequested: !0,
1212
- verticalScrollDirection: S.scrollTop < C ? "forward" : "backward"
1216
+ verticalScrollDirection: x.scrollTop < C ? "forward" : "backward"
1213
1217
  };
1214
1218
  }, this._resetIsScrollingDebounced);
1215
1219
  }, P.scrollToItem = function(p) {
1216
- var T = p.align, C = T === void 0 ? "auto" : T, S = p.columnIndex, N = p.rowIndex, y = this.props, O = y.columnCount, R = y.height, k = y.rowCount, z = y.width, I = this.state, E = I.scrollLeft, W = I.scrollTop, V = Eo();
1217
- S !== void 0 && (S = Math.max(0, Math.min(S, O - 1))), N !== void 0 && (N = Math.max(0, Math.min(N, k - 1)));
1218
- var Z = c(this.props, this._instanceProps), Y = s(this.props, this._instanceProps), j = Y > z ? V : 0, B = Z > R ? V : 0;
1220
+ var T = p.align, C = T === void 0 ? "auto" : T, x = p.columnIndex, N = p.rowIndex, I = this.props, O = I.columnCount, R = I.height, k = I.rowCount, z = I.width, y = this.state, E = y.scrollLeft, W = y.scrollTop, G = Eo();
1221
+ x !== void 0 && (x = Math.max(0, Math.min(x, O - 1))), N !== void 0 && (N = Math.max(0, Math.min(N, k - 1)));
1222
+ var Z = c(this.props, this._instanceProps), X = s(this.props, this._instanceProps), j = X > z ? G : 0, B = Z > R ? G : 0;
1219
1223
  this.scrollTo({
1220
- scrollLeft: S !== void 0 ? l(this.props, S, C, E, this._instanceProps, B) : E,
1224
+ scrollLeft: x !== void 0 ? l(this.props, x, C, E, this._instanceProps, B) : E,
1221
1225
  scrollTop: N !== void 0 ? u(this.props, N, C, W, this._instanceProps, j) : W
1222
1226
  });
1223
1227
  }, P.componentDidMount = function() {
1224
1228
  var p = this.props, T = p.initialScrollLeft, C = p.initialScrollTop;
1225
1229
  if (this._outerRef != null) {
1226
- var S = this._outerRef;
1227
- typeof T == "number" && (S.scrollLeft = T), typeof C == "number" && (S.scrollTop = C);
1230
+ var x = this._outerRef;
1231
+ typeof T == "number" && (x.scrollLeft = T), typeof C == "number" && (x.scrollTop = C);
1228
1232
  }
1229
1233
  this._callPropsCallbacks();
1230
1234
  }, P.componentDidUpdate = function() {
1231
- var p = this.props.direction, T = this.state, C = T.scrollLeft, S = T.scrollTop, N = T.scrollUpdateWasRequested;
1235
+ var p = this.props.direction, T = this.state, C = T.scrollLeft, x = T.scrollTop, N = T.scrollUpdateWasRequested;
1232
1236
  if (N && this._outerRef != null) {
1233
- var y = this._outerRef;
1237
+ var I = this._outerRef;
1234
1238
  if (p === "rtl")
1235
1239
  switch (Xt()) {
1236
1240
  case "negative":
1237
- y.scrollLeft = -C;
1241
+ I.scrollLeft = -C;
1238
1242
  break;
1239
1243
  case "positive-ascending":
1240
- y.scrollLeft = C;
1244
+ I.scrollLeft = C;
1241
1245
  break;
1242
1246
  default:
1243
- var O = y.clientWidth, R = y.scrollWidth;
1244
- y.scrollLeft = R - O - C;
1247
+ var O = I.clientWidth, R = I.scrollWidth;
1248
+ I.scrollLeft = R - O - C;
1245
1249
  break;
1246
1250
  }
1247
1251
  else
1248
- y.scrollLeft = Math.max(0, C);
1249
- y.scrollTop = Math.max(0, S);
1252
+ I.scrollLeft = Math.max(0, C);
1253
+ I.scrollTop = Math.max(0, x);
1250
1254
  }
1251
1255
  this._callPropsCallbacks();
1252
1256
  }, P.componentWillUnmount = function() {
1253
1257
  this._resetIsScrollingTimeoutId !== null && Kt(this._resetIsScrollingTimeoutId);
1254
1258
  }, P.render = function() {
1255
- var p = this.props, T = p.children, C = p.className, S = p.columnCount, N = p.direction, y = p.height, O = p.innerRef, R = p.innerElementType, k = p.innerTagName, z = p.itemData, I = p.itemKey, E = I === void 0 ? Do : I, W = p.outerElementType, V = p.outerTagName, Z = p.rowCount, Y = p.style, j = p.useIsScrolling, B = p.width, te = this.state.isScrolling, ae = this._getHorizontalRangeToRender(), J = ae[0], ne = ae[1], he = this._getVerticalRangeToRender(), ce = he[0], Oe = he[1], we = [];
1256
- if (S > 0 && Z)
1259
+ var p = this.props, T = p.children, C = p.className, x = p.columnCount, N = p.direction, I = p.height, O = p.innerRef, R = p.innerElementType, k = p.innerTagName, z = p.itemData, y = p.itemKey, E = y === void 0 ? Do : y, W = p.outerElementType, G = p.outerTagName, Z = p.rowCount, X = p.style, j = p.useIsScrolling, B = p.width, te = this.state.isScrolling, ae = this._getHorizontalRangeToRender(), Y = ae[0], ne = ae[1], he = this._getVerticalRangeToRender(), ce = he[0], Oe = he[1], we = [];
1260
+ if (x > 0 && Z)
1257
1261
  for (var me = ce; me <= Oe; me++)
1258
- for (var le = J; le <= ne; le++)
1259
- we.push(Ge(T, {
1262
+ for (var le = Y; le <= ne; le++)
1263
+ we.push(Ve(T, {
1260
1264
  columnIndex: le,
1261
1265
  data: z,
1262
1266
  isScrolling: j ? te : void 0,
@@ -1269,20 +1273,20 @@ function zo(e) {
1269
1273
  style: this._getItemStyle(me, le)
1270
1274
  }));
1271
1275
  var De = c(this.props, this._instanceProps), rt = s(this.props, this._instanceProps);
1272
- return Ge(W || V || "div", {
1276
+ return Ve(W || G || "div", {
1273
1277
  className: C,
1274
1278
  onScroll: this._onScroll,
1275
1279
  ref: this._outerRefSetter,
1276
1280
  style: Ar({
1277
1281
  position: "relative",
1278
- height: y,
1282
+ height: I,
1279
1283
  width: B,
1280
1284
  overflow: "auto",
1281
1285
  WebkitOverflowScrolling: "touch",
1282
1286
  willChange: "transform",
1283
1287
  direction: N
1284
- }, Y)
1285
- }, Ge(R || k || "div", {
1288
+ }, X)
1289
+ }, Ve(R || k || "div", {
1286
1290
  children: we,
1287
1291
  ref: O,
1288
1292
  style: {
@@ -1292,27 +1296,27 @@ function zo(e) {
1292
1296
  }
1293
1297
  }));
1294
1298
  }, P._callPropsCallbacks = function() {
1295
- var p = this.props, T = p.columnCount, C = p.onItemsRendered, S = p.onScroll, N = p.rowCount;
1299
+ var p = this.props, T = p.columnCount, C = p.onItemsRendered, x = p.onScroll, N = p.rowCount;
1296
1300
  if (typeof C == "function" && T > 0 && N > 0) {
1297
- var y = this._getHorizontalRangeToRender(), O = y[0], R = y[1], k = y[2], z = y[3], I = this._getVerticalRangeToRender(), E = I[0], W = I[1], V = I[2], Z = I[3];
1298
- this._callOnItemsRendered(O, R, E, W, k, z, V, Z);
1301
+ var I = this._getHorizontalRangeToRender(), O = I[0], R = I[1], k = I[2], z = I[3], y = this._getVerticalRangeToRender(), E = y[0], W = y[1], G = y[2], Z = y[3];
1302
+ this._callOnItemsRendered(O, R, E, W, k, z, G, Z);
1299
1303
  }
1300
- if (typeof S == "function") {
1301
- var Y = this.state, j = Y.horizontalScrollDirection, B = Y.scrollLeft, te = Y.scrollTop, ae = Y.scrollUpdateWasRequested, J = Y.verticalScrollDirection;
1302
- this._callOnScroll(B, te, j, J, ae);
1304
+ if (typeof x == "function") {
1305
+ var X = this.state, j = X.horizontalScrollDirection, B = X.scrollLeft, te = X.scrollTop, ae = X.scrollUpdateWasRequested, Y = X.verticalScrollDirection;
1306
+ this._callOnScroll(B, te, j, Y, ae);
1303
1307
  }
1304
1308
  }, P._getHorizontalRangeToRender = function() {
1305
- var p = this.props, T = p.columnCount, C = p.overscanColumnCount, S = p.overscanColumnsCount, N = p.overscanCount, y = p.rowCount, O = this.state, R = O.horizontalScrollDirection, k = O.isScrolling, z = O.scrollLeft, I = C || S || N || 1;
1306
- if (T === 0 || y === 0)
1309
+ var p = this.props, T = p.columnCount, C = p.overscanColumnCount, x = p.overscanColumnsCount, N = p.overscanCount, I = p.rowCount, O = this.state, R = O.horizontalScrollDirection, k = O.isScrolling, z = O.scrollLeft, y = C || x || N || 1;
1310
+ if (T === 0 || I === 0)
1307
1311
  return [0, 0, 0, 0];
1308
- var E = o(this.props, z, this._instanceProps), W = r(this.props, E, z, this._instanceProps), V = !k || R === "backward" ? Math.max(1, I) : 1, Z = !k || R === "forward" ? Math.max(1, I) : 1;
1309
- return [Math.max(0, E - V), Math.max(0, Math.min(T - 1, W + Z)), E, W];
1312
+ var E = o(this.props, z, this._instanceProps), W = r(this.props, E, z, this._instanceProps), G = !k || R === "backward" ? Math.max(1, y) : 1, Z = !k || R === "forward" ? Math.max(1, y) : 1;
1313
+ return [Math.max(0, E - G), Math.max(0, Math.min(T - 1, W + Z)), E, W];
1310
1314
  }, P._getVerticalRangeToRender = function() {
1311
- var p = this.props, T = p.columnCount, C = p.overscanCount, S = p.overscanRowCount, N = p.overscanRowsCount, y = p.rowCount, O = this.state, R = O.isScrolling, k = O.verticalScrollDirection, z = O.scrollTop, I = S || N || C || 1;
1312
- if (T === 0 || y === 0)
1315
+ var p = this.props, T = p.columnCount, C = p.overscanCount, x = p.overscanRowCount, N = p.overscanRowsCount, I = p.rowCount, O = this.state, R = O.isScrolling, k = O.verticalScrollDirection, z = O.scrollTop, y = x || N || C || 1;
1316
+ if (T === 0 || I === 0)
1313
1317
  return [0, 0, 0, 0];
1314
- var E = h(this.props, z, this._instanceProps), W = g(this.props, E, z, this._instanceProps), V = !R || k === "backward" ? Math.max(1, I) : 1, Z = !R || k === "forward" ? Math.max(1, I) : 1;
1315
- return [Math.max(0, E - V), Math.max(0, Math.min(y - 1, W + Z)), E, W];
1318
+ var E = h(this.props, z, this._instanceProps), W = g(this.props, E, z, this._instanceProps), G = !R || k === "backward" ? Math.max(1, y) : 1, Z = !R || k === "forward" ? Math.max(1, y) : 1;
1319
+ return [Math.max(0, E - G), Math.max(0, Math.min(I - 1, W + Z)), E, W];
1316
1320
  }, m;
1317
1321
  }(nr), t.defaultProps = {
1318
1322
  direction: "ltr",
@@ -1321,9 +1325,9 @@ function zo(e) {
1321
1325
  }, t;
1322
1326
  }
1323
1327
  var Ao = function(t, n) {
1324
- var o = t.children, r = t.direction, i = t.height, c = t.innerTagName, s = t.outerTagName, l = t.overscanColumnsCount, u = t.overscanCount, d = t.overscanRowsCount, f = t.width, h = n.instance;
1328
+ var o = t.children, r = t.direction, a = t.height, c = t.innerTagName, s = t.outerTagName, l = t.overscanColumnsCount, u = t.overscanCount, d = t.overscanRowsCount, f = t.width, h = n.instance;
1325
1329
  if (process.env.NODE_ENV !== "production") {
1326
- if (typeof u == "number" && Ve && !Ve.has(h) && (Ve.add(h), console.warn("The overscanCount prop has been deprecated. Please use the overscanColumnCount and overscanRowCount props instead.")), (typeof l == "number" || typeof d == "number") && Ue && !Ue.has(h) && (Ue.add(h), console.warn("The overscanColumnsCount and overscanRowsCount props have been deprecated. Please use the overscanColumnCount and overscanRowCount props instead.")), (c != null || s != null) && qe && !qe.has(h) && (qe.add(h), console.warn("The innerTagName and outerTagName props have been deprecated. Please use the innerElementType and outerElementType props instead.")), o == null)
1330
+ if (typeof u == "number" && Ge && !Ge.has(h) && (Ge.add(h), console.warn("The overscanCount prop has been deprecated. Please use the overscanColumnCount and overscanRowCount props instead.")), (typeof l == "number" || typeof d == "number") && Ue && !Ue.has(h) && (Ue.add(h), console.warn("The overscanColumnsCount and overscanRowsCount props have been deprecated. Please use the overscanColumnCount and overscanRowCount props instead.")), (c != null || s != null) && qe && !qe.has(h) && (qe.add(h), console.warn("The innerTagName and outerTagName props have been deprecated. Please use the innerElementType and outerElementType props instead.")), o == null)
1327
1331
  throw Error('An invalid "children" prop has been specified. Value should be a React component. ' + ('"' + (o === null ? "null" : typeof o) + '" was specified.'));
1328
1332
  switch (r) {
1329
1333
  case "ltr":
@@ -1334,63 +1338,63 @@ var Ao = function(t, n) {
1334
1338
  }
1335
1339
  if (typeof f != "number")
1336
1340
  throw Error('An invalid "width" prop has been specified. Grids must specify a number for width. ' + ('"' + (f === null ? "null" : typeof f) + '" was specified.'));
1337
- if (typeof i != "number")
1338
- throw Error('An invalid "height" prop has been specified. Grids must specify a number for height. ' + ('"' + (i === null ? "null" : typeof i) + '" was specified.'));
1341
+ if (typeof a != "number")
1342
+ throw Error('An invalid "height" prop has been specified. Grids must specify a number for height. ' + ('"' + (a === null ? "null" : typeof a) + '" was specified.'));
1339
1343
  }
1340
- }, Yt = 50, yn = function(t, n) {
1341
- var o = t.rowCount, r = n.rowMetadataMap, i = n.estimatedRowHeight, c = n.lastMeasuredRowIndex, s = 0;
1344
+ }, Yt = 50, In = function(t, n) {
1345
+ var o = t.rowCount, r = n.rowMetadataMap, a = n.estimatedRowHeight, c = n.lastMeasuredRowIndex, s = 0;
1342
1346
  if (c >= o && (c = o - 1), c >= 0) {
1343
1347
  var l = r[c];
1344
1348
  s = l.offset + l.size;
1345
1349
  }
1346
- var u = o - c - 1, d = u * i;
1350
+ var u = o - c - 1, d = u * a;
1347
1351
  return s + d;
1348
1352
  }, Ln = function(t, n) {
1349
- var o = t.columnCount, r = n.columnMetadataMap, i = n.estimatedColumnWidth, c = n.lastMeasuredColumnIndex, s = 0;
1353
+ var o = t.columnCount, r = n.columnMetadataMap, a = n.estimatedColumnWidth, c = n.lastMeasuredColumnIndex, s = 0;
1350
1354
  if (c >= o && (c = o - 1), c >= 0) {
1351
1355
  var l = r[c];
1352
1356
  s = l.offset + l.size;
1353
1357
  }
1354
- var u = o - c - 1, d = u * i;
1358
+ var u = o - c - 1, d = u * a;
1355
1359
  return s + d;
1356
1360
  }, ve = function(t, n, o, r) {
1357
- var i, c, s;
1358
- if (t === "column" ? (i = r.columnMetadataMap, c = n.columnWidth, s = r.lastMeasuredColumnIndex) : (i = r.rowMetadataMap, c = n.rowHeight, s = r.lastMeasuredRowIndex), o > s) {
1361
+ var a, c, s;
1362
+ if (t === "column" ? (a = r.columnMetadataMap, c = n.columnWidth, s = r.lastMeasuredColumnIndex) : (a = r.rowMetadataMap, c = n.rowHeight, s = r.lastMeasuredRowIndex), o > s) {
1359
1363
  var l = 0;
1360
1364
  if (s >= 0) {
1361
- var u = i[s];
1365
+ var u = a[s];
1362
1366
  l = u.offset + u.size;
1363
1367
  }
1364
1368
  for (var d = s + 1; d <= o; d++) {
1365
1369
  var f = c(d);
1366
- i[d] = {
1370
+ a[d] = {
1367
1371
  offset: l,
1368
1372
  size: f
1369
1373
  }, l += f;
1370
1374
  }
1371
1375
  t === "column" ? r.lastMeasuredColumnIndex = o : r.lastMeasuredRowIndex = o;
1372
1376
  }
1373
- return i[o];
1377
+ return a[o];
1374
1378
  }, Jt = function(t, n, o, r) {
1375
- var i, c;
1376
- t === "column" ? (i = o.columnMetadataMap, c = o.lastMeasuredColumnIndex) : (i = o.rowMetadataMap, c = o.lastMeasuredRowIndex);
1377
- var s = c > 0 ? i[c].offset : 0;
1379
+ var a, c;
1380
+ t === "column" ? (a = o.columnMetadataMap, c = o.lastMeasuredColumnIndex) : (a = o.rowMetadataMap, c = o.lastMeasuredRowIndex);
1381
+ var s = c > 0 ? a[c].offset : 0;
1378
1382
  return s >= r ? Rn(t, n, o, c, 0, r) : Fo(t, n, o, Math.max(0, c), r);
1379
- }, Rn = function(t, n, o, r, i, c) {
1380
- for (; i <= r; ) {
1381
- var s = i + Math.floor((r - i) / 2), l = ve(t, n, s, o).offset;
1383
+ }, Rn = function(t, n, o, r, a, c) {
1384
+ for (; a <= r; ) {
1385
+ var s = a + Math.floor((r - a) / 2), l = ve(t, n, s, o).offset;
1382
1386
  if (l === c)
1383
1387
  return s;
1384
- l < c ? i = s + 1 : l > c && (r = s - 1);
1388
+ l < c ? a = s + 1 : l > c && (r = s - 1);
1385
1389
  }
1386
- return i > 0 ? i - 1 : 0;
1387
- }, Fo = function(t, n, o, r, i) {
1388
- for (var c = t === "column" ? n.columnCount : n.rowCount, s = 1; r < c && ve(t, n, r, o).offset < i; )
1390
+ return a > 0 ? a - 1 : 0;
1391
+ }, Fo = function(t, n, o, r, a) {
1392
+ for (var c = t === "column" ? n.columnCount : n.rowCount, s = 1; r < c && ve(t, n, r, o).offset < a; )
1389
1393
  r += s, s *= 2;
1390
- return Rn(t, n, o, Math.min(r, c - 1), Math.floor(r / 2), i);
1391
- }, Qt = function(t, n, o, r, i, c, s) {
1392
- var l = t === "column" ? n.width : n.height, u = ve(t, n, o, c), d = t === "column" ? Ln(n, c) : yn(n, c), f = Math.max(0, Math.min(d - l, u.offset)), h = Math.max(0, u.offset - l + s + u.size);
1393
- switch (r === "smart" && (i >= h - l && i <= f + l ? r = "auto" : r = "center"), r) {
1394
+ return Rn(t, n, o, Math.min(r, c - 1), Math.floor(r / 2), a);
1395
+ }, Qt = function(t, n, o, r, a, c, s) {
1396
+ var l = t === "column" ? n.width : n.height, u = ve(t, n, o, c), d = t === "column" ? Ln(n, c) : In(n, c), f = Math.max(0, Math.min(d - l, u.offset)), h = Math.max(0, u.offset - l + s + u.size);
1397
+ switch (r === "smart" && (a >= h - l && a <= f + l ? r = "auto" : r = "center"), r) {
1394
1398
  case "start":
1395
1399
  return f;
1396
1400
  case "end":
@@ -1399,7 +1403,7 @@ var Ao = function(t, n) {
1399
1403
  return Math.round(h + (f - h) / 2);
1400
1404
  case "auto":
1401
1405
  default:
1402
- return i >= h && i <= f ? i : h > f || i < h ? h : f;
1406
+ return a >= h && a <= f ? a : h > f || a < h ? h : f;
1403
1407
  }
1404
1408
  }, ko = /* @__PURE__ */ zo({
1405
1409
  getColumnOffset: function(t, n, o) {
@@ -1409,20 +1413,20 @@ var Ao = function(t, n) {
1409
1413
  return Jt("column", t, o, n);
1410
1414
  },
1411
1415
  getColumnStopIndexForStartIndex: function(t, n, o, r) {
1412
- for (var i = t.columnCount, c = t.width, s = ve("column", t, n, r), l = o + c, u = s.offset + s.size, d = n; d < i - 1 && u < l; )
1416
+ for (var a = t.columnCount, c = t.width, s = ve("column", t, n, r), l = o + c, u = s.offset + s.size, d = n; d < a - 1 && u < l; )
1413
1417
  d++, u += ve("column", t, d, r).size;
1414
1418
  return d;
1415
1419
  },
1416
1420
  getColumnWidth: function(t, n, o) {
1417
1421
  return o.columnMetadataMap[n].size;
1418
1422
  },
1419
- getEstimatedTotalHeight: yn,
1423
+ getEstimatedTotalHeight: In,
1420
1424
  getEstimatedTotalWidth: Ln,
1421
- getOffsetForColumnAndAlignment: function(t, n, o, r, i, c) {
1422
- return Qt("column", t, n, o, r, i, c);
1425
+ getOffsetForColumnAndAlignment: function(t, n, o, r, a, c) {
1426
+ return Qt("column", t, n, o, r, a, c);
1423
1427
  },
1424
- getOffsetForRowAndAlignment: function(t, n, o, r, i, c) {
1425
- return Qt("row", t, n, o, r, i, c);
1428
+ getOffsetForRowAndAlignment: function(t, n, o, r, a, c) {
1429
+ return Qt("row", t, n, o, r, a, c);
1426
1430
  },
1427
1431
  getRowOffset: function(t, n, o) {
1428
1432
  return ve("row", t, n, o).offset;
@@ -1434,15 +1438,15 @@ var Ao = function(t, n) {
1434
1438
  return Jt("row", t, o, n);
1435
1439
  },
1436
1440
  getRowStopIndexForStartIndex: function(t, n, o, r) {
1437
- for (var i = t.rowCount, c = t.height, s = ve("row", t, n, r), l = o + c, u = s.offset + s.size, d = n; d < i - 1 && u < l; )
1441
+ for (var a = t.rowCount, c = t.height, s = ve("row", t, n, r), l = o + c, u = s.offset + s.size, d = n; d < a - 1 && u < l; )
1438
1442
  d++, u += ve("row", t, d, r).size;
1439
1443
  return d;
1440
1444
  },
1441
1445
  initInstanceProps: function(t, n) {
1442
- var o = t, r = o.estimatedColumnWidth, i = o.estimatedRowHeight, c = {
1446
+ var o = t, r = o.estimatedColumnWidth, a = o.estimatedRowHeight, c = {
1443
1447
  columnMetadataMap: {},
1444
1448
  estimatedColumnWidth: r || Yt,
1445
- estimatedRowHeight: i || Yt,
1449
+ estimatedRowHeight: a || Yt,
1446
1450
  lastMeasuredColumnIndex: -1,
1447
1451
  lastMeasuredRowIndex: -1,
1448
1452
  rowMetadataMap: {}
@@ -1485,26 +1489,26 @@ function en(e, t) {
1485
1489
  }
1486
1490
  var Mo = ["style"], Wo = ["style"];
1487
1491
  function Ho(e, t) {
1488
- var n = e.style, o = Bt(e, Mo), r = t.style, i = Bt(t, Wo);
1489
- return !en(n, r) && !en(o, i);
1492
+ var n = e.style, o = Bt(e, Mo), r = t.style, a = Bt(t, Wo);
1493
+ return !en(n, r) && !en(o, a);
1490
1494
  }
1491
1495
  const $o = () => {
1492
- const { viewMode: e } = Qe(), { scrollMode: t } = Ee(), { setColumnCount: n } = un(), { virtualScrollableElementRef: o } = et(), r = tt(), i = L(
1496
+ const { viewMode: e } = Qe(), { scrollMode: t } = Ee(), { setColumnCount: n } = un(), { virtualScrollableElementRef: o } = et(), r = tt(), a = L(
1493
1497
  (g) => r.widths[g] || 0,
1494
1498
  [r.widths]
1495
1499
  ), c = L(
1496
1500
  (g) => r.heights[g] || 0,
1497
1501
  [r.heights]
1498
- ), s = F(() => r.heights.length, [r.heights]), l = F(() => Math.max(...r.widths), [r.widths]), u = F(() => t === X.HORIZONTAL_SCROLLING ? s : e === Ze.DUAL_PAGE ? 2 : 1, [e, t, t, s, o, l]);
1502
+ ), s = F(() => r.heights.length, [r.heights]), l = F(() => Math.max(...r.widths), [r.widths]), u = F(() => t === ee.HORIZONTAL_SCROLLING ? s : e === Ze.DUAL_PAGE ? 2 : 1, [e, t, t, s, o, l]);
1499
1503
  A(() => {
1500
1504
  n(u);
1501
1505
  }, [u, n]);
1502
- const d = F(() => t === X.HORIZONTAL_SCROLLING || t === X.PAGE_SCROLLING ? 1 : Math.round(s / u), [u, s, t]), f = F(() => r.heights.reduce((g, w) => g + w, 0) / r.heights.length || 0, [r]), h = F(() => r.widths.reduce((g, w) => g + w, 0) / r.heights.length || 0, [r]);
1506
+ const d = F(() => t === ee.HORIZONTAL_SCROLLING || t === ee.PAGE_SCROLLING ? 1 : Math.round(s / u), [u, s, t]), f = F(() => r.heights.reduce((g, w) => g + w, 0) / r.heights.length || 0, [r]), h = F(() => r.widths.reduce((g, w) => g + w, 0) / r.heights.length || 0, [r]);
1503
1507
  return {
1504
1508
  rowCount: d,
1505
1509
  rowHeight: c,
1506
1510
  columnCount: u,
1507
- columnWidth: i,
1511
+ columnWidth: a,
1508
1512
  pageDimension: r,
1509
1513
  estimatedRowHeight: f,
1510
1514
  estimatedColumnWidth: h
@@ -1526,21 +1530,21 @@ ft == null || rn == null ? (Ct = mt, Tt = function(t) {
1526
1530
  }, tn);
1527
1531
  return [n, o];
1528
1532
  });
1529
- function Go(e) {
1530
- let t, n, o, r, i, c, s;
1533
+ function Vo(e) {
1534
+ let t, n, o, r, a, c, s;
1531
1535
  const l = typeof document < "u" && document.attachEvent;
1532
1536
  if (!l) {
1533
1537
  c = function(_) {
1534
- const m = _.__resizeTriggers__, P = m.firstElementChild, x = m.lastElementChild, p = P.firstElementChild;
1535
- x.scrollLeft = x.scrollWidth, x.scrollTop = x.scrollHeight, p.style.width = P.offsetWidth + 1 + "px", p.style.height = P.offsetHeight + 1 + "px", P.scrollLeft = P.scrollWidth, P.scrollTop = P.scrollHeight;
1536
- }, i = function(_) {
1538
+ const m = _.__resizeTriggers__, P = m.firstElementChild, S = m.lastElementChild, p = P.firstElementChild;
1539
+ S.scrollLeft = S.scrollWidth, S.scrollTop = S.scrollHeight, p.style.width = P.offsetWidth + 1 + "px", p.style.height = P.offsetHeight + 1 + "px", P.scrollLeft = P.scrollWidth, P.scrollTop = P.scrollHeight;
1540
+ }, a = function(_) {
1537
1541
  return _.offsetWidth !== _.__resizeLast__.width || _.offsetHeight !== _.__resizeLast__.height;
1538
1542
  }, s = function(_) {
1539
1543
  if (_.target.className && typeof _.target.className.indexOf == "function" && _.target.className.indexOf("contract-trigger") < 0 && _.target.className.indexOf("expand-trigger") < 0)
1540
1544
  return;
1541
1545
  const m = this;
1542
1546
  c(this), this.__resizeRAF__ && Ct(this.__resizeRAF__), this.__resizeRAF__ = Tt(function() {
1543
- i(m) && (m.__resizeLast__.width = m.offsetWidth, m.__resizeLast__.height = m.offsetHeight, m.__resizeListeners__.forEach(function(p) {
1547
+ a(m) && (m.__resizeLast__.width = m.offsetWidth, m.__resizeLast__.height = m.offsetHeight, m.__resizeListeners__.forEach(function(p) {
1544
1548
  p.call(m, _);
1545
1549
  }));
1546
1550
  });
@@ -1598,7 +1602,7 @@ function Go(e) {
1598
1602
  }
1599
1603
  };
1600
1604
  }
1601
- class Vo extends rr {
1605
+ class Go extends rr {
1602
1606
  constructor(...t) {
1603
1607
  super(...t), this.state = {
1604
1608
  height: this.props.defaultHeight || 0,
@@ -1613,7 +1617,7 @@ class Vo extends rr {
1613
1617
  onResize: r
1614
1618
  } = this.props;
1615
1619
  if (this._parentNode) {
1616
- const i = window.getComputedStyle(this._parentNode) || {}, c = parseFloat(i.paddingLeft || "0"), s = parseFloat(i.paddingRight || "0"), l = parseFloat(i.paddingTop || "0"), u = parseFloat(i.paddingBottom || "0"), d = this._parentNode.getBoundingClientRect(), f = d.height - l - u, h = d.width - c - s, g = this._parentNode.offsetHeight - l - u, w = this._parentNode.offsetWidth - c - s;
1620
+ const a = window.getComputedStyle(this._parentNode) || {}, c = parseFloat(a.paddingLeft || "0"), s = parseFloat(a.paddingRight || "0"), l = parseFloat(a.paddingTop || "0"), u = parseFloat(a.paddingBottom || "0"), d = this._parentNode.getBoundingClientRect(), f = d.height - l - u, h = d.width - c - s, g = this._parentNode.offsetHeight - l - u, w = this._parentNode.offsetWidth - c - s;
1617
1621
  (!n && (this.state.height !== g || this.state.scaledHeight !== f) || !o && (this.state.width !== w || this.state.scaledWidth !== h)) && (this.setState({
1618
1622
  height: g,
1619
1623
  width: w,
@@ -1639,7 +1643,7 @@ class Vo extends rr {
1639
1643
  const o = n.ownerDocument.defaultView.ResizeObserver;
1640
1644
  o != null ? (this._resizeObserver = new o(() => {
1641
1645
  this._timeoutId = setTimeout(this._onResize, 0);
1642
- }), this._resizeObserver.observe(n)) : (this._detectElementResize = Go(t), this._detectElementResize.addResizeListener(n, this._onResize)), this._onResize();
1646
+ }), this._resizeObserver.observe(n)) : (this._detectElementResize = Vo(t), this._detectElementResize.addResizeListener(n, this._onResize)), this._onResize();
1643
1647
  }
1644
1648
  }
1645
1649
  componentWillUnmount() {
@@ -1651,7 +1655,7 @@ class Vo extends rr {
1651
1655
  defaultHeight: n,
1652
1656
  defaultWidth: o,
1653
1657
  disableHeight: r = !1,
1654
- disableWidth: i = !1,
1658
+ disableWidth: a = !1,
1655
1659
  doNotBailOutOnEmptyChildren: c = !1,
1656
1660
  nonce: s,
1657
1661
  onResize: l,
@@ -1667,7 +1671,7 @@ class Vo extends rr {
1667
1671
  overflow: "visible"
1668
1672
  }, _ = {};
1669
1673
  let m = !1;
1670
- return r || (h === 0 && (m = !0), v.height = 0, _.height = h, _.scaledHeight = g), i || (b === 0 && (m = !0), v.width = 0, _.width = b, _.scaledWidth = w), c && (m = !1), Ge(d, {
1674
+ return r || (h === 0 && (m = !0), v.height = 0, _.height = h, _.scaledHeight = g), a || (b === 0 && (m = !0), v.width = 0, _.width = b, _.scaledWidth = w), c && (m = !1), Ve(d, {
1671
1675
  ref: this._setRef,
1672
1676
  style: {
1673
1677
  ...v,
@@ -1685,7 +1689,7 @@ const Uo = ({ widths: e, heights: t }) => {
1685
1689
  s.push(u);
1686
1690
  }
1687
1691
  return s;
1688
- }, [n, o]), i = F(() => [
1692
+ }, [n, o]), a = F(() => [
1689
1693
  {
1690
1694
  position: "absolute",
1691
1695
  left: 0,
@@ -1699,27 +1703,27 @@ const Uo = ({ widths: e, heights: t }) => {
1699
1703
  width: e(n),
1700
1704
  height: t(n)
1701
1705
  }
1702
- ], [e, t, r]), c = F(() => i.reduce((s, l) => s + Number(l.width || 0), 0), [i]);
1703
- return /* @__PURE__ */ a("div", { style: { width: c, position: "relative" }, children: r.map((s, l) => /* @__PURE__ */ a(Nt, { style: i[l], pageNumber: s }, s)) });
1706
+ ], [e, t, r]), c = F(() => a.reduce((s, l) => s + Number(l.width || 0), 0), [a]);
1707
+ return /* @__PURE__ */ i("div", { style: { width: c, position: "relative" }, children: r.map((s, l) => /* @__PURE__ */ i(Nt, { style: a[l], pageNumber: s }, s)) });
1704
1708
  }, qo = ({ widths: e, heights: t }) => {
1705
1709
  const { focusedPage: n } = ie(), o = F(() => ({
1706
1710
  position: "absolute",
1707
1711
  width: e(n - 1),
1708
1712
  height: t(n - 1)
1709
1713
  }), [e, t, n]), r = F(() => e(n - 1), [e]);
1710
- return /* @__PURE__ */ a(
1714
+ return /* @__PURE__ */ i(
1711
1715
  "div",
1712
1716
  {
1713
1717
  style: {
1714
1718
  width: r,
1715
1719
  position: "relative"
1716
1720
  },
1717
- children: /* @__PURE__ */ a(Nt, { style: o, pageNumber: n }, n)
1721
+ children: /* @__PURE__ */ i(Nt, { style: o, pageNumber: n }, n)
1718
1722
  }
1719
1723
  );
1720
1724
  }, Zo = (e, t, n) => {
1721
- const o = M(), { contentRef: r } = Te(), { heights: i, widths: c } = tt(), { setFocusedPage: s } = ie(), [l, u] = $([]), { smoothScrolling: d } = xt(), f = It(l, 100, 500), h = F(() => i.map((w, b) => {
1722
- const v = c[b], _ = Hr(b + 1, e), m = v * _.columnIndex, P = w * _.rowIndex, x = m + v, p = P + w;
1725
+ const o = M(), { contentRef: r } = Te(), { heights: a, widths: c } = tt(), { setFocusedPage: s } = ie(), [l, u] = $([]), { smoothScrolling: d } = St(), f = yt(l, 0, 500), h = F(() => a.map((w, b) => {
1726
+ const v = c[b], _ = Hr(b + 1, e), m = v * _.columnIndex, P = w * _.rowIndex, S = m + v, p = P + w;
1723
1727
  return {
1724
1728
  pageNumber: b + 1,
1725
1729
  ..._,
@@ -1727,10 +1731,10 @@ const Uo = ({ widths: e, heights: t }) => {
1727
1731
  height: w,
1728
1732
  startX: m,
1729
1733
  startY: P,
1730
- endX: x,
1734
+ endX: S,
1731
1735
  endY: p
1732
1736
  };
1733
- }), [i, c, e, t]);
1737
+ }), [a, c, e, t]);
1734
1738
  A(() => {
1735
1739
  f.length > 0 && !d.current && s(f[0].pageNumber);
1736
1740
  }, [f, s]);
@@ -1743,13 +1747,13 @@ const Uo = ({ widths: e, heights: t }) => {
1743
1747
  endTop: b.scrollTop + b.clientHeight,
1744
1748
  endLeft: b.scrollLeft + b.clientWidth
1745
1749
  }, _ = h.filter((m) => {
1746
- const P = m.endX >= v.startLeft && m.endY >= v.startTop, x = m.startX <= v.endLeft && m.startY <= v.endTop;
1747
- return P && x;
1750
+ const P = m.endX >= v.startLeft && m.endY >= v.startTop, S = m.startX <= v.endLeft && m.startY <= v.endTop;
1751
+ return P && S;
1748
1752
  }).map((m) => {
1749
- const P = v.startLeft > m.startX ? v.startLeft : m.startX, x = v.startTop > m.startY ? v.startTop : m.startY, p = v.endLeft < m.endX ? v.endLeft : m.endX, T = v.endTop < m.endY ? v.endTop : m.endY, C = p - P, S = T - x, y = +(C * S / (m.width * m.height) * 100).toFixed(2);
1753
+ const P = v.startLeft > m.startX ? v.startLeft : m.startX, S = v.startTop > m.startY ? v.startTop : m.startY, p = v.endLeft < m.endX ? v.endLeft : m.endX, T = v.endTop < m.endY ? v.endTop : m.endY, C = p - P, x = T - S, I = +(C * x / (m.width * m.height) * 100).toFixed(2);
1750
1754
  return {
1751
1755
  pageNumber: m.pageNumber,
1752
- ratio: y
1756
+ ratio: I
1753
1757
  };
1754
1758
  }).sort((m, P) => P.ratio - m.ratio);
1755
1759
  u(_);
@@ -1765,10 +1769,10 @@ const Uo = ({ widths: e, heights: t }) => {
1765
1769
  }, [n, g]);
1766
1770
  }, Bo = or(({ columnIndex: e, rowIndex: t, data: n, style: o }) => {
1767
1771
  const r = $r(t, e, n.columnCount);
1768
- return /* @__PURE__ */ a(Nt, { style: o, pageNumber: r }, r);
1772
+ return /* @__PURE__ */ i(Nt, { style: o, pageNumber: r }, r);
1769
1773
  }, Ho), Is = () => {
1770
1774
  const { initialPage: e = 1, initialScrollMode: t } = lr(), { pagesRef: n, setPagesRef: o } = Te(), { scrollToPage: r } = bn(), {
1771
- virtualScrollRef: i,
1775
+ virtualScrollRef: a,
1772
1776
  getVirtualScrollRef: c,
1773
1777
  getPageScrollElementRef: s,
1774
1778
  getVirtualScrollableElementRef: l,
@@ -1776,54 +1780,54 @@ const Uo = ({ widths: e, heights: t }) => {
1776
1780
  virtualScrollableElementRef: d,
1777
1781
  totalInnerDimensions: f,
1778
1782
  pageScrollElementRef: h
1779
- } = et(), g = M(!0), { nextPage: w, prevPage: b, setFocusedPage: v, focusedPage: _ } = ie(), { scrollMode: m } = Ee(), { viewMode: P } = Qe(), x = M(null), { loading: p } = K(), { LoaderImageComponent: T } = mn(), { smoothScrolling: C, targetScrollPosition: S } = xt(), N = M(
1783
+ } = et(), g = M(!0), { nextPage: w, prevPage: b, setFocusedPage: v, focusedPage: _ } = ie(), { scrollMode: m } = Ee(), { viewMode: P } = Qe(), S = M(null), { loading: p } = K(), { LoaderImageComponent: T } = mn(), { smoothScrolling: C, targetScrollPosition: x } = St(), N = M(
1780
1784
  f
1781
- ), y = M({
1785
+ ), I = M({
1782
1786
  viewMode: P,
1783
1787
  scrollMode: m
1784
1788
  }), O = M(!1), R = M(), { isFullScreen: k } = dr(), {
1785
1789
  pageDimension: z,
1786
- rowCount: I,
1790
+ rowCount: y,
1787
1791
  rowHeight: E,
1788
1792
  columnCount: W,
1789
- columnWidth: V,
1793
+ columnWidth: G,
1790
1794
  estimatedColumnWidth: Z,
1791
- estimatedRowHeight: Y
1792
- } = $o(), j = It(f, 100), B = M();
1793
- Zo(W, I, d);
1795
+ estimatedRowHeight: X
1796
+ } = $o(), j = yt(f, 100), B = M();
1797
+ Zo(W, y, d);
1794
1798
  const te = M({
1795
1799
  scrollTop: 0,
1796
1800
  scrollLeft: 0
1797
1801
  });
1798
1802
  Wr(n);
1799
- const { isPressed: ae } = kr(), { selectionMode: J } = cr(), { initializeGrabScroll: ne, resetGrabState: he } = Mr({
1803
+ const { isPressed: ae } = kr(), { selectionMode: Y } = cr(), { initializeGrabScroll: ne, resetGrabState: he } = Mr({
1800
1804
  isPressed: ae
1801
- }), ce = F(() => J === ar.HAND, [J]), Oe = F(() => ({
1805
+ }), ce = F(() => Y === ar.HAND, [Y]), Oe = F(() => ({
1802
1806
  columnCount: W
1803
1807
  }), [W]), we = L(
1804
1808
  (H) => {
1805
- const G = document.activeElement !== n;
1806
- !k && G || (["ArrowUp", "ArrowLeft"].includes(H.key) ? (H.preventDefault(), b()) : ["ArrowDown", "ArrowRight"].includes(H.key) && (H.preventDefault(), w()));
1809
+ const V = document.activeElement !== n;
1810
+ !k && V || (["ArrowUp", "ArrowLeft"].includes(H.key) ? (H.preventDefault(), b()) : ["ArrowDown", "ArrowRight"].includes(H.key) && (H.preventDefault(), w()));
1807
1811
  },
1808
1812
  [w, b, k, m]
1809
1813
  );
1810
1814
  A(() => (window.addEventListener("keydown", we), () => {
1811
1815
  window.removeEventListener("keydown", we);
1812
1816
  }), [we]), A(() => {
1813
- if (x.current && (x.current.style.position = "relative"), !!i)
1814
- for (let H = 0; H < I; H++)
1815
- for (let G = 0; G < W; G++)
1816
- i.resetAfterIndices({
1817
- columnIndex: G,
1817
+ if (S.current && (S.current.style.position = "relative"), !!a)
1818
+ for (let H = 0; H < y; H++)
1819
+ for (let V = 0; V < W; V++)
1820
+ a.resetAfterIndices({
1821
+ columnIndex: V,
1818
1822
  rowIndex: H,
1819
1823
  shouldForceUpdate: !0
1820
1824
  });
1821
- }, [I, W, z, i]);
1825
+ }, [y, W, z, a]);
1822
1826
  const me = L(
1823
- (H, G) => {
1827
+ (H, V) => {
1824
1828
  if (!d)
1825
1829
  return { scrollTop: 0, scrollLeft: 0 };
1826
- const fe = te.current.scrollTop > G, ge = te.current.scrollLeft > H;
1830
+ const fe = te.current.scrollTop > V, ge = te.current.scrollLeft > H;
1827
1831
  return fe || ge ? te.current : {
1828
1832
  scrollTop: d.scrollTop,
1829
1833
  scrollLeft: d.scrollLeft
@@ -1831,58 +1835,58 @@ const Uo = ({ widths: e, heights: t }) => {
1831
1835
  },
1832
1836
  [d]
1833
1837
  ), le = L(
1834
- (H, G) => {
1835
- if (y.current.viewMode !== P || y.current.scrollMode !== m) {
1838
+ (H, V) => {
1839
+ if (I.current.viewMode !== P || I.current.scrollMode !== m) {
1836
1840
  B.current && clearTimeout(B.current), O.current = !0, r(_, "auto"), B.current = setTimeout(() => {
1837
1841
  requestAnimationFrame(() => {
1838
- y.current = { viewMode: P, scrollMode: m };
1842
+ I.current = { viewMode: P, scrollMode: m };
1839
1843
  });
1840
1844
  }, 100);
1841
1845
  return;
1842
1846
  }
1843
1847
  const ge = H.scrollTop, ze = H.scrollLeft;
1844
- if (!G.height || !G.width)
1848
+ if (!V.height || !V.width)
1845
1849
  return;
1846
1850
  O.current = !0;
1847
- const { height: Pe, width: ot } = G, { height: At, width: Ft } = N.current;
1851
+ const { height: Pe, width: ot } = V, { height: At, width: Ft } = N.current;
1848
1852
  if (At === Pe && Ft === ot)
1849
1853
  return;
1850
1854
  const Jn = ge / At * Pe, Qn = ze / Ft * ot, er = Math.round(Math.min(Jn, Pe)) || 0, tr = Math.round(Math.min(Qn, ot)) || 0;
1851
1855
  R.current = setTimeout(() => {
1852
1856
  requestAnimationFrame(() => {
1853
- i == null || i.scrollTo({
1857
+ a == null || a.scrollTo({
1854
1858
  scrollTop: er,
1855
1859
  scrollLeft: tr
1856
1860
  });
1857
1861
  });
1858
1862
  }, 0), N.current = {
1859
- height: G.height,
1860
- width: G.width
1863
+ height: V.height,
1864
+ width: V.width
1861
1865
  };
1862
1866
  },
1863
- [i, P, m, r]
1867
+ [a, P, m, r]
1864
1868
  );
1865
1869
  A(() => {
1866
1870
  clearTimeout(R.current);
1867
- const H = Array.from({ length: I }).reduce(
1871
+ const H = Array.from({ length: y }).reduce(
1868
1872
  (ge, ze, Pe) => ge + E(Pe),
1869
1873
  0
1870
- ), G = Array.from({ length: W }).reduce(
1871
- (ge, ze, Pe) => ge + V(Pe),
1874
+ ), V = Array.from({ length: W }).reduce(
1875
+ (ge, ze, Pe) => ge + G(Pe),
1872
1876
  0
1873
- ), fe = me(G, H);
1874
- te.current = fe, le(fe, { height: H, width: G }), u({
1877
+ ), fe = me(V, H);
1878
+ te.current = fe, le(fe, { height: H, width: V }), u({
1875
1879
  height: H,
1876
- width: G
1880
+ width: V
1877
1881
  });
1878
- }, [z, I, W, le]);
1882
+ }, [z, y, W, le]);
1879
1883
  const De = L(
1880
1884
  (H) => {
1881
1885
  te.current = {
1882
1886
  scrollTop: H.scrollTop,
1883
1887
  scrollLeft: H.scrollLeft
1884
1888
  };
1885
- const G = ((d == null ? void 0 : d.scrollHeight) || 0) - ((d == null ? void 0 : d.clientHeight) || 0), fe = ((d == null ? void 0 : d.scrollWidth) || 0) - ((d == null ? void 0 : d.clientWidth) || 0), ge = Math.round(S.current.left) === Math.round(H.scrollLeft) && Math.round(S.current.top) === Math.round(H.scrollTop), ze = Math.round(G) === Math.round(H.scrollTop) && Math.round(fe) === Math.round(H.scrollLeft);
1889
+ const V = ((d == null ? void 0 : d.scrollHeight) || 0) - ((d == null ? void 0 : d.clientHeight) || 0), fe = ((d == null ? void 0 : d.scrollWidth) || 0) - ((d == null ? void 0 : d.clientWidth) || 0), ge = Math.round(x.current.left) === Math.round(H.scrollLeft) && Math.round(x.current.top) === Math.round(H.scrollTop), ze = Math.round(V) === Math.round(H.scrollTop) && Math.round(fe) === Math.round(H.scrollLeft);
1886
1890
  (ge || ze) && (C.current = !1);
1887
1891
  },
1888
1892
  [d]
@@ -1896,7 +1900,7 @@ const Uo = ({ widths: e, heights: t }) => {
1896
1900
  }), [ce, ae]), Yn = L(
1897
1901
  (H) => {
1898
1902
  if (ce && H) {
1899
- const G = re(de["rp-pages"]), fe = document.querySelector(`.${G}`);
1903
+ const V = re(de["rp-pages"]), fe = document.querySelector(`.${V}`);
1900
1904
  ne(fe);
1901
1905
  }
1902
1906
  },
@@ -1906,67 +1910,49 @@ const Uo = ({ widths: e, heights: t }) => {
1906
1910
  p && he();
1907
1911
  }, [p]), A(() => {
1908
1912
  if (!(j.height === 0 || !g.current)) {
1909
- if (t === X.PAGE_SCROLLING) {
1913
+ if (t === ee.PAGE_SCROLLING) {
1910
1914
  e !== _ && h && v(e), g.current = !1;
1911
1915
  return;
1912
1916
  }
1913
- if (i != null && i.scrollToItem) {
1914
- switch (t) {
1915
- case X.HORIZONTAL_SCROLLING:
1916
- i.scrollToItem({
1917
- columnIndex: e - 1,
1918
- rowIndex: 0,
1919
- align: "start"
1920
- });
1921
- break;
1922
- default:
1923
- i.scrollToItem({
1924
- columnIndex: 0,
1925
- rowIndex: e - 1,
1926
- align: "start"
1927
- });
1928
- break;
1929
- }
1930
- v(e), g.current = !1;
1931
- }
1917
+ r(e, "auto"), v(e), g.current = !1;
1932
1918
  }
1933
1919
  }, [
1934
- i,
1920
+ r,
1935
1921
  t,
1936
1922
  h,
1937
1923
  v,
1938
1924
  j
1939
- ]), /* @__PURE__ */ a("div", { ref: o, tabIndex: -1, className: rt, children: /* @__PURE__ */ a(Vo, { style: { minHeight: "50px" }, children: ({ width: H, height: G }) => /* @__PURE__ */ a("div", { "data-rp": "pages", ref: Yn, style: { width: H, height: G }, children: m === X.PAGE_SCROLLING ? /* @__PURE__ */ a(
1925
+ ]), /* @__PURE__ */ i("div", { ref: o, tabIndex: -1, className: rt, children: /* @__PURE__ */ i(Go, { style: { minHeight: "50px" }, children: ({ width: H, height: V }) => /* @__PURE__ */ i("div", { "data-rp": "pages", ref: Yn, style: { width: H, height: V }, children: m === ee.PAGE_SCROLLING ? /* @__PURE__ */ i(
1940
1926
  "div",
1941
1927
  {
1942
1928
  ref: s,
1943
- style: { width: H, height: G },
1929
+ style: { width: H, height: V },
1944
1930
  className: re(de["rp-pages"], de["rp-page-scrolling-wrapper"]),
1945
- children: P === Ze.DUAL_PAGE ? /* @__PURE__ */ a(Uo, { widths: V, heights: E }) : /* @__PURE__ */ a(qo, { widths: V, heights: E })
1931
+ children: P === Ze.DUAL_PAGE ? /* @__PURE__ */ i(Uo, { widths: G, heights: E }) : /* @__PURE__ */ i(qo, { widths: G, heights: E })
1946
1932
  }
1947
- ) : Z ? /* @__PURE__ */ a(
1933
+ ) : Z ? /* @__PURE__ */ i(
1948
1934
  ko,
1949
1935
  {
1950
1936
  ref: c,
1951
1937
  itemData: Oe,
1952
1938
  outerRef: l,
1953
- innerRef: x,
1939
+ innerRef: S,
1954
1940
  onScroll: De,
1955
1941
  columnCount: W,
1956
- columnWidth: V,
1942
+ columnWidth: G,
1957
1943
  rowHeight: E,
1958
- height: G,
1944
+ height: V,
1959
1945
  width: H,
1960
1946
  estimatedColumnWidth: Z,
1961
- estimatedRowHeight: Y,
1962
- rowCount: I,
1947
+ estimatedRowHeight: X,
1948
+ rowCount: y,
1963
1949
  className: re(
1964
1950
  de["rp-pages"],
1965
- m === X.HORIZONTAL_SCROLLING ? de["rp-pages-horizontal-scroll"] : ""
1951
+ m === ee.HORIZONTAL_SCROLLING ? de["rp-pages-horizontal-scroll"] : ""
1966
1952
  ),
1967
1953
  children: Bo
1968
1954
  }
1969
- ) : p ? null : /* @__PURE__ */ a(
1955
+ ) : p ? null : /* @__PURE__ */ i(
1970
1956
  "div",
1971
1957
  {
1972
1958
  className: de["rp-loader"],
@@ -1977,7 +1963,7 @@ const Uo = ({ widths: e, heights: t }) => {
1977
1963
  height: "100%",
1978
1964
  width: "100%"
1979
1965
  },
1980
- children: T && /* @__PURE__ */ a(T, {})
1966
+ children: T && /* @__PURE__ */ i(T, {})
1981
1967
  }
1982
1968
  ) }) }) });
1983
1969
  }, Ae = {
@@ -1992,12 +1978,12 @@ const Uo = ({ widths: e, heights: t }) => {
1992
1978
  "rp-total-page": "_rp-total-page_1y9vo_11"
1993
1979
  }, jo = () => {
1994
1980
  const { prevIcon: e } = pe();
1995
- return e || /* @__PURE__ */ a(Me, {});
1981
+ return e || /* @__PURE__ */ i(Me, {});
1996
1982
  }, Ko = () => {
1997
1983
  const { nextIcon: e } = pe();
1998
- return e || /* @__PURE__ */ a(Me, { style: { transform: "rotate(180deg" } });
1984
+ return e || /* @__PURE__ */ i(Me, { style: { transform: "rotate(180deg" } });
1999
1985
  }, Xo = () => {
2000
- const { focusedPage: e, totalPages: t, setFocusedPage: n, nextPage: o, prevPage: r, goToPage: i } = ie(), [c, s] = $(e.toString()), { pageNavigationTool: l = !0 } = _e(), { isSmallScreen: u } = ye(), { localeMessages: d } = ue();
1986
+ const { focusedPage: e, totalPages: t, setFocusedPage: n, nextPage: o, prevPage: r, goToPage: a } = ie(), [c, s] = $(e.toString()), { pageNavigationTool: l = !0 } = _e(), { isSmallScreen: u } = Ie(), { localeMessages: d } = ue();
2001
1987
  A(() => {
2002
1988
  s(e.toString());
2003
1989
  }, [e]);
@@ -2005,9 +1991,9 @@ const Uo = ({ widths: e, heights: t }) => {
2005
1991
  const v = b.target.value;
2006
1992
  s(v);
2007
1993
  }, []), h = L(async () => {
2008
- const b = i(c);
1994
+ const b = a(c);
2009
1995
  b.success || s(b.currentPage.toString());
2010
- }, [i, c, t]), g = L(() => {
1996
+ }, [a, c, t]), g = L(() => {
2011
1997
  s(e.toString());
2012
1998
  }, [e]), w = L(
2013
1999
  (b) => {
@@ -2015,27 +2001,27 @@ const Uo = ({ widths: e, heights: t }) => {
2015
2001
  },
2016
2002
  [h]
2017
2003
  );
2018
- return typeof l != "boolean" ? /* @__PURE__ */ a(
2004
+ return typeof l != "boolean" ? /* @__PURE__ */ i(
2019
2005
  l,
2020
2006
  {
2021
2007
  total: t,
2022
2008
  current: e,
2023
2009
  nextPage: o,
2024
2010
  prevPage: r,
2025
- goToPage: i,
2011
+ goToPage: a,
2026
2012
  changePage: n
2027
2013
  }
2028
2014
  ) : l ? /* @__PURE__ */ D("div", { className: gt["rp-paginate"], children: [
2029
- !u && /* @__PURE__ */ a(q, { content: d == null ? void 0 : d.previousPageTooltip, children: /* @__PURE__ */ a(
2030
- ee,
2015
+ !u && /* @__PURE__ */ i(q, { content: d == null ? void 0 : d.previousPageTooltip, children: /* @__PURE__ */ i(
2016
+ Q,
2031
2017
  {
2032
2018
  onClick: r,
2033
2019
  "aria-label": d == null ? void 0 : d.previousPageTooltip,
2034
2020
  "aria-disabled": e === 1,
2035
- children: /* @__PURE__ */ a(jo, {})
2021
+ children: /* @__PURE__ */ i(jo, {})
2036
2022
  }
2037
2023
  ) }),
2038
- /* @__PURE__ */ a(q, { content: d == null ? void 0 : d.currentPageTooltip, children: /* @__PURE__ */ a(
2024
+ /* @__PURE__ */ i(q, { content: d == null ? void 0 : d.currentPageTooltip, children: /* @__PURE__ */ i(
2039
2025
  dn,
2040
2026
  {
2041
2027
  onKeyDown: w,
@@ -2049,31 +2035,31 @@ const Uo = ({ widths: e, heights: t }) => {
2049
2035
  "/",
2050
2036
  t
2051
2037
  ] }),
2052
- !u && /* @__PURE__ */ a(q, { content: d == null ? void 0 : d.nextPageTooltip, children: /* @__PURE__ */ a(
2053
- ee,
2038
+ !u && /* @__PURE__ */ i(q, { content: d == null ? void 0 : d.nextPageTooltip, children: /* @__PURE__ */ i(
2039
+ Q,
2054
2040
  {
2055
2041
  onClick: o,
2056
2042
  "aria-label": d == null ? void 0 : d.nextPageTooltip,
2057
2043
  "aria-disabled": e === t,
2058
- children: /* @__PURE__ */ a(Ko, {})
2044
+ children: /* @__PURE__ */ i(Ko, {})
2059
2045
  }
2060
2046
  ) })
2061
2047
  ] }) : null;
2062
2048
  };
2063
- var Et = "Dialog", [Nn, ys] = qr(Et), [Yo, se] = Nn(Et), En = (e) => {
2049
+ var Et = "Dialog", [Nn, Ls] = Zr(Et), [Yo, se] = Nn(Et), En = (e) => {
2064
2050
  const {
2065
2051
  __scopeDialog: t,
2066
2052
  children: n,
2067
2053
  open: o,
2068
2054
  defaultOpen: r,
2069
- onOpenChange: i,
2055
+ onOpenChange: a,
2070
2056
  modal: c = !0
2071
2057
  } = e, s = U.useRef(null), l = U.useRef(null), [u = !1, d] = jr({
2072
2058
  prop: o,
2073
2059
  defaultProp: r,
2074
- onChange: i
2060
+ onChange: a
2075
2061
  });
2076
- return /* @__PURE__ */ a(
2062
+ return /* @__PURE__ */ i(
2077
2063
  Yo,
2078
2064
  {
2079
2065
  scope: t,
@@ -2093,8 +2079,8 @@ var Et = "Dialog", [Nn, ys] = qr(Et), [Yo, se] = Nn(Et), En = (e) => {
2093
2079
  En.displayName = Et;
2094
2080
  var On = "DialogTrigger", Jo = U.forwardRef(
2095
2081
  (e, t) => {
2096
- const { __scopeDialog: n, ...o } = e, r = se(On, n), i = yt(t, r.triggerRef);
2097
- return /* @__PURE__ */ a(
2082
+ const { __scopeDialog: n, ...o } = e, r = se(On, n), a = It(t, r.triggerRef);
2083
+ return /* @__PURE__ */ i(
2098
2084
  He.button,
2099
2085
  {
2100
2086
  type: "button",
@@ -2103,7 +2089,7 @@ var On = "DialogTrigger", Jo = U.forwardRef(
2103
2089
  "aria-controls": r.contentId,
2104
2090
  "data-state": zt(r.open),
2105
2091
  ...o,
2106
- ref: i,
2092
+ ref: a,
2107
2093
  onClick: ke(e.onClick, r.onOpenToggle)
2108
2094
  }
2109
2095
  );
@@ -2113,14 +2099,14 @@ Jo.displayName = On;
2113
2099
  var Ot = "DialogPortal", [Qo, Dn] = Nn(Ot, {
2114
2100
  forceMount: void 0
2115
2101
  }), zn = (e) => {
2116
- const { __scopeDialog: t, forceMount: n, children: o, container: r } = e, i = se(Ot, t);
2117
- return /* @__PURE__ */ a(Qo, { scope: t, forceMount: n, children: U.Children.map(o, (c) => /* @__PURE__ */ a(Lt, { present: n || i.open, children: /* @__PURE__ */ a(Qr, { asChild: !0, container: r, children: c }) })) });
2102
+ const { __scopeDialog: t, forceMount: n, children: o, container: r } = e, a = se(Ot, t);
2103
+ return /* @__PURE__ */ i(Qo, { scope: t, forceMount: n, children: U.Children.map(o, (c) => /* @__PURE__ */ i(Lt, { present: n || a.open, children: /* @__PURE__ */ i(Qr, { asChild: !0, container: r, children: c }) })) });
2118
2104
  };
2119
2105
  zn.displayName = Ot;
2120
2106
  var je = "DialogOverlay", An = U.forwardRef(
2121
2107
  (e, t) => {
2122
- const n = Dn(je, e.__scopeDialog), { forceMount: o = n.forceMount, ...r } = e, i = se(je, e.__scopeDialog);
2123
- return i.modal ? /* @__PURE__ */ a(Lt, { present: o || i.open, children: /* @__PURE__ */ a(ei, { ...r, ref: t }) }) : null;
2108
+ const n = Dn(je, e.__scopeDialog), { forceMount: o = n.forceMount, ...r } = e, a = se(je, e.__scopeDialog);
2109
+ return a.modal ? /* @__PURE__ */ i(Lt, { present: o || a.open, children: /* @__PURE__ */ i(ei, { ...r, ref: t }) }) : null;
2124
2110
  }
2125
2111
  );
2126
2112
  An.displayName = je;
@@ -2130,7 +2116,7 @@ var ei = U.forwardRef(
2130
2116
  return (
2131
2117
  // Make sure `Content` is scrollable even when it doesn't live inside `RemoveScroll`
2132
2118
  // ie. when `Overlay` and `Content` are siblings
2133
- /* @__PURE__ */ a(Xr, { as: Zr, allowPinchZoom: !0, shards: [r.contentRef], children: /* @__PURE__ */ a(
2119
+ /* @__PURE__ */ i(Kr, { as: qr, allowPinchZoom: !0, shards: [r.contentRef], children: /* @__PURE__ */ i(
2134
2120
  He.div,
2135
2121
  {
2136
2122
  "data-state": zt(r.open),
@@ -2141,79 +2127,79 @@ var ei = U.forwardRef(
2141
2127
  ) })
2142
2128
  );
2143
2129
  }
2144
- ), Ie = "DialogContent", Fn = U.forwardRef(
2130
+ ), ye = "DialogContent", Fn = U.forwardRef(
2145
2131
  (e, t) => {
2146
- const n = Dn(Ie, e.__scopeDialog), { forceMount: o = n.forceMount, ...r } = e, i = se(Ie, e.__scopeDialog);
2147
- return /* @__PURE__ */ a(Lt, { present: o || i.open, children: i.modal ? /* @__PURE__ */ a(ti, { ...r, ref: t }) : /* @__PURE__ */ a(ni, { ...r, ref: t }) });
2132
+ const n = Dn(ye, e.__scopeDialog), { forceMount: o = n.forceMount, ...r } = e, a = se(ye, e.__scopeDialog);
2133
+ return /* @__PURE__ */ i(Lt, { present: o || a.open, children: a.modal ? /* @__PURE__ */ i(ti, { ...r, ref: t }) : /* @__PURE__ */ i(ni, { ...r, ref: t }) });
2148
2134
  }
2149
2135
  );
2150
- Fn.displayName = Ie;
2136
+ Fn.displayName = ye;
2151
2137
  var ti = U.forwardRef(
2152
2138
  (e, t) => {
2153
- const n = se(Ie, e.__scopeDialog), o = U.useRef(null), r = yt(t, n.contentRef, o);
2139
+ const n = se(ye, e.__scopeDialog), o = U.useRef(null), r = It(t, n.contentRef, o);
2154
2140
  return U.useEffect(() => {
2155
- const i = o.current;
2156
- if (i)
2157
- return eo(i);
2158
- }, []), /* @__PURE__ */ a(
2141
+ const a = o.current;
2142
+ if (a)
2143
+ return eo(a);
2144
+ }, []), /* @__PURE__ */ i(
2159
2145
  kn,
2160
2146
  {
2161
2147
  ...e,
2162
2148
  ref: r,
2163
2149
  trapFocus: n.open,
2164
2150
  disableOutsidePointerEvents: !0,
2165
- onCloseAutoFocus: ke(e.onCloseAutoFocus, (i) => {
2151
+ onCloseAutoFocus: ke(e.onCloseAutoFocus, (a) => {
2166
2152
  var c;
2167
- i.preventDefault(), (c = n.triggerRef.current) == null || c.focus();
2153
+ a.preventDefault(), (c = n.triggerRef.current) == null || c.focus();
2168
2154
  }),
2169
- onPointerDownOutside: ke(e.onPointerDownOutside, (i) => {
2170
- const c = i.detail.originalEvent, s = c.button === 0 && c.ctrlKey === !0;
2171
- (c.button === 2 || s) && i.preventDefault();
2155
+ onPointerDownOutside: ke(e.onPointerDownOutside, (a) => {
2156
+ const c = a.detail.originalEvent, s = c.button === 0 && c.ctrlKey === !0;
2157
+ (c.button === 2 || s) && a.preventDefault();
2172
2158
  }),
2173
2159
  onFocusOutside: ke(
2174
2160
  e.onFocusOutside,
2175
- (i) => i.preventDefault()
2161
+ (a) => a.preventDefault()
2176
2162
  )
2177
2163
  }
2178
2164
  );
2179
2165
  }
2180
2166
  ), ni = U.forwardRef(
2181
2167
  (e, t) => {
2182
- const n = se(Ie, e.__scopeDialog), o = U.useRef(!1), r = U.useRef(!1);
2183
- return /* @__PURE__ */ a(
2168
+ const n = se(ye, e.__scopeDialog), o = U.useRef(!1), r = U.useRef(!1);
2169
+ return /* @__PURE__ */ i(
2184
2170
  kn,
2185
2171
  {
2186
2172
  ...e,
2187
2173
  ref: t,
2188
2174
  trapFocus: !1,
2189
2175
  disableOutsidePointerEvents: !1,
2190
- onCloseAutoFocus: (i) => {
2176
+ onCloseAutoFocus: (a) => {
2191
2177
  var c, s;
2192
- (c = e.onCloseAutoFocus) == null || c.call(e, i), i.defaultPrevented || (o.current || (s = n.triggerRef.current) == null || s.focus(), i.preventDefault()), o.current = !1, r.current = !1;
2178
+ (c = e.onCloseAutoFocus) == null || c.call(e, a), a.defaultPrevented || (o.current || (s = n.triggerRef.current) == null || s.focus(), a.preventDefault()), o.current = !1, r.current = !1;
2193
2179
  },
2194
- onInteractOutside: (i) => {
2180
+ onInteractOutside: (a) => {
2195
2181
  var l, u;
2196
- (l = e.onInteractOutside) == null || l.call(e, i), i.defaultPrevented || (o.current = !0, i.detail.originalEvent.type === "pointerdown" && (r.current = !0));
2197
- const c = i.target;
2198
- ((u = n.triggerRef.current) == null ? void 0 : u.contains(c)) && i.preventDefault(), i.detail.originalEvent.type === "focusin" && r.current && i.preventDefault();
2182
+ (l = e.onInteractOutside) == null || l.call(e, a), a.defaultPrevented || (o.current = !0, a.detail.originalEvent.type === "pointerdown" && (r.current = !0));
2183
+ const c = a.target;
2184
+ ((u = n.triggerRef.current) == null ? void 0 : u.contains(c)) && a.preventDefault(), a.detail.originalEvent.type === "focusin" && r.current && a.preventDefault();
2199
2185
  }
2200
2186
  }
2201
2187
  );
2202
2188
  }
2203
2189
  ), kn = U.forwardRef(
2204
2190
  (e, t) => {
2205
- const { __scopeDialog: n, trapFocus: o, onOpenAutoFocus: r, onCloseAutoFocus: i, ...c } = e, s = se(Ie, n), l = U.useRef(null), u = yt(t, l);
2206
- return Yr(), /* @__PURE__ */ D(Se, { children: [
2207
- /* @__PURE__ */ a(
2208
- Jr,
2191
+ const { __scopeDialog: n, trapFocus: o, onOpenAutoFocus: r, onCloseAutoFocus: a, ...c } = e, s = se(ye, n), l = U.useRef(null), u = It(t, l);
2192
+ return Xr(), /* @__PURE__ */ D(xe, { children: [
2193
+ /* @__PURE__ */ i(
2194
+ Yr,
2209
2195
  {
2210
2196
  asChild: !0,
2211
2197
  loop: !0,
2212
2198
  trapped: o,
2213
2199
  onMountAutoFocus: r,
2214
- onUnmountAutoFocus: i,
2215
- children: /* @__PURE__ */ a(
2216
- Kr,
2200
+ onUnmountAutoFocus: a,
2201
+ children: /* @__PURE__ */ i(
2202
+ Jr,
2217
2203
  {
2218
2204
  role: "dialog",
2219
2205
  id: s.contentId,
@@ -2227,30 +2213,30 @@ var ti = U.forwardRef(
2227
2213
  )
2228
2214
  }
2229
2215
  ),
2230
- /* @__PURE__ */ D(Se, { children: [
2231
- /* @__PURE__ */ a(oi, { titleId: s.titleId }),
2232
- /* @__PURE__ */ a(ai, { contentRef: l, descriptionId: s.descriptionId })
2216
+ /* @__PURE__ */ D(xe, { children: [
2217
+ /* @__PURE__ */ i(oi, { titleId: s.titleId }),
2218
+ /* @__PURE__ */ i(ai, { contentRef: l, descriptionId: s.descriptionId })
2233
2219
  ] })
2234
2220
  ] });
2235
2221
  }
2236
2222
  ), Dt = "DialogTitle", Mn = U.forwardRef(
2237
2223
  (e, t) => {
2238
2224
  const { __scopeDialog: n, ...o } = e, r = se(Dt, n);
2239
- return /* @__PURE__ */ a(He.h2, { id: r.titleId, ...o, ref: t });
2225
+ return /* @__PURE__ */ i(He.h2, { id: r.titleId, ...o, ref: t });
2240
2226
  }
2241
2227
  );
2242
2228
  Mn.displayName = Dt;
2243
2229
  var Wn = "DialogDescription", ri = U.forwardRef(
2244
2230
  (e, t) => {
2245
2231
  const { __scopeDialog: n, ...o } = e, r = se(Wn, n);
2246
- return /* @__PURE__ */ a(He.p, { id: r.descriptionId, ...o, ref: t });
2232
+ return /* @__PURE__ */ i(He.p, { id: r.descriptionId, ...o, ref: t });
2247
2233
  }
2248
2234
  );
2249
2235
  ri.displayName = Wn;
2250
2236
  var Hn = "DialogClose", $n = U.forwardRef(
2251
2237
  (e, t) => {
2252
2238
  const { __scopeDialog: n, ...o } = e, r = se(Hn, n);
2253
- return /* @__PURE__ */ a(
2239
+ return /* @__PURE__ */ i(
2254
2240
  He.button,
2255
2241
  {
2256
2242
  type: "button",
@@ -2265,12 +2251,12 @@ $n.displayName = Hn;
2265
2251
  function zt(e) {
2266
2252
  return e ? "open" : "closed";
2267
2253
  }
2268
- var Gn = "DialogTitleWarning", [Ls, Vn] = Br(Gn, {
2269
- contentName: Ie,
2254
+ var Vn = "DialogTitleWarning", [Rs, Gn] = Br(Vn, {
2255
+ contentName: ye,
2270
2256
  titleName: Dt,
2271
2257
  docsSlug: "dialog"
2272
2258
  }), oi = ({ titleId: e }) => {
2273
- const t = Vn(Gn), n = `\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
2259
+ const t = Gn(Vn), n = `\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
2274
2260
 
2275
2261
  If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
2276
2262
 
@@ -2279,14 +2265,14 @@ For more information, see https://radix-ui.com/primitives/docs/components/${t.do
2279
2265
  e && (document.getElementById(e) || console.error(n));
2280
2266
  }, [n, e]), null;
2281
2267
  }, ii = "DialogDescriptionWarning", ai = ({ contentRef: e, descriptionId: t }) => {
2282
- const o = `Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${Vn(ii).contentName}}.`;
2268
+ const o = `Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${Gn(ii).contentName}}.`;
2283
2269
  return U.useEffect(() => {
2284
- var i;
2285
- const r = (i = e.current) == null ? void 0 : i.getAttribute("aria-describedby");
2270
+ var a;
2271
+ const r = (a = e.current) == null ? void 0 : a.getAttribute("aria-describedby");
2286
2272
  t && r && (document.getElementById(t) || console.warn(o));
2287
2273
  }, [o, e, t]), null;
2288
2274
  }, si = En, ci = zn, li = An, di = Fn, ui = Mn, pi = $n;
2289
- const xe = {
2275
+ const Se = {
2290
2276
  "rp-dialog-wrapper": "_rp-dialog-wrapper_slqo7_1",
2291
2277
  "rp-dialog-overlay": "_rp-dialog-overlay_slqo7_7",
2292
2278
  "rp-document-dialog": "_rp-document-dialog_slqo7_13",
@@ -2295,7 +2281,7 @@ const xe = {
2295
2281
  "rp-dialog-close": "_rp-dialog-close_slqo7_47",
2296
2282
  "rp-properties-divider": "_rp-properties-divider_slqo7_55"
2297
2283
  }, hi = () => {
2298
- const { pdfProperties: e } = K(), { container: t } = Te(), { activeDocumentProperties: n, setActiveDocumentProperties: o } = no(), { localeMessages: r } = ue(), i = F(() => {
2284
+ const { pdfProperties: e } = K(), { container: t } = Te(), { activeDocumentProperties: n, setActiveDocumentProperties: o } = no(), { localeMessages: r } = ue(), a = F(() => {
2299
2285
  if (!e)
2300
2286
  return [];
2301
2287
  const {
@@ -2335,12 +2321,12 @@ const xe = {
2335
2321
  { label: r == null ? void 0 : r.propertiesPageCountLabel, value: _ }
2336
2322
  ];
2337
2323
  }, [e, r]);
2338
- return /* @__PURE__ */ a(si, { open: n, onOpenChange: o, children: /* @__PURE__ */ a(ci, { container: t, children: /* @__PURE__ */ D("div", { className: xe["rp-dialog-wrapper"], children: [
2339
- /* @__PURE__ */ a(li, { className: xe["rp-dialog-overlay"] }),
2340
- /* @__PURE__ */ D(di, { className: xe["rp-document-dialog"], children: [
2341
- /* @__PURE__ */ a(ui, { className: xe["rp-dialog-title"], children: r == null ? void 0 : r.documentPropertiesLabel }),
2342
- /* @__PURE__ */ a("div", { className: xe["rp-document-properties"], children: i.map((c, s) => /* @__PURE__ */ a("div", { children: c.separate ? /* @__PURE__ */ a("div", { className: xe["rp-properties-divider"] }) : /* @__PURE__ */ a(to, { label: c.label, value: c.value }) }, s)) }),
2343
- /* @__PURE__ */ a(pi, { asChild: !0, className: xe["rp-dialog-close"], children: /* @__PURE__ */ a(vn, {}) })
2324
+ return /* @__PURE__ */ i(si, { open: n, onOpenChange: o, children: /* @__PURE__ */ i(ci, { container: t, children: /* @__PURE__ */ D("div", { className: Se["rp-dialog-wrapper"], children: [
2325
+ /* @__PURE__ */ i(li, { className: Se["rp-dialog-overlay"] }),
2326
+ /* @__PURE__ */ D(di, { className: Se["rp-document-dialog"], children: [
2327
+ /* @__PURE__ */ i(ui, { className: Se["rp-dialog-title"], children: r == null ? void 0 : r.documentPropertiesLabel }),
2328
+ /* @__PURE__ */ i("div", { className: Se["rp-document-properties"], children: a.map((c, s) => /* @__PURE__ */ i("div", { children: c.separate ? /* @__PURE__ */ i("div", { className: Se["rp-properties-divider"] }) : /* @__PURE__ */ i(to, { label: c.label, value: c.value }) }, s)) }),
2329
+ /* @__PURE__ */ i(pi, { asChild: !0, className: Se["rp-dialog-close"], children: /* @__PURE__ */ i(vn, {}) })
2344
2330
  ] })
2345
2331
  ] }) }) });
2346
2332
  }, mi = {
@@ -2349,34 +2335,34 @@ const xe = {
2349
2335
  const n = await (await fetch(e)).blob();
2350
2336
  return fi(n);
2351
2337
  }, Un = () => {
2352
- const { filename: e, pdfSrc: t } = K(), { downloadFilename: n } = _r(), o = (i) => {
2353
- const c = n || i;
2338
+ const { filename: e, pdfSrc: t } = K(), { downloadFilename: n } = _r(), o = (a) => {
2339
+ const c = n || a;
2354
2340
  return c.endsWith(on) ? c : `${c}${on}`;
2355
2341
  };
2356
2342
  return { download: L(async () => {
2357
2343
  if (!e || !t)
2358
2344
  throw new Error("There is no PDF source to download");
2359
- const i = document.createElement("a");
2360
- i.href = await gi(t), i.download = o(e), document.body.appendChild(i), i.click(), document.body.removeChild(i);
2345
+ const a = document.createElement("a");
2346
+ a.href = await gi(t), a.download = o(e), document.body.appendChild(a), a.click(), document.body.removeChild(a);
2361
2347
  }, [e, t]) };
2362
2348
  }, qn = () => {
2363
2349
  const { downloadIcon: e } = pe();
2364
- return e || /* @__PURE__ */ a(so, {});
2365
- }, Zn = ({ children: e, className: t, localeMessages: n }) => /* @__PURE__ */ a(q, { className: t, content: n == null ? void 0 : n.downloadFileTooltip, children: e }), vi = ({ download: e, localeMessages: t }) => /* @__PURE__ */ a(Zn, { localeMessages: t, children: /* @__PURE__ */ a(ee, { onClick: e, "aria-label": t == null ? void 0 : t.downloadFileTooltip, children: /* @__PURE__ */ a(qn, {}) }) }), _i = ({ download: e, localeMessages: t }) => /* @__PURE__ */ a(Ce, { onClick: e, children: /* @__PURE__ */ D(Zn, { className: "rp-menu-item", localeMessages: t, children: [
2366
- /* @__PURE__ */ a("div", { className: "rp-menu-item-left", children: /* @__PURE__ */ a(qn, {}) }),
2350
+ return e || /* @__PURE__ */ i(so, {});
2351
+ }, Zn = ({ children: e, className: t, localeMessages: n }) => /* @__PURE__ */ i(q, { className: t, content: n == null ? void 0 : n.downloadFileTooltip, children: e }), vi = ({ download: e, localeMessages: t }) => /* @__PURE__ */ i(Zn, { localeMessages: t, children: /* @__PURE__ */ i(Q, { onClick: e, "aria-label": t == null ? void 0 : t.downloadFileTooltip, children: /* @__PURE__ */ i(qn, {}) }) }), _i = ({ download: e, localeMessages: t }) => /* @__PURE__ */ i(Ce, { onClick: e, children: /* @__PURE__ */ D(Zn, { className: "rp-menu-item", localeMessages: t, children: [
2352
+ /* @__PURE__ */ i("div", { className: "rp-menu-item-left", children: /* @__PURE__ */ i(qn, {}) }),
2367
2353
  t == null ? void 0 : t.downloadFileLabel
2368
2354
  ] }) }), Bn = () => {
2369
- const { download: e } = Un(), { downloadTool: t = !0 } = _e(), { isSmallScreen: n } = ye(), { localeMessages: o } = ue();
2370
- return t ? n ? /* @__PURE__ */ a(_i, { download: e, localeMessages: o }) : typeof t == "function" ? /* @__PURE__ */ a(t, { download: e }) : t ? /* @__PURE__ */ a(vi, { download: e, localeMessages: o }) : null : null;
2355
+ const { download: e } = Un(), { downloadTool: t = !0 } = _e(), { isSmallScreen: n } = Ie(), { localeMessages: o } = ue();
2356
+ return t ? n ? /* @__PURE__ */ i(_i, { download: e, localeMessages: o }) : typeof t == "function" ? /* @__PURE__ */ i(t, { download: e }) : t ? /* @__PURE__ */ i(vi, { download: e, localeMessages: o }) : null : null;
2371
2357
  }, jn = () => {
2372
2358
  const { printIcon: e } = pe();
2373
- return e || /* @__PURE__ */ a(co, {});
2374
- }, Kn = ({ children: e, className: t, localeMessages: n }) => /* @__PURE__ */ a(q, { className: t, content: n == null ? void 0 : n.printTooltip, children: e }), wi = ({ print: e, localeMessages: t }) => /* @__PURE__ */ a(Kn, { localeMessages: t, children: /* @__PURE__ */ a(ee, { onClick: e, "aria-label": t == null ? void 0 : t.printTooltip, children: /* @__PURE__ */ a(jn, {}) }) }), bi = ({ print: e, localeMessages: t }) => /* @__PURE__ */ a(Ce, { onClick: e, children: /* @__PURE__ */ D(Kn, { className: "rp-menu-item", localeMessages: t, children: [
2375
- /* @__PURE__ */ a("div", { className: "rp-menu-item-left", children: /* @__PURE__ */ a(jn, {}) }),
2359
+ return e || /* @__PURE__ */ i(co, {});
2360
+ }, Kn = ({ children: e, className: t, localeMessages: n }) => /* @__PURE__ */ i(q, { className: t, content: n == null ? void 0 : n.printTooltip, children: e }), wi = ({ print: e, localeMessages: t }) => /* @__PURE__ */ i(Kn, { localeMessages: t, children: /* @__PURE__ */ i(Q, { onClick: e, "aria-label": t == null ? void 0 : t.printTooltip, children: /* @__PURE__ */ i(jn, {}) }) }), bi = ({ print: e, localeMessages: t }) => /* @__PURE__ */ i(Ce, { onClick: e, children: /* @__PURE__ */ D(Kn, { className: "rp-menu-item", localeMessages: t, children: [
2361
+ /* @__PURE__ */ i("div", { className: "rp-menu-item-left", children: /* @__PURE__ */ i(jn, {}) }),
2376
2362
  t == null ? void 0 : t.printLabel
2377
2363
  ] }) }), Xn = () => {
2378
- const { print: e, cancel: t, setOnProgress: n, setOnComplete: o, setOnError: r, progress: i } = nt(), { printTool: c = !0 } = _e(), { isSmallScreen: s } = ye(), { localeMessages: l } = ue();
2379
- return c ? s ? /* @__PURE__ */ a(bi, { print: e, localeMessages: l }) : typeof c == "function" ? /* @__PURE__ */ a(
2364
+ const { print: e, cancel: t, setOnProgress: n, setOnComplete: o, setOnError: r, progress: a } = nt(), { printTool: c = !0 } = _e(), { isSmallScreen: s } = Ie(), { localeMessages: l } = ue();
2365
+ return c ? s ? /* @__PURE__ */ i(bi, { print: e, localeMessages: l }) : typeof c == "function" ? /* @__PURE__ */ i(
2380
2366
  c,
2381
2367
  {
2382
2368
  print: e,
@@ -2384,40 +2370,40 @@ const xe = {
2384
2370
  setOnProgress: n,
2385
2371
  setOnError: r,
2386
2372
  setOnComplete: o,
2387
- progress: i
2373
+ progress: a
2388
2374
  }
2389
- ) : c ? /* @__PURE__ */ a(wi, { print: e, localeMessages: l }) : null : null;
2375
+ ) : c ? /* @__PURE__ */ i(wi, { print: e, localeMessages: l }) : null : null;
2390
2376
  }, Ci = {
2391
2377
  "rp-go-to-Top": "_rp-go-to-Top_4e0yd_1"
2392
2378
  }, Ti = () => {
2393
2379
  const { goToFirstPageIcon: e } = pe();
2394
- return e || /* @__PURE__ */ a(wn, { className: Ci["rp-go-to-Top"] });
2380
+ return e || /* @__PURE__ */ i(wn, { className: Ci["rp-go-to-Top"] });
2395
2381
  }, Pi = () => {
2396
2382
  const { goToLastPageIcon: e } = pe();
2397
- return e || /* @__PURE__ */ a(wn, {});
2398
- }, an = { width: "100%" }, xi = () => {
2399
- const { goToPage: e, totalPages: t, focusedPage: n } = ie(), { jumpNavigationTool: o = !0 } = _e(), { localeMessages: r } = ue(), i = F(() => n === 1, [n]), c = F(() => n === t, [n, t]), s = L(() => {
2383
+ return e || /* @__PURE__ */ i(wn, {});
2384
+ }, an = { width: "100%" }, Si = () => {
2385
+ const { goToPage: e, totalPages: t, focusedPage: n } = ie(), { jumpNavigationTool: o = !0 } = _e(), { localeMessages: r } = ue(), a = F(() => n === 1, [n]), c = F(() => n === t, [n, t]), s = L(() => {
2400
2386
  e(1);
2401
2387
  }, [e]), l = L(() => {
2402
2388
  e(t);
2403
2389
  }, [e, t]);
2404
2390
  return o ? /* @__PURE__ */ D(Be, { children: [
2405
- /* @__PURE__ */ a(Ce, { onClick: s, children: /* @__PURE__ */ a(q, { content: r == null ? void 0 : r.firstPageTooltip, style: an, children: /* @__PURE__ */ D("div", { className: "rp-menu-item", "aria-disabled": i, children: [
2406
- /* @__PURE__ */ a("div", { className: "rp-menu-item-left", children: /* @__PURE__ */ a(Ti, {}) }),
2407
- /* @__PURE__ */ a("span", { children: r == null ? void 0 : r.firstPageLabel })
2391
+ /* @__PURE__ */ i(Ce, { onClick: s, children: /* @__PURE__ */ i(q, { content: r == null ? void 0 : r.firstPageTooltip, style: an, children: /* @__PURE__ */ D("div", { className: "rp-menu-item", "aria-disabled": a, children: [
2392
+ /* @__PURE__ */ i("div", { className: "rp-menu-item-left", children: /* @__PURE__ */ i(Ti, {}) }),
2393
+ /* @__PURE__ */ i("span", { children: r == null ? void 0 : r.firstPageLabel })
2408
2394
  ] }) }) }),
2409
- /* @__PURE__ */ a(Ce, { onClick: l, children: /* @__PURE__ */ a(q, { content: r == null ? void 0 : r.lastPageTooltip, style: an, children: /* @__PURE__ */ D("div", { className: "rp-menu-item", "aria-disabled": c, children: [
2410
- /* @__PURE__ */ a("div", { className: "rp-menu-item-left", children: /* @__PURE__ */ a(Pi, {}) }),
2411
- /* @__PURE__ */ a("span", { children: r == null ? void 0 : r.lastPageLabel })
2395
+ /* @__PURE__ */ i(Ce, { onClick: l, children: /* @__PURE__ */ i(q, { content: r == null ? void 0 : r.lastPageTooltip, style: an, children: /* @__PURE__ */ D("div", { className: "rp-menu-item", "aria-disabled": c, children: [
2396
+ /* @__PURE__ */ i("div", { className: "rp-menu-item-left", children: /* @__PURE__ */ i(Pi, {}) }),
2397
+ /* @__PURE__ */ i("span", { children: r == null ? void 0 : r.lastPageLabel })
2412
2398
  ] }) }) }),
2413
- /* @__PURE__ */ a(Rt, {})
2399
+ /* @__PURE__ */ i(Rt, {})
2414
2400
  ] }) : null;
2415
- }, Si = () => {
2416
- const { container: e } = Te(), { isSmallScreen: t } = ye(), {
2401
+ }, xi = () => {
2402
+ const { container: e } = Te(), { isSmallScreen: t } = Ie(), {
2417
2403
  openFileTool: n,
2418
2404
  downloadTool: o,
2419
2405
  documentProperties: r,
2420
- scrollModeTool: i,
2406
+ scrollModeTool: a,
2421
2407
  rotateTool: c,
2422
2408
  selectionModeTool: s,
2423
2409
  jumpNavigationTool: l,
@@ -2425,53 +2411,53 @@ const xe = {
2425
2411
  fullscreenTool: d
2426
2412
  } = _e(), { localeMessages: f } = ue();
2427
2413
  return F(() => {
2428
- const g = l || c || s || i || r;
2414
+ const g = l || c || s || a || r;
2429
2415
  let w = !1;
2430
2416
  return t && (w = !(!n && !o && !u && !d)), g || w;
2431
2417
  }, [
2432
2418
  n,
2433
2419
  o,
2434
2420
  r,
2435
- i,
2421
+ a,
2436
2422
  c,
2437
2423
  s,
2438
2424
  l,
2439
2425
  t
2440
2426
  ]) ? /* @__PURE__ */ D(ro, { children: [
2441
- /* @__PURE__ */ a(
2427
+ /* @__PURE__ */ i(
2442
2428
  gn,
2443
2429
  {
2444
2430
  container: e,
2445
- triggerComponent: /* @__PURE__ */ a("div", { role: "button", children: /* @__PURE__ */ a(q, { content: f == null ? void 0 : f.moreOptionTooltip, children: /* @__PURE__ */ a(ee, { "aria-label": f == null ? void 0 : f.moreOptionTooltip, children: /* @__PURE__ */ a(Ur, {}) }) }) }),
2431
+ triggerComponent: /* @__PURE__ */ i("div", { role: "button", children: /* @__PURE__ */ i(q, { content: f == null ? void 0 : f.moreOptionTooltip, children: /* @__PURE__ */ i(Q, { "aria-label": f == null ? void 0 : f.moreOptionTooltip, children: /* @__PURE__ */ i(Ur, {}) }) }) }),
2446
2432
  children: /* @__PURE__ */ D("div", { className: mi["rp-other-tool-content"], "data-rp": "moreOptionsDropdown", children: [
2447
2433
  t && /* @__PURE__ */ D(Be, { children: [
2448
- /* @__PURE__ */ a(fn, {}),
2449
- /* @__PURE__ */ a(Bn, {}),
2450
- /* @__PURE__ */ a(Xn, {}),
2451
- /* @__PURE__ */ a(_n, {}),
2452
- /* @__PURE__ */ a(Rt, {})
2434
+ /* @__PURE__ */ i(fn, {}),
2435
+ /* @__PURE__ */ i(Bn, {}),
2436
+ /* @__PURE__ */ i(Xn, {}),
2437
+ /* @__PURE__ */ i(_n, {}),
2438
+ /* @__PURE__ */ i(Rt, {})
2453
2439
  ] }),
2454
- /* @__PURE__ */ a(xi, {}),
2455
- /* @__PURE__ */ a(io, {}),
2456
- /* @__PURE__ */ a(lo, {}),
2457
- /* @__PURE__ */ a(ao, {}),
2458
- /* @__PURE__ */ a(oo, {})
2440
+ /* @__PURE__ */ i(Si, {}),
2441
+ /* @__PURE__ */ i(io, {}),
2442
+ /* @__PURE__ */ i(lo, {}),
2443
+ /* @__PURE__ */ i(ao, {}),
2444
+ /* @__PURE__ */ i(oo, {})
2459
2445
  ] })
2460
2446
  }
2461
2447
  ),
2462
- /* @__PURE__ */ a(hi, {})
2448
+ /* @__PURE__ */ i(hi, {})
2463
2449
  ] }) : null;
2464
- }, Ii = () => {
2465
- const { isSmallScreen: e } = ye();
2466
- return /* @__PURE__ */ D(Se, { children: [
2467
- /* @__PURE__ */ a(Vr, {}),
2468
- !e && /* @__PURE__ */ D(Se, { children: [
2469
- /* @__PURE__ */ a(fn, {}),
2470
- /* @__PURE__ */ a(Bn, {}),
2471
- /* @__PURE__ */ a(Xn, {}),
2472
- /* @__PURE__ */ a(_n, {})
2450
+ }, yi = () => {
2451
+ const { isSmallScreen: e } = Ie();
2452
+ return /* @__PURE__ */ D(xe, { children: [
2453
+ /* @__PURE__ */ i(Gr, {}),
2454
+ !e && /* @__PURE__ */ D(xe, { children: [
2455
+ /* @__PURE__ */ i(fn, {}),
2456
+ /* @__PURE__ */ i(Bn, {}),
2457
+ /* @__PURE__ */ i(Xn, {}),
2458
+ /* @__PURE__ */ i(_n, {})
2473
2459
  ] }),
2474
- /* @__PURE__ */ a(Si, {})
2460
+ /* @__PURE__ */ i(xi, {})
2475
2461
  ] });
2476
2462
  }, Re = {
2477
2463
  "rp-zoom-wrapper": "_rp-zoom-wrapper_cocqs_1",
@@ -2479,14 +2465,14 @@ const xe = {
2479
2465
  "rp-current-zoom-icon": "_rp-current-zoom-icon_cocqs_11",
2480
2466
  "rp-current-zoom-text": "_rp-current-zoom-text_cocqs_16",
2481
2467
  "rp-zoom-dropdown-content": "_rp-zoom-dropdown-content_cocqs_20"
2482
- }, yi = 25, vt = 1e3, Li = [50, 75, 100, 125, 150, 200, 300, 400], Ri = () => {
2468
+ }, Ii = 25, vt = 1e3, Li = [50, 75, 100, 125, 150, 200, 300, 400], Ri = () => {
2483
2469
  const { zoomInIcon: e } = pe();
2484
- return e || /* @__PURE__ */ a(uo, {});
2470
+ return e || /* @__PURE__ */ i(uo, {});
2485
2471
  }, Ni = () => {
2486
2472
  const { zoomOutIcon: e } = pe();
2487
- return e || /* @__PURE__ */ a(po, {});
2473
+ return e || /* @__PURE__ */ i(po, {});
2488
2474
  }, Ei = () => {
2489
- const { zoomLevel: e, setZoomLevel: t } = Je(), { container: n, contentRef: o } = Te(), { zoomTool: r = !0 } = _e(), { focusedPage: i } = ie(), { rotate: c } = Ye(), { pages: s } = K(), { isSmallScreen: l } = ye(), { localeMessages: u } = ue(), d = L(() => {
2475
+ const { zoomLevel: e, setZoomLevel: t } = Je(), { container: n, contentRef: o } = Te(), { zoomTool: r = !0 } = _e(), { focusedPage: a } = ie(), { rotate: c } = Ye(), { pages: s } = K(), { isSmallScreen: l } = Ie(), { localeMessages: u } = ue(), d = L(() => {
2490
2476
  t((_) => {
2491
2477
  const m = Math.floor(_ / 25) * 25;
2492
2478
  return Math.min(m + 25, vt);
@@ -2496,12 +2482,12 @@ const xe = {
2496
2482
  const m = Math.ceil(_ / 25) * 25;
2497
2483
  return Math.min(m - 25, vt);
2498
2484
  });
2499
- }, [t]), h = F(() => e === yi, [e]), g = F(() => e === vt, [e]), w = F(() => {
2485
+ }, [t]), h = F(() => e === Ii, [e]), g = F(() => e === vt, [e]), w = F(() => {
2500
2486
  var _;
2501
- return (_ = s.get(i)) == null ? void 0 : _.page.getViewport({ scale: 1, rotation: c });
2502
- }, [s, i, c]), b = L(
2487
+ return (_ = s.get(a)) == null ? void 0 : _.page.getViewport({ scale: 1, rotation: c });
2488
+ }, [s, a, c]), b = L(
2503
2489
  (_) => {
2504
- const m = ((w == null ? void 0 : w.width) || 0) + 2 * Gt, P = ((w == null ? void 0 : w.height) || 0) + 2 * Gt, x = (o == null ? void 0 : o.clientWidth) || 0, p = (o == null ? void 0 : o.clientHeight) || 0, T = ho(_, x, p, m, P);
2490
+ const m = ((w == null ? void 0 : w.width) || 0) + 2 * Vt, P = ((w == null ? void 0 : w.height) || 0) + 2 * Vt, S = (o == null ? void 0 : o.clientWidth) || 0, p = (o == null ? void 0 : o.clientHeight) || 0, T = ho(_, S, p, m, P);
2505
2491
  t(T);
2506
2492
  },
2507
2493
  [t, w]
@@ -2511,29 +2497,29 @@ const xe = {
2511
2497
  },
2512
2498
  [t, b]
2513
2499
  );
2514
- return typeof r != "boolean" ? /* @__PURE__ */ a(r, { zoomLevel: e, setZoomLevel: t }) : r ? /* @__PURE__ */ D("div", { className: Re["rp-zoom-wrapper"], children: [
2515
- /* @__PURE__ */ a(q, { content: u == null ? void 0 : u.zoomOutTooltip, children: /* @__PURE__ */ a(
2516
- ee,
2500
+ return typeof r != "boolean" ? /* @__PURE__ */ i(r, { zoomLevel: e, setZoomLevel: t }) : r ? /* @__PURE__ */ D("div", { className: Re["rp-zoom-wrapper"], children: [
2501
+ /* @__PURE__ */ i(q, { content: u == null ? void 0 : u.zoomOutTooltip, children: /* @__PURE__ */ i(
2502
+ Q,
2517
2503
  {
2518
2504
  disabled: h,
2519
2505
  onClick: f,
2520
2506
  "aria-label": u == null ? void 0 : u.zoomOutTooltip,
2521
- children: /* @__PURE__ */ a(Ni, {})
2507
+ children: /* @__PURE__ */ i(Ni, {})
2522
2508
  }
2523
2509
  ) }),
2524
- !l && /* @__PURE__ */ a(
2510
+ !l && /* @__PURE__ */ i(
2525
2511
  gn,
2526
2512
  {
2527
2513
  container: n,
2528
- triggerComponent: /* @__PURE__ */ a("div", { role: "button", children: /* @__PURE__ */ a(q, { content: u == null ? void 0 : u.zoomSelectTooltip, children: /* @__PURE__ */ D(
2529
- ee,
2514
+ triggerComponent: /* @__PURE__ */ i("div", { role: "button", children: /* @__PURE__ */ i(q, { content: u == null ? void 0 : u.zoomSelectTooltip, children: /* @__PURE__ */ D(
2515
+ Q,
2530
2516
  {
2531
2517
  className: Re["rp-current-zoom-wrapper"],
2532
2518
  "aria-label": u == null ? void 0 : u.zoomSelectTooltip,
2533
2519
  children: [
2534
- /* @__PURE__ */ a("span", { className: Re["rp-current-zoom-text"], children: e }),
2535
- /* @__PURE__ */ a("span", { className: Re["rp-current-zoom-text"], children: "%" }),
2536
- /* @__PURE__ */ a(Me, { className: Re["rp-current-zoom-icon"] })
2520
+ /* @__PURE__ */ i("span", { className: Re["rp-current-zoom-text"], children: e }),
2521
+ /* @__PURE__ */ i("span", { className: Re["rp-current-zoom-text"], children: "%" }),
2522
+ /* @__PURE__ */ i(Me, { className: Re["rp-current-zoom-icon"] })
2537
2523
  ]
2538
2524
  }
2539
2525
  ) }) }),
@@ -2541,29 +2527,29 @@ const xe = {
2541
2527
  align: "center",
2542
2528
  children: /* @__PURE__ */ D("div", { className: Re["rp-zoom-dropdown-content"], children: [
2543
2529
  /* @__PURE__ */ D(Be, { children: [
2544
- /* @__PURE__ */ a(Ce, { onClick: () => v(it.ACTUAL), children: u == null ? void 0 : u.zoomActualSize }),
2545
- /* @__PURE__ */ a(Ce, { onClick: () => v(it.PAGE_FIT), children: u == null ? void 0 : u.zoomPageFit }),
2546
- /* @__PURE__ */ a(Ce, { onClick: () => v(it.PAGE_WIDTH), children: u == null ? void 0 : u.zoomPageWidth })
2530
+ /* @__PURE__ */ i(Ce, { onClick: () => v(it.ACTUAL), children: u == null ? void 0 : u.zoomActualSize }),
2531
+ /* @__PURE__ */ i(Ce, { onClick: () => v(it.PAGE_FIT), children: u == null ? void 0 : u.zoomPageFit }),
2532
+ /* @__PURE__ */ i(Ce, { onClick: () => v(it.PAGE_WIDTH), children: u == null ? void 0 : u.zoomPageWidth })
2547
2533
  ] }),
2548
- /* @__PURE__ */ a(Rt, {}),
2549
- /* @__PURE__ */ a(Be, { children: Li.map((_) => /* @__PURE__ */ D(Ce, { onClick: () => v(_), children: [
2534
+ /* @__PURE__ */ i(Rt, {}),
2535
+ /* @__PURE__ */ i(Be, { children: Li.map((_) => /* @__PURE__ */ D(Ce, { onClick: () => v(_), children: [
2550
2536
  _,
2551
2537
  " %"
2552
2538
  ] }, _)) })
2553
2539
  ] })
2554
2540
  }
2555
2541
  ),
2556
- /* @__PURE__ */ a(q, { content: u == null ? void 0 : u.zoomInTooltip, children: /* @__PURE__ */ a(
2557
- ee,
2542
+ /* @__PURE__ */ i(q, { content: u == null ? void 0 : u.zoomInTooltip, children: /* @__PURE__ */ i(
2543
+ Q,
2558
2544
  {
2559
2545
  disabled: g,
2560
2546
  onClick: d,
2561
2547
  "aria-label": u == null ? void 0 : u.zoomInTooltip,
2562
- children: /* @__PURE__ */ a(Ri, {})
2548
+ children: /* @__PURE__ */ i(Ri, {})
2563
2549
  }
2564
2550
  ) })
2565
2551
  ] }) : null;
2566
- }, Q = {
2552
+ }, J = {
2567
2553
  "rp-search-tool-content": "_rp-search-tool-content_lnthn_1",
2568
2554
  "rp-search-tool-input": "_rp-search-tool-input_lnthn_10",
2569
2555
  "rp-search-tool-input-icon": "_rp-search-tool-input-icon_lnthn_17",
@@ -2576,9 +2562,9 @@ const xe = {
2576
2562
  "rp-search-loader-icon": "_rp-search-loader-icon_lnthn_74"
2577
2563
  }, sn = () => {
2578
2564
  const { searchIcon: e } = pe();
2579
- return e || /* @__PURE__ */ a(mo, {});
2565
+ return e || /* @__PURE__ */ i(mo, {});
2580
2566
  }, Oi = () => {
2581
- const { container: e } = Te(), [t, n] = $(!1), { pdf: o } = K(), [r, i] = $(null), {
2567
+ const { container: e } = Te(), [t, n] = $(!1), { pdf: o } = K(), [r, a] = $(null), {
2582
2568
  searchOptions: c,
2583
2569
  setSearchOptions: s,
2584
2570
  loading: l,
@@ -2588,21 +2574,21 @@ const xe = {
2588
2574
  nextMatch: h,
2589
2575
  prevMatch: g,
2590
2576
  search: w
2591
- } = In(), { searchTool: b = !0 } = _e(), [v, _] = $(w), { localeMessages: m } = ue(), P = L(() => {
2577
+ } = yn(), { searchTool: b = !0 } = _e(), [v, _] = $(w), { localeMessages: m } = ue(), P = L(() => {
2592
2578
  n(!0);
2593
- }, []), x = L(() => {
2579
+ }, []), S = L(() => {
2594
2580
  u(""), _(""), n(!1);
2595
- }, [u]), p = (I) => {
2596
- const E = I.key === "Enter", W = I.key === " ";
2597
- (E || W) && x();
2581
+ }, [u]), p = (y) => {
2582
+ const E = y.key === "Enter", W = y.key === " ";
2583
+ (E || W) && S();
2598
2584
  }, T = L(
2599
- (I) => {
2600
- I.key === "Escape" && t && x();
2585
+ (y) => {
2586
+ y.key === "Escape" && t && S();
2601
2587
  },
2602
2588
  [t]
2603
2589
  ), C = L(
2604
- (I) => {
2605
- I.shiftKey && I.key === "Enter" ? g() : I.key === "Enter" && w !== v ? u(v) : I.key === "Enter" && h();
2590
+ (y) => {
2591
+ y.shiftKey && y.key === "Enter" ? g() : y.key === "Enter" && w !== v ? u(v) : y.key === "Enter" && h();
2606
2592
  },
2607
2593
  [v, g, h, u, w]
2608
2594
  );
@@ -2611,76 +2597,76 @@ const xe = {
2611
2597
  }), [T]), A(() => {
2612
2598
  r && r.focus();
2613
2599
  }, [r]);
2614
- const S = L((I) => {
2615
- _(I.target.value);
2600
+ const x = L((y) => {
2601
+ _(y.target.value);
2616
2602
  }, []), N = L(() => {
2617
2603
  _(""), u("");
2618
- }, [u]), y = F(() => `${f} / ${d}`, [f, d]), { wholeWords: O, matchCase: R } = F(() => c, [c]), k = L(
2619
- (I) => {
2620
- s((E) => ({ ...E, matchCase: I }));
2604
+ }, [u]), I = F(() => `${f} / ${d}`, [f, d]), { wholeWords: O, matchCase: R } = F(() => c, [c]), k = L(
2605
+ (y) => {
2606
+ s((E) => ({ ...E, matchCase: y }));
2621
2607
  },
2622
2608
  [s]
2623
2609
  ), z = L(
2624
- (I) => {
2625
- s((E) => ({ ...E, wholeWords: I }));
2610
+ (y) => {
2611
+ s((E) => ({ ...E, wholeWords: y }));
2626
2612
  },
2627
2613
  [s]
2628
2614
  );
2629
2615
  return A(() => {
2630
- x();
2631
- }, [o, x]), b ? /* @__PURE__ */ a(Se, { children: /* @__PURE__ */ a(
2616
+ S();
2617
+ }, [o, S]), b ? /* @__PURE__ */ i(xe, { children: /* @__PURE__ */ i(
2632
2618
  Fr,
2633
2619
  {
2634
2620
  open: t,
2635
2621
  container: e,
2636
- triggerComponent: /* @__PURE__ */ a(q, { content: m == null ? void 0 : m.searchButtonTooltip, children: /* @__PURE__ */ a(ee, { onClick: P, "aria-label": m == null ? void 0 : m.searchButtonTooltip, children: /* @__PURE__ */ a(sn, {}) }) }),
2637
- children: /* @__PURE__ */ D("div", { className: Q["rp-search-tool-content"], children: [
2638
- /* @__PURE__ */ D("div", { className: Q["rp-search-tool-input-wrapper"], children: [
2639
- /* @__PURE__ */ D("div", { className: Q["rp-search-tool-input"], children: [
2640
- /* @__PURE__ */ a(q, { content: m == null ? void 0 : m.searchInputTooltip, children: /* @__PURE__ */ a(
2622
+ triggerComponent: /* @__PURE__ */ i(q, { content: m == null ? void 0 : m.searchButtonTooltip, children: /* @__PURE__ */ i(Q, { onClick: P, "aria-label": m == null ? void 0 : m.searchButtonTooltip, children: /* @__PURE__ */ i(sn, {}) }) }),
2623
+ children: /* @__PURE__ */ D("div", { className: J["rp-search-tool-content"], children: [
2624
+ /* @__PURE__ */ D("div", { className: J["rp-search-tool-input-wrapper"], children: [
2625
+ /* @__PURE__ */ D("div", { className: J["rp-search-tool-input"], children: [
2626
+ /* @__PURE__ */ i(q, { content: m == null ? void 0 : m.searchInputTooltip, children: /* @__PURE__ */ i(
2641
2627
  dn,
2642
2628
  {
2643
2629
  value: v,
2644
2630
  onKeyDown: C,
2645
- onChange: S,
2646
- icon: /* @__PURE__ */ a(sn, {}),
2631
+ onChange: x,
2632
+ icon: /* @__PURE__ */ i(sn, {}),
2647
2633
  placeholder: m == null ? void 0 : m.searchInputPlaceholder,
2648
- className: Q["rp-search-input"],
2649
- ref: i,
2650
- children: !!v && /* @__PURE__ */ a("span", { className: Q["rp-search-tool-input-clear"], onClick: N, children: /* @__PURE__ */ a(fo, {}) })
2634
+ className: J["rp-search-input"],
2635
+ ref: a,
2636
+ children: !!v && /* @__PURE__ */ i("span", { className: J["rp-search-tool-input-clear"], onClick: N, children: /* @__PURE__ */ i(fo, {}) })
2651
2637
  }
2652
2638
  ) }),
2653
- l ? /* @__PURE__ */ a("span", { children: /* @__PURE__ */ a(St, { className: Q["rp-search-loader-icon"] }) }) : /* @__PURE__ */ a("span", { children: y })
2639
+ l ? /* @__PURE__ */ i("span", { children: /* @__PURE__ */ i(xt, { className: J["rp-search-loader-icon"] }) }) : /* @__PURE__ */ i("span", { children: I })
2654
2640
  ] }),
2655
- /* @__PURE__ */ D("div", { className: Q["rp-search-tool-input-checkboxes"], children: [
2656
- /* @__PURE__ */ a(Vt, { name: "matchCase", value: R, onChange: k, children: m == null ? void 0 : m.searchMatchCaseLabel }),
2657
- /* @__PURE__ */ a(q, { content: m == null ? void 0 : m.searchMatchCaseTooltip, children: /* @__PURE__ */ a("div", { className: Q["rp-search-icon-info"], tabIndex: 0, children: /* @__PURE__ */ a(Ut, {}) }) }),
2658
- /* @__PURE__ */ a(Vt, { name: "wholeWord", value: O, onChange: z, children: m == null ? void 0 : m.searchWholeWordsLabel }),
2659
- /* @__PURE__ */ a(q, { content: m == null ? void 0 : m.searchWholeWordsTooltip, children: /* @__PURE__ */ a("div", { className: Q["rp-search-icon-info"], tabIndex: 0, children: /* @__PURE__ */ a(Ut, {}) }) })
2641
+ /* @__PURE__ */ D("div", { className: J["rp-search-tool-input-checkboxes"], children: [
2642
+ /* @__PURE__ */ i(Gt, { name: "matchCase", value: R, onChange: k, children: m == null ? void 0 : m.searchMatchCaseLabel }),
2643
+ /* @__PURE__ */ i(q, { content: m == null ? void 0 : m.searchMatchCaseTooltip, children: /* @__PURE__ */ i("div", { className: J["rp-search-icon-info"], tabIndex: 0, children: /* @__PURE__ */ i(Ut, {}) }) }),
2644
+ /* @__PURE__ */ i(Gt, { name: "wholeWord", value: O, onChange: z, children: m == null ? void 0 : m.searchWholeWordsLabel }),
2645
+ /* @__PURE__ */ i(q, { content: m == null ? void 0 : m.searchWholeWordsTooltip, children: /* @__PURE__ */ i("div", { className: J["rp-search-icon-info"], tabIndex: 0, children: /* @__PURE__ */ i(Ut, {}) }) })
2660
2646
  ] })
2661
2647
  ] }),
2662
- /* @__PURE__ */ D("div", { className: Q["rp-search-tool-controls"], children: [
2663
- /* @__PURE__ */ a(q, { content: m == null ? void 0 : m.searchPrevTooltip, children: /* @__PURE__ */ a(ee, { onClick: g, "aria-label": m == null ? void 0 : m.searchPrevTooltip, children: /* @__PURE__ */ a(
2648
+ /* @__PURE__ */ D("div", { className: J["rp-search-tool-controls"], children: [
2649
+ /* @__PURE__ */ i(q, { content: m == null ? void 0 : m.searchPrevTooltip, children: /* @__PURE__ */ i(Q, { onClick: g, "aria-label": m == null ? void 0 : m.searchPrevTooltip, children: /* @__PURE__ */ i(
2664
2650
  Me,
2665
2651
  {
2666
- className: Q["rp-search-tool-input-icon"],
2652
+ className: J["rp-search-tool-input-icon"],
2667
2653
  "aria-disabled": !d
2668
2654
  }
2669
2655
  ) }) }),
2670
- /* @__PURE__ */ a(q, { content: m == null ? void 0 : m.searchNextTooltip, children: /* @__PURE__ */ a(ee, { onClick: h, "aria-label": m == null ? void 0 : m.searchNextTooltip, children: /* @__PURE__ */ a(
2656
+ /* @__PURE__ */ i(q, { content: m == null ? void 0 : m.searchNextTooltip, children: /* @__PURE__ */ i(Q, { onClick: h, "aria-label": m == null ? void 0 : m.searchNextTooltip, children: /* @__PURE__ */ i(
2671
2657
  Me,
2672
2658
  {
2673
2659
  style: { transform: "rotate(180deg" },
2674
- className: Q["rp-search-tool-input-icon"],
2660
+ className: J["rp-search-tool-input-icon"],
2675
2661
  "aria-disabled": !d
2676
2662
  }
2677
2663
  ) }) }),
2678
- /* @__PURE__ */ a(q, { content: m == null ? void 0 : m.searchCloseButtonTooltip, children: /* @__PURE__ */ a(
2679
- ee,
2664
+ /* @__PURE__ */ i(q, { content: m == null ? void 0 : m.searchCloseButtonTooltip, children: /* @__PURE__ */ i(
2665
+ Q,
2680
2666
  {
2681
2667
  onKeyDown: p,
2682
2668
  "aria-label": m == null ? void 0 : m.searchCloseButtonTooltip,
2683
- children: /* @__PURE__ */ a(vn, { onClick: x, className: Q["rp-search-tool-input-icon"] })
2669
+ children: /* @__PURE__ */ i(vn, { onClick: S, className: J["rp-search-tool-input-icon"] })
2684
2670
  }
2685
2671
  ) })
2686
2672
  ] })
@@ -2697,32 +2683,32 @@ const xe = {
2697
2683
  loading: Di
2698
2684
  }, zi = ({ percentage: e }) => {
2699
2685
  const { cancel: t } = nt(), { localeMessages: n } = ue();
2700
- return e < 1 ? null : /* @__PURE__ */ a("div", { className: re(Ne["rp-loading-overlay"]), children: /* @__PURE__ */ D("div", { className: re(Ne["rp-loading-modal"]), children: [
2686
+ return e < 1 ? null : /* @__PURE__ */ i("div", { className: re(Ne["rp-loading-overlay"]), children: /* @__PURE__ */ D("div", { className: re(Ne["rp-loading-modal"]), children: [
2701
2687
  /* @__PURE__ */ D("div", { className: re(Ne["rp-loading-title"]), children: [
2702
2688
  n == null ? void 0 : n.printLoadingMessage,
2703
2689
  "..."
2704
2690
  ] }),
2705
- /* @__PURE__ */ a("div", { className: re(Ne["rp-loading-progress-bar"]), children: /* @__PURE__ */ a(
2691
+ /* @__PURE__ */ i("div", { className: re(Ne["rp-loading-progress-bar"]), children: /* @__PURE__ */ i(
2706
2692
  "div",
2707
2693
  {
2708
2694
  className: re(Ne["rp-loading-progress"]),
2709
2695
  style: { width: `${e}%` }
2710
2696
  }
2711
2697
  ) }),
2712
- /* @__PURE__ */ a("button", { className: re(Ne["rp-loading-cancel-button"]), onClick: t, children: n == null ? void 0 : n.printCancelLabel })
2698
+ /* @__PURE__ */ i("button", { className: re(Ne["rp-loading-cancel-button"]), onClick: t, children: n == null ? void 0 : n.printCancelLabel })
2713
2699
  ] }) });
2714
2700
  }, Ai = We((e, t) => {
2715
- const { showPrintProgress: n } = _e(), { progress: o } = nt(), { isSmallScreen: r } = ye(), { percentage: i } = o || {}, c = () => r ? { gridTemplateColumns: "25% 60% 15%" } : void 0;
2701
+ const { showPrintProgress: n } = _e(), { progress: o } = nt(), { isSmallScreen: r } = Ie(), { percentage: a } = o || {}, c = () => r ? { gridTemplateColumns: "25% 60% 15%" } : void 0;
2716
2702
  return /* @__PURE__ */ D("div", { children: [
2717
- /* @__PURE__ */ a("div", { "data-rp": "topBar", ref: t, className: Ae["rp-toolbar-content"], children: /* @__PURE__ */ D("div", { className: Ae["rp-toolbar-wrapper"], style: c(), children: [
2703
+ /* @__PURE__ */ i("div", { "data-rp": "topBar", ref: t, className: Ae["rp-toolbar-content"], children: /* @__PURE__ */ D("div", { className: Ae["rp-toolbar-wrapper"], style: c(), children: [
2718
2704
  /* @__PURE__ */ D("div", { "data-rp": "topBarLeft", className: Ae["rp-toolbar-start"], children: [
2719
- /* @__PURE__ */ a(Oi, {}),
2720
- /* @__PURE__ */ a(Xo, {})
2705
+ /* @__PURE__ */ i(Oi, {}),
2706
+ /* @__PURE__ */ i(Xo, {})
2721
2707
  ] }),
2722
- /* @__PURE__ */ a("div", { "data-rp": "topBarCenter", className: Ae["rp-toolbar-middle"], children: /* @__PURE__ */ a(Ei, {}) }),
2723
- /* @__PURE__ */ a("div", { "data-rp": "topBarRight", className: Ae["rp-toolbar-end"], children: /* @__PURE__ */ a(Ii, {}) })
2708
+ /* @__PURE__ */ i("div", { "data-rp": "topBarCenter", className: Ae["rp-toolbar-middle"], children: /* @__PURE__ */ i(Ei, {}) }),
2709
+ /* @__PURE__ */ i("div", { "data-rp": "topBarRight", className: Ae["rp-toolbar-end"], children: /* @__PURE__ */ i(yi, {}) })
2724
2710
  ] }) }),
2725
- n && i ? /* @__PURE__ */ a(zi, { percentage: i }) : null
2711
+ n && a ? /* @__PURE__ */ i(zi, { percentage: a }) : null
2726
2712
  ] });
2727
2713
  }), _t = {
2728
2714
  "rp-sidebar-content-wrapper": "_rp-sidebar-content-wrapper_1sdl6_1",
@@ -2736,12 +2722,12 @@ const xe = {
2736
2722
  "rp-thumbnail-active": "_rp-thumbnail-active_3fenb_22",
2737
2723
  "rp-thumbnail-loader": "_rp-thumbnail-loader_3fenb_31"
2738
2724
  }, Fi = (e) => {
2739
- const { thumbnailSrc: t, pageNumber: n, isFocused: o, viewport: r } = e, { goToPage: i } = ie(), c = F(() => o ? Fe["rp-thumbnail-active"] : "", [o]), s = F(() => ({
2725
+ const { thumbnailSrc: t, pageNumber: n, isFocused: o, viewport: r } = e, { goToPage: a } = ie(), c = F(() => o ? Fe["rp-thumbnail-active"] : "", [o]), s = F(() => ({
2740
2726
  width: Math.round(r.width),
2741
2727
  height: Math.round(r.height)
2742
2728
  }), [r]), l = L(() => {
2743
- n && i(n);
2744
- }, [i, n]);
2729
+ n && a(n);
2730
+ }, [a, n]);
2745
2731
  return /* @__PURE__ */ D(
2746
2732
  "div",
2747
2733
  {
@@ -2749,7 +2735,7 @@ const xe = {
2749
2735
  id: `page-${n}`,
2750
2736
  className: Fe["rp-thumbnail-wrapper"],
2751
2737
  children: [
2752
- /* @__PURE__ */ a("div", { className: re(c, Fe["rp-thumbnail"]), children: t ? /* @__PURE__ */ a(
2738
+ /* @__PURE__ */ i("div", { className: re(c, Fe["rp-thumbnail"]), children: t ? /* @__PURE__ */ i(
2753
2739
  "img",
2754
2740
  {
2755
2741
  src: t,
@@ -2757,7 +2743,7 @@ const xe = {
2757
2743
  height: s.height,
2758
2744
  alt: "thumbnail"
2759
2745
  }
2760
- ) : /* @__PURE__ */ a(
2746
+ ) : /* @__PURE__ */ i(
2761
2747
  "div",
2762
2748
  {
2763
2749
  className: Fe["rp-thumbnail-loader"],
@@ -2765,10 +2751,10 @@ const xe = {
2765
2751
  width: `${s.width}px`,
2766
2752
  height: `${s.height}px`
2767
2753
  },
2768
- children: /* @__PURE__ */ a(St, {})
2754
+ children: /* @__PURE__ */ i(xt, {})
2769
2755
  }
2770
2756
  ) }),
2771
- /* @__PURE__ */ a("div", { className: Fe["rp-thumbnail-text"], children: n })
2757
+ /* @__PURE__ */ i("div", { className: Fe["rp-thumbnail-text"], children: n })
2772
2758
  ]
2773
2759
  }
2774
2760
  );
@@ -2779,17 +2765,17 @@ const xe = {
2779
2765
  const n = e == null ? void 0 : e.querySelector(`#page-${t}`);
2780
2766
  e && (n != null && n.offsetTop) && (e.scrollTop = (n == null ? void 0 : n.offsetTop) - ki);
2781
2767
  }, Wi = We((e, t) => {
2782
- const { show: n } = e, { focusedPage: o, totalPages: r } = ie(), { thumbnailPages: i, addPage: c, thumbnailLength: s, addToPage: l } = xn(), u = M(null), d = M(1);
2768
+ const { show: n } = e, { focusedPage: o, totalPages: r } = ie(), { thumbnailPages: a, addPage: c, thumbnailLength: s, addToPage: l } = Sn(), u = M(null), d = M(1);
2783
2769
  ln(t, () => u.current);
2784
- const f = F(() => Object.values(i), [i]), h = L(() => {
2770
+ const f = F(() => Object.values(a), [a]), h = L(() => {
2785
2771
  const g = s + 1;
2786
2772
  g <= r && c(g);
2787
2773
  }, [c, r, s]);
2788
2774
  return A(() => {
2789
2775
  o > s ? l(o) : n && d.current !== o && (Mi(u.current, o), d.current = o);
2790
- }, [o, s, l, n, f]), br(u.current, h), /* @__PURE__ */ a("div", { ref: u, className: cn["rp-thumbnails-container"], children: /* @__PURE__ */ a("div", { className: cn["rp-thumbnails"], children: n ? f.map((g, w) => {
2776
+ }, [o, s, l, n, f]), br(u.current, h), /* @__PURE__ */ i("div", { ref: u, className: cn["rp-thumbnails-container"], children: /* @__PURE__ */ i("div", { className: cn["rp-thumbnails"], children: n ? f.map((g, w) => {
2791
2777
  var b, v;
2792
- return /* @__PURE__ */ a(
2778
+ return /* @__PURE__ */ i(
2793
2779
  Fi,
2794
2780
  {
2795
2781
  isFocused: o === ((b = g.page) == null ? void 0 : b.pageNumber),
@@ -2803,27 +2789,27 @@ const xe = {
2803
2789
  }) : null }) });
2804
2790
  }), Hi = () => {
2805
2791
  const { thumbnailIcon: e } = pe();
2806
- return e || /* @__PURE__ */ a(wr, {});
2792
+ return e || /* @__PURE__ */ i(wr, {});
2807
2793
  }, $i = () => {
2808
- const { active: e, setActive: t } = xn(), [n, o] = $(200), r = M(null), { thumbnailTool: i, sidebarEnable: c } = _e(), { localeMessages: s } = ue(), l = L(() => {
2794
+ const { active: e, setActive: t } = Sn(), [n, o] = $(200), r = M(null), { thumbnailTool: a, sidebarEnable: c } = _e(), { localeMessages: s } = ue(), l = L(() => {
2809
2795
  t((d) => !d);
2810
- }, []), u = F(() => typeof i != "boolean" && i ? /* @__PURE__ */ a(i, { onClick: l, active: e }) : i ? /* @__PURE__ */ a(q, { content: s == null ? void 0 : s.thumbnailTooltip, children: /* @__PURE__ */ a(
2811
- ee,
2796
+ }, []), u = F(() => typeof a != "boolean" && a ? /* @__PURE__ */ i(a, { onClick: l, active: e }) : a ? /* @__PURE__ */ i(q, { content: s == null ? void 0 : s.thumbnailTooltip, children: /* @__PURE__ */ i(
2797
+ Q,
2812
2798
  {
2813
2799
  onClick: l,
2814
2800
  active: e,
2815
2801
  "aria-label": s == null ? void 0 : s.thumbnailTooltip,
2816
- children: /* @__PURE__ */ a(Hi, {})
2802
+ children: /* @__PURE__ */ i(Hi, {})
2817
2803
  }
2818
- ) }) : null, [i, e, l, s]);
2819
- return /* @__PURE__ */ a(Se, { children: c && /* @__PURE__ */ D(
2804
+ ) }) : null, [a, e, l, s]);
2805
+ return /* @__PURE__ */ i(xe, { children: c && /* @__PURE__ */ D(
2820
2806
  "div",
2821
2807
  {
2822
2808
  style: { "--rp-thumbnail-width": `${n}px` },
2823
2809
  className: _t["rp-sidebar-content-wrapper"],
2824
2810
  "data-rp": "sidebar",
2825
2811
  children: [
2826
- /* @__PURE__ */ a("div", { className: _t["rp-sidebar-content"], children: u }),
2812
+ /* @__PURE__ */ i("div", { className: _t["rp-sidebar-content"], children: u }),
2827
2813
  /* @__PURE__ */ D(
2828
2814
  "div",
2829
2815
  {
@@ -2831,8 +2817,8 @@ const xe = {
2831
2817
  hidden: !e,
2832
2818
  className: _t["rp-thumbnails-wrapper"],
2833
2819
  children: [
2834
- /* @__PURE__ */ a(Wi, { show: e, ref: r }),
2835
- /* @__PURE__ */ a(Cr, { onWidthChange: o, thumbnailRef: r })
2820
+ /* @__PURE__ */ i(Wi, { show: e, ref: r }),
2821
+ /* @__PURE__ */ i(Cr, { onWidthChange: o, thumbnailRef: r })
2836
2822
  ]
2837
2823
  }
2838
2824
  )
@@ -2847,10 +2833,10 @@ const xe = {
2847
2833
  "rp-loader": "_rp-loader_12d1x_52",
2848
2834
  "rp-theme-variables": "_rp-theme-variables_12d1x_56",
2849
2835
  "rp-dark-mode": "_rp-dark-mode_12d1x_147"
2850
- }, Gi = We(
2836
+ }, Vi = We(
2851
2837
  (e, t) => {
2852
- const { children: n, toolbarRef: o, style: r, className: i } = e, { customVariables: c, customDarkVariables: s } = Lr(), { darkMode: l } = ir();
2853
- return /* @__PURE__ */ a(
2838
+ const { children: n, toolbarRef: o, style: r, className: a } = e, { customVariables: c, customDarkVariables: s } = Lr(), { darkMode: l } = ir();
2839
+ return /* @__PURE__ */ i(
2854
2840
  "div",
2855
2841
  {
2856
2842
  ref: t,
@@ -2858,7 +2844,7 @@ const xe = {
2858
2844
  be["rp-theme-variables"],
2859
2845
  be["rp-container"],
2860
2846
  l ? be["rp-dark-mode"] : "",
2861
- i
2847
+ a
2862
2848
  ),
2863
2849
  style: {
2864
2850
  "--rp-toolbar-height": `${(o == null ? void 0 : o.clientHeight) || 48}px`,
@@ -2870,12 +2856,12 @@ const xe = {
2870
2856
  }
2871
2857
  );
2872
2858
  }
2873
- ), Rs = We((e, t) => {
2859
+ ), Ns = We((e, t) => {
2874
2860
  const {
2875
2861
  children: n,
2876
2862
  slots: o,
2877
2863
  icons: r,
2878
- style: i,
2864
+ style: a,
2879
2865
  className: c,
2880
2866
  mobileWidth: s,
2881
2867
  onLoaded: l,
@@ -2884,18 +2870,18 @@ const xe = {
2884
2870
  } = e, [f, h] = $(null), { setContainer: g, setContentRef: w } = Te(), { loading: b } = K(), { LoaderImageComponent: v } = mn();
2885
2871
  return A(() => (l && l(), () => {
2886
2872
  u && u();
2887
- }), [l, u]), /* @__PURE__ */ a(Gi, { toolbarRef: f, ref: t, children: /* @__PURE__ */ a(yr, { mobileWidth: s, onLayoutWidthChange: d, children: /* @__PURE__ */ a(Tr, { slots: o, children: /* @__PURE__ */ a(Pr, { icons: r, children: /* @__PURE__ */ D(xr, { getContainerRef: g, style: i, className: c, children: [
2888
- /* @__PURE__ */ D(Sr, { children: [
2873
+ }), [l, u]), /* @__PURE__ */ i(Vi, { toolbarRef: f, ref: t, children: /* @__PURE__ */ i(Ir, { mobileWidth: s, onLayoutWidthChange: d, children: /* @__PURE__ */ i(Tr, { slots: o, children: /* @__PURE__ */ i(Pr, { icons: r, children: /* @__PURE__ */ D(Sr, { getContainerRef: g, style: a, className: c, children: [
2874
+ /* @__PURE__ */ D(xr, { children: [
2889
2875
  /* @__PURE__ */ D("div", { className: be["rp-layout"], children: [
2890
- /* @__PURE__ */ a(Ai, { ref: h }),
2876
+ /* @__PURE__ */ i(Ai, { ref: h }),
2891
2877
  /* @__PURE__ */ D("div", { className: be["rp-content"], children: [
2892
- /* @__PURE__ */ a("div", { className: be["rp-sidebar"], children: /* @__PURE__ */ a($i, {}) }),
2893
- /* @__PURE__ */ a("div", { ref: w, className: be["rp-pages"], children: n })
2878
+ /* @__PURE__ */ i("div", { className: be["rp-sidebar"], children: /* @__PURE__ */ i($i, {}) }),
2879
+ /* @__PURE__ */ i("div", { ref: w, className: be["rp-pages"], children: n })
2894
2880
  ] })
2895
2881
  ] }),
2896
- /* @__PURE__ */ a(Ir, {})
2882
+ /* @__PURE__ */ i(yr, {})
2897
2883
  ] }),
2898
- b ? /* @__PURE__ */ a(
2884
+ b ? /* @__PURE__ */ i(
2899
2885
  "div",
2900
2886
  {
2901
2887
  className: be["rp-loader"],
@@ -2908,7 +2894,7 @@ const xe = {
2908
2894
  width: "100%",
2909
2895
  height: "100%"
2910
2896
  },
2911
- children: /* @__PURE__ */ a(
2897
+ children: /* @__PURE__ */ i(
2912
2898
  "div",
2913
2899
  {
2914
2900
  style: {
@@ -2918,7 +2904,7 @@ const xe = {
2918
2904
  height: "100%",
2919
2905
  width: "100%"
2920
2906
  },
2921
- children: v && /* @__PURE__ */ a(v, {})
2907
+ children: v && /* @__PURE__ */ i(v, {})
2922
2908
  }
2923
2909
  )
2924
2910
  }
@@ -2926,7 +2912,7 @@ const xe = {
2926
2912
  ] }) }) }) }) });
2927
2913
  });
2928
2914
  export {
2929
- xo as A,
2915
+ So as A,
2930
2916
  Oi as B,
2931
2917
  bo as C,
2932
2918
  Uo as D,
@@ -2935,20 +2921,20 @@ export {
2935
2921
  Fi as G,
2936
2922
  Wi as H,
2937
2923
  $i as I,
2938
- Gi as J,
2924
+ Vi as J,
2939
2925
  zi as L,
2940
- xi as M,
2941
- Si as O,
2942
- Ts as P,
2926
+ Si as M,
2927
+ xi as O,
2928
+ Ps as P,
2943
2929
  Is as R,
2944
- Ss as S,
2930
+ ys as S,
2945
2931
  xs as T,
2946
2932
  Ei as Z,
2947
- Ps as a,
2948
- Rs as b,
2933
+ Ss as a,
2934
+ Ns as b,
2949
2935
  Un as c,
2950
2936
  nt as d,
2951
- In as e,
2937
+ yn as e,
2952
2938
  bn as f,
2953
2939
  go as g,
2954
2940
  Cn as h,
@@ -2956,11 +2942,11 @@ export {
2956
2942
  Tn as j,
2957
2943
  _o as k,
2958
2944
  Pn as l,
2959
- xn as m,
2945
+ Sn as m,
2960
2946
  wo as n,
2961
- Sn as o,
2947
+ xn as o,
2962
2948
  Co as p,
2963
- So as q,
2949
+ xo as q,
2964
2950
  Nt as r,
2965
2951
  $o as s,
2966
2952
  qo as t,
@@ -2969,5 +2955,5 @@ export {
2969
2955
  Xo as w,
2970
2956
  hi as x,
2971
2957
  Xn as y,
2972
- Ii as z
2958
+ yi as z
2973
2959
  };