@pdf-viewer/react 1.8.0 → 1.8.1-rc.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 (45) hide show
  1. package/dist/{RPDefaultLayout-4b330ca1.js → RPDefaultLayout-c0c44afa.js} +838 -823
  2. package/dist/assets/RPDefaultLayout.css +1 -1
  3. package/dist/components/RPController.js +1 -1
  4. package/dist/components/RPPages.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/MostPageTool.js +1 -1
  13. package/dist/components/layout/toolbar/OtherTool.js +1 -1
  14. package/dist/components/layout/toolbar/Paginate.js +1 -1
  15. package/dist/components/layout/toolbar/PrintTool.js +1 -1
  16. package/dist/components/layout/toolbar/RPToolbar.js +1 -1
  17. package/dist/components/layout/toolbar/RPToolbarEnd.js +1 -1
  18. package/dist/components/layout/toolbar/SearchResultNavigator.js +1 -1
  19. package/dist/components/layout/toolbar/SearchTool.js +1 -1
  20. package/dist/components/layout/toolbar/ZoomTool.js +3 -2
  21. package/dist/components/page/AnnotationLayer.js +1 -1
  22. package/dist/components/page/CanvasLayer.js +1 -1
  23. package/dist/components/page/DualPage.js +1 -1
  24. package/dist/components/page/RPPage.js +1 -1
  25. package/dist/components/page/SinglePage.js +1 -1
  26. package/dist/components/page/TextHighlightLayer.js +1 -1
  27. package/dist/components/page/TextLayer.js +1 -1
  28. package/dist/components/ui/DropDown.js +16 -16
  29. package/dist/components/ui/LoadingIndicator.js +1 -1
  30. package/dist/contexts/PaginationContext.js +1 -1
  31. package/dist/contexts/PrintContext.js +1 -1
  32. package/dist/contexts/SearchContext.js +1 -1
  33. package/dist/contexts/ThumbnailsContext.js +1 -1
  34. package/dist/main.js +1 -1
  35. package/dist/types/components/ui/DropDown.d.ts +2 -1
  36. package/dist/utils/hooks/useFileDownload.js +1 -1
  37. package/dist/utils/hooks/useLicense.js +1 -1
  38. package/dist/utils/hooks/usePaginate.js +1 -1
  39. package/dist/utils/hooks/usePresentPage.js +1 -1
  40. package/dist/utils/hooks/usePrint.js +1 -1
  41. package/dist/utils/hooks/useScrollToPage.js +1 -1
  42. package/dist/utils/hooks/useSearch.js +1 -1
  43. package/dist/utils/hooks/useThumbnail.js +1 -1
  44. package/dist/utils/hooks/useVirtualReactWindow.js +1 -1
  45. package/package.json +7 -2
