@factorialco/f0-react 4.52.0 → 4.53.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ChatDocxThumbnail-ZpA0oGfg.js → ChatDocxThumbnail-DzNPNFya.js} +1 -1
- package/dist/{ChatPdfThumbnail-Inmuy7U7.js → ChatPdfThumbnail-Ee5Wx96X.js} +1 -1
- package/dist/{DocumentToolbar-BYKMRth5.js → DocumentToolbar-BwJIFXDT.js} +2 -2
- package/dist/{DocxViewer-DTyN6WkM.js → DocxViewer-C8UBtCTB.js} +3 -3
- package/dist/{F0AiProcessingOverlay-DEjwsdqP.js → F0AiProcessingOverlay-BR8LMWyo.js} +1 -1
- package/dist/{F0CanvasPanel-DkQ4xhBx.js → F0CanvasPanel-DGLx1cqO.js} +545 -575
- package/dist/{LocationMap-BiiecVq_.js → LocationMap-BeSyUnec.js} +1 -1
- package/dist/{SheetViewer-BettRk5l.js → SheetViewer-DUvAHeaC.js} +2 -2
- package/dist/{TextViewer-DkXDyzcR.js → TextViewer-60i44dbD.js} +2 -2
- package/dist/_commonjsHelpers-ByX85dGu.js +33 -0
- package/dist/ai.d.ts +10 -10
- package/dist/ai.js +2 -2
- package/dist/axe-mZXA-kzX.js +23823 -0
- package/dist/component-status.d.ts +24 -10
- package/dist/component-status.js +305 -100
- package/dist/{docx-preview-bIzfytWN.js → docx-preview-BaRDMyPN.js} +1 -1
- package/dist/experimental.d.ts +10 -10
- package/dist/experimental.js +7 -7
- package/dist/f0.d.ts +10 -10
- package/dist/f0.js +571 -570
- package/dist/i18n-provider-defaults.d.ts +10 -10
- package/dist/{index-C4zDor6d.js → index-DsuHJt_y.js} +135 -134
- package/dist/{index-Ck1QOo1R.js → index-EDXekGcx.js} +29 -29
- package/dist/{pdfWorker-BecOMPtI.js → pdfWorker-D0j0TkJF.js} +3 -2
- package/dist/styles.css +1 -1
- package/package.json +2 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { S as L,
|
|
1
|
+
import { S as L, m as ye, u as Z, n as ne, o as Se, q as Re, i as ke, j as _e, k as Ne, r as Ce, l as Le, w as Fe, s as Ve, t as Te } from "./F0CanvasPanel-DGLx1cqO.js";
|
|
2
2
|
import { jsx as t, jsxs as y } from "react/jsx-runtime";
|
|
3
3
|
import { lazy as J, forwardRef as ae, Suspense as He, useState as V, useRef as A, useMemo as te, useCallback as w, useEffect as T } from "react";
|
|
4
|
-
import { e as Ee, D as Ue, P as je, c as De } from "./pdfWorker-
|
|
4
|
+
import { e as Ee, D as Ue, P as je, c as De } from "./pdfWorker-D0j0TkJF.js";
|
|
5
5
|
import { F as We } from "./Printer-B7iDPx2r.js";
|
|
6
6
|
import './index.css';const Oe = ({
|
|
7
7
|
label: o,
|
|
@@ -46,8 +46,8 @@ import './index.css';const Oe = ({
|
|
|
46
46
|
selectedScale: l,
|
|
47
47
|
scaleOptions: s,
|
|
48
48
|
onPreviousPage: d,
|
|
49
|
-
onNextPage:
|
|
50
|
-
onZoomIn:
|
|
49
|
+
onNextPage: g,
|
|
50
|
+
onZoomIn: m,
|
|
51
51
|
onZoomOut: v,
|
|
52
52
|
onScaleChange: k,
|
|
53
53
|
rotatable: P,
|
|
@@ -94,7 +94,7 @@ import './index.css';const Oe = ({
|
|
|
94
94
|
R,
|
|
95
95
|
{
|
|
96
96
|
label: c.nextPage,
|
|
97
|
-
onClick:
|
|
97
|
+
onClick: g,
|
|
98
98
|
icon: Re,
|
|
99
99
|
size: "sm"
|
|
100
100
|
}
|
|
@@ -113,7 +113,7 @@ import './index.css';const Oe = ({
|
|
|
113
113
|
R,
|
|
114
114
|
{
|
|
115
115
|
label: c.zoomIn,
|
|
116
|
-
onClick:
|
|
116
|
+
onClick: m,
|
|
117
117
|
icon: _e
|
|
118
118
|
}
|
|
119
119
|
),
|
|
@@ -208,28 +208,28 @@ import './index.css';const Oe = ({
|
|
|
208
208
|
let i = null, l = 0;
|
|
209
209
|
return a.forEach((s, d) => {
|
|
210
210
|
if (!s) return;
|
|
211
|
-
const
|
|
212
|
-
if (!(P < v && p >
|
|
211
|
+
const g = s.offsetHeight, m = s.offsetTop, v = m + g, k = o.offsetHeight - e, P = o.scrollTop + e, p = P + k;
|
|
212
|
+
if (!(P < v && p > m)) return;
|
|
213
213
|
let x;
|
|
214
|
-
if (P <=
|
|
215
|
-
x = p > v ?
|
|
214
|
+
if (P <= m)
|
|
215
|
+
x = p > v ? g : p - m;
|
|
216
216
|
else {
|
|
217
|
-
let h = P -
|
|
218
|
-
p < v && (h += v - p), x =
|
|
217
|
+
let h = P - m;
|
|
218
|
+
p < v && (h += v - p), x = g - h;
|
|
219
219
|
}
|
|
220
220
|
x > l && (l = x, i = d + 1);
|
|
221
221
|
}), i;
|
|
222
222
|
};
|
|
223
223
|
Ee();
|
|
224
|
-
const qe = J(() => import("./SheetViewer-
|
|
224
|
+
const qe = J(() => import("./SheetViewer-DUvAHeaC.js")), Ge = J(() => import("./DocxViewer-C8UBtCTB.js")), Ze = J(() => import("./TextViewer-60i44dbD.js")), oe = 48, se = ae(
|
|
225
225
|
(o, a) => {
|
|
226
226
|
const { kind: e = "pdf", mimeType: i, ...l } = o;
|
|
227
227
|
if (e === "pdf") return /* @__PURE__ */ t(le, { ref: a, ...l });
|
|
228
228
|
const {
|
|
229
229
|
url: s,
|
|
230
230
|
filename: d,
|
|
231
|
-
actions:
|
|
232
|
-
withCredentials:
|
|
231
|
+
actions: g,
|
|
232
|
+
withCredentials: m = !0,
|
|
233
233
|
page: v,
|
|
234
234
|
pagesToDisplay: k,
|
|
235
235
|
initialScale: P,
|
|
@@ -256,8 +256,8 @@ const qe = J(() => import("./SheetViewer-BettRk5l.js")), Ge = J(() => import("./
|
|
|
256
256
|
{
|
|
257
257
|
url: s,
|
|
258
258
|
filename: d,
|
|
259
|
-
withCredentials:
|
|
260
|
-
actions:
|
|
259
|
+
withCredentials: m,
|
|
260
|
+
actions: g
|
|
261
261
|
}
|
|
262
262
|
),
|
|
263
263
|
e === "docx" && /* @__PURE__ */ t(
|
|
@@ -265,8 +265,8 @@ const qe = J(() => import("./SheetViewer-BettRk5l.js")), Ge = J(() => import("./
|
|
|
265
265
|
{
|
|
266
266
|
url: s,
|
|
267
267
|
filename: d,
|
|
268
|
-
withCredentials:
|
|
269
|
-
actions:
|
|
268
|
+
withCredentials: m,
|
|
269
|
+
actions: g
|
|
270
270
|
}
|
|
271
271
|
),
|
|
272
272
|
e === "text" && /* @__PURE__ */ t(
|
|
@@ -275,8 +275,8 @@ const qe = J(() => import("./SheetViewer-BettRk5l.js")), Ge = J(() => import("./
|
|
|
275
275
|
url: s,
|
|
276
276
|
name: d ?? "",
|
|
277
277
|
mimeType: i,
|
|
278
|
-
withCredentials:
|
|
279
|
-
actions:
|
|
278
|
+
withCredentials: m,
|
|
279
|
+
actions: g
|
|
280
280
|
}
|
|
281
281
|
)
|
|
282
282
|
]
|
|
@@ -294,8 +294,8 @@ const le = ae((o, a) => {
|
|
|
294
294
|
page: l = 0,
|
|
295
295
|
pagesToDisplay: s = [],
|
|
296
296
|
initialScale: d = "page-width",
|
|
297
|
-
withCredentials:
|
|
298
|
-
rotatable:
|
|
297
|
+
withCredentials: g = !0,
|
|
298
|
+
rotatable: m = !1,
|
|
299
299
|
initialRotation: v = 0,
|
|
300
300
|
onRotationChange: k,
|
|
301
301
|
onPdfLoaded: P,
|
|
@@ -312,7 +312,7 @@ const le = ae((o, a) => {
|
|
|
312
312
|
}))
|
|
313
313
|
],
|
|
314
314
|
[h.pageWidth, h.pageFit]
|
|
315
|
-
), fe = te(() => ({ url: e, withCredentials:
|
|
315
|
+
), fe = te(() => ({ url: e, withCredentials: g }), [e, g]), F = w(
|
|
316
316
|
(n) => {
|
|
317
317
|
const r = (W ?? 1) - 1, f = Math.min(Math.max(n, 0), r), u = D.current[f], C = u?.offsetParent;
|
|
318
318
|
u && C instanceof HTMLElement && (C.scrollTop = u.offsetTop - (j.current?.offsetHeight ?? 0) - 10);
|
|
@@ -340,10 +340,10 @@ const le = ae((o, a) => {
|
|
|
340
340
|
z(n);
|
|
341
341
|
const r = G.find((f) => Number(f) === n);
|
|
342
342
|
r && M(r);
|
|
343
|
-
}, []),
|
|
343
|
+
}, []), me = w(
|
|
344
344
|
() => $(Me(N)),
|
|
345
345
|
[N, $]
|
|
346
|
-
),
|
|
346
|
+
), ge = w(
|
|
347
347
|
() => $(Ie(N)),
|
|
348
348
|
[N, $]
|
|
349
349
|
), pe = w(() => {
|
|
@@ -414,10 +414,10 @@ const le = ae((o, a) => {
|
|
|
414
414
|
scaleOptions: de,
|
|
415
415
|
onPreviousPage: () => F(S - 2),
|
|
416
416
|
onNextPage: () => F(S),
|
|
417
|
-
onZoomIn:
|
|
418
|
-
onZoomOut:
|
|
417
|
+
onZoomIn: me,
|
|
418
|
+
onZoomOut: ge,
|
|
419
419
|
onScaleChange: ue,
|
|
420
|
-
rotatable:
|
|
420
|
+
rotatable: m,
|
|
421
421
|
onRotate: pe,
|
|
422
422
|
onPrint: we,
|
|
423
423
|
onDownload: Pe,
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { createContext, useReducer, forwardRef, useRef, useImperativeHandle, useEffect, useCallback, useMemo, useContext, useLayoutEffect } from "react";
|
|
3
|
-
import {
|
|
4
|
-
import { d as dequal } from "./index-
|
|
3
|
+
import { v as invariant, x as clsx } from "./F0CanvasPanel-DGLx1cqO.js";
|
|
4
|
+
import { d as dequal } from "./index-DsuHJt_y.js";
|
|
5
|
+
import { a as getAugmentedNamespace, g as getDefaultExportFromCjs } from "./_commonjsHelpers-ByX85dGu.js";
|
|
5
6
|
import { c as commonjsRequire } from "./_commonjs-dynamic-modules-BpilXLfW.js";
|
|
6
7
|
import './pdfWorker.css';var pdf$1 = { exports: {} };
|
|
7
8
|
const __viteBrowserExternal = {}, __viteBrowserExternal$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|