eddyter 1.3.76 → 1.3.78
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/Provider/EditorProvider.d.ts +12 -0
- package/dist/api/auth.d.ts +10 -0
- package/dist/api/bugReport.d.ts +2 -0
- package/dist/assets/style.css +1 -1
- package/dist/components/ImageView/ImageCropDialog.d.ts +18 -0
- package/dist/components/LockedFeature/LockedFeature.d.ts +4 -0
- package/dist/config/env.d.ts +1 -0
- package/dist/editorConfig.d.ts +1 -0
- package/dist/{generateDocxThumbnail-BbSs-3CJ.js → generateDocxThumbnail-DI95OEXG.js} +1 -1
- package/dist/{generatePdfThumbnail-U8R2yu3J.js → generatePdfThumbnail-B7hHlIu1.js} +3 -3
- package/dist/{generateXlsxThumbnail-BUwuqsXR.js → generateXlsxThumbnail-L2Rxm_uB.js} +1 -1
- package/dist/{html2pdf.bundle.min-Css6bHHm.js → html2pdf.bundle.min-D1aH-6LZ.js} +1 -1
- package/dist/{index-CCVZobcV.js → index-BBPa4rFJ.js} +15 -15
- package/dist/{index-DjD3NbU0.js → index-BDzAe_Dw.js} +12581 -12238
- package/dist/index-Bl_jnnhX.js +1498 -0
- package/dist/{index-CVEa0GRe.js → index-Bzbg5ykO.js} +29 -29
- package/dist/index.js +1 -1
- package/dist/nodes/EmbedNode.d.ts +2 -1
- package/dist/types.d.ts +2 -0
- package/dist/utils/cropUrl.d.ts +28 -0
- package/dist/utils/export.d.ts +5 -0
- package/package.json +6 -5
- package/dist/index-DTkM3xiE.js +0 -848
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
type CropDialogProps = {
|
|
2
|
+
open: boolean;
|
|
3
|
+
onOpenChange: (open: boolean) => void;
|
|
4
|
+
src: string;
|
|
5
|
+
altText: string;
|
|
6
|
+
width: "inherit" | number;
|
|
7
|
+
height: "inherit" | number;
|
|
8
|
+
onCropApply: (crop: {
|
|
9
|
+
x: number;
|
|
10
|
+
y: number;
|
|
11
|
+
width: number;
|
|
12
|
+
height: number;
|
|
13
|
+
naturalWidth: number;
|
|
14
|
+
naturalHeight: number;
|
|
15
|
+
}) => void | Promise<void>;
|
|
16
|
+
};
|
|
17
|
+
export default function ImageCropDialog({ open, onOpenChange, src, altText, width, height, onCropApply, }: CropDialogProps): JSX.Element;
|
|
18
|
+
export {};
|
|
@@ -13,6 +13,10 @@ export interface LockedFeatureProps {
|
|
|
13
13
|
* planAllows: true if the user's plan includes this feature.
|
|
14
14
|
*/
|
|
15
15
|
planAllows?: boolean;
|
|
16
|
+
/**
|
|
17
|
+
* Optional custom tooltip when locked (e.g. BYOK "Add API keys in License > Manage API Keys").
|
|
18
|
+
*/
|
|
19
|
+
tooltipMessage?: string;
|
|
16
20
|
}
|
|
17
21
|
/**
|
|
18
22
|
* LockedFeature - A wrapper component that shows a lock/disabled overlay on disabled features
|
package/dist/config/env.d.ts
CHANGED
package/dist/editorConfig.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as Tt, g as Se,
|
|
1
|
+
import { c as Tt, g as Se, H as Ce, k as xe } from "./index-BDzAe_Dw.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
1
|
import * as g from "pdfjs-dist";
|
|
2
|
-
import {
|
|
2
|
+
import { H as l, k as m } from "./index-BDzAe_Dw.js";
|
|
3
3
|
g.GlobalWorkerOptions.workerSrc = "https://cdnjs.cloudflare.com/ajax/libs/pdf.js/3.11.174/pdf.worker.min.js";
|
|
4
4
|
async function u(a) {
|
|
5
5
|
if (a.startsWith("data:application/pdf;base64,") || a.startsWith("data:application/pdf,")) {
|
|
@@ -15,7 +15,7 @@ async function u(a) {
|
|
|
15
15
|
return new Uint8Array(n);
|
|
16
16
|
}
|
|
17
17
|
const d = 240, p = 176;
|
|
18
|
-
async function
|
|
18
|
+
async function y(a) {
|
|
19
19
|
try {
|
|
20
20
|
const o = await u(a), n = await (await g.getDocument({ data: o }).promise).getPage(1), f = n.getViewport({ scale: 1 }), r = d / f.width, e = n.getViewport({ scale: r }), t = document.createElement("canvas");
|
|
21
21
|
t.width = e.width, t.height = e.height;
|
|
@@ -49,5 +49,5 @@ async function b(a) {
|
|
|
49
49
|
}
|
|
50
50
|
}
|
|
51
51
|
export {
|
|
52
|
-
|
|
52
|
+
y as generatePdfThumbnail
|
|
53
53
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h as Ci } from "./html2canvas.esm-C2wu93Kq.js";
|
|
2
|
-
import {
|
|
2
|
+
import { H as yi, k as Di } from "./index-BDzAe_Dw.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,
|
|
@@ -13,14 +13,14 @@ import { RichTextPlugin as gt } from "@lexical/react/LexicalRichTextPlugin";
|
|
|
13
13
|
import { useLexicalEditable as mt } from "@lexical/react/useLexicalEditable";
|
|
14
14
|
import { useLexicalNodeSelection as ht } from "@lexical/react/useLexicalNodeSelection";
|
|
15
15
|
import { mergeRegister as pt } from "@lexical/utils";
|
|
16
|
-
import { $getSelection as L, $isNodeSelection as h, $setSelection as O, SELECTION_CHANGE_COMMAND as bt, COMMAND_PRIORITY_LOW as f, CLICK_COMMAND as Ct, DRAGSTART_COMMAND as xt, KEY_DELETE_COMMAND as Nt, KEY_BACKSPACE_COMMAND as vt, KEY_ENTER_COMMAND as Et, KEY_ESCAPE_COMMAND as Rt, RootNode as
|
|
17
|
-
import { useRef as P, useState as
|
|
18
|
-
import {
|
|
16
|
+
import { $getSelection as L, $isNodeSelection as h, $setSelection as O, SELECTION_CHANGE_COMMAND as bt, COMMAND_PRIORITY_LOW as f, CLICK_COMMAND as Ct, DRAGSTART_COMMAND as xt, KEY_DELETE_COMMAND as Nt, KEY_BACKSPACE_COMMAND as vt, KEY_ENTER_COMMAND as Et, KEY_ESCAPE_COMMAND as Rt, RootNode as yt, TextNode as At, LineBreakNode as kt, ParagraphNode as St, $getNodeByKey as A, $isParagraphNode as T } from "lexical";
|
|
17
|
+
import { useRef as P, useState as w, useCallback as N, useEffect as Dt } from "react";
|
|
18
|
+
import { G as v, W as Lt, l as Pt, A as Mt, m as _t, n as $t, T as zt, x as It, L as Wt, i as Ot } from "./index-BDzAe_Dw.js";
|
|
19
19
|
function ie({
|
|
20
|
-
src:
|
|
20
|
+
src: j,
|
|
21
21
|
nodeKey: g,
|
|
22
22
|
width: p,
|
|
23
|
-
height:
|
|
23
|
+
height: k,
|
|
24
24
|
maxWidth: B,
|
|
25
25
|
resizable: Y,
|
|
26
26
|
showCaption: E,
|
|
@@ -29,7 +29,7 @@ function ie({
|
|
|
29
29
|
controls: V = !0,
|
|
30
30
|
position: n = "none"
|
|
31
31
|
}) {
|
|
32
|
-
const a = P(null), S = P(null), [l, d, C] = ht(g), [s, M] =
|
|
32
|
+
const a = P(null), S = P(null), [l, d, C] = ht(g), [s, M] = w(!1), [o] = lt(), [R, H] = w(null), _ = P(null), K = mt(), D = N(
|
|
33
33
|
(t) => {
|
|
34
34
|
const r = L();
|
|
35
35
|
return l && h(r) && (t.preventDefault(), o.update(() => {
|
|
@@ -69,8 +69,8 @@ function ie({
|
|
|
69
69
|
const c = e === a.current;
|
|
70
70
|
let u = !1;
|
|
71
71
|
if (!c && a.current) {
|
|
72
|
-
const
|
|
73
|
-
u = r.clientX >=
|
|
72
|
+
const y = a.current.getBoundingClientRect();
|
|
73
|
+
u = r.clientX >= y.left && r.clientX <= y.right && r.clientY >= y.top && r.clientY <= y.bottom;
|
|
74
74
|
}
|
|
75
75
|
return c || u ? (r.shiftKey ? d(!l) : (C(), d(!0)), !0) : !1;
|
|
76
76
|
},
|
|
@@ -131,21 +131,21 @@ function ie({
|
|
|
131
131
|
]);
|
|
132
132
|
const X = () => {
|
|
133
133
|
o.update(() => {
|
|
134
|
-
const t =
|
|
134
|
+
const t = A(g);
|
|
135
135
|
v(t) && t.setShowCaption(!0);
|
|
136
136
|
});
|
|
137
137
|
}, G = (t, r) => {
|
|
138
138
|
setTimeout(() => {
|
|
139
139
|
M(!1);
|
|
140
140
|
}, 200), o.update(() => {
|
|
141
|
-
const e =
|
|
141
|
+
const e = A(g);
|
|
142
142
|
v(e) && e.setWidthAndHeight(t, r);
|
|
143
143
|
});
|
|
144
144
|
}, U = () => {
|
|
145
145
|
M(!0);
|
|
146
146
|
}, q = (t) => {
|
|
147
147
|
t.preventDefault(), t.stopPropagation(), o.update(() => {
|
|
148
|
-
const r =
|
|
148
|
+
const r = A(g);
|
|
149
149
|
if (v(r)) {
|
|
150
150
|
const e = r.getParent();
|
|
151
151
|
r.remove(), e && T(e) && e.getChildrenSize() === 0 && e.setFormat("left");
|
|
@@ -153,7 +153,7 @@ function ie({
|
|
|
153
153
|
});
|
|
154
154
|
}, m = (t, r) => {
|
|
155
155
|
t.preventDefault(), t.stopPropagation(), o.update(() => {
|
|
156
|
-
const e =
|
|
156
|
+
const e = A(g);
|
|
157
157
|
if (v(e)) {
|
|
158
158
|
e.setPosition(r);
|
|
159
159
|
const c = e.getParent();
|
|
@@ -173,7 +173,7 @@ function ie({
|
|
|
173
173
|
!e && !c || (t.stopPropagation(), t.shiftKey ? d(!l) : (C(), d(!0)));
|
|
174
174
|
},
|
|
175
175
|
[s, l, d, C]
|
|
176
|
-
), Q = l && h(R) && !s, W = (l || s) && K, Z = typeof p == "number" && typeof
|
|
176
|
+
), Q = l && h(R) && !s, W = (l || s) && K, Z = typeof p == "number" && typeof k == "number", tt = typeof p == "number" ? p : "auto", et = typeof k == "number" ? k : "auto";
|
|
177
177
|
return /* @__PURE__ */ x(rt, { children: [
|
|
178
178
|
/* @__PURE__ */ x(
|
|
179
179
|
"div",
|
|
@@ -213,7 +213,7 @@ function ie({
|
|
|
213
213
|
"video",
|
|
214
214
|
{
|
|
215
215
|
ref: a,
|
|
216
|
-
src:
|
|
216
|
+
src: j,
|
|
217
217
|
controls: V,
|
|
218
218
|
preload: "metadata",
|
|
219
219
|
className: W ? `focused ${h(R) ? "draggable" : ""}` : void 0,
|
|
@@ -337,9 +337,9 @@ function ie({
|
|
|
337
337
|
{
|
|
338
338
|
initialEditor: b,
|
|
339
339
|
initialNodes: [
|
|
340
|
-
kt,
|
|
341
340
|
yt,
|
|
342
341
|
At,
|
|
342
|
+
kt,
|
|
343
343
|
St,
|
|
344
344
|
nt,
|
|
345
345
|
ot
|