@veztraa/report-designer 0.3.4 → 0.4.1
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/README.md +1 -1
- package/dist/icons.d.ts +7 -0
- package/dist/index.js +5442 -5533
- package/dist/store/useReportStore.d.ts +17 -2
- package/dist/templates.d.ts +0 -19
- package/package.json +4 -3
|
@@ -1,10 +1,15 @@
|
|
|
1
1
|
import { Template, ReportElement, ContainerElement } from '@veztraa/report-core';
|
|
2
2
|
export type SidebarTab = "components" | "layers" | "data" | "document";
|
|
3
|
+
interface HistoryEntry {
|
|
4
|
+
template: Template;
|
|
5
|
+
selectedId: string | null;
|
|
6
|
+
}
|
|
3
7
|
interface ReportStore {
|
|
4
8
|
template: Template;
|
|
5
9
|
selectedId: string | null;
|
|
6
|
-
|
|
7
|
-
|
|
10
|
+
selectedIds: string[];
|
|
11
|
+
history: HistoryEntry[];
|
|
12
|
+
future: HistoryEntry[];
|
|
8
13
|
zoom: number;
|
|
9
14
|
activeSection: "header" | "body" | "footer";
|
|
10
15
|
sidebarTab: SidebarTab;
|
|
@@ -14,13 +19,23 @@ interface ReportStore {
|
|
|
14
19
|
fieldTypes: Record<string, string>;
|
|
15
20
|
theme: "dark" | "light";
|
|
16
21
|
selectElement: (id: string | null) => void;
|
|
22
|
+
toggleSelectElement: (id: string) => void;
|
|
23
|
+
setSelectedIds: (ids: string[]) => void;
|
|
17
24
|
toggleTheme: () => void;
|
|
18
25
|
setTheme: (theme: "dark" | "light") => void;
|
|
26
|
+
clipboard: ReportElement[];
|
|
27
|
+
copySelected: () => void;
|
|
28
|
+
pasteElements: () => void;
|
|
19
29
|
addElement: (el: ReportElement) => void;
|
|
20
30
|
addChildElement: (containerId: string, el: ReportElement) => void;
|
|
21
31
|
updateElement: (id: string, patch: Partial<ReportElement>) => void;
|
|
32
|
+
updateElementSilent: (id: string, patch: Partial<ReportElement>) => void;
|
|
33
|
+
updateElementDebounced: (id: string, patch: Partial<ReportElement>) => void;
|
|
34
|
+
pushSnapshot: () => void;
|
|
22
35
|
deleteSelected: () => void;
|
|
23
36
|
duplicateSelected: () => void;
|
|
37
|
+
bringForward: () => void;
|
|
38
|
+
sendBack: () => void;
|
|
24
39
|
reorderElement: (section: "header" | "body" | "footer", fromIdx: number, toIdx: number) => void;
|
|
25
40
|
undo: () => void;
|
|
26
41
|
redo: () => void;
|
package/dist/templates.d.ts
CHANGED
|
@@ -1,21 +1,2 @@
|
|
|
1
1
|
import { Template } from '@veztraa/report-core';
|
|
2
2
|
export declare const BLANK_TEMPLATE: Template;
|
|
3
|
-
export declare const BLANK_DATA = "{}";
|
|
4
|
-
export declare const INVOICE_TEMPLATE: Template;
|
|
5
|
-
export declare const INVOICE_DATA: string;
|
|
6
|
-
export declare const ALL_ELEMENTS_TEMPLATE: Template;
|
|
7
|
-
export declare const ALL_ELEMENTS_DATA: string;
|
|
8
|
-
export declare const TABLE_CLEAN_TEMPLATE: Template;
|
|
9
|
-
export declare const TABLE_CLEAN_DATA: string;
|
|
10
|
-
export declare const TABLE_STRIPED_TEMPLATE: Template;
|
|
11
|
-
export declare const TABLE_STRIPED_DATA: string;
|
|
12
|
-
export declare const TABLE_FINANCIAL_TEMPLATE: Template;
|
|
13
|
-
export declare const TABLE_FINANCIAL_DATA: string;
|
|
14
|
-
export declare const CHART_BAR_TEMPLATE: Template;
|
|
15
|
-
export declare const CHART_BAR_DATA: string;
|
|
16
|
-
export declare const CHART_LINE_TEMPLATE: Template;
|
|
17
|
-
export declare const CHART_LINE_DATA: string;
|
|
18
|
-
export declare const CHART_PIE_TEMPLATE: Template;
|
|
19
|
-
export declare const CHART_PIE_DATA: string;
|
|
20
|
-
export declare const PAGE_BREAK_TEST_TEMPLATE: Template;
|
|
21
|
-
export declare const PAGE_BREAK_TEST_DATA = "{}";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@veztraa/report-designer",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.1",
|
|
4
4
|
"description": "Embeddable React drag-and-drop PDF report designer — visual canvas, live preview, undo/redo, dark mode, signature element (draw/type/upload), handwriting fonts, multilingual Noto fonts, and data-bound repeating containers.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"pdf",
|
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
"veztraa",
|
|
21
21
|
"typescript"
|
|
22
22
|
],
|
|
23
|
+
"homepage": "https://npm.veztraa.com/report-designer",
|
|
23
24
|
"license": "MIT",
|
|
24
25
|
"type": "module",
|
|
25
26
|
"main": "dist/index.js",
|
|
@@ -44,8 +45,8 @@
|
|
|
44
45
|
},
|
|
45
46
|
"dependencies": {
|
|
46
47
|
"zustand": "^5.0.2",
|
|
47
|
-
"@veztraa/report-core": "0.
|
|
48
|
-
"@veztraa/report-renderer": "^0.
|
|
48
|
+
"@veztraa/report-core": "0.4.1",
|
|
49
|
+
"@veztraa/report-renderer": "^0.4.1"
|
|
49
50
|
},
|
|
50
51
|
"devDependencies": {
|
|
51
52
|
"@react-pdf/renderer": "^4.1.6",
|