@@ -4,15 +4,15 @@ import { useRef as H, useEffect as F, useCallback as N, useState as $, useMemo a
4
4
  import { ChevronUpIcon as He } from "./components/icons/ChevronUpIcon.js";
5
5
  import { UIButton as re } from "./components/ui/Button.js";
6
6
  import { UIInput as dn } from "./components/ui/Input.js";
7
- import { ViewMode as Re, ScrollMode as Q, AnnotationSubType as zt, SelectionMode as nr, ZoomLevel as st } from "./utils/types.js";
8
- import { useScrollModeContext as Ee } from "./contexts/ScrollModeContext.js";
7
+ import { ViewMode as Le, ScrollMode as Q, AnnotationSubType as zt, SelectionMode as nr, ZoomLevel as st } from "./utils/types.js";
8
+ import { useScrollModeContext as Ne } from "./contexts/ScrollModeContext.js";
9
9
  import { useDocumentContext as ee } from "./contexts/RPDocumentContext.js";
10
10
  import { useDocumentPasswordContext as rr } from "./contexts/DocumentPasswordContext.js";
11
11
  import { useDarkModeContext as or } from "./contexts/DarkModeContext.js";
12
12
  import "./contexts/RotationContext.js";
13
13
  import { useLayerContext as ir } from "./contexts/LayerContext.js";
14
14
  import { useZoomContext as Qe } from "./contexts/ZoomContext.js";
15
- import { useViewModeContext as Ne } from "./contexts/ViewModeContext.js";
15
+ import { useViewModeContext as Oe } from "./contexts/ViewModeContext.js";
16
16
  import { useVirtualScrollContext as et } from "./contexts/VirtualScrollContext.js";
17
17
  import { useVirtualGridContext as un } from "./contexts/VirtualGridContext.js";
18
18
  import { useSelectionModeContext as ar } from "./contexts/SelectionModeContext.js";
@@ -47,7 +47,7 @@ import { RPDropFileZone as Pr } from "./components/RPDropFileZone.js";
47
47
  import { useViewportContext as Pe, ViewportProvider as Tr } from "./contexts/ViewportContext.js";
48
48
  import { useThemeContext as Sr } from "./contexts/ThemeContext.js";
49
49
  import * as yr from "pdfjs-dist";
50
- import { PixelsPerInch as xr, AnnotationMode as Ir, RenderingCancelledException as Rr, AnnotationLayer as Lr } from "pdfjs-dist";
50
+ import { PixelsPerInch as Ir, AnnotationMode as xr, RenderingCancelledException as Rr, AnnotationLayer as Lr } from "pdfjs-dist";
51
51
  import { SimpleLinkService as Er } from "./utils/link_service.js";
52
52
  import { annotationsEvents as Nr, annotationEventsHandler as Or, handleClick as At, handleAnnotationWidget as Dr, handleAnnotationLink as zr, bindLayerEvents as Ar, unbindLayerEvents as Ft } from "./utils/annotations.js";
53
53
  import { normalizeSingleKeyword as Fr, sortHighlightPosition as Wr, unwrap as kr } from "./components/page/searchHighlight.js";
@@ -80,7 +80,7 @@ import { DocumentProperties as ho } from "./components/layout/toolbar/DocumentPr
80
80
  import { RotateTool as fo } from "./components/layout/toolbar/RotateTool.js";
81
81
  import { ViewModeTool as mo } from "./components/layout/toolbar/ViewModeTool.js";
82
82
  import { ScrollModeTool as go } from "./components/layout/toolbar/ScrollModeTool.js";
83
- import { MenuSeparator as xt } from "./components/layout/toolbar/MenuSeparator.js";
83
+ import { MenuSeparator as It } from "./components/layout/toolbar/MenuSeparator.js";
84
84
  import { FileDownloadDefaultIcon as vo } from "./components/icons/FileDownloadDefaultIcon.js";
85
85
  import { MenuItem as Ce } from "./components/layout/toolbar/MenuItem.js";
86
86
  import { PrintDefaultTool as wo } from "./components/icons/PrintDefaultIcon.js";
@@ -97,59 +97,59 @@ import { UICheckbox as $t } from "./components/ui/Checkbox.js";
97
97
  import { ClearIcon as So } from "./components/icons/ClearIcon.js";
98
98
  import { InfoIcon as Gt } from "./components/icons/InfoIcon.js";
99
99
  import './assets/RPDefaultLayout.css';const wn = () => {
100
- const { viewMode: t } = Ne(), { scrollMode: e } = Ee(), { virtualScrollRef: n, virtualScrollableElementRef: o, pageScrollElementRef: r } = et(), { setFocusedPage: a } = ie(), l = H(), { columnCount: c } = un(), { widths: u, heights: d } = Ge(), m = H(e), v = H(t), p = H(c), { targetScrollPage: w } = pn();
100
+ const { viewMode: t } = Oe(), { scrollMode: e } = Ne(), { virtualScrollRef: n, virtualScrollableElementRef: o, pageScrollElementRef: r } = et(), { setFocusedPage: a } = ie(), l = H(), { columnCount: c } = un(), { widths: u, heights: d } = Ge(), m = H(e), w = H(t), p = H(c), { targetScrollPage: _ } = pn();
101
101
  F(() => {
102
102
  n != null && n.scrollToItem && (l.current = n);
103
103
  }, [n]), F(() => {
104
- m.current = e, v.current = t;
104
+ m.current = e, w.current = t;
105
105
  }, [e, t]);
106
- const P = N(
107
- (_, y) => {
106
+ const b = N(
107
+ (C, y) => {
108
108
  if (!r)
109
109
  return;
110
- const h = Math.ceil(_ / 2) * 2 - 1;
111
- if (_ === h + 1) {
110
+ const f = Math.ceil(C / 2) * 2 - 1;
111
+ if (C === f + 1) {
112
112
  const g = {
113
- left: u[h],
113
+ left: u[f],
114
114
  top: 0
115
115
  };
116
116
  return new Promise(
117
117
  (s) => ct(r, g, s)
118
118
  );
119
119
  }
120
- const f = {
120
+ const h = {
121
121
  left: 0,
122
122
  top: 0
123
123
  };
124
124
  return r == null ? void 0 : r.scrollTo({
125
- ...f,
125
+ ...h,
126
126
  behavior: y
127
127
  });
128
128
  },
129
129
  [r, u, ct]
130
130
  );
131
131
  return F(() => {
132
- m.current = e, v.current = t;
132
+ m.current = e, w.current = t;
133
133
  }, [e, t]), F(() => {
134
134
  p.current = c;
135
135
  }, [c]), { scrollToPage: N(
136
- (_, y = "smooth") => {
137
- a(_);
138
- const h = _ - 1;
139
- let f = h, g = 0;
140
- if (v.current === Re.DUAL_PAGE && m.current === Q.PAGE_SCROLLING) {
141
- P(_, y);
136
+ (C, y = "smooth") => {
137
+ a(C);
138
+ const f = C - 1;
139
+ let h = f, g = 0;
140
+ if (w.current === Le.DUAL_PAGE && m.current === Q.PAGE_SCROLLING) {
141
+ b(C, y);
142
142
  return;
143
143
  }
144
144
  if (m.current === Q.PAGE_SCROLLING) {
145
- a(_);
145
+ a(C);
146
146
  return;
147
147
  }
148
148
  if (!l.current || !o)
149
149
  return;
150
150
  const s = o;
151
- if (w.current = _, m.current === Q.HORIZONTAL_SCROLLING) {
152
- g = h;
151
+ if (_.current = C, m.current === Q.HORIZONTAL_SCROLLING) {
152
+ g = f;
153
153
  const T = {
154
154
  left: Ae(u, g),
155
155
  top: 0
@@ -159,30 +159,30 @@ import './assets/RPDefaultLayout.css';const wn = () => {
159
159
  behavior: y
160
160
  });
161
161
  }
162
- if (v.current === Re.DUAL_PAGE) {
163
- g = h % 2, f = Math.floor(h / 2);
162
+ if (w.current === Le.DUAL_PAGE) {
163
+ g = f % 2, h = Math.floor(f / 2);
164
164
  const T = {
165
165
  left: Ae(u, g),
166
- top: Ae(d, f)
166
+ top: Ae(d, h)
167
167
  };
168
168
  return s.scrollTo({
169
169
  ...T,
170
170
  behavior: y
171
171
  });
172
172
  }
173
- const C = {
173
+ const P = {
174
174
  left: 0,
175
- top: Ae(d, f)
175
+ top: Ae(d, h)
176
176
  };
177
177
  return s.scrollTo({
178
- ...C,
178
+ ...P,
179
179
  behavior: y
180
180
  });
181
181
  },
182
182
  [
183
183
  o,
184
184
  c,
185
- P,
185
+ b,
186
186
  a,
187
187
  ct,
188
188
  d,
@@ -190,43 +190,43 @@ import './assets/RPDefaultLayout.css';const wn = () => {
190
190
  ]
191
191
  ) };
192
192
  }, yo = (t = 1) => {
193
- const [e, n] = $(t), [o, r] = $(0), { scrollToPage: a } = wn(), l = H(1), { viewMode: c } = Ne(), { scrollMode: u } = Ee(), { widths: d } = Ge(), { pagesRef: m } = me(), v = Tt(e, 100), p = N(
194
- (f) => {
195
- if (!/^[0-9]*$/g.test(f.toString()) || !f)
193
+ const [e, n] = $(t), [o, r] = $(0), { scrollToPage: a } = wn(), l = H(1), { viewMode: c } = Oe(), { scrollMode: u } = Ne(), { widths: d } = Ge(), { pagesRef: m } = me(), w = Tt(e, 100), p = N(
194
+ (h) => {
195
+ if (!/^[0-9]*$/g.test(h.toString()) || !h)
196
196
  return { success: !1, currentPage: l.current };
197
- const s = +f;
198
- return s < 0 || s > o ? { success: !1, currentPage: l.current } : (n(s), l.current = s, { success: !0, currentPage: +f });
197
+ const s = +h;
198
+ return s < 0 || s > o ? { success: !1, currentPage: l.current } : (n(s), l.current = s, { success: !0, currentPage: +h });
199
199
  },
200
200
  [o]
201
- ), w = N(p, [p]), P = N(
202
- (f) => {
203
- const g = p(f);
201
+ ), _ = N(p, [p]), b = N(
202
+ (h) => {
203
+ const g = p(h);
204
204
  return g.success && a(g.currentPage), g;
205
205
  },
206
206
  [p, a]
207
- ), S = N((f) => {
208
- const g = f % 2 === 1;
207
+ ), S = N((h) => {
208
+ const g = h % 2 === 1;
209
209
  if (!m || g)
210
210
  return !1;
211
- const s = g ? d[f] : d[f - 1], C = g ? d[f + 1] : d[f];
212
- return c === Re.DUAL_PAGE && s + C < m.clientWidth;
213
- }, [c, d, m, o]), _ = N(() => {
214
- let f = e - 1;
215
- S(f) && (f = e - 2), P(f);
216
- }, [P, e, c, u, S]), y = k(() => c === Re.DUAL_PAGE && u === Q.PAGE_SCROLLING ? e === o - 1 : e === o, [e, o, c, u]), h = N(() => {
211
+ const s = g ? d[h] : d[h - 1], P = g ? d[h + 1] : d[h];
212
+ return c === Le.DUAL_PAGE && s + P < m.clientWidth;
213
+ }, [c, d, m, o]), C = N(() => {
214
+ let h = e - 1;
215
+ S(h) && (h = e - 2), b(h);
216
+ }, [b, e, c, u, S]), y = k(() => c === Le.DUAL_PAGE && u === Q.PAGE_SCROLLING ? e === o - 1 : e === o, [e, o, c, u]), f = N(() => {
217
217
  if (y)
218
218
  return;
219
- let f = e + 1;
220
- S(f) && (f = e + 2), P(f);
221
- }, [P, e, S, c, u, y]);
219
+ let h = e + 1;
220
+ S(h) && (h = e + 2), b(h);
221
+ }, [b, e, S, c, u, y]);
222
222
  return {
223
- focusedPage: v,
223
+ focusedPage: w,
224
224
  totalPages: o,
225
- setFocusedPage: w,
225
+ setFocusedPage: _,
226
226
  setTotalPages: r,
227
- nextPage: h,
228
- prevPage: _,
229
- goToPage: P
227
+ nextPage: f,
228
+ prevPage: C,
229
+ goToPage: b
230
230
  };
231
231
  }, _n = Ye({
232
232
  focusedPage: 0,
@@ -243,7 +243,7 @@ import './assets/RPDefaultLayout.css';const wn = () => {
243
243
  }), ie = () => {
244
244
  const t = Je(_n);
245
245
  return typeof (t == null ? void 0 : t.focusedPage) > "u" && Kr.error("Please use this hooks inside children component of RPProvider"), t;
246
- }, Us = ({ children: t }) => {
246
+ }, Vs = ({ children: t }) => {
247
247
  const { pdf: e } = ee(), { focusedPage: n, totalPages: o, setFocusedPage: r, setTotalPages: a, goToPage: l, nextPage: c, prevPage: u } = yo();
248
248
  return F(() => {
249
249
  e != null && e.numPages && (a(e.numPages), r(1));
@@ -263,7 +263,7 @@ import './assets/RPDefaultLayout.css';const wn = () => {
263
263
  }
264
264
  );
265
265
  };
266
- const xo = () => {
266
+ const Io = () => {
267
267
  const { pdf: t, pages: e } = ee(), [n, o] = $({
268
268
  loadedPages: 0,
269
269
  totalPages: 0,
@@ -272,24 +272,24 @@ const xo = () => {
272
272
  F(() => {
273
273
  m.current;
274
274
  }, [m]);
275
- const v = N(() => {
275
+ const w = N(() => {
276
276
  document.documentElement.classList.remove("rp-print-html-printing"), document.body.classList.remove("rp-print-body-printing");
277
- const f = document.querySelector(".rp-print-zone");
278
- f && f.remove();
277
+ const h = document.querySelector(".rp-print-zone");
278
+ h && h.remove();
279
279
  }, []), p = N(() => {
280
280
  m.current = !1, a(!1), c(!1), d(null), o({
281
281
  loadedPages: 0,
282
282
  totalPages: 0,
283
283
  percentage: 0
284
284
  });
285
- }, []), w = () => {
285
+ }, []), _ = () => {
286
286
  m.current = !0;
287
- }, P = async ({
288
- scratchCanvas: f,
287
+ }, b = async ({
288
+ scratchCanvas: h,
289
289
  pdfDocument: g,
290
290
  pageNumber: s,
291
- viewerPdfPage: C,
292
- printResolution: b,
291
+ viewerPdfPage: P,
292
+ printResolution: v,
293
293
  optionalContentConfigPromise: T,
294
294
  printAnnotationStoragePromise: E
295
295
  }) => {
@@ -297,11 +297,11 @@ const xo = () => {
297
297
  p();
298
298
  return;
299
299
  }
300
- const x = b / xr.PDF;
301
- f.width = Math.floor(C.width * x), f.height = Math.floor(C.height * x);
302
- const R = f.getContext("2d");
303
- R.save(), R.fillStyle = "rgb(255, 255, 255)", R.fillRect(0, 0, f.width, f.height), R.restore();
304
- const [D, z] = await Promise.all([
300
+ const I = v / Ir.PDF;
301
+ h.width = Math.floor(P.width * I), h.height = Math.floor(P.height * I);
302
+ const R = h.getContext("2d");
303
+ R.save(), R.fillStyle = "rgb(255, 255, 255)", R.fillRect(0, 0, h.width, h.height), R.restore();
304
+ const [O, z] = await Promise.all([
305
305
  g.getPage(s),
306
306
  E
307
307
  ]);
@@ -311,87 +311,87 @@ const xo = () => {
311
311
  }
312
312
  const A = {
313
313
  canvasContext: R,
314
- transform: [x, 0, 0, x, 0, 0],
315
- viewport: D.getViewport({ scale: 1, rotation: C.rotation }),
314
+ transform: [I, 0, 0, I, 0, 0],
315
+ viewport: O.getViewport({ scale: 1, rotation: P.rotation }),
316
316
  intent: "print",
317
- annotationMode: Ir.ENABLE_STORAGE,
317
+ annotationMode: xr.ENABLE_STORAGE,
318
318
  optionalContentConfigPromise: T,
319
319
  printAnnotationStorage: z
320
320
  };
321
321
  try {
322
- return D.render(A).promise;
322
+ return O.render(A).promise;
323
323
  } catch (L) {
324
324
  throw L instanceof Rr || console.error(L), L;
325
325
  }
326
326
  }, S = N(() => {
327
- const f = window.print;
327
+ const h = window.print;
328
328
  return new Promise((g) => {
329
329
  const s = (T) => {
330
330
  setTimeout(() => {
331
- f.call(window), setTimeout(() => T(), 20);
331
+ h.call(window), setTimeout(() => T(), 20);
332
332
  }, 0);
333
333
  };
334
334
  if (document.querySelector(".rp-print-zone")) {
335
335
  s(g);
336
336
  return;
337
337
  }
338
- const b = new MutationObserver(() => {
339
- document.querySelector(".rp-print-zone") && (s(g), b.disconnect());
338
+ const v = new MutationObserver(() => {
339
+ document.querySelector(".rp-print-zone") && (s(g), v.disconnect());
340
340
  });
341
- b.observe(document.body, { childList: !0, subtree: !0 });
341
+ v.observe(document.body, { childList: !0, subtree: !0 });
342
342
  });
343
- }, []), _ = async (f) => {
343
+ }, []), C = async (h) => {
344
344
  const g = document.createElement("img"), s = document.createElement("div");
345
- return s.classList.add("rp-print-page"), await new Promise((C, b) => {
346
- f.toBlob((T) => {
345
+ return s.classList.add("rp-print-page"), await new Promise((P, v) => {
346
+ h.toBlob((T) => {
347
347
  T ? (g.src = URL.createObjectURL(T), g.onload = () => {
348
- URL.revokeObjectURL(g.src), C();
349
- }, g.onerror = b) : b(new Error("Failed to create blob"));
348
+ URL.revokeObjectURL(g.src), P();
349
+ }, g.onerror = v) : v(new Error("Failed to create blob"));
350
350
  });
351
351
  }).catch(() => {
352
352
  }), s.appendChild(g), s;
353
- }, y = (f, g) => {
353
+ }, y = (h, g) => {
354
354
  const s = document.createElement("div");
355
355
  s.classList.add("rp-print-zone");
356
- const C = document.createElement("style"), b = g.get(1);
357
- if (b) {
358
- const { width: T, height: E } = b == null ? void 0 : b.page.getViewport({ scale: 1 });
359
- C.innerHTML = `@page { size: ${T}px ${E}px }`;
356
+ const P = document.createElement("style"), v = g.get(1);
357
+ if (v) {
358
+ const { width: T, height: E } = v == null ? void 0 : v.page.getViewport({ scale: 1 });
359
+ P.innerHTML = `@page { size: ${T}px ${E}px }`;
360
360
  }
361
- return s.appendChild(C), s.append(...f), s;
362
- }, h = N(async () => {
361
+ return s.appendChild(P), s.append(...h), s;
362
+ }, f = N(async () => {
363
363
  if (!t)
364
364
  return;
365
365
  p();
366
- const f = document.createElement("canvas"), g = [];
366
+ const h = document.createElement("canvas"), g = [];
367
367
  try {
368
368
  t.isPureXfa && console.warn("[rp] XFA Form is not supported at the moment.");
369
- const C = t.getOptionalContentConfig({ intent: "print" }), b = Promise.resolve(
369
+ const P = t.getOptionalContentConfig({ intent: "print" }), v = Promise.resolve(
370
370
  t.annotationStorage.print ?? void 0
371
371
  ), T = e.size;
372
- for (const [x, R] of e) {
372
+ for (const [I, R] of e) {
373
373
  if (m.current) {
374
374
  p();
375
375
  return;
376
376
  }
377
- const D = R.page.getViewport({ scale: 1 });
378
- if (await P({
379
- scratchCanvas: f,
377
+ const O = R.page.getViewport({ scale: 1 });
378
+ if (await b({
379
+ scratchCanvas: h,
380
380
  pdfDocument: t,
381
- pageNumber: x,
382
- viewerPdfPage: D,
381
+ pageNumber: I,
382
+ viewerPdfPage: O,
383
383
  printResolution: 150,
384
- optionalContentConfigPromise: C,
385
- printAnnotationStoragePromise: b
384
+ optionalContentConfigPromise: P,
385
+ printAnnotationStoragePromise: v
386
386
  }), m.current) {
387
387
  p();
388
388
  return;
389
389
  }
390
- const z = await _(f);
390
+ const z = await C(h);
391
391
  g.push(z);
392
392
  const A = parseFloat((g.length / T * 100).toFixed(2));
393
393
  o({
394
- loadedPages: x,
394
+ loadedPages: I,
395
395
  totalPages: T,
396
396
  percentage: A
397
397
  });
@@ -405,19 +405,19 @@ const xo = () => {
405
405
  } catch (s) {
406
406
  c(!0), s instanceof Error && d(s);
407
407
  } finally {
408
- f.height = 0, f.width = 0;
408
+ h.height = 0, h.width = 0;
409
409
  }
410
410
  }, [t, e, m]);
411
411
  return F(() => {
412
- const f = () => {
413
- p(), v();
412
+ const h = () => {
413
+ p(), w();
414
414
  };
415
- return window.addEventListener("afterprint", f, !0), () => {
416
- window.removeEventListener("afterprint", f, !0);
415
+ return window.addEventListener("afterprint", h, !0), () => {
416
+ window.removeEventListener("afterprint", h, !0);
417
417
  };
418
- }, [v, p]), {
419
- print: h,
420
- cancel: w,
418
+ }, [w, p]), {
419
+ print: f,
420
+ cancel: _,
421
421
  progress: n,
422
422
  isComplete: r,
423
423
  isError: l,
@@ -440,33 +440,33 @@ const xo = () => {
440
440
  console.error("Error in setOnError callback:", e);
441
441
  }
442
442
  }
443
- }), Vs = ({ children: t }) => {
444
- const [e, n] = $(null), [o, r] = $(null), { print: a, cancel: l, progress: c, isComplete: u, isError: d, error: m } = xo(), v = N((_) => {
445
- _ && typeof _ == "function" && r(() => _);
446
- }, []), p = (_) => {
447
- m && _(m);
448
- }, w = N(
449
- (_) => {
450
- n(() => _);
443
+ }), qs = ({ children: t }) => {
444
+ const [e, n] = $(null), [o, r] = $(null), { print: a, cancel: l, progress: c, isComplete: u, isError: d, error: m } = Io(), w = N((C) => {
445
+ C && typeof C == "function" && r(() => C);
446
+ }, []), p = (C) => {
447
+ m && C(m);
448
+ }, _ = N(
449
+ (C) => {
450
+ n(() => C);
451
451
  },
452
452
  [c, e]
453
453
  );
454
454
  F(() => {
455
- u && o && P();
455
+ u && o && b();
456
456
  }, [u, o]), F(() => {
457
- d && p((_) => {
458
- console.error(_);
457
+ d && p((C) => {
458
+ console.error(C);
459
459
  });
460
460
  }, [d]), F(() => {
461
461
  c && e && e(c);
462
462
  }, [c, e]);
463
- const P = () => {
463
+ const b = () => {
464
464
  o && (o(), r(null));
465
465
  }, S = {
466
466
  print: a,
467
467
  cancel: l,
468
- setOnProgress: w,
469
- setOnComplete: v,
468
+ setOnProgress: _,
469
+ setOnComplete: w,
470
470
  setOnError: p,
471
471
  progress: c
472
472
  };
@@ -476,44 +476,44 @@ const xo = () => {
476
476
  if (!t)
477
477
  throw new Error("usePrintContext must be used within a PrintProvider");
478
478
  return t;
479
- }, Io = () => {
479
+ }, xo = () => {
480
480
  const [t, e] = $({}), { pages: n } = ee(), o = k(() => Object.keys(t).length, [t]), r = N(
481
481
  (l) => {
482
482
  if (!n.size)
483
483
  return;
484
- const c = l > n.size ? n.size : l, u = Array.from(n.values()).slice(0, c).map((v) => {
485
- const { thumbnailViewport: p, scale: w } = Wt(v.page, v.defaultRotation);
484
+ const c = l > n.size ? n.size : l, u = Array.from(n.values()).slice(0, c).map((w) => {
485
+ const { thumbnailViewport: p, scale: _ } = Wt(w.page, w.defaultRotation);
486
486
  return {
487
- scale: w,
488
- page: v.page,
487
+ scale: _,
488
+ page: w.page,
489
489
  loading: !0,
490
490
  viewport: p,
491
- defaultRotation: v.defaultRotation
491
+ defaultRotation: w.defaultRotation
492
492
  };
493
- }), d = u.reduce((v, p) => (v[p.page.pageNumber] = p, v), {});
493
+ }), d = u.reduce((w, p) => (w[p.page.pageNumber] = p, w), {});
494
494
  e(d);
495
495
  const m = [];
496
- for (const v of u) {
497
- const p = document.createElement("canvas"), w = wt(v.page, p, {
498
- scale: v.scale,
499
- rotate: v.defaultRotation
496
+ for (const w of u) {
497
+ const p = document.createElement("canvas"), _ = wt(w.page, p, {
498
+ scale: w.scale,
499
+ rotate: w.defaultRotation
500
500
  }).promise.then(() => {
501
- const P = p.toDataURL();
501
+ const b = p.toDataURL();
502
502
  return {
503
- ...v,
504
- thumbnailSrc: P,
503
+ ...w,
504
+ thumbnailSrc: b,
505
505
  loading: !1,
506
- defaultRotation: v.defaultRotation
506
+ defaultRotation: w.defaultRotation
507
507
  };
508
508
  });
509
- m.push(w);
509
+ m.push(_);
510
510
  }
511
- Promise.all(m).then((v) => {
512
- const p = v.reduce(
513
- (w, P) => (w[P.page.pageNumber] = P, w),
511
+ Promise.all(m).then((w) => {
512
+ const p = w.reduce(
513
+ (_, b) => (_[b.page.pageNumber] = b, _),
514
514
  {}
515
515
  );
516
- e((w) => ({ ...w, ...p }));
516
+ e((_) => ({ ..._, ...p }));
517
517
  }).catch(() => {
518
518
  });
519
519
  },
@@ -544,9 +544,9 @@ const xo = () => {
544
544
  scale: c.thumbnailScale,
545
545
  rotate: c.defaultRotation
546
546
  }).promise.then(() => {
547
- const d = u.toDataURL(), { thumbnailViewport: m, scale: v } = Wt(c.page);
547
+ const d = u.toDataURL(), { thumbnailViewport: m, scale: w } = Wt(c.page);
548
548
  return {
549
- scale: v,
549
+ scale: w,
550
550
  thumbnailSrc: d,
551
551
  page: c.page,
552
552
  loading: !1,
@@ -570,11 +570,11 @@ const xo = () => {
570
570
  setActive: (t) => {
571
571
  },
572
572
  active: !1
573
- }), Pn = () => Je(Cn), qs = ({
573
+ }), Pn = () => Je(Cn), Bs = ({
574
574
  children: t,
575
575
  initialThumbnailsVisible: e
576
576
  }) => {
577
- const { thumbnailPages: n, addPage: o, addToPage: r, thumbnailLength: a } = Io(), [l, c] = $(e);
577
+ const { thumbnailPages: n, addPage: o, addToPage: r, thumbnailLength: a } = xo(), [l, c] = $(e);
578
578
  return /* @__PURE__ */ i(
579
579
  Cn.Provider,
580
580
  {
@@ -583,35 +583,35 @@ const xo = () => {
583
583
  }
584
584
  );
585
585
  }, Ro = (t = {}, e = "") => {
586
- const [n, o] = $(e), [r, a] = $(!1), { pdf: l, pages: c } = ee(), { widths: u, heights: d } = Ge(), m = H(!n), { currentZoom: v } = Qe(), [p, w] = $([]), { setFocusedPage: P } = ie(), { columnCount: S } = Ne(), { pageRotate: _ } = Ue(), [y, h] = $(0), { pageScrollElementRef: f, virtualScrollableElementRef: g } = et(), { scrollMode: s } = Ee(), { pagesRef: C } = me(), [b, T] = $(null), E = H({}), x = k(() => y === 0 ? null : p[y - 1], [y, p]), R = k(() => p.length, [p]);
586
+ const [n, o] = $(e), [r, a] = $(!1), { pdf: l, pages: c } = ee(), { widths: u, heights: d } = Ge(), m = H(!n), { currentZoom: w } = Qe(), [p, _] = $([]), { setFocusedPage: b } = ie(), { columnCount: S } = Oe(), { pageRotate: C } = Ue(), [y, f] = $(0), { pageScrollElementRef: h, virtualScrollableElementRef: g } = et(), { scrollMode: s } = Ne(), { pagesRef: P } = me(), [v, T] = $(null), E = H({}), I = k(() => y === 0 ? null : p[y - 1], [y, p]), R = k(() => p.length, [p]);
587
587
  F(() => {
588
- if (!x || !c)
588
+ if (!I || !c)
589
589
  return;
590
- const L = g || f;
591
- if (!L || !C)
590
+ const L = g || h;
591
+ if (!L || !P)
592
592
  return;
593
- const I = c.get(x.page);
594
- if (s === Q.PAGE_SCROLLING && P(x.page), !I)
593
+ const x = c.get(I.page);
594
+ if (s === Q.PAGE_SCROLLING && b(I.page), !x)
595
595
  return;
596
- let O = 0, M = 0;
596
+ let D = 0, M = 0;
597
597
  if (s === Q.VERTICAL_SCROLLING) {
598
- const le = x.page - 1, Y = S, Fe = le % Y, we = Math.floor(le / Y);
599
- O = Ae(d, we), M = Ae(u, Fe);
598
+ const le = I.page - 1, Y = S, Fe = le % Y, we = Math.floor(le / Y);
599
+ D = Ae(d, we), M = Ae(u, Fe);
600
600
  }
601
- s === Q.HORIZONTAL_SCROLLING && (M = u.slice(0, x.page - 1).reduce((le, Y) => le + Y, 0));
601
+ s === Q.HORIZONTAL_SCROLLING && (M = u.slice(0, I.page - 1).reduce((le, Y) => le + Y, 0));
602
602
  const G = {
603
- height: d[x.page - 1],
604
- width: u[x.page - 1]
603
+ height: d[I.page - 1],
604
+ width: u[I.page - 1]
605
605
  }, Z = {
606
606
  top: G.height / 2,
607
607
  left: G.width / 2
608
- }, j = _[x.page], { leftInPage: q, topInPage: te } = jr(
608
+ }, j = C[I.page], { leftInPage: q, topInPage: te } = jr(
609
609
  G,
610
610
  Z,
611
- x.rect,
612
- v,
611
+ I.rect,
612
+ w,
613
613
  j
614
- ), X = M + q, ce = O + te, ve = {
614
+ ), X = M + q, ce = D + te, ve = {
615
615
  left: Math.max(X, 0),
616
616
  top: Math.max(ce, 0)
617
617
  };
@@ -621,39 +621,39 @@ const xo = () => {
621
621
  });
622
622
  }, [
623
623
  c,
624
- P,
624
+ b,
625
625
  u,
626
626
  d,
627
- x,
627
+ I,
628
628
  s,
629
629
  g,
630
- f,
631
- C
630
+ h,
631
+ P
632
632
  ]);
633
- const D = N(() => {
634
- h((L) => R ? L + 1 > R ? 1 : L + 1 : 0);
633
+ const O = N(() => {
634
+ f((L) => R ? L + 1 > R ? 1 : L + 1 : 0);
635
635
  }, [R]), z = N(() => {
636
- h((L) => R ? L - 1 <= 0 ? R : L - 1 : 0);
636
+ f((L) => R ? L - 1 <= 0 ? R : L - 1 : 0);
637
637
  }, [R]), A = N(async (L) => {
638
638
  if (!L)
639
639
  return {};
640
- const I = L.numPages, O = {};
641
- for (let M = 1; M <= I; M++) {
640
+ const x = L.numPages, D = {};
641
+ for (let M = 1; M <= x; M++) {
642
642
  if (m.current)
643
643
  throw "close pop over";
644
644
  const G = await L.getPage(M);
645
- O[M.toString()] = await G.getTextContent();
645
+ D[M.toString()] = await G.getTextContent();
646
646
  }
647
- return O;
647
+ return D;
648
648
  }, []);
649
649
  return F(() => {
650
650
  if (!n) {
651
- m.current = !0, w([]), h(0);
651
+ m.current = !0, _([]), f(0);
652
652
  return;
653
653
  }
654
- m.current = !1, a(!0), w([]), h(0), A(l).then((L) => {
654
+ m.current = !1, a(!0), _([]), f(0), A(l).then((L) => {
655
655
  E.current = L;
656
- const O = Object.keys(L).reduce((M, G) => {
656
+ const D = Object.keys(L).reduce((M, G) => {
657
657
  const Z = lr(
658
658
  [n],
659
659
  L[G],
@@ -662,9 +662,9 @@ const xo = () => {
662
662
  ).map((j, q) => ({ ...j, page: Number(G), pageMatchIdx: q }));
663
663
  return [...M, ...Z];
664
664
  }, []);
665
- w(O), h(O.length ? 1 : 0);
665
+ _(D), f(D.length ? 1 : 0);
666
666
  }).catch(() => {
667
- w([]), h(0);
667
+ _([]), f(0);
668
668
  }).finally(() => a(!1));
669
669
  }, [n, A, l, t]), {
670
670
  search: n,
@@ -673,10 +673,10 @@ const xo = () => {
673
673
  matches: p,
674
674
  totalMatches: R,
675
675
  currentMatchPosition: y,
676
- currentMatch: x,
677
- nextMatch: D,
676
+ currentMatch: I,
677
+ nextMatch: O,
678
678
  prevMatch: z,
679
- currentMatchElement: b,
679
+ currentMatchElement: v,
680
680
  setCurrentMatchElement: T
681
681
  };
682
682
  }, Tn = Ye({
@@ -697,7 +697,7 @@ const xo = () => {
697
697
  currentMatchElement: null,
698
698
  setCurrentMatchElement: (t) => {
699
699
  }
700
- }), Bs = ({
700
+ }), Zs = ({
701
701
  children: t,
702
702
  initialSearch: e
703
703
  }) => {
@@ -709,10 +709,10 @@ const xo = () => {
709
709
  currentMatch: u,
710
710
  search: d,
711
711
  matches: m,
712
- nextMatch: v,
712
+ nextMatch: w,
713
713
  prevMatch: p,
714
- currentMatchElement: w,
715
- setCurrentMatchElement: P
714
+ currentMatchElement: _,
715
+ setCurrentMatchElement: b
716
716
  } = Ro(n, e);
717
717
  return /* @__PURE__ */ i(
718
718
  Tn.Provider,
@@ -725,17 +725,17 @@ const xo = () => {
725
725
  totalMatches: l,
726
726
  currentMatchPosition: c,
727
727
  currentMatch: u,
728
- nextMatch: v,
728
+ nextMatch: w,
729
729
  prevMatch: p,
730
730
  search: d,
731
731
  matches: m,
732
- currentMatchElement: w,
733
- setCurrentMatchElement: P
732
+ currentMatchElement: _,
733
+ setCurrentMatchElement: b
734
734
  },
735
735
  children: t
736
736
  }
737
737
  );
738
- }, It = () => Je(Tn), de = {
738
+ }, xt = () => Je(Tn), de = {
739
739
  "rp-pages": "_rp-pages_17t6t_1",
740
740
  "rp-pages-horizontal-scroll": "_rp-pages-horizontal-scroll_17t6t_7",
741
741
  "rp-pages-container": "_rp-pages-container_17t6t_11",
@@ -757,8 +757,8 @@ const xo = () => {
757
757
  if (r.current && d) {
758
758
  const m = r.current;
759
759
  m.hidden = !0;
760
- const v = c.current;
761
- v && v.cancel(), o && o(), c.current = wt(d.page, m, {
760
+ const w = c.current;
761
+ w && w.cancel(), o && o(), c.current = wt(d.page, m, {
762
762
  scale: u,
763
763
  rotate: l[e],
764
764
  renderForms: !0
@@ -779,27 +779,27 @@ const xo = () => {
779
779
  selecting: Eo,
780
780
  "rp-text-layer-text": "_rp-text-layer-text_usdup_39"
781
781
  }, No = (t) => {
782
- const { pageNumber: e } = t, { pages: n } = ee(), o = H(null), { matches: r, currentMatch: a, setCurrentMatchElement: l } = It(), [c, u] = $(
782
+ const { pageNumber: e } = t, { pages: n } = ee(), o = H(null), { matches: r, currentMatch: a, setCurrentMatchElement: l } = xt(), [c, u] = $(
783
783
  []
784
- ), d = H(), m = H(), v = H([]), p = k(() => r.filter((f) => f.pageIndex === e - 1), [r, e]), w = N(
785
- (f, g, s = !1) => {
786
- if (s && dr(f, g), !p.length) {
787
- v.current = [], u([]);
784
+ ), d = H(), m = H(), w = H([]), p = k(() => r.filter((h) => h.pageIndex === e - 1), [r, e]), _ = N(
785
+ (h, g, s = !1) => {
786
+ if (s && dr(h, g), !p.length) {
787
+ w.current = [], u([]);
788
788
  return;
789
789
  }
790
- const C = ur(p, f, g);
791
- u(C);
790
+ const P = ur(p, h, g);
791
+ u(P);
792
792
  },
793
793
  [p]
794
- ), P = H(), S = H(!1), _ = N(() => Array.from(document.querySelectorAll('[data-rp$="-textLayer"]')), []);
794
+ ), b = H(), S = H(!1), C = N(() => Array.from(document.querySelectorAll('[data-rp$="-textLayer"]')), []);
795
795
  F(() => ((() => {
796
- if (P.current)
796
+ if (b.current)
797
797
  return;
798
- P.current = new AbortController();
799
- const { signal: g } = P.current, s = () => {
800
- _().forEach((b) => {
801
- const T = b.querySelector(".endOfContent");
802
- T && (b.appendChild(T), T.style.width = "", T.style.height = "", b.classList.remove(pe.selecting));
798
+ b.current = new AbortController();
799
+ const { signal: g } = b.current, s = () => {
800
+ C().forEach((v) => {
801
+ const T = v.querySelector(".endOfContent");
802
+ T && (v.appendChild(T), T.style.width = "", T.style.height = "", v.classList.remove(pe.selecting));
803
803
  });
804
804
  };
805
805
  document.addEventListener(
@@ -827,87 +827,87 @@ const xo = () => {
827
827
  },
828
828
  { signal: g }
829
829
  );
830
- let C = null;
830
+ let P = null;
831
831
  document.addEventListener(
832
832
  "selectionchange",
833
833
  () => {
834
834
  var A, L;
835
- const b = document.getSelection();
836
- if (!b)
835
+ const v = document.getSelection();
836
+ if (!v)
837
837
  return;
838
- if (b.rangeCount === 0) {
838
+ if (v.rangeCount === 0) {
839
839
  s();
840
840
  return;
841
841
  }
842
842
  const T = /* @__PURE__ */ new Set();
843
- for (let I = 0; I < b.rangeCount; I++) {
844
- const O = b.getRangeAt(I);
845
- _().forEach((M) => {
846
- O.intersectsNode(M) && !T.has(M) && T.add(M);
843
+ for (let x = 0; x < v.rangeCount; x++) {
844
+ const D = v.getRangeAt(x);
845
+ C().forEach((M) => {
846
+ D.intersectsNode(M) && !T.has(M) && T.add(M);
847
847
  });
848
848
  }
849
- _().forEach((I) => {
850
- if (T.has(I))
851
- I.classList.add(pe.selecting);
849
+ C().forEach((x) => {
850
+ if (T.has(x))
851
+ x.classList.add(pe.selecting);
852
852
  else {
853
- const O = I.querySelector(".endOfContent");
854
- O && (I.appendChild(O), O.style.width = "", O.style.height = "", I.classList.remove(pe.selecting));
853
+ const D = x.querySelector(".endOfContent");
854
+ D && (x.appendChild(D), D.style.width = "", D.style.height = "", x.classList.remove(pe.selecting));
855
855
  }
856
856
  });
857
- const E = b.getRangeAt(0);
858
- let R = C && (E.compareBoundaryPoints(Range.END_TO_END, C) === 0 || E.compareBoundaryPoints(Range.START_TO_END, C) === 0) ? E.startContainer : E.endContainer;
857
+ const E = v.getRangeAt(0);
858
+ let R = P && (E.compareBoundaryPoints(Range.END_TO_END, P) === 0 || E.compareBoundaryPoints(Range.START_TO_END, P) === 0) ? E.startContainer : E.endContainer;
859
859
  R.nodeType === Node.TEXT_NODE && (R = R.parentNode);
860
- const D = (A = R.parentElement) == null ? void 0 : A.closest(
860
+ const O = (A = R.parentElement) == null ? void 0 : A.closest(
861
861
  pe["rp-text-layer"]
862
- ), z = D == null ? void 0 : D.querySelector(".endOfContent");
863
- z && D && (z.style.width = D.style.width, z.style.height = D.style.height, (L = R.parentElement) == null || L.insertBefore(z, R.nextSibling)), C = E.cloneRange();
862
+ ), z = O == null ? void 0 : O.querySelector(".endOfContent");
863
+ z && O && (z.style.width = O.style.width, z.style.height = O.style.height, (L = R.parentElement) == null || L.insertBefore(z, R.nextSibling)), P = E.cloneRange();
864
864
  },
865
865
  { signal: g }
866
866
  );
867
867
  })(), () => {
868
868
  var g;
869
- (g = P.current) == null || g.abort(), P.current = void 0;
870
- }), [_]);
869
+ (g = b.current) == null || g.abort(), b.current = void 0;
870
+ }), [C]);
871
871
  const y = N(() => {
872
872
  o.current && o.current.classList.add(pe.selecting);
873
- }, []), h = N(() => {
873
+ }, []), f = N(() => {
874
874
  o.current && o.current.classList.remove(pe.selecting);
875
875
  }, []);
876
876
  return F(() => {
877
- if (v.current.forEach((s) => {
877
+ if (w.current.forEach((s) => {
878
878
  s.classList.remove("selected");
879
879
  }), !c.length || !a || a.pageIndex !== e - 1)
880
880
  return;
881
- const f = p.findIndex(
881
+ const h = p.findIndex(
882
882
  (s) => JSON.stringify(s) === JSON.stringify(a)
883
883
  );
884
- if (f === -1)
884
+ if (h === -1)
885
885
  return;
886
- const g = c.filter((s) => s.index === f);
887
- g.length && (v.current = g.map((s) => s.element), l(g[0].element), g.forEach((s) => {
886
+ const g = c.filter((s) => s.index === h);
887
+ g.length && (w.current = g.map((s) => s.element), l(g[0].element), g.forEach((s) => {
888
888
  s.element.classList.add("selected");
889
889
  }));
890
890
  }, [a, c, p]), F(() => {
891
- const f = n.get(e);
892
- if (!f || !o.current)
891
+ const h = n.get(e);
892
+ if (!h || !o.current)
893
893
  return;
894
894
  const g = o.current;
895
- return d.current && d.current.cancel(), f.page.getTextContent().then((s) => {
896
- const C = f.page.getViewport({ scale: 1 });
895
+ return d.current && d.current.cancel(), h.page.getTextContent().then((s) => {
896
+ const P = h.page.getViewport({ scale: 1 });
897
897
  return d.current = new yr.TextLayer({
898
- viewport: C,
898
+ viewport: P,
899
899
  textContentSource: s,
900
900
  container: g
901
901
  }), m.current = s, g && (g.innerText = ""), d.current.render();
902
902
  }).then(() => {
903
903
  var T, E;
904
- [].slice.call(g.children).forEach((x) => {
905
- x.classList.add(pe["rp-text-layer-text"]), x.setAttribute("data-rp", "rp-text-layer-text");
904
+ [].slice.call(g.children).forEach((I) => {
905
+ I.classList.add(pe["rp-text-layer-text"]), I.setAttribute("data-rp", "rp-text-layer-text");
906
906
  });
907
- const C = (T = d.current) == null ? void 0 : T.textDivs;
908
- C && m.current && w(m.current, C);
909
- const b = document.createElement("div");
910
- b.className = "endOfContent", (E = o.current) == null || E.appendChild(b);
907
+ const P = (T = d.current) == null ? void 0 : T.textDivs;
908
+ P && m.current && _(m.current, P);
909
+ const v = document.createElement("div");
910
+ v.className = "endOfContent", (E = o.current) == null || E.appendChild(v);
911
911
  }).catch(() => {
912
912
  }), () => {
913
913
  var s;
@@ -915,19 +915,19 @@ const xo = () => {
915
915
  };
916
916
  }, [n, e]), F(() => {
917
917
  var s;
918
- [].slice.call(o.current.children).forEach((C) => {
919
- C.classList.add(pe["rp-text-layer-text"]);
918
+ [].slice.call(o.current.children).forEach((P) => {
919
+ P.classList.add(pe["rp-text-layer-text"]);
920
920
  });
921
921
  const g = (s = d.current) == null ? void 0 : s.textDivs;
922
- g && m.current && w(m.current, g, !0);
923
- }, [w]), /* @__PURE__ */ i(
922
+ g && m.current && _(m.current, g, !0);
923
+ }, [_]), /* @__PURE__ */ i(
924
924
  "div",
925
925
  {
926
926
  "data-rp": `page-${e}-textLayer`,
927
927
  className: pe["rp-text-layer"],
928
928
  ref: o,
929
929
  onMouseDown: y,
930
- onMouseUp: h
930
+ onMouseUp: f
931
931
  }
932
932
  );
933
933
  }, Oo = {
@@ -935,30 +935,30 @@ const xo = () => {
935
935
  };
936
936
  let Do = "https://unpkg.com/pdfjs-dist@4.4.168/web/images/";
937
937
  const zo = (t) => {
938
- const { pageNumber: e } = t, n = H(null), { pages: o, pdf: r } = ee(), a = H(), [l, c] = $(), { setFocusedPage: u, goToPage: d } = ie(), { scrollMode: m } = Ee(), { print: v } = tt(), { download: p } = Gn(), w = k(() => o.get(e), [o, e]), P = k(() => w == null ? void 0 : w.page.getViewport(), [w]);
938
+ const { pageNumber: e } = t, n = H(null), { pages: o, pdf: r } = ee(), a = H(), [l, c] = $(), { setFocusedPage: u, goToPage: d } = ie(), { scrollMode: m } = Ne(), { print: w } = tt(), { download: p } = Gn(), _ = k(() => o.get(e), [o, e]), b = k(() => _ == null ? void 0 : _.page.getViewport(), [_]);
939
939
  F(() => {
940
940
  a.current && (a.current.div.replaceChildren(), a.current = void 0);
941
941
  }, [r]), F(() => {
942
- w && w.page.getAnnotations().then((_) => {
943
- a.current = void 0, c(_), n.current && (n.current.innerText = "");
942
+ _ && _.page.getAnnotations().then((C) => {
943
+ a.current = void 0, c(C), n.current && (n.current.innerText = "");
944
944
  });
945
- }, [w]);
945
+ }, [_]);
946
946
  const S = N(
947
- (_) => {
948
- !l || !r || (Nr(_), Or(_, r, l).then((y) => {
949
- var h, f;
950
- ((h = y == null ? void 0 : y.data) == null ? void 0 : h.action) === "Print" ? v() : ((f = y == null ? void 0 : y.data) == null ? void 0 : f.action) === "SaveAs" && p();
951
- }), m === Q.PAGE_SCROLLING ? At(_, l, r, (y) => u(y.pageIndex + 1)) : At(_, l, r, (y) => d(y.pageIndex + 1)));
947
+ (C) => {
948
+ !l || !r || (Nr(C), Or(C, r, l).then((y) => {
949
+ var f, h;
950
+ ((f = y == null ? void 0 : y.data) == null ? void 0 : f.action) === "Print" ? w() : ((h = y == null ? void 0 : y.data) == null ? void 0 : h.action) === "SaveAs" && p();
951
+ }), m === Q.PAGE_SCROLLING ? At(C, l, r, (y) => u(y.pageIndex + 1)) : At(C, l, r, (y) => d(y.pageIndex + 1)));
952
952
  },
953
- [r, l, d, u, m, v, p]
953
+ [r, l, d, u, m, w, p]
954
954
  );
955
955
  return F(() => {
956
- if (!w || !l)
956
+ if (!_ || !l)
957
957
  return;
958
- const _ = w.page.getViewport();
958
+ const C = _.page.getViewport();
959
959
  if (a.current) {
960
960
  a.current.update({
961
- viewport: _.clone({ dontFlip: !0 })
961
+ viewport: C.clone({ dontFlip: !0 })
962
962
  });
963
963
  return;
964
964
  }
@@ -970,33 +970,33 @@ const zo = (t) => {
970
970
  zr(g);
971
971
  break;
972
972
  case zt.Widget:
973
- Dr(g, _, y);
973
+ Dr(g, C, y);
974
974
  break;
975
975
  }
976
976
  }
977
- const h = new AbortController();
977
+ const f = new AbortController();
978
978
  return (async () => {
979
- var C;
979
+ var P;
980
980
  a.current && (a.current.div.replaceChildren(), a.current = void 0), n.current && (n.current.innerText = ""), a.current = new Lr({
981
981
  div: n.current,
982
982
  accessibilityManager: void 0,
983
983
  annotationCanvasMap: void 0,
984
984
  annotationEditorUIManager: void 0,
985
985
  structTreeLayer: null,
986
- page: w.page,
987
- viewport: _.clone({ dontFlip: !0 })
986
+ page: _.page,
987
+ viewport: C.clone({ dontFlip: !0 })
988
988
  }), n.current && Ft(n.current, S);
989
989
  const g = await (r == null ? void 0 : r.hasJSActions()), s = await (r == null ? void 0 : r.getFieldObjects());
990
- if (h.signal.aborted)
990
+ if (f.signal.aborted)
991
991
  throw "abort";
992
- return (C = a.current) == null ? void 0 : C.render({
992
+ return (P = a.current) == null ? void 0 : P.render({
993
993
  annotations: l,
994
994
  annotationStorage: r == null ? void 0 : r.annotationStorage,
995
995
  hasJSActions: g,
996
996
  fieldObjects: s,
997
997
  div: n.current,
998
- viewport: _.clone({ dontFlip: !0 }),
999
- page: w.page,
998
+ viewport: C.clone({ dontFlip: !0 }),
999
+ page: _.page,
1000
1000
  imageResourcesPath: Do,
1001
1001
  renderForms: !0,
1002
1002
  linkService: new Er(),
@@ -1009,13 +1009,13 @@ const zo = (t) => {
1009
1009
  if (g !== "abort")
1010
1010
  throw g;
1011
1011
  }), () => {
1012
- h.abort("clear"), n.current && Ft(n.current, S);
1012
+ f.abort("clear"), n.current && Ft(n.current, S);
1013
1013
  };
1014
1014
  }, [r, l, S]), /* @__PURE__ */ i(
1015
1015
  "div",
1016
1016
  {
1017
1017
  "data-rp": `page-${e}-annotationLayer`,
1018
- style: { width: `${P == null ? void 0 : P.width}px`, height: `${P == null ? void 0 : P.height}px` },
1018
+ style: { width: `${b == null ? void 0 : b.width}px`, height: `${b == null ? void 0 : b.height}px` },
1019
1019
  className: Oo["rp-annotation-layer"],
1020
1020
  ref: n
1021
1021
  }
@@ -1023,92 +1023,92 @@ const zo = (t) => {
1023
1023
  }, Ao = {
1024
1024
  "rp-text-highlight": "_rp-text-highlight_jdkf8_1"
1025
1025
  }, Fo = ({ pageNumber: t, viewport: e }) => {
1026
- const [n, o] = $(), { pages: r } = ee(), { highlightKeywords: a } = hr(), l = !0, c = H(null), [u, d] = $(null), [m, v] = $([]);
1026
+ const [n, o] = $(), { pages: r } = ee(), { highlightKeywords: a } = hr(), l = !0, c = H(null), [u, d] = $(null), [m, w] = $([]);
1027
1027
  F(() => {
1028
1028
  c.current && d(c.current.parentElement);
1029
1029
  }, [c]), F(() => {
1030
1030
  (async () => {
1031
- const f = r.get(t);
1032
- if (!f || !c.current)
1031
+ const h = r.get(t);
1032
+ if (!h || !c.current)
1033
1033
  return;
1034
- const g = await f.page.getTextContent();
1034
+ const g = await h.page.getTextContent();
1035
1035
  o(g);
1036
1036
  })();
1037
1037
  }, [r, t]);
1038
- const p = k(() => a ? a.map((h) => {
1039
- var f, g;
1038
+ const p = k(() => a ? a.map((f) => {
1039
+ var h, g;
1040
1040
  return {
1041
- ...Fr(h.keyword, (f = h.options) == null ? void 0 : f.matchCase, (g = h.options) == null ? void 0 : g.wholeWords),
1042
- color: h.highlightColor
1041
+ ...Fr(f.keyword, (h = f.options) == null ? void 0 : h.matchCase, (g = f.options) == null ? void 0 : g.wholeWords),
1042
+ color: f.highlightColor
1043
1043
  };
1044
1044
  }) : [], [a]);
1045
- function w(h, f) {
1046
- if (!h)
1045
+ function _(f, h) {
1046
+ if (!f)
1047
1047
  return;
1048
- const g = `[data-rp="page-${f}-textLayer"]`;
1048
+ const g = `[data-rp="page-${h}-textLayer"]`;
1049
1049
  return new Promise((s) => {
1050
- const C = h.querySelector(g);
1051
- if (C) {
1052
- s(C);
1050
+ const P = f.querySelector(g);
1051
+ if (P) {
1052
+ s(P);
1053
1053
  return;
1054
1054
  }
1055
1055
  new MutationObserver((T, E) => {
1056
- const x = h.querySelector(g);
1057
- x && (s(x), E.disconnect());
1058
- }).observe(h, { childList: !0, subtree: !0 });
1056
+ const I = f.querySelector(g);
1057
+ I && (s(I), E.disconnect());
1058
+ }).observe(f, { childList: !0, subtree: !0 });
1059
1059
  });
1060
1060
  }
1061
- function P(h) {
1062
- return new Promise((f) => {
1063
- const g = h.querySelectorAll(
1061
+ function b(f) {
1062
+ return new Promise((h) => {
1063
+ const g = f.querySelectorAll(
1064
1064
  '[data-rp="rp-text-layer-text"]'
1065
1065
  );
1066
1066
  if (g.length) {
1067
- f(Array.from(g));
1067
+ h(Array.from(g));
1068
1068
  return;
1069
1069
  }
1070
- new MutationObserver((C, b) => {
1071
- const T = h.querySelectorAll(
1070
+ new MutationObserver((P, v) => {
1071
+ const T = f.querySelectorAll(
1072
1072
  ".rp-text-layer-text"
1073
1073
  );
1074
- T.length && (f(Array.from(T)), b.disconnect());
1075
- }).observe(h, { childList: !0, subtree: !0 });
1074
+ T.length && (h(Array.from(T)), v.disconnect());
1075
+ }).observe(f, { childList: !0, subtree: !0 });
1076
1076
  });
1077
1077
  }
1078
- const S = (h, f, g, s) => {
1078
+ const S = (f, h, g, s) => {
1079
1079
  var Z;
1080
- const C = document.createRange(), b = g.firstChild;
1081
- if (!b || b.nodeType !== Node.TEXT_NODE)
1080
+ const P = document.createRange(), v = g.firstChild;
1081
+ if (!v || v.nodeType !== Node.TEXT_NODE)
1082
1082
  return null;
1083
- const T = ((Z = b.textContent) == null ? void 0 : Z.length) ?? 0, E = s[0].charIdxInSpan, x = s.length === 1 ? E : s[s.length - 1].charIdxInSpan;
1084
- if (E > T || x + 1 > T)
1083
+ const T = ((Z = v.textContent) == null ? void 0 : Z.length) ?? 0, E = s[0].charIdxInSpan, I = s.length === 1 ? E : s[s.length - 1].charIdxInSpan;
1084
+ if (E > T || I + 1 > T)
1085
1085
  return null;
1086
- C.setStart(b, E), C.setEnd(b, x + 1);
1086
+ P.setStart(v, E), P.setEnd(v, I + 1);
1087
1087
  const R = document.createElement("span");
1088
- R.style.width = "auto", C.surroundContents(R);
1089
- const D = R.getBoundingClientRect(), z = h.getBoundingClientRect(), A = z.height, L = z.width, I = 100 * (D.left - z.left) / L, O = 100 * (D.top - z.top) / A, M = 100 * D.height / A, G = 100 * D.width / L;
1088
+ R.style.width = "auto", P.surroundContents(R);
1089
+ const O = R.getBoundingClientRect(), z = f.getBoundingClientRect(), A = z.height, L = z.width, x = 100 * (O.left - z.left) / L, D = 100 * (O.top - z.top) / A, M = 100 * O.height / A, G = 100 * O.width / L;
1090
1090
  return kr(R), {
1091
- keywordStr: f,
1092
- left: I,
1093
- top: O,
1091
+ keywordStr: h,
1092
+ left: x,
1093
+ top: D,
1094
1094
  height: M,
1095
1095
  width: G,
1096
1096
  pageHeight: A,
1097
1097
  pageWidth: L
1098
1098
  };
1099
1099
  };
1100
- async function _(h, f) {
1101
- const g = await w(u, h);
1100
+ async function C(f, h) {
1101
+ const g = await _(u, f);
1102
1102
  if (!g)
1103
1103
  return;
1104
- const s = await P(g);
1104
+ const s = await b(g);
1105
1105
  if (s.length) {
1106
- const C = s.map((T) => T.tagName === "BR" ? " " : T.textContent).reduce(
1107
- (T, E, x) => T.concat(
1108
- E.split("").map((R, D) => ({
1106
+ const P = s.map((T) => T.tagName === "BR" ? " " : T.textContent).reduce(
1107
+ (T, E, I) => T.concat(
1108
+ E.split("").map((R, O) => ({
1109
1109
  char: R,
1110
- charIdxInSpan: D,
1111
- spanIdx: x
1110
+ charIdxInSpan: O,
1111
+ spanIdx: I
1112
1112
  }))
1113
1113
  ),
1114
1114
  [
@@ -1118,29 +1118,29 @@ const zo = (t) => {
1118
1118
  spanIdx: 0
1119
1119
  }
1120
1120
  ]
1121
- ).slice(1), b = y(g, f, s, C);
1122
- v(b);
1121
+ ).slice(1), v = y(g, h, s, P);
1122
+ w(v);
1123
1123
  }
1124
1124
  }
1125
- const y = (h, f, g, s) => {
1126
- const C = f.length;
1127
- if (!s.length || !C)
1125
+ const y = (f, h, g, s) => {
1126
+ const P = h.length;
1127
+ if (!s.length || !P)
1128
1128
  return [];
1129
- const b = [], T = s.map((E) => E.char).join("");
1129
+ const v = [], T = s.map((E) => E.char).join("");
1130
1130
  return p.forEach((E) => {
1131
- const { keyword: x, regExp: R, wholeWords: D, color: z } = E, A = x;
1131
+ const { keyword: I, regExp: R, wholeWords: O, color: z } = E, A = I;
1132
1132
  if (!A.trim())
1133
1133
  return;
1134
1134
  const L = R.flags.indexOf("g") === -1 ? new RegExp(R, `${R.flags}g`) : R;
1135
- let I;
1136
- const O = [];
1137
- for (; (I = L.exec(T)) !== null; )
1138
- D && !pr(T, I.index, I[0].length) || O.push({
1135
+ let x;
1136
+ const D = [];
1137
+ for (; (x = L.exec(T)) !== null; )
1138
+ O && !pr(T, x.index, x[0].length) || D.push({
1139
1139
  keyword: L,
1140
- startIndex: I.index,
1140
+ startIndex: x.index,
1141
1141
  endIndex: L.lastIndex
1142
1142
  });
1143
- const M = O.map((G) => ({
1143
+ const M = D.map((G) => ({
1144
1144
  keyword: G.keyword,
1145
1145
  indexes: s.slice(G.startIndex, G.endIndex),
1146
1146
  color: z
@@ -1153,46 +1153,46 @@ const zo = (t) => {
1153
1153
  for (const j of Object.values(Z))
1154
1154
  if (j.length !== 1 || j[0].char.trim() !== "") {
1155
1155
  const q = j, te = g[q[0].spanIdx], X = S(
1156
- h,
1156
+ f,
1157
1157
  A,
1158
1158
  te,
1159
1159
  q
1160
1160
  );
1161
1161
  if (X) {
1162
1162
  const { left: ce, top: ve } = X;
1163
- if (b.find((Y) => Y.left === ce && Y.top === ve))
1163
+ if (v.find((Y) => Y.left === ce && Y.top === ve))
1164
1164
  continue;
1165
- b.push({ ...X, highlightColor: G.color });
1165
+ v.push({ ...X, highlightColor: G.color });
1166
1166
  }
1167
1167
  }
1168
1168
  }
1169
- }), b.sort(Wr), b;
1169
+ }), v.sort(Wr), v;
1170
1170
  };
1171
1171
  return F(() => {
1172
1172
  (async () => {
1173
1173
  if (!(!a || a.length === 0))
1174
1174
  try {
1175
- await _(t, a);
1176
- } catch (f) {
1177
- console.error(f);
1175
+ await C(t, a);
1176
+ } catch (h) {
1177
+ console.error(h);
1178
1178
  }
1179
1179
  })();
1180
- }, [l, a, t, n, e]), /* @__PURE__ */ i(fe, { children: /* @__PURE__ */ i("div", { ref: c, "data-rp": `page-${t}-textHighlightLayer`, children: m.map((h, f) => /* @__PURE__ */ i(
1180
+ }, [l, a, t, n, e]), /* @__PURE__ */ i(fe, { children: /* @__PURE__ */ i("div", { ref: c, "data-rp": `page-${t}-textHighlightLayer`, children: m.map((f, h) => /* @__PURE__ */ i(
1181
1181
  "div",
1182
1182
  {
1183
1183
  className: Ao["rp-text-highlight"],
1184
1184
  style: {
1185
- top: `${h.top}%`,
1186
- left: `${h.left}%`,
1187
- width: `${h.width}%`,
1188
- height: `${h.height}%`,
1189
- backgroundColor: h.highlightColor
1185
+ top: `${f.top}%`,
1186
+ left: `${f.left}%`,
1187
+ width: `${f.width}%`,
1188
+ height: `${f.height}%`,
1189
+ backgroundColor: f.highlightColor
1190
1190
  }
1191
1191
  },
1192
- f
1192
+ h
1193
1193
  )) }) });
1194
1194
  }, Rt = $e((t, e) => {
1195
- const { pageNumber: n, style: o, ...r } = t, { pages: a } = ee(), { pageRotate: l } = Ue(), { textLayer: c } = ir(), { currentZoom: u } = Qe(), d = H(a.get(n)), [m, v] = $(!1), p = H(null), [w, P] = $({
1195
+ const { pageNumber: n, style: o, ...r } = t, { pages: a } = ee(), { pageRotate: l } = Ue(), { textLayer: c } = ir(), { currentZoom: u } = Qe(), d = H(a.get(n)), [m, w] = $(!1), p = H(null), [_, b] = $({
1196
1196
  width: 0,
1197
1197
  height: 0
1198
1198
  });
@@ -1200,27 +1200,27 @@ const zo = (t) => {
1200
1200
  const S = k(() => d.current ? l[n] : 0, [n, l]);
1201
1201
  F(() => {
1202
1202
  if (a && (d.current = a.get(n), d.current)) {
1203
- const f = d.current.page.getViewport({
1203
+ const h = d.current.page.getViewport({
1204
1204
  scale: u,
1205
1205
  rotation: S
1206
1206
  });
1207
- P(f);
1207
+ b(h);
1208
1208
  }
1209
1209
  }, [a, n, S, u]);
1210
- const _ = k(() => {
1210
+ const C = k(() => {
1211
1211
  switch (S) {
1212
1212
  case 90:
1213
- return `${w.width / 2}px ${w.width / 2}px`;
1213
+ return `${_.width / 2}px ${_.width / 2}px`;
1214
1214
  case -90:
1215
1215
  case 270:
1216
- return `${w.height / 2}px ${w.height / 2}px`;
1216
+ return `${_.height / 2}px ${_.height / 2}px`;
1217
1217
  default:
1218
1218
  return "center";
1219
1219
  }
1220
- }, [S, w]), y = N(() => {
1221
- v(!0);
1222
- }, []), h = N(() => {
1223
- v(!1);
1220
+ }, [S, _]), y = N(() => {
1221
+ w(!0);
1222
+ }, []), f = N(() => {
1223
+ w(!1);
1224
1224
  }, []);
1225
1225
  return /* @__PURE__ */ i(
1226
1226
  "div",
@@ -1232,7 +1232,7 @@ const zo = (t) => {
1232
1232
  style: {
1233
1233
  ...o,
1234
1234
  "--rp-rotate": `${S}deg`,
1235
- "--rp-page-rotate-translate": `${_}`,
1235
+ "--rp-page-rotate-translate": `${C}`,
1236
1236
  "--scale-factor": u
1237
1237
  },
1238
1238
  className: dt["rp-page-wrapper"],
@@ -1240,16 +1240,16 @@ const zo = (t) => {
1240
1240
  "div",
1241
1241
  {
1242
1242
  style: {
1243
- width: `${w.width}px`,
1244
- height: `${w.height}px`
1243
+ width: `${_.width}px`,
1244
+ height: `${_.height}px`
1245
1245
  },
1246
1246
  className: dt["rp-page"],
1247
1247
  children: [
1248
- /* @__PURE__ */ i(Lo, { onLoading: y, onLoaded: h, pageNumber: n }),
1248
+ /* @__PURE__ */ i(Lo, { onLoading: y, onLoaded: f, pageNumber: n }),
1249
1249
  m && /* @__PURE__ */ i("div", { className: dt["rp-loader-wrapper"], children: /* @__PURE__ */ i(Pt, {}) }),
1250
1250
  /* @__PURE__ */ i(Mr, { pageNumber: n }),
1251
1251
  c && /* @__PURE__ */ i(No, { pageNumber: n }),
1252
- /* @__PURE__ */ i(Fo, { pageNumber: n, viewport: w }),
1252
+ /* @__PURE__ */ i(Fo, { pageNumber: n, viewport: _ }),
1253
1253
  /* @__PURE__ */ i(zo, { pageNumber: n })
1254
1254
  ]
1255
1255
  }
@@ -1332,15 +1332,15 @@ function Go(t) {
1332
1332
  }
1333
1333
  return pt;
1334
1334
  }
1335
- var Oe = null;
1335
+ var De = null;
1336
1336
  function jt(t) {
1337
- if (t === void 0 && (t = !1), Oe === null || t) {
1337
+ if (t === void 0 && (t = !1), De === null || t) {
1338
1338
  var e = document.createElement("div"), n = e.style;
1339
1339
  n.width = "50px", n.height = "50px", n.overflow = "scroll", n.direction = "rtl";
1340
1340
  var o = document.createElement("div"), r = o.style;
1341
- return r.width = "100px", r.height = "100px", e.appendChild(o), document.body.appendChild(e), e.scrollLeft > 0 ? Oe = "positive-descending" : (e.scrollLeft = 1, e.scrollLeft === 0 ? Oe = "negative" : Oe = "positive-ascending"), document.body.removeChild(e), Oe;
1341
+ return r.width = "100px", r.height = "100px", e.appendChild(o), document.body.appendChild(e), e.scrollLeft > 0 ? De = "positive-descending" : (e.scrollLeft = 1, e.scrollLeft === 0 ? De = "negative" : De = "positive-ascending"), document.body.removeChild(e), De;
1342
1342
  }
1343
- return Oe;
1343
+ return De;
1344
1344
  }
1345
1345
  var Uo = 150, Vo = function(e) {
1346
1346
  var n = e.columnIndex;
@@ -1350,12 +1350,12 @@ var Uo = 150, Vo = function(e) {
1350
1350
  }, Be = null, Ze = null, je = null;
1351
1351
  process.env.NODE_ENV !== "production" && typeof window < "u" && typeof window.WeakSet < "u" && (Be = /* @__PURE__ */ new WeakSet(), Ze = /* @__PURE__ */ new WeakSet(), je = /* @__PURE__ */ new WeakSet());
1352
1352
  function qo(t) {
1353
- var e, n = t.getColumnOffset, o = t.getColumnStartIndexForOffset, r = t.getColumnStopIndexForStartIndex, a = t.getColumnWidth, l = t.getEstimatedTotalHeight, c = t.getEstimatedTotalWidth, u = t.getOffsetForColumnAndAlignment, d = t.getOffsetForRowAndAlignment, m = t.getRowHeight, v = t.getRowOffset, p = t.getRowStartIndexForOffset, w = t.getRowStopIndexForStartIndex, P = t.initInstanceProps, S = t.shouldResetStyleCacheOnItemSizeChange, _ = t.validateProps;
1353
+ var e, n = t.getColumnOffset, o = t.getColumnStartIndexForOffset, r = t.getColumnStopIndexForStartIndex, a = t.getColumnWidth, l = t.getEstimatedTotalHeight, c = t.getEstimatedTotalWidth, u = t.getOffsetForColumnAndAlignment, d = t.getOffsetForRowAndAlignment, m = t.getRowHeight, w = t.getRowOffset, p = t.getRowStartIndexForOffset, _ = t.getRowStopIndexForStartIndex, b = t.initInstanceProps, S = t.shouldResetStyleCacheOnItemSizeChange, C = t.validateProps;
1354
1354
  return e = /* @__PURE__ */ function(y) {
1355
- Wo(h, y);
1356
- function h(g) {
1355
+ Wo(f, y);
1356
+ function f(g) {
1357
1357
  var s;
1358
- return s = y.call(this, g) || this, s._instanceProps = P(s.props, Ut(s)), s._resetIsScrollingTimeoutId = null, s._outerRef = void 0, s.state = {
1358
+ return s = y.call(this, g) || this, s._instanceProps = b(s.props, Ut(s)), s._resetIsScrollingTimeoutId = null, s._outerRef = void 0, s.state = {
1359
1359
  instance: Ut(s),
1360
1360
  isScrolling: !1,
1361
1361
  horizontalScrollDirection: "forward",
@@ -1363,72 +1363,72 @@ function qo(t) {
1363
1363
  scrollTop: typeof s.props.initialScrollTop == "number" ? s.props.initialScrollTop : 0,
1364
1364
  scrollUpdateWasRequested: !1,
1365
1365
  verticalScrollDirection: "forward"
1366
- }, s._callOnItemsRendered = void 0, s._callOnItemsRendered = ut(function(C, b, T, E, x, R, D, z) {
1366
+ }, s._callOnItemsRendered = void 0, s._callOnItemsRendered = ut(function(P, v, T, E, I, R, O, z) {
1367
1367
  return s.props.onItemsRendered({
1368
- overscanColumnStartIndex: C,
1369
- overscanColumnStopIndex: b,
1368
+ overscanColumnStartIndex: P,
1369
+ overscanColumnStopIndex: v,
1370
1370
  overscanRowStartIndex: T,
1371
1371
  overscanRowStopIndex: E,
1372
- visibleColumnStartIndex: x,
1372
+ visibleColumnStartIndex: I,
1373
1373
  visibleColumnStopIndex: R,
1374
- visibleRowStartIndex: D,
1374
+ visibleRowStartIndex: O,
1375
1375
  visibleRowStopIndex: z
1376
1376
  });
1377
- }), s._callOnScroll = void 0, s._callOnScroll = ut(function(C, b, T, E, x) {
1377
+ }), s._callOnScroll = void 0, s._callOnScroll = ut(function(P, v, T, E, I) {
1378
1378
  return s.props.onScroll({
1379
1379
  horizontalScrollDirection: T,
1380
- scrollLeft: C,
1381
- scrollTop: b,
1380
+ scrollLeft: P,
1381
+ scrollTop: v,
1382
1382
  verticalScrollDirection: E,
1383
- scrollUpdateWasRequested: x
1383
+ scrollUpdateWasRequested: I
1384
1384
  });
1385
- }), s._getItemStyle = void 0, s._getItemStyle = function(C, b) {
1386
- var T = s.props, E = T.columnWidth, x = T.direction, R = T.rowHeight, D = s._getItemStyleCache(S && E, S && x, S && R), z = C + ":" + b, A;
1387
- if (D.hasOwnProperty(z))
1388
- A = D[z];
1385
+ }), s._getItemStyle = void 0, s._getItemStyle = function(P, v) {
1386
+ var T = s.props, E = T.columnWidth, I = T.direction, R = T.rowHeight, O = s._getItemStyleCache(S && E, S && I, S && R), z = P + ":" + v, A;
1387
+ if (O.hasOwnProperty(z))
1388
+ A = O[z];
1389
1389
  else {
1390
- var L = n(s.props, b, s._instanceProps), I = x === "rtl";
1391
- D[z] = A = {
1390
+ var L = n(s.props, v, s._instanceProps), x = I === "rtl";
1391
+ O[z] = A = {
1392
1392
  position: "absolute",
1393
- left: I ? void 0 : L,
1394
- right: I ? L : void 0,
1395
- top: v(s.props, C, s._instanceProps),
1396
- height: m(s.props, C, s._instanceProps),
1397
- width: a(s.props, b, s._instanceProps)
1393
+ left: x ? void 0 : L,
1394
+ right: x ? L : void 0,
1395
+ top: w(s.props, P, s._instanceProps),
1396
+ height: m(s.props, P, s._instanceProps),
1397
+ width: a(s.props, v, s._instanceProps)
1398
1398
  };
1399
1399
  }
1400
1400
  return A;
1401
- }, s._getItemStyleCache = void 0, s._getItemStyleCache = ut(function(C, b, T) {
1401
+ }, s._getItemStyleCache = void 0, s._getItemStyleCache = ut(function(P, v, T) {
1402
1402
  return {};
1403
- }), s._onScroll = function(C) {
1404
- var b = C.currentTarget, T = b.clientHeight, E = b.clientWidth, x = b.scrollLeft, R = b.scrollTop, D = b.scrollHeight, z = b.scrollWidth;
1403
+ }), s._onScroll = function(P) {
1404
+ var v = P.currentTarget, T = v.clientHeight, E = v.clientWidth, I = v.scrollLeft, R = v.scrollTop, O = v.scrollHeight, z = v.scrollWidth;
1405
1405
  s.setState(function(A) {
1406
- if (A.scrollLeft === x && A.scrollTop === R)
1406
+ if (A.scrollLeft === I && A.scrollTop === R)
1407
1407
  return null;
1408
- var L = s.props.direction, I = x;
1408
+ var L = s.props.direction, x = I;
1409
1409
  if (L === "rtl")
1410
1410
  switch (jt()) {
1411
1411
  case "negative":
1412
- I = -x;
1412
+ x = -I;
1413
1413
  break;
1414
1414
  case "positive-descending":
1415
- I = z - E - x;
1415
+ x = z - E - I;
1416
1416
  break;
1417
1417
  }
1418
- I = Math.max(0, Math.min(I, z - E));
1419
- var O = Math.max(0, Math.min(R, D - T));
1418
+ x = Math.max(0, Math.min(x, z - E));
1419
+ var D = Math.max(0, Math.min(R, O - T));
1420
1420
  return {
1421
1421
  isScrolling: !0,
1422
- horizontalScrollDirection: A.scrollLeft < x ? "forward" : "backward",
1423
- scrollLeft: I,
1424
- scrollTop: O,
1422
+ horizontalScrollDirection: A.scrollLeft < I ? "forward" : "backward",
1423
+ scrollLeft: x,
1424
+ scrollTop: D,
1425
1425
  verticalScrollDirection: A.scrollTop < R ? "forward" : "backward",
1426
1426
  scrollUpdateWasRequested: !1
1427
1427
  };
1428
1428
  }, s._resetIsScrollingDebounced);
1429
- }, s._outerRefSetter = function(C) {
1430
- var b = s.props.outerRef;
1431
- s._outerRef = C, typeof b == "function" ? b(C) : b != null && typeof b == "object" && b.hasOwnProperty("current") && (b.current = C);
1429
+ }, s._outerRefSetter = function(P) {
1430
+ var v = s.props.outerRef;
1431
+ s._outerRef = P, typeof v == "function" ? v(P) : v != null && typeof v == "object" && v.hasOwnProperty("current") && (v.current = P);
1432
1432
  }, s._resetIsScrollingDebounced = function() {
1433
1433
  s._resetIsScrollingTimeoutId !== null && Zt(s._resetIsScrollingTimeoutId), s._resetIsScrollingTimeoutId = $o(s._resetIsScrolling, Uo);
1434
1434
  }, s._resetIsScrolling = function() {
@@ -1439,70 +1439,70 @@ function qo(t) {
1439
1439
  });
1440
1440
  }, s;
1441
1441
  }
1442
- h.getDerivedStateFromProps = function(s, C) {
1443
- return Bo(s, C), _(s), null;
1442
+ f.getDerivedStateFromProps = function(s, P) {
1443
+ return Bo(s, P), C(s), null;
1444
1444
  };
1445
- var f = h.prototype;
1446
- return f.scrollTo = function(s) {
1447
- var C = s.scrollLeft, b = s.scrollTop;
1448
- C !== void 0 && (C = Math.max(0, C)), b !== void 0 && (b = Math.max(0, b)), this.setState(function(T) {
1449
- return C === void 0 && (C = T.scrollLeft), b === void 0 && (b = T.scrollTop), T.scrollLeft === C && T.scrollTop === b ? null : {
1450
- horizontalScrollDirection: T.scrollLeft < C ? "forward" : "backward",
1451
- scrollLeft: C,
1452
- scrollTop: b,
1445
+ var h = f.prototype;
1446
+ return h.scrollTo = function(s) {
1447
+ var P = s.scrollLeft, v = s.scrollTop;
1448
+ P !== void 0 && (P = Math.max(0, P)), v !== void 0 && (v = Math.max(0, v)), this.setState(function(T) {
1449
+ return P === void 0 && (P = T.scrollLeft), v === void 0 && (v = T.scrollTop), T.scrollLeft === P && T.scrollTop === v ? null : {
1450
+ horizontalScrollDirection: T.scrollLeft < P ? "forward" : "backward",
1451
+ scrollLeft: P,
1452
+ scrollTop: v,
1453
1453
  scrollUpdateWasRequested: !0,
1454
- verticalScrollDirection: T.scrollTop < b ? "forward" : "backward"
1454
+ verticalScrollDirection: T.scrollTop < v ? "forward" : "backward"
1455
1455
  };
1456
1456
  }, this._resetIsScrollingDebounced);
1457
- }, f.scrollToItem = function(s) {
1458
- var C = s.align, b = C === void 0 ? "auto" : C, T = s.columnIndex, E = s.rowIndex, x = this.props, R = x.columnCount, D = x.height, z = x.rowCount, A = x.width, L = this.state, I = L.scrollLeft, O = L.scrollTop, M = Go();
1457
+ }, h.scrollToItem = function(s) {
1458
+ var P = s.align, v = P === void 0 ? "auto" : P, T = s.columnIndex, E = s.rowIndex, I = this.props, R = I.columnCount, O = I.height, z = I.rowCount, A = I.width, L = this.state, x = L.scrollLeft, D = L.scrollTop, M = Go();
1459
1459
  T !== void 0 && (T = Math.max(0, Math.min(T, R - 1))), E !== void 0 && (E = Math.max(0, Math.min(E, z - 1)));
1460
- var G = l(this.props, this._instanceProps), Z = c(this.props, this._instanceProps), j = Z > A ? M : 0, q = G > D ? M : 0;
1460
+ var G = l(this.props, this._instanceProps), Z = c(this.props, this._instanceProps), j = Z > A ? M : 0, q = G > O ? M : 0;
1461
1461
  this.scrollTo({
1462
- scrollLeft: T !== void 0 ? u(this.props, T, b, I, this._instanceProps, q) : I,
1463
- scrollTop: E !== void 0 ? d(this.props, E, b, O, this._instanceProps, j) : O
1462
+ scrollLeft: T !== void 0 ? u(this.props, T, v, x, this._instanceProps, q) : x,
1463
+ scrollTop: E !== void 0 ? d(this.props, E, v, D, this._instanceProps, j) : D
1464
1464
  });
1465
- }, f.componentDidMount = function() {
1466
- var s = this.props, C = s.initialScrollLeft, b = s.initialScrollTop;
1465
+ }, h.componentDidMount = function() {
1466
+ var s = this.props, P = s.initialScrollLeft, v = s.initialScrollTop;
1467
1467
  if (this._outerRef != null) {
1468
1468
  var T = this._outerRef;
1469
- typeof C == "number" && (T.scrollLeft = C), typeof b == "number" && (T.scrollTop = b);
1469
+ typeof P == "number" && (T.scrollLeft = P), typeof v == "number" && (T.scrollTop = v);
1470
1470
  }
1471
1471
  this._callPropsCallbacks();
1472
- }, f.componentDidUpdate = function() {
1473
- var s = this.props.direction, C = this.state, b = C.scrollLeft, T = C.scrollTop, E = C.scrollUpdateWasRequested;
1472
+ }, h.componentDidUpdate = function() {
1473
+ var s = this.props.direction, P = this.state, v = P.scrollLeft, T = P.scrollTop, E = P.scrollUpdateWasRequested;
1474
1474
  if (E && this._outerRef != null) {
1475
- var x = this._outerRef;
1475
+ var I = this._outerRef;
1476
1476
  if (s === "rtl")
1477
1477
  switch (jt()) {
1478
1478
  case "negative":
1479
- x.scrollLeft = -b;
1479
+ I.scrollLeft = -v;
1480
1480
  break;
1481
1481
  case "positive-ascending":
1482
- x.scrollLeft = b;
1482
+ I.scrollLeft = v;
1483
1483
  break;
1484
1484
  default:
1485
- var R = x.clientWidth, D = x.scrollWidth;
1486
- x.scrollLeft = D - R - b;
1485
+ var R = I.clientWidth, O = I.scrollWidth;
1486
+ I.scrollLeft = O - R - v;
1487
1487
  break;
1488
1488
  }
1489
1489
  else
1490
- x.scrollLeft = Math.max(0, b);
1491
- x.scrollTop = Math.max(0, T);
1490
+ I.scrollLeft = Math.max(0, v);
1491
+ I.scrollTop = Math.max(0, T);
1492
1492
  }
1493
1493
  this._callPropsCallbacks();
1494
- }, f.componentWillUnmount = function() {
1494
+ }, h.componentWillUnmount = function() {
1495
1495
  this._resetIsScrollingTimeoutId !== null && Zt(this._resetIsScrollingTimeoutId);
1496
- }, f.render = function() {
1497
- var s = this.props, C = s.children, b = s.className, T = s.columnCount, E = s.direction, x = s.height, R = s.innerRef, D = s.innerElementType, z = s.innerTagName, A = s.itemData, L = s.itemKey, I = L === void 0 ? Vo : L, O = s.outerElementType, M = s.outerTagName, G = s.rowCount, Z = s.style, j = s.useIsScrolling, q = s.width, te = this.state.isScrolling, X = this._getHorizontalRangeToRender(), ce = X[0], ve = X[1], le = this._getVerticalRangeToRender(), Y = le[0], Fe = le[1], we = [];
1496
+ }, h.render = function() {
1497
+ var s = this.props, P = s.children, v = s.className, T = s.columnCount, E = s.direction, I = s.height, R = s.innerRef, O = s.innerElementType, z = s.innerTagName, A = s.itemData, L = s.itemKey, x = L === void 0 ? Vo : L, D = s.outerElementType, M = s.outerTagName, G = s.rowCount, Z = s.style, j = s.useIsScrolling, q = s.width, te = this.state.isScrolling, X = this._getHorizontalRangeToRender(), ce = X[0], ve = X[1], le = this._getVerticalRangeToRender(), Y = le[0], Fe = le[1], we = [];
1498
1498
  if (T > 0 && G)
1499
1499
  for (var Te = Y; Te <= Fe; Te++)
1500
1500
  for (var _e = ce; _e <= ve; _e++)
1501
- we.push(qe(C, {
1501
+ we.push(qe(P, {
1502
1502
  columnIndex: _e,
1503
1503
  data: A,
1504
1504
  isScrolling: j ? te : void 0,
1505
- key: I({
1505
+ key: x({
1506
1506
  columnIndex: _e,
1507
1507
  data: A,
1508
1508
  rowIndex: Te
@@ -1511,20 +1511,20 @@ function qo(t) {
1511
1511
  style: this._getItemStyle(Te, _e)
1512
1512
  }));
1513
1513
  var rt = l(this.props, this._instanceProps), ot = c(this.props, this._instanceProps);
1514
- return qe(O || M || "div", {
1515
- className: b,
1514
+ return qe(D || M || "div", {
1515
+ className: v,
1516
1516
  onScroll: this._onScroll,
1517
1517
  ref: this._outerRefSetter,
1518
1518
  style: Hr({
1519
1519
  position: "relative",
1520
- height: x,
1520
+ height: I,
1521
1521
  width: q,
1522
1522
  overflow: "auto",
1523
1523
  WebkitOverflowScrolling: "touch",
1524
1524
  willChange: "transform",
1525
1525
  direction: E
1526
1526
  }, Z)
1527
- }, qe(D || z || "div", {
1527
+ }, qe(O || z || "div", {
1528
1528
  children: we,
1529
1529
  ref: R,
1530
1530
  style: {
@@ -1533,29 +1533,29 @@ function qo(t) {
1533
1533
  width: ot
1534
1534
  }
1535
1535
  }));
1536
- }, f._callPropsCallbacks = function() {
1537
- var s = this.props, C = s.columnCount, b = s.onItemsRendered, T = s.onScroll, E = s.rowCount;
1538
- if (typeof b == "function" && C > 0 && E > 0) {
1539
- var x = this._getHorizontalRangeToRender(), R = x[0], D = x[1], z = x[2], A = x[3], L = this._getVerticalRangeToRender(), I = L[0], O = L[1], M = L[2], G = L[3];
1540
- this._callOnItemsRendered(R, D, I, O, z, A, M, G);
1536
+ }, h._callPropsCallbacks = function() {
1537
+ var s = this.props, P = s.columnCount, v = s.onItemsRendered, T = s.onScroll, E = s.rowCount;
1538
+ if (typeof v == "function" && P > 0 && E > 0) {
1539
+ var I = this._getHorizontalRangeToRender(), R = I[0], O = I[1], z = I[2], A = I[3], L = this._getVerticalRangeToRender(), x = L[0], D = L[1], M = L[2], G = L[3];
1540
+ this._callOnItemsRendered(R, O, x, D, z, A, M, G);
1541
1541
  }
1542
1542
  if (typeof T == "function") {
1543
1543
  var Z = this.state, j = Z.horizontalScrollDirection, q = Z.scrollLeft, te = Z.scrollTop, X = Z.scrollUpdateWasRequested, ce = Z.verticalScrollDirection;
1544
1544
  this._callOnScroll(q, te, j, ce, X);
1545
1545
  }
1546
- }, f._getHorizontalRangeToRender = function() {
1547
- var s = this.props, C = s.columnCount, b = s.overscanColumnCount, T = s.overscanColumnsCount, E = s.overscanCount, x = s.rowCount, R = this.state, D = R.horizontalScrollDirection, z = R.isScrolling, A = R.scrollLeft, L = b || T || E || 1;
1548
- if (C === 0 || x === 0)
1546
+ }, h._getHorizontalRangeToRender = function() {
1547
+ var s = this.props, P = s.columnCount, v = s.overscanColumnCount, T = s.overscanColumnsCount, E = s.overscanCount, I = s.rowCount, R = this.state, O = R.horizontalScrollDirection, z = R.isScrolling, A = R.scrollLeft, L = v || T || E || 1;
1548
+ if (P === 0 || I === 0)
1549
1549
  return [0, 0, 0, 0];
1550
- var I = o(this.props, A, this._instanceProps), O = r(this.props, I, A, this._instanceProps), M = !z || D === "backward" ? Math.max(1, L) : 1, G = !z || D === "forward" ? Math.max(1, L) : 1;
1551
- return [Math.max(0, I - M), Math.max(0, Math.min(C - 1, O + G)), I, O];
1552
- }, f._getVerticalRangeToRender = function() {
1553
- var s = this.props, C = s.columnCount, b = s.overscanCount, T = s.overscanRowCount, E = s.overscanRowsCount, x = s.rowCount, R = this.state, D = R.isScrolling, z = R.verticalScrollDirection, A = R.scrollTop, L = T || E || b || 1;
1554
- if (C === 0 || x === 0)
1550
+ var x = o(this.props, A, this._instanceProps), D = r(this.props, x, A, this._instanceProps), M = !z || O === "backward" ? Math.max(1, L) : 1, G = !z || O === "forward" ? Math.max(1, L) : 1;
1551
+ return [Math.max(0, x - M), Math.max(0, Math.min(P - 1, D + G)), x, D];
1552
+ }, h._getVerticalRangeToRender = function() {
1553
+ var s = this.props, P = s.columnCount, v = s.overscanCount, T = s.overscanRowCount, E = s.overscanRowsCount, I = s.rowCount, R = this.state, O = R.isScrolling, z = R.verticalScrollDirection, A = R.scrollTop, L = T || E || v || 1;
1554
+ if (P === 0 || I === 0)
1555
1555
  return [0, 0, 0, 0];
1556
- var I = p(this.props, A, this._instanceProps), O = w(this.props, I, A, this._instanceProps), M = !D || z === "backward" ? Math.max(1, L) : 1, G = !D || z === "forward" ? Math.max(1, L) : 1;
1557
- return [Math.max(0, I - M), Math.max(0, Math.min(x - 1, O + G)), I, O];
1558
- }, h;
1556
+ var x = p(this.props, A, this._instanceProps), D = _(this.props, x, A, this._instanceProps), M = !O || z === "backward" ? Math.max(1, L) : 1, G = !O || z === "forward" ? Math.max(1, L) : 1;
1557
+ return [Math.max(0, x - M), Math.max(0, Math.min(I - 1, D + G)), x, D];
1558
+ }, f;
1559
1559
  }(er), e.defaultProps = {
1560
1560
  direction: "ltr",
1561
1561
  itemData: void 0,
@@ -1563,7 +1563,7 @@ function qo(t) {
1563
1563
  }, e;
1564
1564
  }
1565
1565
  var Bo = function(e, n) {
1566
- var o = e.children, r = e.direction, a = e.height, l = e.innerTagName, c = e.outerTagName, u = e.overscanColumnsCount, d = e.overscanCount, m = e.overscanRowsCount, v = e.width, p = n.instance;
1566
+ var o = e.children, r = e.direction, a = e.height, l = e.innerTagName, c = e.outerTagName, u = e.overscanColumnsCount, d = e.overscanCount, m = e.overscanRowsCount, w = e.width, p = n.instance;
1567
1567
  if (process.env.NODE_ENV !== "production") {
1568
1568
  if (typeof d == "number" && Be && !Be.has(p) && (Be.add(p), console.warn("The overscanCount prop has been deprecated. Please use the overscanColumnCount and overscanRowCount props instead.")), (typeof u == "number" || typeof m == "number") && Ze && !Ze.has(p) && (Ze.add(p), console.warn("The overscanColumnsCount and overscanRowsCount props have been deprecated. Please use the overscanColumnCount and overscanRowCount props instead.")), (l != null || c != null) && je && !je.has(p) && (je.add(p), console.warn("The innerTagName and outerTagName props have been deprecated. Please use the innerElementType and outerElementType props instead.")), o == null)
1569
1569
  throw Error('An invalid "children" prop has been specified. Value should be a React component. ' + ('"' + (o === null ? "null" : typeof o) + '" was specified.'));
@@ -1574,8 +1574,8 @@ var Bo = function(e, n) {
1574
1574
  default:
1575
1575
  throw Error('An invalid "direction" prop has been specified. Value should be either "ltr" or "rtl". ' + ('"' + r + '" was specified.'));
1576
1576
  }
1577
- if (typeof v != "number")
1578
- throw Error('An invalid "width" prop has been specified. Grids must specify a number for width. ' + ('"' + (v === null ? "null" : typeof v) + '" was specified.'));
1577
+ if (typeof w != "number")
1578
+ throw Error('An invalid "width" prop has been specified. Grids must specify a number for width. ' + ('"' + (w === null ? "null" : typeof w) + '" was specified.'));
1579
1579
  if (typeof a != "number")
1580
1580
  throw Error('An invalid "height" prop has been specified. Grids must specify a number for height. ' + ('"' + (a === null ? "null" : typeof a) + '" was specified.'));
1581
1581
  }
@@ -1604,11 +1604,11 @@ var Bo = function(e, n) {
1604
1604
  u = d.offset + d.size;
1605
1605
  }
1606
1606
  for (var m = c + 1; m <= o; m++) {
1607
- var v = l(m);
1607
+ var w = l(m);
1608
1608
  a[m] = {
1609
1609
  offset: u,
1610
- size: v
1611
- }, u += v;
1610
+ size: w
1611
+ }, u += w;
1612
1612
  }
1613
1613
  e === "column" ? r.lastMeasuredColumnIndex = o : r.lastMeasuredRowIndex = o;
1614
1614
  }
@@ -1617,8 +1617,8 @@ var Bo = function(e, n) {
1617
1617
  var a, l;
1618
1618
  e === "column" ? (a = o.columnMetadataMap, l = o.lastMeasuredColumnIndex) : (a = o.rowMetadataMap, l = o.lastMeasuredRowIndex);
1619
1619
  var c = l > 0 ? a[l].offset : 0;
1620
- return c >= r ? xn(e, n, o, l, 0, r) : Zo(e, n, o, Math.max(0, l), r);
1621
- }, xn = function(e, n, o, r, a, l) {
1620
+ return c >= r ? In(e, n, o, l, 0, r) : Zo(e, n, o, Math.max(0, l), r);
1621
+ }, In = function(e, n, o, r, a, l) {
1622
1622
  for (; a <= r; ) {
1623
1623
  var c = a + Math.floor((r - a) / 2), u = he(e, n, c, o).offset;
1624
1624
  if (u === l)
@@ -1629,19 +1629,19 @@ var Bo = function(e, n) {
1629
1629
  }, Zo = function(e, n, o, r, a) {
1630
1630
  for (var l = e === "column" ? n.columnCount : n.rowCount, c = 1; r < l && he(e, n, r, o).offset < a; )
1631
1631
  r += c, c *= 2;
1632
- return xn(e, n, o, Math.min(r, l - 1), Math.floor(r / 2), a);
1632
+ return In(e, n, o, Math.min(r, l - 1), Math.floor(r / 2), a);
1633
1633
  }, Yt = function(e, n, o, r, a, l, c) {
1634
- var u = e === "column" ? n.width : n.height, d = he(e, n, o, l), m = e === "column" ? yn(n, l) : Sn(n, l), v = Math.max(0, Math.min(m - u, d.offset)), p = Math.max(0, d.offset - u + c + d.size);
1635
- switch (r === "smart" && (a >= p - u && a <= v + u ? r = "auto" : r = "center"), r) {
1634
+ var u = e === "column" ? n.width : n.height, d = he(e, n, o, l), m = e === "column" ? yn(n, l) : Sn(n, l), w = Math.max(0, Math.min(m - u, d.offset)), p = Math.max(0, d.offset - u + c + d.size);
1635
+ switch (r === "smart" && (a >= p - u && a <= w + u ? r = "auto" : r = "center"), r) {
1636
1636
  case "start":
1637
- return v;
1637
+ return w;
1638
1638
  case "end":
1639
1639
  return p;
1640
1640
  case "center":
1641
- return Math.round(p + (v - p) / 2);
1641
+ return Math.round(p + (w - p) / 2);
1642
1642
  case "auto":
1643
1643
  default:
1644
- return a >= p && a <= v ? a : p > v || a < p ? p : v;
1644
+ return a >= p && a <= w ? a : p > w || a < p ? p : w;
1645
1645
  }
1646
1646
  }, jo = /* @__PURE__ */ qo({
1647
1647
  getColumnOffset: function(e, n, o) {
@@ -1700,8 +1700,8 @@ var Bo = function(e, n) {
1700
1700
  shouldForceUpdate: u
1701
1701
  });
1702
1702
  }, n.resetAfterIndices = function(c) {
1703
- var u = c.columnIndex, d = c.rowIndex, m = c.shouldForceUpdate, v = m === void 0 ? !0 : m;
1704
- typeof u == "number" && (l.lastMeasuredColumnIndex = Math.min(l.lastMeasuredColumnIndex, u - 1)), typeof d == "number" && (l.lastMeasuredRowIndex = Math.min(l.lastMeasuredRowIndex, d - 1)), n._getItemStyleCache(-1), v && n.forceUpdate();
1703
+ var u = c.columnIndex, d = c.rowIndex, m = c.shouldForceUpdate, w = m === void 0 ? !0 : m;
1704
+ typeof u == "number" && (l.lastMeasuredColumnIndex = Math.min(l.lastMeasuredColumnIndex, u - 1)), typeof d == "number" && (l.lastMeasuredRowIndex = Math.min(l.lastMeasuredRowIndex, d - 1)), n._getItemStyleCache(-1), w && n.forceUpdate();
1705
1705
  }, l;
1706
1706
  },
1707
1707
  shouldResetStyleCacheOnItemSizeChange: !1,
@@ -1731,36 +1731,36 @@ function Yo(t, e) {
1731
1731
  return !Jt(n, r) && !Jt(o, a);
1732
1732
  }
1733
1733
  const Jo = () => {
1734
- const { viewMode: t } = Ne(), { scrollMode: e } = Ee(), { setColumnCount: n } = un(), { virtualScrollableElementRef: o } = et(), r = Ge(), a = k(() => r.heights.length, [r.heights]), l = k(() => e === Q.HORIZONTAL_SCROLLING ? a : t === Re.DUAL_PAGE ? 2 : 1, [t, e, e, a, o]), c = k(() => r.widths.reduce((P, S, _) => {
1735
- const y = _ % l;
1736
- return (!P[y] || S > P[y]) && (P[y] = S), P;
1734
+ const { viewMode: t } = Oe(), { scrollMode: e } = Ne(), { setColumnCount: n } = un(), { virtualScrollableElementRef: o } = et(), r = Ge(), a = k(() => r.heights.length, [r.heights]), l = k(() => e === Q.HORIZONTAL_SCROLLING ? a : t === Le.DUAL_PAGE ? 2 : 1, [t, e, e, a, o]), c = k(() => r.widths.reduce((b, S, C) => {
1735
+ const y = C % l;
1736
+ return (!b[y] || S > b[y]) && (b[y] = S), b;
1737
1737
  }, []), [r.widths, l]), u = N(
1738
- (w) => {
1739
- const P = w % c.length;
1740
- return c[P] || 0;
1738
+ (_) => {
1739
+ const b = _ % c.length;
1740
+ return c[b] || 0;
1741
1741
  },
1742
1742
  [c]
1743
1743
  ), d = N(
1744
- (w) => {
1745
- const P = Array.from({ length: l }, (S, _) => {
1746
- const y = w * l + _;
1744
+ (_) => {
1745
+ const b = Array.from({ length: l }, (S, C) => {
1746
+ const y = _ * l + C;
1747
1747
  return r.heights[y] || 0;
1748
1748
  });
1749
- return Math.max(...P);
1749
+ return Math.max(...b);
1750
1750
  },
1751
1751
  [r.heights, l]
1752
1752
  );
1753
1753
  F(() => {
1754
1754
  n(l);
1755
1755
  }, [l, n]);
1756
- const m = k(() => e === Q.HORIZONTAL_SCROLLING || e === Q.PAGE_SCROLLING ? 1 : Math.round(a / l), [l, a, e]), v = k(() => r.heights.reduce((w, P) => w + P, 0) / r.heights.length || 0, [r]), p = k(() => r.widths.reduce((w, P) => w + P, 0) / r.heights.length || 0, [r]);
1756
+ const m = k(() => e === Q.HORIZONTAL_SCROLLING || e === Q.PAGE_SCROLLING ? 1 : Math.round(a / l), [l, a, e]), w = k(() => r.heights.reduce((_, b) => _ + b, 0) / r.heights.length || 0, [r]), p = k(() => r.widths.reduce((_, b) => _ + b, 0) / r.heights.length || 0, [r]);
1757
1757
  return {
1758
1758
  rowCount: m,
1759
1759
  rowHeight: d,
1760
1760
  columnCount: l,
1761
1761
  columnWidth: u,
1762
1762
  pageDimension: r,
1763
- estimatedRowHeight: v,
1763
+ estimatedRowHeight: w,
1764
1764
  estimatedColumnWidth: p
1765
1765
  };
1766
1766
  };
@@ -1785,64 +1785,64 @@ function Qo(t) {
1785
1785
  const u = typeof document < "u" && document.attachEvent;
1786
1786
  if (!u) {
1787
1787
  l = function(y) {
1788
- const h = y.__resizeTriggers__, f = h.firstElementChild, g = h.lastElementChild, s = f.firstElementChild;
1789
- g.scrollLeft = g.scrollWidth, g.scrollTop = g.scrollHeight, s.style.width = f.offsetWidth + 1 + "px", s.style.height = f.offsetHeight + 1 + "px", f.scrollLeft = f.scrollWidth, f.scrollTop = f.scrollHeight;
1788
+ const f = y.__resizeTriggers__, h = f.firstElementChild, g = f.lastElementChild, s = h.firstElementChild;
1789
+ g.scrollLeft = g.scrollWidth, g.scrollTop = g.scrollHeight, s.style.width = h.offsetWidth + 1 + "px", s.style.height = h.offsetHeight + 1 + "px", h.scrollLeft = h.scrollWidth, h.scrollTop = h.scrollHeight;
1790
1790
  }, a = function(y) {
1791
1791
  return y.offsetWidth !== y.__resizeLast__.width || y.offsetHeight !== y.__resizeLast__.height;
1792
1792
  }, c = function(y) {
1793
1793
  if (y.target.className && typeof y.target.className.indexOf == "function" && y.target.className.indexOf("contract-trigger") < 0 && y.target.className.indexOf("expand-trigger") < 0)
1794
1794
  return;
1795
- const h = this;
1795
+ const f = this;
1796
1796
  l(this), this.__resizeRAF__ && bt(this.__resizeRAF__), this.__resizeRAF__ = Ct(function() {
1797
- a(h) && (h.__resizeLast__.width = h.offsetWidth, h.__resizeLast__.height = h.offsetHeight, h.__resizeListeners__.forEach(function(s) {
1798
- s.call(h, y);
1797
+ a(f) && (f.__resizeLast__.width = f.offsetWidth, f.__resizeLast__.height = f.offsetHeight, f.__resizeListeners__.forEach(function(s) {
1798
+ s.call(f, y);
1799
1799
  }));
1800
1800
  });
1801
1801
  };
1802
- let p = !1, w = "";
1802
+ let p = !1, _ = "";
1803
1803
  o = "animationstart";
1804
- const P = "Webkit Moz O ms".split(" ");
1805
- let S = "webkitAnimationStart animationstart oAnimationStart MSAnimationStart".split(" "), _ = "";
1804
+ const b = "Webkit Moz O ms".split(" ");
1805
+ let S = "webkitAnimationStart animationstart oAnimationStart MSAnimationStart".split(" "), C = "";
1806
1806
  {
1807
1807
  const y = document.createElement("fakeelement");
1808
1808
  if (y.style.animationName !== void 0 && (p = !0), p === !1) {
1809
- for (let h = 0; h < P.length; h++)
1810
- if (y.style[P[h] + "AnimationName"] !== void 0) {
1811
- _ = P[h], w = "-" + _.toLowerCase() + "-", o = S[h], p = !0;
1809
+ for (let f = 0; f < b.length; f++)
1810
+ if (y.style[b[f] + "AnimationName"] !== void 0) {
1811
+ C = b[f], _ = "-" + C.toLowerCase() + "-", o = S[f], p = !0;
1812
1812
  break;
1813
1813
  }
1814
1814
  }
1815
1815
  }
1816
- n = "resizeanim", e = "@" + w + "keyframes " + n + " { from { opacity: 0; } to { opacity: 0; } } ", r = w + "animation: 1ms " + n + "; ";
1816
+ n = "resizeanim", e = "@" + _ + "keyframes " + n + " { from { opacity: 0; } to { opacity: 0; } } ", r = _ + "animation: 1ms " + n + "; ";
1817
1817
  }
1818
1818
  const d = function(p) {
1819
1819
  if (!p.getElementById("detectElementResize")) {
1820
- const w = (e || "") + ".resize-triggers { " + (r || "") + 'visibility: hidden; opacity: 0; } .resize-triggers, .resize-triggers > div, .contract-trigger:before { content: " "; display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; overflow: hidden; z-index: -1; } .resize-triggers > div { background: #eee; overflow: auto; } .contract-trigger:before { width: 200%; height: 200%; }', P = p.head || p.getElementsByTagName("head")[0], S = p.createElement("style");
1821
- S.id = "detectElementResize", S.type = "text/css", t != null && S.setAttribute("nonce", t), S.styleSheet ? S.styleSheet.cssText = w : S.appendChild(p.createTextNode(w)), P.appendChild(S);
1820
+ const _ = (e || "") + ".resize-triggers { " + (r || "") + 'visibility: hidden; opacity: 0; } .resize-triggers, .resize-triggers > div, .contract-trigger:before { content: " "; display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; overflow: hidden; z-index: -1; } .resize-triggers > div { background: #eee; overflow: auto; } .contract-trigger:before { width: 200%; height: 200%; }', b = p.head || p.getElementsByTagName("head")[0], S = p.createElement("style");
1821
+ S.id = "detectElementResize", S.type = "text/css", t != null && S.setAttribute("nonce", t), S.styleSheet ? S.styleSheet.cssText = _ : S.appendChild(p.createTextNode(_)), b.appendChild(S);
1822
1822
  }
1823
1823
  };
1824
1824
  return {
1825
- addResizeListener: function(p, w) {
1825
+ addResizeListener: function(p, _) {
1826
1826
  if (u)
1827
- p.attachEvent("onresize", w);
1827
+ p.attachEvent("onresize", _);
1828
1828
  else {
1829
1829
  if (!p.__resizeTriggers__) {
1830
- const P = p.ownerDocument, S = oe.getComputedStyle(p);
1831
- S && S.position === "static" && (p.style.position = "relative"), d(P), p.__resizeLast__ = {}, p.__resizeListeners__ = [], (p.__resizeTriggers__ = P.createElement("div")).className = "resize-triggers";
1832
- const _ = P.createElement("div");
1833
- _.className = "expand-trigger", _.appendChild(P.createElement("div"));
1834
- const y = P.createElement("div");
1835
- y.className = "contract-trigger", p.__resizeTriggers__.appendChild(_), p.__resizeTriggers__.appendChild(y), p.appendChild(p.__resizeTriggers__), l(p), p.addEventListener("scroll", c, !0), o && (p.__resizeTriggers__.__animationListener__ = function(f) {
1836
- f.animationName === n && l(p);
1830
+ const b = p.ownerDocument, S = oe.getComputedStyle(p);
1831
+ S && S.position === "static" && (p.style.position = "relative"), d(b), p.__resizeLast__ = {}, p.__resizeListeners__ = [], (p.__resizeTriggers__ = b.createElement("div")).className = "resize-triggers";
1832
+ const C = b.createElement("div");
1833
+ C.className = "expand-trigger", C.appendChild(b.createElement("div"));
1834
+ const y = b.createElement("div");
1835
+ y.className = "contract-trigger", p.__resizeTriggers__.appendChild(C), p.__resizeTriggers__.appendChild(y), p.appendChild(p.__resizeTriggers__), l(p), p.addEventListener("scroll", c, !0), o && (p.__resizeTriggers__.__animationListener__ = function(h) {
1836
+ h.animationName === n && l(p);
1837
1837
  }, p.__resizeTriggers__.addEventListener(o, p.__resizeTriggers__.__animationListener__));
1838
1838
  }
1839
- p.__resizeListeners__.push(w);
1839
+ p.__resizeListeners__.push(_);
1840
1840
  }
1841
1841
  },
1842
- removeResizeListener: function(p, w) {
1842
+ removeResizeListener: function(p, _) {
1843
1843
  if (u)
1844
- p.detachEvent("onresize", w);
1845
- else if (p.__resizeListeners__.splice(p.__resizeListeners__.indexOf(w), 1), !p.__resizeListeners__.length) {
1844
+ p.detachEvent("onresize", _);
1845
+ else if (p.__resizeListeners__.splice(p.__resizeListeners__.indexOf(_), 1), !p.__resizeListeners__.length) {
1846
1846
  p.removeEventListener("scroll", c, !0), p.__resizeTriggers__.__animationListener__ && (p.__resizeTriggers__.removeEventListener(o, p.__resizeTriggers__.__animationListener__), p.__resizeTriggers__.__animationListener__ = null);
1847
1847
  try {
1848
1848
  p.__resizeTriggers__ = !p.removeChild(p.__resizeTriggers__);
@@ -1865,24 +1865,24 @@ class ei extends tr {
1865
1865
  onResize: r
1866
1866
  } = this.props;
1867
1867
  if (this._parentNode) {
1868
- const a = window.getComputedStyle(this._parentNode) || {}, l = parseFloat(a.paddingLeft || "0"), c = parseFloat(a.paddingRight || "0"), u = parseFloat(a.paddingTop || "0"), d = parseFloat(a.paddingBottom || "0"), m = this._parentNode.getBoundingClientRect(), v = m.height - u - d, p = m.width - l - c;
1869
- if (!n && this.state.height !== v || !o && this.state.width !== p) {
1868
+ const a = window.getComputedStyle(this._parentNode) || {}, l = parseFloat(a.paddingLeft || "0"), c = parseFloat(a.paddingRight || "0"), u = parseFloat(a.paddingTop || "0"), d = parseFloat(a.paddingBottom || "0"), m = this._parentNode.getBoundingClientRect(), w = m.height - u - d, p = m.width - l - c;
1869
+ if (!n && this.state.height !== w || !o && this.state.width !== p) {
1870
1870
  this.setState({
1871
- height: v,
1871
+ height: w,
1872
1872
  width: p
1873
1873
  });
1874
- const w = () => {
1874
+ const _ = () => {
1875
1875
  this._didLogDeprecationWarning || (this._didLogDeprecationWarning = !0, console.warn("scaledWidth and scaledHeight parameters have been deprecated; use width and height instead"));
1876
1876
  };
1877
1877
  typeof r == "function" && r({
1878
- height: v,
1878
+ height: w,
1879
1879
  width: p,
1880
1880
  // TODO Remove these params in the next major release
1881
1881
  get scaledHeight() {
1882
- return w(), v;
1882
+ return _(), w;
1883
1883
  },
1884
1884
  get scaledWidth() {
1885
- return w(), p;
1885
+ return _(), p;
1886
1886
  }
1887
1887
  });
1888
1888
  }
@@ -1918,22 +1918,22 @@ class ei extends tr {
1918
1918
  onResize: u,
1919
1919
  style: d = {},
1920
1920
  tagName: m = "div",
1921
- ...v
1921
+ ...w
1922
1922
  } = this.props, {
1923
1923
  height: p,
1924
- width: w
1925
- } = this.state, P = {
1924
+ width: _
1925
+ } = this.state, b = {
1926
1926
  overflow: "visible"
1927
1927
  }, S = {};
1928
- let _ = !1;
1929
- return r || (p === 0 && (_ = !0), P.height = 0, S.height = p, S.scaledHeight = p), a || (w === 0 && (_ = !0), P.width = 0, S.width = w, S.scaledWidth = w), l && (_ = !1), qe(m, {
1928
+ let C = !1;
1929
+ return r || (p === 0 && (C = !0), b.height = 0, S.height = p, S.scaledHeight = p), a || (_ === 0 && (C = !0), b.width = 0, S.width = _, S.scaledWidth = _), l && (C = !1), qe(m, {
1930
1930
  ref: this._setRef,
1931
1931
  style: {
1932
- ...P,
1932
+ ...b,
1933
1933
  ...d
1934
1934
  },
1935
- ...v
1936
- }, !_ && e(S));
1935
+ ...w
1936
+ }, !C && e(S));
1937
1937
  }
1938
1938
  }
1939
1939
  const ti = ln(({ widths: t, heights: e }) => {
@@ -1945,21 +1945,21 @@ const ti = ln(({ widths: t, heights: e }) => {
1945
1945
  }
1946
1946
  return c;
1947
1947
  }, [n, o]), a = k(() => {
1948
- const c = n % 2 === 1 ? n - 1 : n - 2, u = t(c), d = e(c), m = t(c + 1), v = e(c + 1), p = d > v ? d : v, w = d < v ? d : v, P = p / 2 - w / 2;
1948
+ const c = n % 2 === 1 ? n - 1 : n - 2, u = t(c), d = e(c), m = t(c + 1), w = e(c + 1), p = d > w ? d : w, _ = d < w ? d : w, b = p / 2 - _ / 2;
1949
1949
  return [
1950
1950
  {
1951
1951
  position: "absolute",
1952
1952
  left: 0,
1953
- top: p === d ? 0 : P,
1953
+ top: p === d ? 0 : b,
1954
1954
  width: u,
1955
1955
  height: d
1956
1956
  },
1957
1957
  {
1958
1958
  position: "absolute",
1959
1959
  left: u,
1960
- top: p === v ? 0 : P,
1960
+ top: p === w ? 0 : b,
1961
1961
  width: m,
1962
- height: v
1962
+ height: w
1963
1963
  }
1964
1964
  ];
1965
1965
  }, [t, e, r]), l = k(() => a.reduce((c, u) => c + Number(u.width || 0), 0), [a]);
@@ -1981,45 +1981,45 @@ const ti = ln(({ widths: t, heights: e }) => {
1981
1981
  }
1982
1982
  );
1983
1983
  }, ri = (t, e, n) => {
1984
- const o = H(), { contentRef: r } = me(), { heights: a, widths: l } = Ge(), { setFocusedPage: c } = ie(), [u, d] = $([]), { targetScrollPage: m } = pn(), v = Tt(u, 0, 500), p = k(() => a.map((P, S) => {
1985
- const _ = l[S], y = Br(S + 1, t), h = _ * y.columnIndex, f = P * y.rowIndex, g = h + _, s = f + P;
1984
+ const o = H(), { contentRef: r } = me(), { heights: a, widths: l } = Ge(), { setFocusedPage: c } = ie(), [u, d] = $([]), { targetScrollPage: m } = pn(), w = Tt(u, 0, 500), p = k(() => a.map((b, S) => {
1985
+ const C = l[S], y = Br(S + 1, t), f = C * y.columnIndex, h = b * y.rowIndex, g = f + C, s = h + b;
1986
1986
  return {
1987
1987
  pageNumber: S + 1,
1988
1988
  ...y,
1989
- width: _,
1990
- height: P,
1991
- startX: h,
1992
- startY: f,
1989
+ width: C,
1990
+ height: b,
1991
+ startX: f,
1992
+ startY: h,
1993
1993
  endX: g,
1994
1994
  endY: s
1995
1995
  };
1996
1996
  }), [a, l, t, e]);
1997
1997
  F(() => {
1998
1998
  var S;
1999
- v.length > 0 && !m.current && c(v[0].pageNumber);
2000
- let P = (S = v[0]) == null ? void 0 : S.ratio;
2001
- P && v.filter((_) => Math.round(_.ratio) === Math.round(P)).some((_) => _.pageNumber === m.current) && setTimeout(() => {
1999
+ w.length > 0 && !m.current && c(w[0].pageNumber);
2000
+ let b = (S = w[0]) == null ? void 0 : S.ratio;
2001
+ b && w.filter((C) => Math.round(C.ratio) === Math.round(b)).some((C) => C.pageNumber === m.current) && setTimeout(() => {
2002
2002
  m.current = void 0;
2003
2003
  }, 500);
2004
- }, [v, c]);
2005
- const w = N(
2006
- (P) => {
2004
+ }, [w, c]);
2005
+ const _ = N(
2006
+ (b) => {
2007
2007
  o.current && cancelAnimationFrame(o.current), o.current = requestAnimationFrame(() => {
2008
- const S = P.target, _ = {
2008
+ const S = b.target, C = {
2009
2009
  startTop: S.scrollTop,
2010
2010
  startLeft: S.scrollLeft,
2011
2011
  endTop: S.scrollTop + S.clientHeight,
2012
2012
  endLeft: S.scrollLeft + S.clientWidth
2013
- }, y = p.filter((h) => {
2014
- const f = h.endX >= _.startLeft && h.endY >= _.startTop, g = h.startX <= _.endLeft && h.startY <= _.endTop;
2015
- return f && g;
2016
- }).map((h) => {
2017
- const f = _.startLeft > h.startX ? _.startLeft : h.startX, g = _.startTop > h.startY ? _.startTop : h.startY, s = _.endLeft < h.endX ? _.endLeft : h.endX, C = _.endTop < h.endY ? _.endTop : h.endY, b = s - f, T = C - g, x = +(b * T / (h.width * h.height) * 100).toFixed(2);
2013
+ }, y = p.filter((f) => {
2014
+ const h = f.endX >= C.startLeft && f.endY >= C.startTop, g = f.startX <= C.endLeft && f.startY <= C.endTop;
2015
+ return h && g;
2016
+ }).map((f) => {
2017
+ const h = C.startLeft > f.startX ? C.startLeft : f.startX, g = C.startTop > f.startY ? C.startTop : f.startY, s = C.endLeft < f.endX ? C.endLeft : f.endX, P = C.endTop < f.endY ? C.endTop : f.endY, v = s - h, T = P - g, I = +(v * T / (f.width * f.height) * 100).toFixed(2);
2018
2018
  return {
2019
- pageNumber: h.pageNumber,
2020
- ratio: x
2019
+ pageNumber: f.pageNumber,
2020
+ ratio: I
2021
2021
  };
2022
- }).sort((h, f) => f.ratio - h.ratio);
2022
+ }).sort((f, h) => h.ratio - f.ratio);
2023
2023
  d(y);
2024
2024
  });
2025
2025
  },
@@ -2027,10 +2027,10 @@ const ti = ln(({ widths: t, heights: e }) => {
2027
2027
  );
2028
2028
  F(() => {
2029
2029
  if (n)
2030
- return n == null || n.addEventListener("scroll", w), () => {
2031
- n == null || n.removeEventListener("scroll", w);
2030
+ return n == null || n.addEventListener("scroll", _), () => {
2031
+ n == null || n.removeEventListener("scroll", _);
2032
2032
  };
2033
- }, [n, w]);
2033
+ }, [n, _]);
2034
2034
  }, be = {
2035
2035
  "rp-layout": "_rp-layout_1g4ff_1",
2036
2036
  "rp-content": "_rp-content_1g4ff_5",
@@ -2039,7 +2039,7 @@ const ti = ln(({ widths: t, heights: e }) => {
2039
2039
  "rp-loader": "_rp-loader_1g4ff_20",
2040
2040
  "rp-theme-variables": "_rp-theme-variables_1g4ff_24",
2041
2041
  "rp-dark-mode": "_rp-dark-mode_1g4ff_135"
2042
- }, In = $e(
2042
+ }, xn = $e(
2043
2043
  (t, e) => {
2044
2044
  const { children: n, toolbarRef: o, style: r, className: a, ...l } = t, { customVariables: c, customDarkVariables: u } = Sr(), { darkMode: d } = or();
2045
2045
  return /* @__PURE__ */ i(
@@ -2066,31 +2066,31 @@ const ti = ln(({ widths: t, heights: e }) => {
2066
2066
  ), oi = ln(({ columnIndex: t, rowIndex: e, data: n, style: o }) => {
2067
2067
  const r = Zr(e, t, n.columnCount);
2068
2068
  return /* @__PURE__ */ i(Rt, { style: o, pageNumber: r }, r);
2069
- }, Yo), Zs = () => {
2069
+ }, Yo), js = () => {
2070
2070
  const { initialPage: t = 1, initialScrollMode: e, instanceId: n } = sr(), { pagesRef: o, setPagesRef: r } = me(), { scrollToPage: a } = wn(), {
2071
2071
  virtualScrollRef: l,
2072
2072
  getVirtualScrollRef: c,
2073
2073
  getPageScrollElementRef: u,
2074
2074
  getVirtualScrollableElementRef: d,
2075
2075
  setTotalInnerDimensions: m,
2076
- virtualScrollableElementRef: v,
2076
+ virtualScrollableElementRef: w,
2077
2077
  totalInnerDimensions: p,
2078
- pageScrollElementRef: w
2079
- } = et(), P = H(!0), { nextPage: S, prevPage: _, setFocusedPage: y, focusedPage: h } = ie(), { scrollMode: f } = Ee(), { viewMode: g } = Ne(), s = H(null), { loading: C } = ee(), { passwordRequired: b } = rr(), { LoaderImageComponent: T } = hn(), E = H(
2078
+ pageScrollElementRef: _
2079
+ } = et(), b = H(!0), { nextPage: S, prevPage: C, setFocusedPage: y, focusedPage: f } = ie(), { scrollMode: h } = Ne(), { viewMode: g } = Oe(), s = H(null), { loading: P } = ee(), { passwordRequired: v } = rr(), { LoaderImageComponent: T } = hn(), E = H(
2080
2080
  p
2081
- ), x = H({
2081
+ ), I = H({
2082
2082
  viewMode: g,
2083
- scrollMode: f
2084
- }), R = H(!1), D = H(), { isFullScreen: z } = cr(), {
2083
+ scrollMode: h
2084
+ }), R = H(!1), O = H(), { isFullScreen: z } = cr(), {
2085
2085
  pageDimension: A,
2086
2086
  rowCount: L,
2087
- rowHeight: I,
2088
- columnCount: O,
2087
+ rowHeight: x,
2088
+ columnCount: D,
2089
2089
  columnWidth: M,
2090
2090
  estimatedColumnWidth: G,
2091
2091
  estimatedRowHeight: Z
2092
2092
  } = Jo(), j = Tt(p, 100), q = H();
2093
- ri(O, L, v);
2093
+ ri(D, L, w);
2094
2094
  const te = H({
2095
2095
  scrollTop: 0,
2096
2096
  scrollLeft: 0
@@ -2099,43 +2099,43 @@ const ti = ln(({ widths: t, heights: e }) => {
2099
2099
  const { isPressed: X } = Gr(), { selectionMode: ce } = ar(), { initializeGrabScroll: ve, resetGrabState: le } = Ur({
2100
2100
  isPressed: X
2101
2101
  }), Y = k(() => ce === nr.HAND, [ce]), Fe = k(() => ({
2102
- columnCount: O
2103
- }), [O]), we = N(
2102
+ columnCount: D
2103
+ }), [D]), we = N(
2104
2104
  (U) => {
2105
2105
  const V = document.activeElement !== o;
2106
- !z && V || (["ArrowUp", "ArrowLeft"].includes(U.key) ? (U.preventDefault(), _()) : ["ArrowDown", "ArrowRight"].includes(U.key) && (U.preventDefault(), S()));
2106
+ !z && V || (["ArrowUp", "ArrowLeft"].includes(U.key) ? (U.preventDefault(), C()) : ["ArrowDown", "ArrowRight"].includes(U.key) && (U.preventDefault(), S()));
2107
2107
  },
2108
- [S, _, z, f]
2108
+ [S, C, z, h]
2109
2109
  );
2110
2110
  F(() => (window.addEventListener("keydown", we), () => {
2111
2111
  window.removeEventListener("keydown", we);
2112
2112
  }), [we]), F(() => {
2113
2113
  if (s.current && (s.current.style.position = "relative"), !!l)
2114
2114
  for (let U = 0; U < L; U++)
2115
- for (let V = 0; V < O; V++)
2115
+ for (let V = 0; V < D; V++)
2116
2116
  l.resetAfterIndices({
2117
2117
  columnIndex: V,
2118
2118
  rowIndex: U,
2119
2119
  shouldForceUpdate: !0
2120
2120
  });
2121
- }, [L, O, A, l]);
2121
+ }, [L, D, A, l]);
2122
2122
  const Te = N(
2123
2123
  (U, V) => {
2124
- if (!v)
2124
+ if (!w)
2125
2125
  return { scrollTop: 0, scrollLeft: 0 };
2126
2126
  const Se = te.current.scrollTop > V, ye = te.current.scrollLeft > U;
2127
2127
  return Se || ye ? te.current : {
2128
- scrollTop: v.scrollTop,
2129
- scrollLeft: v.scrollLeft
2128
+ scrollTop: w.scrollTop,
2129
+ scrollLeft: w.scrollLeft
2130
2130
  };
2131
2131
  },
2132
- [v]
2132
+ [w]
2133
2133
  ), _e = N(
2134
2134
  (U, V) => {
2135
- if (x.current.viewMode !== g || x.current.scrollMode !== f) {
2136
- q.current && clearTimeout(q.current), R.current = !0, a(h, "auto"), q.current = setTimeout(() => {
2135
+ if (I.current.viewMode !== g || I.current.scrollMode !== h) {
2136
+ q.current && clearTimeout(q.current), R.current = !0, a(f, "auto"), q.current = setTimeout(() => {
2137
2137
  requestAnimationFrame(() => {
2138
- x.current = { viewMode: g, scrollMode: f };
2138
+ I.current = { viewMode: g, scrollMode: h };
2139
2139
  });
2140
2140
  }, 100);
2141
2141
  return;
@@ -2144,11 +2144,11 @@ const ti = ln(({ widths: t, heights: e }) => {
2144
2144
  if (!V.height || !V.width)
2145
2145
  return;
2146
2146
  R.current = !0;
2147
- const { height: xe, width: at } = V, { height: Ot, width: Dt } = E.current;
2148
- if (Ot === xe && Dt === at)
2147
+ const { height: Ie, width: at } = V, { height: Ot, width: Dt } = E.current;
2148
+ if (Ot === Ie && Dt === at)
2149
2149
  return;
2150
- const Xn = ye / Ot * xe, Yn = it / Dt * at, Jn = Math.round(Math.min(Xn, xe)) || 0, Qn = Math.round(Math.min(Yn, at)) || 0;
2151
- D.current = setTimeout(() => {
2150
+ const Xn = ye / Ot * Ie, Yn = it / Dt * at, Jn = Math.round(Math.min(Xn, Ie)) || 0, Qn = Math.round(Math.min(Yn, at)) || 0;
2151
+ O.current = setTimeout(() => {
2152
2152
  requestAnimationFrame(() => {
2153
2153
  l == null || l.scrollTo({
2154
2154
  scrollTop: Jn,
@@ -2160,22 +2160,22 @@ const ti = ln(({ widths: t, heights: e }) => {
2160
2160
  width: V.width
2161
2161
  };
2162
2162
  },
2163
- [l, g, f, a]
2163
+ [l, g, h, a]
2164
2164
  );
2165
2165
  F(() => {
2166
- clearTimeout(D.current);
2166
+ clearTimeout(O.current);
2167
2167
  const U = Array.from({ length: L }).reduce(
2168
- (ye, it, xe) => ye + I(xe),
2168
+ (ye, it, Ie) => ye + x(Ie),
2169
2169
  0
2170
- ), V = Array.from({ length: O }).reduce(
2171
- (ye, it, xe) => ye + M(xe),
2170
+ ), V = Array.from({ length: D }).reduce(
2171
+ (ye, it, Ie) => ye + M(Ie),
2172
2172
  0
2173
2173
  ), Se = Te(V, U);
2174
2174
  te.current = Se, _e(Se, { height: U, width: V }), m({
2175
2175
  height: U,
2176
2176
  width: V
2177
2177
  });
2178
- }, [A, L, O, _e]);
2178
+ }, [A, L, D, _e]);
2179
2179
  const rt = N(
2180
2180
  (U) => {
2181
2181
  te.current = {
@@ -2183,7 +2183,7 @@ const ti = ln(({ widths: t, heights: e }) => {
2183
2183
  scrollLeft: U.scrollLeft
2184
2184
  };
2185
2185
  },
2186
- [v]
2186
+ [w]
2187
2187
  );
2188
2188
  F(() => () => {
2189
2189
  q.current && clearTimeout(q.current);
@@ -2201,29 +2201,29 @@ const ti = ln(({ widths: t, heights: e }) => {
2201
2201
  [Y, ve, de]
2202
2202
  );
2203
2203
  return F(() => {
2204
- C && le();
2205
- }, [C]), F(() => {
2206
- if (!(j.height === 0 || !P.current)) {
2204
+ P && le();
2205
+ }, [P]), F(() => {
2206
+ if (!(j.height === 0 || !b.current)) {
2207
2207
  if (e === Q.PAGE_SCROLLING) {
2208
- t !== h && w && y(t), P.current = !1;
2208
+ t !== f && _ && y(t), b.current = !1;
2209
2209
  return;
2210
2210
  }
2211
- a(t, "auto"), y(t), P.current = !1;
2211
+ a(t, "auto"), y(t), b.current = !1;
2212
2212
  }
2213
2213
  }, [
2214
2214
  a,
2215
2215
  e,
2216
- w,
2216
+ _,
2217
2217
  y,
2218
2218
  j
2219
2219
  ]), /* @__PURE__ */ W(fe, { children: [
2220
- /* @__PURE__ */ i(In, { id: n, ref: r, tabIndex: -1, className: ot, children: /* @__PURE__ */ i(ei, { style: { minHeight: "50px" }, children: ({ width: U, height: V }) => /* @__PURE__ */ i("div", { "data-rp": "pages", ref: Kn, style: { width: U, height: V }, children: f === Q.PAGE_SCROLLING ? /* @__PURE__ */ i(
2220
+ /* @__PURE__ */ i(xn, { id: n, ref: r, tabIndex: -1, className: ot, children: /* @__PURE__ */ i(ei, { style: { minHeight: "50px" }, children: ({ width: U, height: V }) => /* @__PURE__ */ i("div", { "data-rp": "pages", ref: Kn, style: { width: U, height: V }, children: h === Q.PAGE_SCROLLING ? /* @__PURE__ */ i(
2221
2221
  "div",
2222
2222
  {
2223
2223
  ref: u,
2224
2224
  style: { width: U, height: V },
2225
2225
  className: ne(de["rp-pages"], de["rp-page-scrolling-wrapper"]),
2226
- children: g === Re.DUAL_PAGE ? /* @__PURE__ */ i(ti, { widths: M, heights: I }) : /* @__PURE__ */ i(ni, { widths: M, heights: I })
2226
+ children: g === Le.DUAL_PAGE ? /* @__PURE__ */ i(ti, { widths: M, heights: x }) : /* @__PURE__ */ i(ni, { widths: M, heights: x })
2227
2227
  }
2228
2228
  ) : G ? /* @__PURE__ */ i(
2229
2229
  jo,
@@ -2233,9 +2233,9 @@ const ti = ln(({ widths: t, heights: e }) => {
2233
2233
  outerRef: d,
2234
2234
  innerRef: s,
2235
2235
  onScroll: rt,
2236
- columnCount: O,
2236
+ columnCount: D,
2237
2237
  columnWidth: M,
2238
- rowHeight: I,
2238
+ rowHeight: x,
2239
2239
  height: V,
2240
2240
  width: U,
2241
2241
  estimatedColumnWidth: G,
@@ -2243,11 +2243,11 @@ const ti = ln(({ widths: t, heights: e }) => {
2243
2243
  rowCount: L,
2244
2244
  className: ne(
2245
2245
  de["rp-pages"],
2246
- f === Q.HORIZONTAL_SCROLLING ? de["rp-pages-horizontal-scroll"] : ""
2246
+ h === Q.HORIZONTAL_SCROLLING ? de["rp-pages-horizontal-scroll"] : ""
2247
2247
  ),
2248
2248
  children: oi
2249
2249
  }
2250
- ) : C ? null : /* @__PURE__ */ i(
2250
+ ) : P ? null : /* @__PURE__ */ i(
2251
2251
  "div",
2252
2252
  {
2253
2253
  className: de["rp-loader"],
@@ -2261,7 +2261,7 @@ const ti = ln(({ widths: t, heights: e }) => {
2261
2261
  children: T && /* @__PURE__ */ i(T, {})
2262
2262
  }
2263
2263
  ) }) }) }),
2264
- b && /* @__PURE__ */ i(qr, {})
2264
+ v && /* @__PURE__ */ i(qr, {})
2265
2265
  ] });
2266
2266
  }, We = {
2267
2267
  "rp-toolbar-content": "_rp-toolbar-content_sz31z_1",
@@ -2280,24 +2280,24 @@ const ti = ln(({ widths: t, heights: e }) => {
2280
2280
  const { nextIcon: t } = ue();
2281
2281
  return t || /* @__PURE__ */ i(He, { style: { transform: "rotate(180deg" } });
2282
2282
  }, si = () => {
2283
- const { focusedPage: t, totalPages: e, setFocusedPage: n, nextPage: o, prevPage: r, goToPage: a } = ie(), [l, c] = $(t.toString()), { pageNavigationTool: u = !0 } = ge(), { isSmallScreen: d } = Pe(), { localeMessages: m } = ae(), { viewMode: v } = Ne(), { scrollMode: p } = Ee();
2283
+ const { focusedPage: t, totalPages: e, setFocusedPage: n, nextPage: o, prevPage: r, goToPage: a } = ie(), [l, c] = $(t.toString()), { pageNavigationTool: u = !0 } = ge(), { isSmallScreen: d } = Pe(), { localeMessages: m } = ae(), { viewMode: w } = Oe(), { scrollMode: p } = Ne();
2284
2284
  F(() => {
2285
2285
  c(t.toString());
2286
2286
  }, [t]);
2287
- const w = N((h) => {
2288
- const f = h.target.value;
2289
- c(f);
2290
- }, []), P = N(async () => {
2291
- const h = a(l);
2292
- h.success || c(h.currentPage.toString());
2287
+ const _ = N((f) => {
2288
+ const h = f.target.value;
2289
+ c(h);
2290
+ }, []), b = N(async () => {
2291
+ const f = a(l);
2292
+ f.success || c(f.currentPage.toString());
2293
2293
  }, [a, l, e]), S = N(() => {
2294
2294
  c(t.toString());
2295
- }, [t]), _ = N(
2296
- (h) => {
2297
- h.key === "Enter" && P();
2295
+ }, [t]), C = N(
2296
+ (f) => {
2297
+ f.key === "Enter" && b();
2298
2298
  },
2299
- [P]
2300
- ), y = k(() => v === Re.DUAL_PAGE && p === Q.PAGE_SCROLLING && t === e - 1 || t === e, [t, e, v, p]);
2299
+ [b]
2300
+ ), y = k(() => w === Le.DUAL_PAGE && p === Q.PAGE_SCROLLING && t === e - 1 || t === e, [t, e, w, p]);
2301
2301
  return typeof u != "boolean" ? /* @__PURE__ */ i(
2302
2302
  u,
2303
2303
  {
@@ -2321,9 +2321,9 @@ const ti = ln(({ widths: t, heights: e }) => {
2321
2321
  /* @__PURE__ */ i(K, { content: m == null ? void 0 : m.currentPageTooltip, children: /* @__PURE__ */ i(
2322
2322
  dn,
2323
2323
  {
2324
- onKeyDown: _,
2324
+ onKeyDown: C,
2325
2325
  onBlur: S,
2326
- onChange: w,
2326
+ onChange: _,
2327
2327
  value: l,
2328
2328
  className: mt["rp-page-input"]
2329
2329
  }
@@ -2343,7 +2343,7 @@ const ti = ln(({ widths: t, heights: e }) => {
2343
2343
  ) })
2344
2344
  ] }) : null;
2345
2345
  };
2346
- var nt = "Dialog", [Rn, js] = Jr(nt), [ci, se] = Rn(nt), Ln = (t) => {
2346
+ var nt = "Dialog", [Rn, Ks] = Jr(nt), [ci, se] = Rn(nt), Ln = (t) => {
2347
2347
  const {
2348
2348
  __scopeDialog: e,
2349
2349
  children: n,
@@ -2368,7 +2368,7 @@ var nt = "Dialog", [Rn, js] = Jr(nt), [ci, se] = Rn(nt), Ln = (t) => {
2368
2368
  descriptionId: lt(),
2369
2369
  open: d,
2370
2370
  onOpenChange: m,
2371
- onOpenToggle: B.useCallback(() => m((v) => !v), [m]),
2371
+ onOpenToggle: B.useCallback(() => m((w) => !w), [m]),
2372
2372
  modal: l,
2373
2373
  children: n
2374
2374
  }
@@ -2425,16 +2425,16 @@ var ui = to("DialogOverlay.RemoveScroll"), pi = B.forwardRef(
2425
2425
  ) })
2426
2426
  );
2427
2427
  }
2428
- ), Le = "DialogContent", zn = B.forwardRef(
2428
+ ), Ee = "DialogContent", zn = B.forwardRef(
2429
2429
  (t, e) => {
2430
- const n = Nn(Le, t.__scopeDialog), { forceMount: o = n.forceMount, ...r } = t, a = se(Le, t.__scopeDialog);
2430
+ const n = Nn(Ee, t.__scopeDialog), { forceMount: o = n.forceMount, ...r } = t, a = se(Ee, t.__scopeDialog);
2431
2431
  return /* @__PURE__ */ i(yt, { present: o || a.open, children: a.modal ? /* @__PURE__ */ i(hi, { ...r, ref: e }) : /* @__PURE__ */ i(fi, { ...r, ref: e }) });
2432
2432
  }
2433
2433
  );
2434
- zn.displayName = Le;
2434
+ zn.displayName = Ee;
2435
2435
  var hi = B.forwardRef(
2436
2436
  (t, e) => {
2437
- const n = se(Le, t.__scopeDialog), o = B.useRef(null), r = St(e, n.contentRef, o);
2437
+ const n = se(Ee, t.__scopeDialog), o = B.useRef(null), r = St(e, n.contentRef, o);
2438
2438
  return B.useEffect(() => {
2439
2439
  const a = o.current;
2440
2440
  if (a)
@@ -2463,7 +2463,7 @@ var hi = B.forwardRef(
2463
2463
  }
2464
2464
  ), fi = B.forwardRef(
2465
2465
  (t, e) => {
2466
- const n = se(Le, t.__scopeDialog), o = B.useRef(!1), r = B.useRef(!1);
2466
+ const n = se(Ee, t.__scopeDialog), o = B.useRef(!1), r = B.useRef(!1);
2467
2467
  return /* @__PURE__ */ i(
2468
2468
  An,
2469
2469
  {
@@ -2486,7 +2486,7 @@ var hi = B.forwardRef(
2486
2486
  }
2487
2487
  ), An = B.forwardRef(
2488
2488
  (t, e) => {
2489
- const { __scopeDialog: n, trapFocus: o, onOpenAutoFocus: r, onCloseAutoFocus: a, ...l } = t, c = se(Le, n), u = B.useRef(null), d = St(e, u);
2489
+ const { __scopeDialog: n, trapFocus: o, onOpenAutoFocus: r, onCloseAutoFocus: a, ...l } = t, c = se(Ee, n), u = B.useRef(null), d = St(e, u);
2490
2490
  return oo(), /* @__PURE__ */ W(fe, { children: [
2491
2491
  /* @__PURE__ */ i(
2492
2492
  io,
@@ -2549,8 +2549,8 @@ Mn.displayName = kn;
2549
2549
  function Nt(t) {
2550
2550
  return t ? "open" : "closed";
2551
2551
  }
2552
- var Hn = "DialogTitleWarning", [Ks, $n] = Qr(Hn, {
2553
- contentName: Le,
2552
+ var Hn = "DialogTitleWarning", [Xs, $n] = Qr(Hn, {
2553
+ contentName: Ee,
2554
2554
  titleName: Et,
2555
2555
  docsSlug: "dialog"
2556
2556
  }), gi = ({ titleId: t }) => {
@@ -2570,7 +2570,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${e.do
2570
2570
  e && r && (document.getElementById(e) || console.warn(o));
2571
2571
  }, [o, t, e]), null;
2572
2572
  }, _i = Ln, bi = On, Ci = Dn, Pi = zn, Ti = Fn, Si = Mn;
2573
- const Ie = {
2573
+ const xe = {
2574
2574
  "rp-dialog-wrapper": "_rp-dialog-wrapper_slqo7_1",
2575
2575
  "rp-dialog-overlay": "_rp-dialog-overlay_slqo7_7",
2576
2576
  "rp-document-dialog": "_rp-document-dialog_slqo7_13",
@@ -2588,12 +2588,12 @@ const Ie = {
2588
2588
  title: u,
2589
2589
  author: d,
2590
2590
  subject: m,
2591
- createdOn: v,
2591
+ createdOn: w,
2592
2592
  creator: p,
2593
- keywords: w,
2594
- modifiedOn: P,
2593
+ keywords: _,
2594
+ modifiedOn: b,
2595
2595
  pdfProducer: S,
2596
- pdfVersion: _,
2596
+ pdfVersion: C,
2597
2597
  pageCount: y
2598
2598
  } = t;
2599
2599
  return [
@@ -2603,35 +2603,35 @@ const Ie = {
2603
2603
  { label: r == null ? void 0 : r.propertiesTitleLabel, value: u },
2604
2604
  { label: r == null ? void 0 : r.propertiesAuthorLabel, value: d },
2605
2605
  { label: r == null ? void 0 : r.propertiesSubjectLabel, value: m },
2606
- { label: r == null ? void 0 : r.propertiesKeywordLabel, value: w },
2606
+ { label: r == null ? void 0 : r.propertiesKeywordLabel, value: _ },
2607
2607
  { label: r == null ? void 0 : r.propertiesCreatorLabel, value: p },
2608
2608
  {
2609
2609
  label: r == null ? void 0 : r.propertiesCreateOnLabel,
2610
- value: v ? kt(v) : ""
2610
+ value: w ? kt(w) : ""
2611
2611
  },
2612
2612
  {
2613
2613
  label: r == null ? void 0 : r.propertiesModifiedOnLabel,
2614
- value: P ? kt(P) : ""
2614
+ value: b ? kt(b) : ""
2615
2615
  },
2616
2616
  { separate: !0 },
2617
2617
  { label: r == null ? void 0 : r.propertiesPDFProducerLabel, value: S },
2618
- { label: r == null ? void 0 : r.propertiesPDFVersionLabel, value: _ },
2618
+ { label: r == null ? void 0 : r.propertiesPDFVersionLabel, value: C },
2619
2619
  { label: r == null ? void 0 : r.propertiesPageCountLabel, value: y }
2620
2620
  ];
2621
2621
  }, [t, r]);
2622
- return /* @__PURE__ */ i(_i, { open: n, onOpenChange: o, children: /* @__PURE__ */ i(bi, { container: e, children: /* @__PURE__ */ W("div", { className: Ie["rp-dialog-wrapper"], children: [
2623
- /* @__PURE__ */ i(Ci, { className: Ie["rp-dialog-overlay"] }),
2624
- /* @__PURE__ */ W(Pi, { className: Ie["rp-document-dialog"], children: [
2625
- /* @__PURE__ */ i(Ti, { className: Ie["rp-dialog-title"], children: r == null ? void 0 : r.documentPropertiesLabel }),
2626
- /* @__PURE__ */ i("div", { className: Ie["rp-document-properties"], children: a.map((l, c) => /* @__PURE__ */ i("div", { children: l.separate ? /* @__PURE__ */ i("div", { className: Ie["rp-properties-divider"] }) : /* @__PURE__ */ i(lo, { label: l.label, value: l.value }) }, c)) }),
2627
- /* @__PURE__ */ i(Si, { asChild: !0, className: Ie["rp-dialog-close"], children: /* @__PURE__ */ i(co, {}) })
2622
+ return /* @__PURE__ */ i(_i, { open: n, onOpenChange: o, children: /* @__PURE__ */ i(bi, { container: e, children: /* @__PURE__ */ W("div", { className: xe["rp-dialog-wrapper"], children: [
2623
+ /* @__PURE__ */ i(Ci, { className: xe["rp-dialog-overlay"] }),
2624
+ /* @__PURE__ */ W(Pi, { className: xe["rp-document-dialog"], children: [
2625
+ /* @__PURE__ */ i(Ti, { className: xe["rp-dialog-title"], children: r == null ? void 0 : r.documentPropertiesLabel }),
2626
+ /* @__PURE__ */ i("div", { className: xe["rp-document-properties"], children: a.map((l, c) => /* @__PURE__ */ i("div", { children: l.separate ? /* @__PURE__ */ i("div", { className: xe["rp-properties-divider"] }) : /* @__PURE__ */ i(lo, { label: l.label, value: l.value }) }, c)) }),
2627
+ /* @__PURE__ */ i(Si, { asChild: !0, className: xe["rp-dialog-close"], children: /* @__PURE__ */ i(co, {}) })
2628
2628
  ] })
2629
2629
  ] }) }) });
2630
- }, xi = {
2630
+ }, Ii = {
2631
2631
  "rp-other-tool-content": "_rp-other-tool-content_su718_1"
2632
- }, nn = ".pdf", Ii = (t) => URL.createObjectURL(t), Ri = async (t) => {
2632
+ }, nn = ".pdf", xi = (t) => URL.createObjectURL(t), Ri = async (t) => {
2633
2633
  const n = await (await fetch(t)).blob();
2634
- return Ii(n);
2634
+ return xi(n);
2635
2635
  }, Gn = () => {
2636
2636
  const { filename: t, pdfSrc: e } = ee(), { downloadFilename: n } = fr(), o = (a) => {
2637
2637
  const l = n || a;
@@ -2694,60 +2694,61 @@ const Ie = {
2694
2694
  /* @__PURE__ */ i("div", { className: "rp-menu-item-left", children: /* @__PURE__ */ i(Ai, {}) }),
2695
2695
  /* @__PURE__ */ i("span", { children: r == null ? void 0 : r.lastPageLabel })
2696
2696
  ] }) }) }),
2697
- /* @__PURE__ */ i(xt, {})
2697
+ /* @__PURE__ */ i(It, {})
2698
2698
  ] }) : null;
2699
2699
  }, Wi = () => {
2700
- const { container: t, pagesRef: e } = me(), { isSmallScreen: n } = Pe(), {
2701
- openFileTool: o,
2702
- downloadTool: r,
2703
- documentProperties: a,
2704
- scrollModeTool: l,
2705
- rotateTool: c,
2706
- selectionModeTool: u,
2707
- jumpNavigationTool: d,
2708
- printTool: m,
2709
- fullscreenTool: v
2710
- } = ge(), { localeMessages: p } = ae(), [w, P] = $(0), S = H(
2711
- new ResizeObserver((y) => {
2712
- P(y[0].contentRect.height);
2700
+ const [t, e] = $(!1), { container: n, pagesRef: o } = me(), { isSmallScreen: r } = Pe(), {
2701
+ openFileTool: a,
2702
+ downloadTool: l,
2703
+ documentProperties: c,
2704
+ scrollModeTool: u,
2705
+ rotateTool: d,
2706
+ selectionModeTool: m,
2707
+ jumpNavigationTool: w,
2708
+ printTool: p,
2709
+ fullscreenTool: _
2710
+ } = ge(), { localeMessages: b } = ae(), [S, C] = $(0), y = H(
2711
+ new ResizeObserver((h) => {
2712
+ C(h[0].contentRect.height);
2713
2713
  })
2714
- ), _ = k(() => {
2715
- const y = d || c || u || l || a;
2716
- let h = !1;
2717
- return n && (h = !(!o && !r && !m && !v)), y || h;
2714
+ ), f = k(() => {
2715
+ const h = w || d || m || u || c;
2716
+ let g = !1;
2717
+ return r && (g = !(!a && !l && !p && !_)), h || g;
2718
2718
  }, [
2719
- o,
2720
- r,
2721
2719
  a,
2722
2720
  l,
2723
2721
  c,
2724
2722
  u,
2725
2723
  d,
2726
- n
2724
+ m,
2725
+ w,
2726
+ r
2727
2727
  ]);
2728
- return F(() => (e && S.current.observe(e), () => {
2729
- S.current.disconnect();
2730
- }), [e]), _ ? /* @__PURE__ */ W(po, { children: [
2728
+ return F(() => (o && y.current.observe(o), () => {
2729
+ y.current.disconnect();
2730
+ }), [o]), f ? /* @__PURE__ */ W(po, { children: [
2731
2731
  /* @__PURE__ */ i(
2732
2732
  mn,
2733
2733
  {
2734
- container: t,
2735
- triggerComponent: /* @__PURE__ */ i("div", { role: "button", children: /* @__PURE__ */ i(K, { content: p == null ? void 0 : p.moreOptionTooltip, children: /* @__PURE__ */ i(re, { "aria-label": p == null ? void 0 : p.moreOptionTooltip, children: /* @__PURE__ */ i(Yr, {}) }) }) }),
2734
+ container: n,
2735
+ onOpenChange: e,
2736
+ triggerComponent: /* @__PURE__ */ i("div", { role: "button", children: /* @__PURE__ */ i(K, { content: b == null ? void 0 : b.moreOptionTooltip, children: /* @__PURE__ */ i(re, { active: t, "aria-label": b == null ? void 0 : b.moreOptionTooltip, children: /* @__PURE__ */ i(Yr, {}) }) }) }),
2736
2737
  side: "bottom",
2737
2738
  avoidCollisions: !1,
2738
2739
  children: /* @__PURE__ */ W(
2739
2740
  "div",
2740
2741
  {
2741
- style: { maxHeight: `${w}px`, overflow: "auto" },
2742
- className: xi["rp-other-tool-content"],
2742
+ style: { maxHeight: `${S}px`, overflow: "auto" },
2743
+ className: Ii["rp-other-tool-content"],
2743
2744
  "data-rp": "moreOptionsDropdown",
2744
2745
  children: [
2745
- n && /* @__PURE__ */ W(Ke, { children: [
2746
+ r && /* @__PURE__ */ W(Ke, { children: [
2746
2747
  /* @__PURE__ */ i(fn, {}),
2747
2748
  /* @__PURE__ */ i(qn, {}),
2748
2749
  /* @__PURE__ */ i(jn, {}),
2749
2750
  /* @__PURE__ */ i(gn, {}),
2750
- /* @__PURE__ */ i(xt, {})
2751
+ /* @__PURE__ */ i(It, {})
2751
2752
  ] }),
2752
2753
  /* @__PURE__ */ i(Fi, {}),
2753
2754
  /* @__PURE__ */ i(fo, {}),
@@ -2774,80 +2775,86 @@ const Ie = {
2774
2775
  ] }),
2775
2776
  /* @__PURE__ */ i(Wi, {})
2776
2777
  ] });
2777
- }, De = {
2778
- "rp-zoom-wrapper": "_rp-zoom-wrapper_cocqs_1",
2779
- "rp-current-zoom-wrapper": "_rp-current-zoom-wrapper_cocqs_6",
2780
- "rp-current-zoom-icon": "_rp-current-zoom-icon_cocqs_11",
2781
- "rp-current-zoom-text": "_rp-current-zoom-text_cocqs_16",
2782
- "rp-zoom-dropdown-content": "_rp-zoom-dropdown-content_cocqs_20"
2783
- }, Mi = 25, gt = 1e3, Hi = [50, 75, 100, 125, 150, 200, 300, 400], $i = () => {
2778
+ }, Mi = "_active_1fv1b_11", Re = {
2779
+ "rp-zoom-wrapper": "_rp-zoom-wrapper_1fv1b_1",
2780
+ "rp-current-zoom-wrapper": "_rp-current-zoom-wrapper_1fv1b_6",
2781
+ active: Mi,
2782
+ "rp-current-zoom-icon": "_rp-current-zoom-icon_1fv1b_15",
2783
+ "rp-current-zoom-text": "_rp-current-zoom-text_1fv1b_20",
2784
+ "rp-zoom-dropdown-content": "_rp-zoom-dropdown-content_1fv1b_24"
2785
+ }, Hi = 25, gt = 1e3, $i = [50, 75, 100, 125, 150, 200, 300, 400], Gi = () => {
2784
2786
  const { zoomInIcon: t } = ue();
2785
2787
  return t || /* @__PURE__ */ i(bo, {});
2786
- }, Gi = () => {
2788
+ }, Ui = () => {
2787
2789
  const { zoomOutIcon: t } = ue();
2788
2790
  return t || /* @__PURE__ */ i(Co, {});
2789
- }, Ui = () => {
2790
- const { zoomLevel: t, setZoomLevel: e } = Qe(), { container: n, pagesRef: o } = me(), { zoomTool: r = !0 } = ge(), { focusedPage: a } = ie(), { pageRotate: l } = Ue(), { pages: c } = ee(), { isSmallScreen: u } = Pe(), { localeMessages: d } = ae(), { viewMode: m } = Ne(), [v, p] = $(0), w = H(
2791
- new ResizeObserver((s) => {
2792
- p(s[0].contentRect.height);
2791
+ }, Vi = () => {
2792
+ const { zoomLevel: t, setZoomLevel: e } = Qe(), { container: n, pagesRef: o } = me(), { zoomTool: r = !0 } = ge(), { focusedPage: a } = ie(), { pageRotate: l } = Ue(), { pages: c } = ee(), { isSmallScreen: u } = Pe(), { localeMessages: d } = ae(), { viewMode: m } = Oe(), [w, p] = $(0), [_, b] = $(!1), S = H(
2793
+ new ResizeObserver((v) => {
2794
+ p(v[0].contentRect.height);
2793
2795
  })
2794
- ), P = N(() => {
2795
- e((s) => {
2796
- const C = Math.floor(s / 25) * 25;
2797
- return Math.min(C + 25, gt);
2796
+ ), C = N(() => {
2797
+ e((v) => {
2798
+ const T = Math.floor(v / 25) * 25;
2799
+ return Math.min(T + 25, gt);
2798
2800
  });
2799
- }, [e]), S = N(() => {
2800
- e((s) => {
2801
- const C = Math.ceil(s / 25) * 25;
2802
- return Math.min(C - 25, gt);
2801
+ }, [e]), y = N(() => {
2802
+ e((v) => {
2803
+ const T = Math.ceil(v / 25) * 25;
2804
+ return Math.min(T - 25, gt);
2803
2805
  });
2804
- }, [e]), _ = k(() => t === Mi, [t]), y = k(() => t === gt, [t]), h = k(() => {
2805
- const s = c.get(a);
2806
- return s ? s.page.getViewport({ scale: 1, rotation: l[a] }) : null;
2807
- }, [c, a, l]), f = N(
2808
- (s) => {
2809
- const C = ((h == null ? void 0 : h.width) || 0) + 2 * Mt, b = ((h == null ? void 0 : h.height) || 0) + 2 * Mt, T = (o == null ? void 0 : o.clientWidth) || 0, E = (o == null ? void 0 : o.clientHeight) || 0, x = Po(
2810
- s,
2806
+ }, [e]), f = k(() => t === Hi, [t]), h = k(() => t === gt, [t]), g = k(() => {
2807
+ const v = c.get(a);
2808
+ return v ? v.page.getViewport({ scale: 1, rotation: l[a] }) : null;
2809
+ }, [c, a, l]), s = N(
2810
+ (v) => {
2811
+ const T = ((g == null ? void 0 : g.width) || 0) + 2 * Mt, E = ((g == null ? void 0 : g.height) || 0) + 2 * Mt, I = (o == null ? void 0 : o.clientWidth) || 0, R = (o == null ? void 0 : o.clientHeight) || 0, O = Po(
2812
+ v,
2813
+ I,
2814
+ R,
2811
2815
  T,
2812
2816
  E,
2813
- C,
2814
- b,
2815
2817
  m
2816
2818
  );
2817
- e(x);
2819
+ e(O);
2818
2820
  },
2819
- [e, h, o]
2820
- ), g = N(
2821
- (s) => {
2822
- typeof s == "number" ? e(s) : f(s);
2821
+ [e, g, o]
2822
+ ), P = N(
2823
+ (v) => {
2824
+ typeof v == "number" ? e(v) : s(v);
2823
2825
  },
2824
- [e, f]
2826
+ [e, s]
2825
2827
  );
2826
- return F(() => (o && w.current.observe(o), () => {
2827
- w.current.disconnect();
2828
- }), [o]), typeof r != "boolean" ? /* @__PURE__ */ i(r, { zoomLevel: t, setZoomLevel: e }) : r ? /* @__PURE__ */ W("div", { className: De["rp-zoom-wrapper"], children: [
2828
+ return F(() => (o && S.current.observe(o), () => {
2829
+ S.current.disconnect();
2830
+ }), [o]), typeof r != "boolean" ? /* @__PURE__ */ i(r, { zoomLevel: t, setZoomLevel: e }) : r ? /* @__PURE__ */ W("div", { className: Re["rp-zoom-wrapper"], children: [
2829
2831
  /* @__PURE__ */ i(K, { content: d == null ? void 0 : d.zoomOutTooltip, children: /* @__PURE__ */ i(
2830
2832
  re,
2831
2833
  {
2832
- disabled: _,
2833
- onClick: S,
2834
+ disabled: f,
2835
+ onClick: y,
2834
2836
  "aria-label": d == null ? void 0 : d.zoomOutTooltip,
2835
- children: /* @__PURE__ */ i(Gi, {})
2837
+ children: /* @__PURE__ */ i(Ui, {})
2836
2838
  }
2837
2839
  ) }),
2838
2840
  !u && /* @__PURE__ */ i(
2839
2841
  mn,
2840
2842
  {
2841
2843
  container: n,
2844
+ open: _,
2845
+ onOpenChange: b,
2842
2846
  triggerComponent: /* @__PURE__ */ i("div", { role: "button", children: /* @__PURE__ */ i(K, { content: d == null ? void 0 : d.zoomSelectTooltip, children: /* @__PURE__ */ W(
2843
2847
  re,
2844
2848
  {
2845
- className: De["rp-current-zoom-wrapper"],
2849
+ className: ne(
2850
+ Re["rp-current-zoom-wrapper"],
2851
+ _ && Re.active
2852
+ ),
2846
2853
  "aria-label": d == null ? void 0 : d.zoomSelectTooltip,
2847
2854
  children: [
2848
- /* @__PURE__ */ i("span", { className: De["rp-current-zoom-text"], children: t }),
2849
- /* @__PURE__ */ i("span", { className: De["rp-current-zoom-text"], children: "%" }),
2850
- /* @__PURE__ */ i(He, { className: De["rp-current-zoom-icon"] })
2855
+ /* @__PURE__ */ i("span", { className: Re["rp-current-zoom-text"], children: t }),
2856
+ /* @__PURE__ */ i("span", { className: Re["rp-current-zoom-text"], children: "%" }),
2857
+ /* @__PURE__ */ i(He, { className: Re["rp-current-zoom-icon"] })
2851
2858
  ]
2852
2859
  }
2853
2860
  ) }) }),
@@ -2858,19 +2865,19 @@ const Ie = {
2858
2865
  children: /* @__PURE__ */ W(
2859
2866
  "div",
2860
2867
  {
2861
- style: { maxHeight: `${v}px`, overflow: "auto" },
2862
- className: De["rp-zoom-dropdown-content"],
2868
+ style: { maxHeight: `${w}px`, overflow: "auto" },
2869
+ className: Re["rp-zoom-dropdown-content"],
2863
2870
  children: [
2864
2871
  /* @__PURE__ */ W(Ke, { children: [
2865
- /* @__PURE__ */ i(Ce, { onClick: () => g(st.ACTUAL), children: d == null ? void 0 : d.zoomActualSize }),
2866
- /* @__PURE__ */ i(Ce, { onClick: () => g(st.PAGE_FIT), children: d == null ? void 0 : d.zoomPageFit }),
2867
- /* @__PURE__ */ i(Ce, { onClick: () => g(st.PAGE_WIDTH), children: d == null ? void 0 : d.zoomPageWidth })
2872
+ /* @__PURE__ */ i(Ce, { onClick: () => P(st.ACTUAL), children: d == null ? void 0 : d.zoomActualSize }),
2873
+ /* @__PURE__ */ i(Ce, { onClick: () => P(st.PAGE_FIT), children: d == null ? void 0 : d.zoomPageFit }),
2874
+ /* @__PURE__ */ i(Ce, { onClick: () => P(st.PAGE_WIDTH), children: d == null ? void 0 : d.zoomPageWidth })
2868
2875
  ] }),
2869
- /* @__PURE__ */ i(xt, {}),
2870
- /* @__PURE__ */ i(Ke, { children: Hi.map((s) => /* @__PURE__ */ W(Ce, { onClick: () => g(s), children: [
2871
- s,
2876
+ /* @__PURE__ */ i(It, {}),
2877
+ /* @__PURE__ */ i(Ke, { children: $i.map((v) => /* @__PURE__ */ W(Ce, { onClick: () => P(v), children: [
2878
+ v,
2872
2879
  " %"
2873
- ] }, s)) })
2880
+ ] }, v)) })
2874
2881
  ]
2875
2882
  }
2876
2883
  )
@@ -2879,10 +2886,10 @@ const Ie = {
2879
2886
  /* @__PURE__ */ i(K, { content: d == null ? void 0 : d.zoomInTooltip, children: /* @__PURE__ */ i(
2880
2887
  re,
2881
2888
  {
2882
- disabled: y,
2883
- onClick: P,
2889
+ disabled: h,
2890
+ onClick: C,
2884
2891
  "aria-label": d == null ? void 0 : d.zoomInTooltip,
2885
- children: /* @__PURE__ */ i($i, {})
2892
+ children: /* @__PURE__ */ i(Gi, {})
2886
2893
  }
2887
2894
  ) })
2888
2895
  ] }) : null;
@@ -2891,7 +2898,7 @@ const Ie = {
2891
2898
  totalMatches: t,
2892
2899
  nextMatch: e,
2893
2900
  prevMatch: n
2894
- } = It(), { localeMessages: o } = ae();
2901
+ } = xt(), { localeMessages: o } = ae();
2895
2902
  return /* @__PURE__ */ W(fe, { children: [
2896
2903
  /* @__PURE__ */ i(K, { content: o == null ? void 0 : o.searchPrevTooltip, className: J["rp-search-tool-result-navigator"], children: /* @__PURE__ */ i(re, { onClick: n, "aria-label": o == null ? void 0 : o.searchPrevTooltip, children: /* @__PURE__ */ i(
2897
2904
  He,
@@ -2912,52 +2919,52 @@ const Ie = {
2912
2919
  }, an = () => {
2913
2920
  const { searchIcon: t } = ue();
2914
2921
  return t || /* @__PURE__ */ i(To, {});
2915
- }, Vi = () => {
2922
+ }, qi = () => {
2916
2923
  const { container: t } = me(), [e, n] = $(!1), { pdf: o } = ee(), [r, a] = $(null), {
2917
2924
  searchOptions: l,
2918
2925
  setSearchOptions: c,
2919
2926
  loading: u,
2920
2927
  setSearch: d,
2921
2928
  totalMatches: m,
2922
- currentMatchPosition: v,
2929
+ currentMatchPosition: w,
2923
2930
  nextMatch: p,
2924
- prevMatch: w,
2925
- search: P
2926
- } = It(), { searchTool: S = !0 } = ge(), [_, y] = $(P), { localeMessages: h } = ae(), { isSmallScreen: f } = Pe(), g = N(() => {
2931
+ prevMatch: _,
2932
+ search: b
2933
+ } = xt(), { searchTool: S = !0 } = ge(), [C, y] = $(b), { localeMessages: f } = ae(), { isSmallScreen: h } = Pe(), g = N(() => {
2927
2934
  n(!0);
2928
2935
  }, []), s = N(() => {
2929
2936
  d(""), y(""), n(!1);
2930
- }, [d]), C = (I) => {
2931
- const O = I.key === "Enter", M = I.key === " ";
2932
- (O || M) && s();
2933
- }, b = N(
2934
- (I) => {
2935
- I.key === "Escape" && e && s();
2937
+ }, [d]), P = (x) => {
2938
+ const D = x.key === "Enter", M = x.key === " ";
2939
+ (D || M) && s();
2940
+ }, v = N(
2941
+ (x) => {
2942
+ x.key === "Escape" && e && s();
2936
2943
  },
2937
2944
  [e]
2938
2945
  ), T = N(
2939
- (I) => {
2940
- I.shiftKey && I.key === "Enter" ? w() : I.key === "Enter" && P !== _ ? d(_) : I.key === "Enter" && p();
2946
+ (x) => {
2947
+ x.shiftKey && x.key === "Enter" ? _() : x.key === "Enter" && b !== C ? d(C) : x.key === "Enter" && p();
2941
2948
  },
2942
- [_, w, p, d, P]
2949
+ [C, _, p, d, b]
2943
2950
  );
2944
- F(() => (window.addEventListener("keydown", b), () => {
2945
- window.removeEventListener("keydown", b);
2946
- }), [b]), F(() => {
2951
+ F(() => (window.addEventListener("keydown", v), () => {
2952
+ window.removeEventListener("keydown", v);
2953
+ }), [v]), F(() => {
2947
2954
  r && r.focus();
2948
2955
  }, [r]);
2949
- const E = N((I) => {
2950
- y(I.target.value);
2951
- }, []), x = N(() => {
2956
+ const E = N((x) => {
2957
+ y(x.target.value);
2958
+ }, []), I = N(() => {
2952
2959
  y(""), d("");
2953
- }, [d]), R = k(() => `${v} / ${m}`, [v, m]), { wholeWords: D, matchCase: z } = k(() => l, [l]), A = N(
2954
- (I) => {
2955
- c((O) => ({ ...O, matchCase: I }));
2960
+ }, [d]), R = k(() => `${w} / ${m}`, [w, m]), { wholeWords: O, matchCase: z } = k(() => l, [l]), A = N(
2961
+ (x) => {
2962
+ c((D) => ({ ...D, matchCase: x }));
2956
2963
  },
2957
2964
  [c]
2958
2965
  ), L = N(
2959
- (I) => {
2960
- c((O) => ({ ...O, wholeWords: I }));
2966
+ (x) => {
2967
+ c((D) => ({ ...D, wholeWords: x }));
2961
2968
  },
2962
2969
  [c]
2963
2970
  );
@@ -2968,50 +2975,58 @@ const Ie = {
2968
2975
  {
2969
2976
  open: e,
2970
2977
  container: t,
2971
- triggerComponent: /* @__PURE__ */ i(K, { content: h == null ? void 0 : h.searchButtonTooltip, children: /* @__PURE__ */ i(re, { onClick: g, "aria-label": h == null ? void 0 : h.searchButtonTooltip, children: /* @__PURE__ */ i(an, {}) }) }),
2978
+ triggerComponent: /* @__PURE__ */ i(K, { content: f == null ? void 0 : f.searchButtonTooltip, children: /* @__PURE__ */ i(
2979
+ re,
2980
+ {
2981
+ onClick: g,
2982
+ active: e,
2983
+ "aria-label": f == null ? void 0 : f.searchButtonTooltip,
2984
+ children: /* @__PURE__ */ i(an, {})
2985
+ }
2986
+ ) }),
2972
2987
  children: /* @__PURE__ */ W("div", { className: J["rp-search-tool-content"], children: [
2973
2988
  /* @__PURE__ */ W("div", { className: J["rp-search-tool-input-wrapper"], children: [
2974
2989
  /* @__PURE__ */ W("div", { className: J["rp-search-tool-input"], children: [
2975
- /* @__PURE__ */ i(K, { content: h == null ? void 0 : h.searchInputTooltip, children: /* @__PURE__ */ i(
2990
+ /* @__PURE__ */ i(K, { content: f == null ? void 0 : f.searchInputTooltip, children: /* @__PURE__ */ i(
2976
2991
  dn,
2977
2992
  {
2978
- value: _,
2993
+ value: C,
2979
2994
  onKeyDown: T,
2980
2995
  onChange: E,
2981
2996
  icon: /* @__PURE__ */ i(an, {}),
2982
- placeholder: h == null ? void 0 : h.searchInputPlaceholder,
2997
+ placeholder: f == null ? void 0 : f.searchInputPlaceholder,
2983
2998
  className: J["rp-search-input"],
2984
2999
  ref: a,
2985
- children: !!_ && /* @__PURE__ */ i("span", { className: J["rp-search-tool-input-clear"], onClick: x, children: /* @__PURE__ */ i(So, {}) })
3000
+ children: !!C && /* @__PURE__ */ i("span", { className: J["rp-search-tool-input-clear"], onClick: I, children: /* @__PURE__ */ i(So, {}) })
2986
3001
  }
2987
3002
  ) }),
2988
3003
  u ? /* @__PURE__ */ i("span", { children: /* @__PURE__ */ i(Pt, { className: J["rp-search-loader-icon"] }) }) : /* @__PURE__ */ i("span", { children: R }),
2989
- f && /* @__PURE__ */ i("div", { className: J["rp-search-tool-controls"], children: /* @__PURE__ */ i(Ht, { onKeyPress: C, handleClose: s }) })
3004
+ h && /* @__PURE__ */ i("div", { className: J["rp-search-tool-controls"], children: /* @__PURE__ */ i(Ht, { onKeyPress: P, handleClose: s }) })
2990
3005
  ] }),
2991
3006
  /* @__PURE__ */ W("div", { className: J["rp-search-tool-input-checkboxes"], children: [
2992
- f && /* @__PURE__ */ i(on, {}),
2993
- /* @__PURE__ */ i($t, { name: "matchCase", value: z, onChange: A, children: h == null ? void 0 : h.searchMatchCaseLabel }),
2994
- !f && /* @__PURE__ */ i(K, { content: h == null ? void 0 : h.searchMatchCaseTooltip, children: /* @__PURE__ */ i("div", { className: J["rp-search-icon-info"], tabIndex: 0, children: /* @__PURE__ */ i(Gt, {}) }) }),
2995
- /* @__PURE__ */ i($t, { name: "wholeWord", value: D, onChange: L, children: h == null ? void 0 : h.searchWholeWordsLabel }),
2996
- !f && /* @__PURE__ */ i(K, { content: h == null ? void 0 : h.searchWholeWordsTooltip, children: /* @__PURE__ */ i("div", { className: J["rp-search-icon-info"], tabIndex: 0, children: /* @__PURE__ */ i(Gt, {}) }) })
3007
+ h && /* @__PURE__ */ i(on, {}),
3008
+ /* @__PURE__ */ i($t, { name: "matchCase", value: z, onChange: A, children: f == null ? void 0 : f.searchMatchCaseLabel }),
3009
+ !h && /* @__PURE__ */ i(K, { content: f == null ? void 0 : f.searchMatchCaseTooltip, children: /* @__PURE__ */ i("div", { className: J["rp-search-icon-info"], tabIndex: 0, children: /* @__PURE__ */ i(Gt, {}) }) }),
3010
+ /* @__PURE__ */ i($t, { name: "wholeWord", value: O, onChange: L, children: f == null ? void 0 : f.searchWholeWordsLabel }),
3011
+ !h && /* @__PURE__ */ i(K, { content: f == null ? void 0 : f.searchWholeWordsTooltip, children: /* @__PURE__ */ i("div", { className: J["rp-search-icon-info"], tabIndex: 0, children: /* @__PURE__ */ i(Gt, {}) }) })
2997
3012
  ] })
2998
3013
  ] }),
2999
- !f && /* @__PURE__ */ W("div", { className: J["rp-search-tool-controls"], children: [
3014
+ !h && /* @__PURE__ */ W("div", { className: J["rp-search-tool-controls"], children: [
3000
3015
  /* @__PURE__ */ i(on, {}),
3001
- /* @__PURE__ */ i(Ht, { onKeyPress: C, handleClose: s })
3016
+ /* @__PURE__ */ i(Ht, { onKeyPress: P, handleClose: s })
3002
3017
  ] })
3003
3018
  ] })
3004
3019
  }
3005
3020
  ) }) : null;
3006
- }, qi = "_loading_wazy2_1", ze = {
3021
+ }, Bi = "_loading_wazy2_1", ze = {
3007
3022
  "rp-loading-overlay": "_rp-loading-overlay_wazy2_1",
3008
3023
  "rp-loading-modal": "_rp-loading-modal_wazy2_14",
3009
3024
  "rp-loading-title": "_rp-loading-title_wazy2_27",
3010
3025
  "rp-loading-progress-bar": "_rp-loading-progress-bar_wazy2_35",
3011
3026
  "rp-loading-progress": "_rp-loading-progress_wazy2_35",
3012
3027
  "rp-loading-cancel-button": "_rp-loading-cancel-button_wazy2_55",
3013
- loading: qi
3014
- }, Bi = ({ percentage: t }) => {
3028
+ loading: Bi
3029
+ }, Zi = ({ percentage: t }) => {
3015
3030
  const { cancel: e } = tt(), { localeMessages: n } = ae();
3016
3031
  return t < 1 ? null : /* @__PURE__ */ i("div", { className: ne(ze["rp-loading-overlay"]), children: /* @__PURE__ */ W("div", { className: ne(ze["rp-loading-modal"]), children: [
3017
3032
  /* @__PURE__ */ W("div", { className: ne(ze["rp-loading-title"]), children: [
@@ -3027,18 +3042,18 @@ const Ie = {
3027
3042
  ) }),
3028
3043
  /* @__PURE__ */ i("button", { className: ne(ze["rp-loading-cancel-button"]), onClick: e, children: n == null ? void 0 : n.printCancelLabel })
3029
3044
  ] }) });
3030
- }, Zi = $e((t, e) => {
3045
+ }, ji = $e((t, e) => {
3031
3046
  const { showPrintProgress: n } = ge(), { progress: o } = tt(), { isSmallScreen: r } = Pe(), { percentage: a } = o || {}, l = () => r ? { gridTemplateColumns: "25% 60% 15%" } : void 0;
3032
3047
  return /* @__PURE__ */ W("div", { children: [
3033
3048
  /* @__PURE__ */ i("div", { "data-rp": "topBar", ref: e, className: We["rp-toolbar-content"], children: /* @__PURE__ */ W("div", { className: We["rp-toolbar-wrapper"], style: l(), children: [
3034
3049
  /* @__PURE__ */ W("div", { "data-rp": "topBarLeft", className: We["rp-toolbar-start"], children: [
3035
- /* @__PURE__ */ i(Vi, {}),
3050
+ /* @__PURE__ */ i(qi, {}),
3036
3051
  /* @__PURE__ */ i(si, {})
3037
3052
  ] }),
3038
- /* @__PURE__ */ i("div", { "data-rp": "topBarCenter", className: We["rp-toolbar-middle"], children: /* @__PURE__ */ i(Ui, {}) }),
3053
+ /* @__PURE__ */ i("div", { "data-rp": "topBarCenter", className: We["rp-toolbar-middle"], children: /* @__PURE__ */ i(Vi, {}) }),
3039
3054
  /* @__PURE__ */ i("div", { "data-rp": "topBarRight", className: We["rp-toolbar-end"], children: /* @__PURE__ */ i(ki, {}) })
3040
3055
  ] }) }),
3041
- n && a ? /* @__PURE__ */ i(Bi, { percentage: a }) : null
3056
+ n && a ? /* @__PURE__ */ i(Zi, { percentage: a }) : null
3042
3057
  ] });
3043
3058
  }), vt = {
3044
3059
  "rp-sidebar-content-wrapper": "_rp-sidebar-content-wrapper_1sdl6_1",
@@ -3051,7 +3066,7 @@ const Ie = {
3051
3066
  "rp-thumbnail": "_rp-thumbnail_3fenb_1",
3052
3067
  "rp-thumbnail-active": "_rp-thumbnail-active_3fenb_22",
3053
3068
  "rp-thumbnail-loader": "_rp-thumbnail-loader_3fenb_31"
3054
- }, ji = (t) => {
3069
+ }, Ki = (t) => {
3055
3070
  const { thumbnailSrc: e, pageNumber: n, isFocused: o, viewport: r } = t, { goToPage: a } = ie(), { pageRotate: l } = Ue(), c = k(() => o ? ke["rp-thumbnail-active"] : "", [o]), u = k(() => ({
3056
3071
  width: Math.round(r.width),
3057
3072
  height: Math.round(r.height)
@@ -3100,37 +3115,37 @@ const Ie = {
3100
3115
  }, sn = {
3101
3116
  "rp-thumbnails-container": "_rp-thumbnails-container_16vqr_1",
3102
3117
  "rp-thumbnails": "_rp-thumbnails_16vqr_1"
3103
- }, Ki = 16, Xi = (t, e) => {
3118
+ }, Xi = 16, Yi = (t, e) => {
3104
3119
  const n = t == null ? void 0 : t.querySelector(`#page-${e}`);
3105
- t && (n != null && n.offsetTop) && (t.scrollTop = (n == null ? void 0 : n.offsetTop) - Ki);
3106
- }, Yi = $e((t, e) => {
3120
+ t && (n != null && n.offsetTop) && (t.scrollTop = (n == null ? void 0 : n.offsetTop) - Xi);
3121
+ }, Ji = $e((t, e) => {
3107
3122
  const { show: n } = t, { focusedPage: o, totalPages: r } = ie(), { thumbnailPages: a, addPage: l, thumbnailLength: c, addToPage: u } = Pn(), d = H(null), m = H(1);
3108
3123
  cn(e, () => d.current);
3109
- const v = k(() => Object.values(a), [a]), p = N(() => {
3110
- const w = c + 1;
3111
- w <= r && l(w);
3124
+ const w = k(() => Object.values(a), [a]), p = N(() => {
3125
+ const _ = c + 1;
3126
+ _ <= r && l(_);
3112
3127
  }, [l, r, c]);
3113
3128
  return F(() => {
3114
- o > c ? u(o) : n && m.current !== o && (Xi(d.current, o), m.current = o);
3115
- }, [o, c, u, n, v]), gr(d.current, p), /* @__PURE__ */ i("div", { ref: d, className: sn["rp-thumbnails-container"], children: /* @__PURE__ */ i("div", { className: sn["rp-thumbnails"], children: n ? v.map((w, P) => {
3116
- var S, _;
3129
+ o > c ? u(o) : n && m.current !== o && (Yi(d.current, o), m.current = o);
3130
+ }, [o, c, u, n, w]), gr(d.current, p), /* @__PURE__ */ i("div", { ref: d, className: sn["rp-thumbnails-container"], children: /* @__PURE__ */ i("div", { className: sn["rp-thumbnails"], children: n ? w.map((_, b) => {
3131
+ var S, C;
3117
3132
  return /* @__PURE__ */ i(
3118
- ji,
3133
+ Ki,
3119
3134
  {
3120
- isFocused: o === ((S = w.page) == null ? void 0 : S.pageNumber),
3121
- pageNumber: (_ = w.page) == null ? void 0 : _.pageNumber,
3122
- thumbnailSrc: w.thumbnailSrc,
3123
- loading: w.loading,
3124
- viewport: w.viewport,
3125
- defaultRotation: w.defaultRotation
3135
+ isFocused: o === ((S = _.page) == null ? void 0 : S.pageNumber),
3136
+ pageNumber: (C = _.page) == null ? void 0 : C.pageNumber,
3137
+ thumbnailSrc: _.thumbnailSrc,
3138
+ loading: _.loading,
3139
+ viewport: _.viewport,
3140
+ defaultRotation: _.defaultRotation
3126
3141
  },
3127
- P
3142
+ b
3128
3143
  );
3129
3144
  }) : null }) });
3130
- }), Ji = () => {
3145
+ }), Qi = () => {
3131
3146
  const { thumbnailIcon: t } = ue();
3132
3147
  return t || /* @__PURE__ */ i(mr, {});
3133
- }, Qi = () => {
3148
+ }, ea = () => {
3134
3149
  const { active: t, setActive: e } = Pn(), [n, o] = $(200), r = H(null), { thumbnailTool: a, sidebarEnable: l } = ge(), { localeMessages: c } = ae(), u = N(() => {
3135
3150
  e((m) => !m);
3136
3151
  }, []), d = k(() => typeof a != "boolean" && a ? /* @__PURE__ */ i(a, { onClick: u, active: t }) : a ? /* @__PURE__ */ i(K, { content: c == null ? void 0 : c.thumbnailTooltip, children: /* @__PURE__ */ i(
@@ -3139,7 +3154,7 @@ const Ie = {
3139
3154
  onClick: u,
3140
3155
  active: t,
3141
3156
  "aria-label": c == null ? void 0 : c.thumbnailTooltip,
3142
- children: /* @__PURE__ */ i(Ji, {})
3157
+ children: /* @__PURE__ */ i(Qi, {})
3143
3158
  }
3144
3159
  ) }) : null, [a, t, u, c]);
3145
3160
  return /* @__PURE__ */ i(fe, { children: l && /* @__PURE__ */ W(
@@ -3157,7 +3172,7 @@ const Ie = {
3157
3172
  hidden: !t,
3158
3173
  className: vt["rp-thumbnails-wrapper"],
3159
3174
  children: [
3160
- /* @__PURE__ */ i(Yi, { show: t, ref: r }),
3175
+ /* @__PURE__ */ i(Ji, { show: t, ref: r }),
3161
3176
  /* @__PURE__ */ i(vr, { onWidthChange: o, thumbnailRef: r })
3162
3177
  ]
3163
3178
  }
@@ -3165,7 +3180,7 @@ const Ie = {
3165
3180
  ]
3166
3181
  }
3167
3182
  ) });
3168
- }, Xs = $e((t, e) => {
3183
+ }, Ys = $e((t, e) => {
3169
3184
  const {
3170
3185
  children: n,
3171
3186
  slots: o,
@@ -3176,16 +3191,16 @@ const Ie = {
3176
3191
  onLoaded: u,
3177
3192
  cleanupOnLoaded: d,
3178
3193
  onLayoutWidthChange: m
3179
- } = t, [v, p] = $(null), { setContainer: w, setContentRef: P } = me(), { loading: S } = ee(), { LoaderImageComponent: _ } = hn();
3194
+ } = t, [w, p] = $(null), { setContainer: _, setContentRef: b } = me(), { loading: S } = ee(), { LoaderImageComponent: C } = hn();
3180
3195
  return F(() => (u && u(), () => {
3181
3196
  d && d();
3182
- }), [u, d]), /* @__PURE__ */ i(In, { toolbarRef: v, ref: e, children: /* @__PURE__ */ i(Tr, { mobileWidth: c, onLayoutWidthChange: m, children: /* @__PURE__ */ i(wr, { slots: o, children: /* @__PURE__ */ i(_r, { icons: r, children: /* @__PURE__ */ W(br, { getContainerRef: w, style: a, className: l, children: [
3197
+ }), [u, d]), /* @__PURE__ */ i(xn, { toolbarRef: w, ref: e, children: /* @__PURE__ */ i(Tr, { mobileWidth: c, onLayoutWidthChange: m, children: /* @__PURE__ */ i(wr, { slots: o, children: /* @__PURE__ */ i(_r, { icons: r, children: /* @__PURE__ */ W(br, { getContainerRef: _, style: a, className: l, children: [
3183
3198
  /* @__PURE__ */ W(Cr, { children: [
3184
3199
  /* @__PURE__ */ W("div", { className: be["rp-layout"], children: [
3185
- /* @__PURE__ */ i(Zi, { ref: p }),
3200
+ /* @__PURE__ */ i(ji, { ref: p }),
3186
3201
  /* @__PURE__ */ W("div", { className: be["rp-content"], children: [
3187
- /* @__PURE__ */ i("div", { className: be["rp-sidebar"], children: /* @__PURE__ */ i(Qi, {}) }),
3188
- /* @__PURE__ */ i("div", { ref: P, className: be["rp-pages"], children: n })
3202
+ /* @__PURE__ */ i("div", { className: be["rp-sidebar"], children: /* @__PURE__ */ i(ea, {}) }),
3203
+ /* @__PURE__ */ i("div", { ref: b, className: be["rp-pages"], children: n })
3189
3204
  ] })
3190
3205
  ] }),
3191
3206
  /* @__PURE__ */ i(Pr, {})
@@ -3213,7 +3228,7 @@ const Ie = {
3213
3228
  height: "100%",
3214
3229
  width: "100%"
3215
3230
  },
3216
- children: _ && /* @__PURE__ */ i(_, {})
3231
+ children: C && /* @__PURE__ */ i(C, {})
3217
3232
  }
3218
3233
  )
3219
3234
  }
@@ -3225,32 +3240,32 @@ export {
3225
3240
  on as B,
3226
3241
  Lo as C,
3227
3242
  ti as D,
3228
- Vi as E,
3243
+ qi as E,
3229
3244
  qn as F,
3230
- Bi as G,
3231
- Zi as H,
3232
- ji as I,
3233
- Yi as J,
3234
- Qi as K,
3235
- In as L,
3245
+ Zi as G,
3246
+ ji as H,
3247
+ Ki as I,
3248
+ Ji as J,
3249
+ ea as K,
3250
+ xn as L,
3236
3251
  Fi as M,
3237
3252
  Wi as O,
3238
- Us as P,
3239
- Zs as R,
3240
- Bs as S,
3241
- qs as T,
3242
- Ui as Z,
3243
- Xs as a,
3253
+ Vs as P,
3254
+ js as R,
3255
+ Zs as S,
3256
+ Bs as T,
3257
+ Vi as Z,
3258
+ Ys as a,
3244
3259
  Gn as b,
3245
3260
  tt as c,
3246
- It as d,
3247
- Vs as e,
3261
+ xt as d,
3262
+ qs as e,
3248
3263
  wn as f,
3249
3264
  yo as g,
3250
3265
  _n as h,
3251
- xo as i,
3266
+ Io as i,
3252
3267
  bn as j,
3253
- Io as k,
3268
+ xo as k,
3254
3269
  Cn as l,
3255
3270
  Pn as m,
3256
3271
  Ro as n,