visio-solid-viewer 0.5.9 → 0.6.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
CHANGED
|
@@ -8,6 +8,8 @@
|
|
|
8
8
|
|
|
9
9
|
[Live demo](https://christophervr.github.io/ooxml/visio/demo/) | [npm](https://www.npmjs.com/package/visio-solid-viewer) | [Full docs](https://christophervr.github.io/ooxml/visio/) | [Source](https://github.com/ChristopherVR/ooxml/tree/main/viewers/visio)
|
|
10
10
|
|
|
11
|
+
Part of [ooxml](https://github.com/ChristopherVR/ooxml#readme): [Office](https://github.com/ChristopherVR/ooxml#ooxml-office-the-whole-suite-in-one-app) · [Word](https://github.com/ChristopherVR/ooxml/tree/main/viewers/docx#readme) · [Excel](https://github.com/ChristopherVR/ooxml/tree/main/viewers/xlsx#readme) · [PowerPoint](https://github.com/ChristopherVR/ooxml/tree/main/viewers/pptx#readme) · **[Visio](https://github.com/ChristopherVR/ooxml/tree/main/viewers/visio#readme)** · [OpenTeams](https://github.com/ChristopherVR/ooxml/tree/main/viewers/teams#readme) · [Core](https://github.com/ChristopherVR/ooxml/tree/main/src/core#readme)
|
|
12
|
+
|
|
11
13
|
## Install
|
|
12
14
|
|
|
13
15
|
```bash
|
package/dist/index.js
CHANGED
|
@@ -67,12 +67,36 @@ function viewerHandle(current) {
|
|
|
67
67
|
async load(source) {
|
|
68
68
|
await requireViewer().load(source);
|
|
69
69
|
},
|
|
70
|
+
async createBlankDrawing(options) {
|
|
71
|
+
await requireViewer().createBlankDrawing(options);
|
|
72
|
+
},
|
|
70
73
|
async applyEdits(edits) {
|
|
71
74
|
await requireViewer().applyEdits(edits);
|
|
72
75
|
},
|
|
76
|
+
selectShapes(shapes) {
|
|
77
|
+
requireViewer().selectShapes(shapes);
|
|
78
|
+
},
|
|
79
|
+
selectAll() {
|
|
80
|
+
requireViewer().selectAll();
|
|
81
|
+
},
|
|
82
|
+
clearSelection() {
|
|
83
|
+
requireViewer().clearSelection();
|
|
84
|
+
},
|
|
73
85
|
async replacePlainText(pageId, shapeId, text) {
|
|
74
86
|
await requireViewer().replacePlainText(pageId, shapeId, text);
|
|
75
87
|
},
|
|
88
|
+
async duplicateSelection() {
|
|
89
|
+
await requireViewer().duplicateSelection();
|
|
90
|
+
},
|
|
91
|
+
async copySelection() {
|
|
92
|
+
await requireViewer().copySelection();
|
|
93
|
+
},
|
|
94
|
+
async cutSelection() {
|
|
95
|
+
await requireViewer().cutSelection();
|
|
96
|
+
},
|
|
97
|
+
async pasteSelection() {
|
|
98
|
+
await requireViewer().pasteSelection();
|
|
99
|
+
},
|
|
76
100
|
async undo() {
|
|
77
101
|
await requireViewer().undo();
|
|
78
102
|
},
|
package/dist/index.server.js
CHANGED
|
@@ -67,12 +67,36 @@ function viewerHandle(current) {
|
|
|
67
67
|
async load(source) {
|
|
68
68
|
await requireViewer().load(source);
|
|
69
69
|
},
|
|
70
|
+
async createBlankDrawing(options) {
|
|
71
|
+
await requireViewer().createBlankDrawing(options);
|
|
72
|
+
},
|
|
70
73
|
async applyEdits(edits) {
|
|
71
74
|
await requireViewer().applyEdits(edits);
|
|
72
75
|
},
|
|
76
|
+
selectShapes(shapes) {
|
|
77
|
+
requireViewer().selectShapes(shapes);
|
|
78
|
+
},
|
|
79
|
+
selectAll() {
|
|
80
|
+
requireViewer().selectAll();
|
|
81
|
+
},
|
|
82
|
+
clearSelection() {
|
|
83
|
+
requireViewer().clearSelection();
|
|
84
|
+
},
|
|
73
85
|
async replacePlainText(pageId, shapeId, text) {
|
|
74
86
|
await requireViewer().replacePlainText(pageId, shapeId, text);
|
|
75
87
|
},
|
|
88
|
+
async duplicateSelection() {
|
|
89
|
+
await requireViewer().duplicateSelection();
|
|
90
|
+
},
|
|
91
|
+
async copySelection() {
|
|
92
|
+
await requireViewer().copySelection();
|
|
93
|
+
},
|
|
94
|
+
async cutSelection() {
|
|
95
|
+
await requireViewer().cutSelection();
|
|
96
|
+
},
|
|
97
|
+
async pasteSelection() {
|
|
98
|
+
await requireViewer().pasteSelection();
|
|
99
|
+
},
|
|
76
100
|
async undo() {
|
|
77
101
|
await requireViewer().undo();
|
|
78
102
|
},
|
|
@@ -7,7 +7,7 @@ export type ViewerProps = {
|
|
|
7
7
|
} & {
|
|
8
8
|
events?: ViewerCallbacks | undefined;
|
|
9
9
|
};
|
|
10
|
-
export type ViewerHandle = Pick<MountedViewer, 'element' | 'controller' | 'load' | 'applyEdits' | 'replacePlainText' | 'undo' | 'redo' | 'cancelEdit' | 'exportVsdx' | 'fit' | 'setLayerVisibility' | 'resetLayerVisibility' | 'exportSvg' | 'createPrintSnapshot'>;
|
|
10
|
+
export type ViewerHandle = Pick<MountedViewer, 'element' | 'controller' | 'load' | 'createBlankDrawing' | 'applyEdits' | 'selectShapes' | 'selectAll' | 'clearSelection' | 'duplicateSelection' | 'copySelection' | 'cutSelection' | 'pasteSelection' | 'replacePlainText' | 'undo' | 'redo' | 'cancelEdit' | 'exportVsdx' | 'fit' | 'setLayerVisibility' | 'resetLayerVisibility' | 'exportSvg' | 'createPrintSnapshot'>;
|
|
11
11
|
/** One mapping for every property and event, shared by every framework adapter. */
|
|
12
12
|
export declare function viewerOptions(props: ViewerProps): ViewerOptions;
|
|
13
13
|
/**
|
|
@@ -33,8 +33,9 @@ export { mountViewer };
|
|
|
33
33
|
export type { MountedViewer, ViewerCallbacks, ViewerOptions, ViewerProperties };
|
|
34
34
|
export { eventKeys, propertyKeys };
|
|
35
35
|
export type { ViewerEvents, VsdxSource } from 'ooxml-ui/visio';
|
|
36
|
+
export type { VisioShapeSelection } from 'ooxml-ui/visio';
|
|
36
37
|
export { ViewerController, type ViewerState } from 'ooxml-ui/visio';
|
|
37
38
|
export type { SvgExportOptions, SvgExportResult } from 'ooxml-ui/visio';
|
|
38
39
|
export type { CurrentPagePrintSnapshotOptions, PrintSnapshot, PrintSnapshotPage, PrintSnapshotOptions, PrintSnapshotLimits, PrintSnapshotUsage, } from 'ooxml-ui/visio';
|
|
39
40
|
export type { ViewerEditState, VsdxExportResult } from 'ooxml-ui/visio';
|
|
40
|
-
export type { VisioEdit, VisioGeometryEdit } from 'ooxml-core/visio';
|
|
41
|
+
export type { VisioEdit, VisioGeometryEdit, CreateVsdxOptions } from 'ooxml-core/visio';
|
|
@@ -13,4 +13,4 @@ export declare function VisioViewer(props: VisioViewerProps): JSX.Element;
|
|
|
13
13
|
* `viewerRef`). Follows handle changes and cleans up with the owning scope.
|
|
14
14
|
*/
|
|
15
15
|
export declare function createVisioViewerState(handle: Accessor<ViewerHandle | undefined>): Accessor<ViewerState | null>;
|
|
16
|
-
export type { ViewerState, ViewerHandle, ViewerCallbacks, ViewerOptions, ViewerEvents, ViewerEditState, VsdxExportResult, } from './common.js';
|
|
16
|
+
export type { ViewerState, ViewerHandle, ViewerCallbacks, ViewerOptions, ViewerEvents, VisioShapeSelection, ViewerEditState, VsdxExportResult, } from './common.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "visio-solid-viewer",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.1",
|
|
4
4
|
"description": "Local-first Visio viewer for solid",
|
|
5
5
|
"homepage": "https://christophervr.github.io/ooxml/visio/",
|
|
6
6
|
"bugs": {
|
|
@@ -32,9 +32,9 @@
|
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"emf-converter": "4.8.21",
|
|
35
|
-
"ooxml-core": "^1.
|
|
36
|
-
"ooxml-ui": "^1.1
|
|
37
|
-
"visio-core": "^0.
|
|
35
|
+
"ooxml-core": "^1.4.0",
|
|
36
|
+
"ooxml-ui": "^1.4.1",
|
|
37
|
+
"visio-core": "^0.4.1"
|
|
38
38
|
},
|
|
39
39
|
"peerDependencies": {
|
|
40
40
|
"solid-js": "^1.9.0"
|