eddyter 1.3.76 → 1.3.77

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/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { G as a, H as r, I as t, J as s, K as o, M as d, N as v, O as u, P as f, Q as n, R as l, U as w } from "./index-DjD3NbU0.js";
1
+ import { J as a, K as r, M as t, N as s, O as o, P as d, Q as v, R as u, U as f, V as n, X as l, Y as w } from "./index-Dh3DFyBT.js";
2
2
  export {
3
3
  a as ConfigurableEditor,
4
4
  r as ConfigurableEditorWithAuth,
@@ -1,4 +1,4 @@
1
- import { DecoratorNode, DOMExportOutput, NodeKey } from '../../node_modules/lexical';
1
+ import { DecoratorNode, DOMConversionMap, DOMExportOutput, NodeKey } from '../../node_modules/lexical';
2
2
  /**
3
3
  * A custom Lexical node that embeds and renders various types of content
4
4
  * such as videos, PDFs, documents, and other media files.
@@ -21,6 +21,7 @@ export declare class EmbedNode extends DecoratorNode<JSX.Element> {
21
21
  updateDOM(): boolean;
22
22
  static importJSON(serializedNode: any): EmbedNode;
23
23
  exportJSON(): any;
24
+ static importDOM(): DOMConversionMap | null;
24
25
  exportDOM(): DOMExportOutput;
25
26
  getURL(): string;
26
27
  getDisplayType(): DisplayType;
package/dist/types.d.ts CHANGED
@@ -45,6 +45,7 @@ export interface ToolbarProps {
45
45
  enableCharts?: boolean;
46
46
  enableAutoCorrection?: boolean;
47
47
  enablePdfExport?: boolean;
48
+ enableDocExport?: boolean;
48
49
  enableSpeechToText?: boolean;
49
50
  enableComments?: boolean;
50
51
  enableMentions?: boolean;
@@ -147,6 +148,7 @@ export interface EditorConfigTypes {
147
148
  enableCharts: boolean;
148
149
  enableAutoCorrection: boolean;
149
150
  enablePdfExport: boolean;
151
+ enableDocExport: boolean;
150
152
  enableSpeechToText: boolean;
151
153
  enableComments: boolean;
152
154
  enableMentions: boolean;
@@ -0,0 +1,28 @@
1
+ export type CropData = {
2
+ x: number;
3
+ y: number;
4
+ width: number;
5
+ height: number;
6
+ naturalWidth: number;
7
+ naturalHeight: number;
8
+ };
9
+ /**
10
+ * Returns true if the given src is served from our CloudFront CDN.
11
+ * Includes both direct CDN URLs and /transform-image/... crop URLs.
12
+ */
13
+ export declare function isCdnUrl(src: string): boolean;
14
+ /**
15
+ * Builds the crop URL using CDN: https://<cdn>/transform-image/<s3-key>?crop=x,y,w,h
16
+ */
17
+ export declare function buildCropUrl(src: string, crop: CropData): string;
18
+ /**
19
+ * Strips the `crop` query param. Used when re-opening the crop dialog (full image).
20
+ */
21
+ export declare function stripCropParams(src: string): string;
22
+ /**
23
+ * Returns the URL for the original (full, uncropped) image. Use this for the crop
24
+ * dialog preview so the user always sees the full image to draw a new crop.
25
+ * For CDN images this is the direct object URL (e.g. https://cdn.../key), not
26
+ * /transform-image/..., so the preview loads reliably.
27
+ */
28
+ export declare function getOriginalImageUrl(src: string): string;
@@ -1,2 +1,7 @@
1
1
  import { LexicalEditor } from '../../node_modules/lexical';
2
2
  export declare function exportEditorToPDF(editor: LexicalEditor, filename?: string, apiKey?: string): Promise<void>;
3
+ /**
4
+ * Export editor content as a Word document (.docx).
5
+ * Uses the same HTML as the editor (with inline styles). Requires complete HTML document for html-docx-js.
6
+ */
7
+ export declare function exportEditorToDoc(editor: LexicalEditor, filename?: string, _apiKey?: string): Promise<void>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "eddyter",
3
3
  "private": false,
4
- "version": "1.3.76",
4
+ "version": "1.3.77",
5
5
  "type": "module",
6
6
  "packageManager": "pnpm@9.0.0",
7
7
  "keywords": [
@@ -88,16 +88,16 @@
88
88
  "class-variance-authority": "^0.7.1",
89
89
  "clsx": "^2.1.1",
90
90
  "docx-preview": "^0.3.0",
91
- "html2canvas": "^1.4.1",
92
91
  "emoji-picker-react": "^4.12.0",
92
+ "html-docx-js": "^0.3.1",
93
+ "html2canvas": "^1.4.1",
93
94
  "html2pdf.js": "^0.14.0",
94
95
  "lexical": "^0.24.0",
95
96
  "lexical-ai-plugin": "0.0.2-alpha",
96
97
  "lodash-es": "^4.17.21",
97
- "pdfjs-dist": "^3.11.174",
98
- "xlsx": "^0.18.5",
99
98
  "lucide-react": "^0.344.0",
100
99
  "marked": "^17.0.1",
100
+ "pdfjs-dist": "^3.11.174",
101
101
  "prettier": "^3.5.1",
102
102
  "react-colorful": "^5.6.1",
103
103
  "react-router-dom": "^7.2.0",
@@ -105,7 +105,8 @@
105
105
  "sass": "^1.57.1",
106
106
  "tailwind-merge": "^3.0.2",
107
107
  "tailwindcss": "3",
108
- "tailwindcss-animate": "^1.0.7"
108
+ "tailwindcss-animate": "^1.0.7",
109
+ "xlsx": "^0.18.5"
109
110
  },
110
111
  "license": "SEE LICENSE IN LICENSE",
111
112
  "devDependencies": {