@rhc-office/sdk 6.6.398 → 6.6.400
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/api/annotation-tool.d.ts +23 -0
- package/dist/api/annotation-tool.d.ts.map +1 -1
- package/dist/browser/document-viewer.js +1 -1
- package/dist/browser/document-viewer.js.map +1 -1
- package/dist/index.js +4 -3
- package/dist/index.js.map +1 -1
- package/dist/index.umd.cjs +1 -1
- package/dist/index.umd.cjs.map +1 -1
- package/dist/tools/AnnotationToolImpl.d.ts +1 -0
- package/dist/tools/AnnotationToolImpl.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/api/annotation-tool.ts +33 -0
- package/src/tools/AnnotationToolImpl.ts +5 -0
- package/src/viewer/DocumentSDK.ts +2 -2
package/dist/index.js
CHANGED
|
@@ -237,6 +237,7 @@ const K = "RIGHT_CENTER", q = "REGULAR_ESM", z = "auto", f = "__RHC_OFFICE_DIGIT
|
|
|
237
237
|
selectAnnotationTool: { kind: "command" },
|
|
238
238
|
selectAnnotationStamp: { kind: "command" },
|
|
239
239
|
openTextNoteCalloutDialog: { kind: "command", returnsResult: !0 },
|
|
240
|
+
createTextNoteAnnotation: { kind: "command", returnsResult: !0 },
|
|
240
241
|
getCustomStamps: { kind: "query" },
|
|
241
242
|
addCustomTextStamp: { kind: "query" },
|
|
242
243
|
addCustomImageStamp: { kind: "query" },
|
|
@@ -246,7 +247,7 @@ const K = "RIGHT_CENTER", q = "REGULAR_ESM", z = "auto", f = "__RHC_OFFICE_DIGIT
|
|
|
246
247
|
};
|
|
247
248
|
class de {
|
|
248
249
|
constructor(n) {
|
|
249
|
-
this.openAnnotationView = (e) => this.adapter.openAnnotationView(e), this.closeAnnotationView = () => this.adapter.closeAnnotationView(), this.saveAnnotations = (e) => this.adapter.saveAnnotations(e), this.clearAnnotations = () => this.adapter.clearAnnotations(), this.undoAnnotation = () => this.adapter.undoAnnotation(), this.redoAnnotation = () => this.adapter.redoAnnotation(), this.canUndoAnnotation = () => this.adapter.canUndoAnnotation(), this.canRedoAnnotation = () => this.adapter.canRedoAnnotation(), this.selectAnnotationTool = (e, i) => this.adapter.selectAnnotationTool(e, i), this.selectAnnotationStamp = (e) => this.adapter.selectAnnotationStamp(e), this.openTextNoteCalloutDialog = (e) => this.adapter.openTextNoteCalloutDialog(e), this.getCustomStamps = () => this.adapter.getCustomStamps(), this.addCustomTextStamp = (e) => this.adapter.addCustomTextStamp(e), this.addCustomImageStamp = (e) => this.adapter.addCustomImageStamp(e), this.setAnnotationPenColor = (e) => this.adapter.setAnnotationPenColor(e), this.setAnnotationPenWidth = (e) => this.adapter.setAnnotationPenWidth(e), this.setAnnotationPenStyle = (e) => this.adapter.setAnnotationPenStyle(e), this.isInAnnotationMode = () => this.adapter.isInAnnotationMode(), this.getAnnotationMode = () => this.adapter.getAnnotationMode(), this.getAnnotations = () => this.adapter.getAnnotations(), this.getAnnotationsCount = () => this.adapter.getAnnotationsCount(), this.addAnnotationEventCallback = (e) => this.adapter.addAnnotationEventCallback(e), this.adapter = u(
|
|
250
|
+
this.openAnnotationView = (e) => this.adapter.openAnnotationView(e), this.closeAnnotationView = () => this.adapter.closeAnnotationView(), this.saveAnnotations = (e) => this.adapter.saveAnnotations(e), this.clearAnnotations = () => this.adapter.clearAnnotations(), this.undoAnnotation = () => this.adapter.undoAnnotation(), this.redoAnnotation = () => this.adapter.redoAnnotation(), this.canUndoAnnotation = () => this.adapter.canUndoAnnotation(), this.canRedoAnnotation = () => this.adapter.canRedoAnnotation(), this.selectAnnotationTool = (e, i) => this.adapter.selectAnnotationTool(e, i), this.selectAnnotationStamp = (e) => this.adapter.selectAnnotationStamp(e), this.openTextNoteCalloutDialog = (e) => this.adapter.openTextNoteCalloutDialog(e), this.createTextNoteAnnotation = (e) => this.adapter.createTextNoteAnnotation(e), this.getCustomStamps = () => this.adapter.getCustomStamps(), this.addCustomTextStamp = (e) => this.adapter.addCustomTextStamp(e), this.addCustomImageStamp = (e) => this.adapter.addCustomImageStamp(e), this.setAnnotationPenColor = (e) => this.adapter.setAnnotationPenColor(e), this.setAnnotationPenWidth = (e) => this.adapter.setAnnotationPenWidth(e), this.setAnnotationPenStyle = (e) => this.adapter.setAnnotationPenStyle(e), this.isInAnnotationMode = () => this.adapter.isInAnnotationMode(), this.getAnnotationMode = () => this.adapter.getAnnotationMode(), this.getAnnotations = () => this.adapter.getAnnotations(), this.getAnnotationsCount = () => this.adapter.getAnnotationsCount(), this.addAnnotationEventCallback = (e) => this.adapter.addAnnotationEventCallback(e), this.adapter = u(
|
|
250
251
|
"annotation",
|
|
251
252
|
oe,
|
|
252
253
|
n
|
|
@@ -1120,11 +1121,11 @@ const S = "__RHC_OFFICE_READER_RUNTIME__", y = "__rhcOfficeReaderRuntimeConfig",
|
|
|
1120
1121
|
const n = t.trim().replace(/[-_\s]/g, "").toLowerCase();
|
|
1121
1122
|
return n === "view" ? "VIEW" : n === "annotation" ? "ANNOTATION" : n === "digitalsign" ? "DIGITAL_SIGN" : null;
|
|
1122
1123
|
}, U = (t) => {
|
|
1123
|
-
const n = [];
|
|
1124
|
+
const n = ["VIEW"];
|
|
1124
1125
|
return t.split(/[;,]/).forEach((e) => {
|
|
1125
1126
|
const i = bt(e);
|
|
1126
1127
|
i && !n.includes(i) && n.push(i);
|
|
1127
|
-
}), n.
|
|
1128
|
+
}), n.join(",");
|
|
1128
1129
|
}, St = (t) => {
|
|
1129
1130
|
const n = {};
|
|
1130
1131
|
return t.canOpenNewFile !== void 0 && (n.canOpenNewFile = t.canOpenNewFile), t.canPrint !== void 0 && (n.canPrint = t.canPrint), t.canDownload !== void 0 && (n.canDownload = t.canDownload), Object.keys(n).length > 0 ? n : void 0;
|