eddyter 1.4.11 → 1.4.12
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/LazyCodeMirror-CcceEUqu.js +45365 -0
- package/dist/LazySignatureCanvas-Cck44R9l.js +528 -0
- package/dist/assets/style.css +1 -1
- package/dist/components/AlignMenu/AlignMenu.d.ts +3 -1
- package/dist/components/LazyCodeMirror/LazyCodeMirror.d.ts +10 -0
- package/dist/components/LineHeightPicker/LineHeightControl.d.ts +1 -0
- package/dist/{generateDocxThumbnail-sE1G5G6C.js → generateDocxThumbnail-DGj_L73_.js} +1 -1
- package/dist/{generatePdfThumbnail-BcT_cjxm.js → generatePdfThumbnail-D1ui86rp.js} +13 -13
- package/dist/{generateXlsxThumbnail-nCbKlvf2.js → generateXlsxThumbnail-CbJOr-_6.js} +1 -1
- package/dist/{html2pdf.bundle.min-D4m3s3b2.js → html2pdf.bundle.min-CN_w9Sxu.js} +1 -1
- package/dist/{index-Ct4lYZ_n.js → index-CuwrKBfY.js} +1 -1
- package/dist/index-Dh0oRk6u.js +47653 -0
- package/dist/{index-DwmEaul2.js → index-DiSjJC3k.js} +4 -4
- package/dist/{index-DpFqIrjJ.js → index-hrDzgkRb.js} +7 -7
- package/dist/index.js +1 -1
- package/dist/objectWithoutPropertiesLoose-DO0w4vQT.js +26 -0
- package/dist/plugins/SignatureCanvasPlugin/LazySignatureCanvas.d.ts +6 -0
- package/package.json +1 -1
- package/dist/index-CkMNlf2-.js +0 -93399
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ReactCodeMirrorProps } from '@uiw/react-codemirror';
|
|
2
|
+
export interface LazyCodeMirrorProps extends Omit<ReactCodeMirrorProps, "theme" | "extensions"> {
|
|
3
|
+
/** Apply One Dark theme when true */
|
|
4
|
+
isDarkMode?: boolean;
|
|
5
|
+
/** Additional CodeMirror extensions appended to the language extension */
|
|
6
|
+
extraExtensions?: ReactCodeMirrorProps["extensions"];
|
|
7
|
+
/** Language preset — defaults to HTML */
|
|
8
|
+
language?: "html" | "css" | "js" | "json";
|
|
9
|
+
}
|
|
10
|
+
export default function LazyCodeMirror({ isDarkMode, extraExtensions, language, ...rest }: LazyCodeMirrorProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { H as Tt, g as Se, K as Ce, m as xe } from "./index-Dh0oRk6u.js";
|
|
2
2
|
import { h as Ee } from "./html2canvas.esm-C2wu93Kq.js";
|
|
3
3
|
function Ft(c) {
|
|
4
4
|
throw new Error('Could not dynamically require "' + c + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { K as u,
|
|
2
|
-
const
|
|
1
|
+
import { K as u, m as b } from "./index-Dh0oRk6u.js";
|
|
2
|
+
const g = "https://cdnjs.cloudflare.com/ajax/libs/pdf.js/3.11.174";
|
|
3
3
|
let w = null;
|
|
4
4
|
async function C() {
|
|
5
5
|
if (w)
|
|
@@ -10,12 +10,12 @@ async function C() {
|
|
|
10
10
|
return;
|
|
11
11
|
}
|
|
12
12
|
const a = document.createElement("script");
|
|
13
|
-
a.src = `${
|
|
13
|
+
a.src = `${g}/pdf.min.js`, a.onload = () => n(), a.onerror = () => o(new Error("Failed to load pdf.js from CDN")), document.head.appendChild(a);
|
|
14
14
|
});
|
|
15
15
|
const t = window.pdfjsLib;
|
|
16
16
|
if (!t)
|
|
17
17
|
throw new Error("pdfjsLib not found on window after loading CDN script");
|
|
18
|
-
return t.GlobalWorkerOptions.workerSrc = `${
|
|
18
|
+
return t.GlobalWorkerOptions.workerSrc = `${g}/pdf.worker.min.js`, w = t, t;
|
|
19
19
|
}
|
|
20
20
|
async function j(t) {
|
|
21
21
|
if (t.startsWith("data:application/pdf;base64,") || t.startsWith("data:application/pdf,")) {
|
|
@@ -30,35 +30,35 @@ async function j(t) {
|
|
|
30
30
|
const a = await o.arrayBuffer();
|
|
31
31
|
return new Uint8Array(a);
|
|
32
32
|
}
|
|
33
|
-
const p = 240,
|
|
33
|
+
const p = 240, h = 176;
|
|
34
34
|
async function D(t) {
|
|
35
35
|
try {
|
|
36
36
|
const n = await C(), o = await j(t), r = await (await n.getDocument({ data: o }).promise).getPage(1), i = r.getViewport({ scale: 1 }), c = p / i.width, e = r.getViewport({ scale: c }), s = document.createElement("canvas");
|
|
37
37
|
s.width = e.width, s.height = e.height;
|
|
38
|
-
const
|
|
39
|
-
if (!
|
|
38
|
+
const l = s.getContext("2d");
|
|
39
|
+
if (!l)
|
|
40
40
|
throw new Error("Could not get 2d context");
|
|
41
41
|
await r.render({
|
|
42
|
-
canvasContext:
|
|
42
|
+
canvasContext: l,
|
|
43
43
|
viewport: e
|
|
44
44
|
}).promise;
|
|
45
45
|
const d = document.createElement("canvas");
|
|
46
|
-
d.width = p, d.height =
|
|
46
|
+
d.width = p, d.height = h;
|
|
47
47
|
const f = d.getContext("2d");
|
|
48
48
|
if (!f)
|
|
49
49
|
return s.toDataURL("image/png");
|
|
50
|
-
f.fillStyle = "#ffffff", f.fillRect(0, 0, p,
|
|
51
|
-
const
|
|
50
|
+
f.fillStyle = "#ffffff", f.fillRect(0, 0, p, h);
|
|
51
|
+
const m = Math.min(e.height, h);
|
|
52
52
|
return f.drawImage(
|
|
53
53
|
s,
|
|
54
54
|
0,
|
|
55
55
|
0,
|
|
56
56
|
e.width,
|
|
57
|
-
|
|
57
|
+
m,
|
|
58
58
|
0,
|
|
59
59
|
0,
|
|
60
60
|
p,
|
|
61
|
-
|
|
61
|
+
m
|
|
62
62
|
), d.toDataURL("image/png");
|
|
63
63
|
} catch (n) {
|
|
64
64
|
throw console.error("[generatePdfThumbnail] Error", n), n;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h as Ci } from "./html2canvas.esm-C2wu93Kq.js";
|
|
2
|
-
import { K as yi,
|
|
2
|
+
import { K as yi, m as Di } from "./index-Dh0oRk6u.js";
|
|
3
3
|
var In = 1252, Oi = [874, 932, 936, 949, 950, 1250, 1251, 1252, 1253, 1254, 1255, 1256, 1257, 1258, 1e4], Zt = {
|
|
4
4
|
/*::[*/
|
|
5
5
|
0: 1252,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as o, jsxs as b, Fragment as Jt } from "react/jsx-runtime";
|
|
2
2
|
import { I as De } from "./ImageResizer-BVwxL4Eh.js";
|
|
3
|
-
import { c as Et, d as ne, e as se, f as de,
|
|
3
|
+
import { c as Et, d as ne, e as se, f as de, h as ce, i as le, j as ue, B as Qt, C as zt, I as Le, S as Te, u as $e, k as Z, t as M, l as We, m as Ye, L as je, W as Oe, n as _e, A as He, o as Fe, p as Xe, q as Be, r as Ue, s as Ge, E as Ke, v as qe, X as Ve, M as Je, w as Qe, x as Ze, y as tr, z as er, G as rr } from "./index-Dh0oRk6u.js";
|
|
4
4
|
import { LinkNode as or } from "@lexical/link";
|
|
5
5
|
import { AutoFocusPlugin as ir } from "@lexical/react/LexicalAutoFocusPlugin";
|
|
6
6
|
import { useCollaborationContext as ar } from "@lexical/react/LexicalCollaborationContext";
|