@ones-editor/editor 2.1.7-beta.16 → 2.1.7-beta.18
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
|
@@ -38161,7 +38161,7 @@ ${codeText}
|
|
|
38161
38161
|
var _a, _b;
|
|
38162
38162
|
if ((_a = this.options) == null ? void 0 : _a.uploadResource) {
|
|
38163
38163
|
try {
|
|
38164
|
-
const ret2 = await this.options.uploadResource(file2, options);
|
|
38164
|
+
const ret2 = await this.options.uploadResource(this, file2, options);
|
|
38165
38165
|
return ret2;
|
|
38166
38166
|
} catch (err) {
|
|
38167
38167
|
}
|
|
@@ -38175,7 +38175,7 @@ ${codeText}
|
|
|
38175
38175
|
buildResourceUrl(resourceId, options) {
|
|
38176
38176
|
var _a;
|
|
38177
38177
|
if ((_a = this.options) == null ? void 0 : _a.buildResourceUrl) {
|
|
38178
|
-
const ret = this.options.buildResourceUrl(resourceId, options);
|
|
38178
|
+
const ret = this.options.buildResourceUrl(this, resourceId, options);
|
|
38179
38179
|
if (ret) {
|
|
38180
38180
|
return ret;
|
|
38181
38181
|
}
|
|
@@ -87810,7 +87810,7 @@ ${data2.flowchartText}
|
|
|
87810
87810
|
}
|
|
87811
87811
|
}
|
|
87812
87812
|
});
|
|
87813
|
-
editor.version = "2.1.7-beta.
|
|
87813
|
+
editor.version = "2.1.7-beta.18";
|
|
87814
87814
|
if (Logger$2.level === LogLevel.DEBUG) {
|
|
87815
87815
|
window.setReauthFail = (fail) => {
|
|
87816
87816
|
window.isReauthError = fail;
|
|
@@ -87929,7 +87929,7 @@ ${data2.flowchartText}
|
|
|
87929
87929
|
}
|
|
87930
87930
|
}
|
|
87931
87931
|
OnesEditorToolbar.register(editor);
|
|
87932
|
-
editor.version = "2.1.7-beta.
|
|
87932
|
+
editor.version = "2.1.7-beta.18";
|
|
87933
87933
|
return editor;
|
|
87934
87934
|
}
|
|
87935
87935
|
async function showDocVersions(editor, options, serverUrl) {
|
|
@@ -134059,6 +134059,7 @@ ${data2.flowchartText}
|
|
|
134059
134059
|
exports2.genId = genId;
|
|
134060
134060
|
exports2.generateEditorContainerId = generateEditorContainerId;
|
|
134061
134061
|
exports2.getAllChildBlocks = getAllChildBlocks;
|
|
134062
|
+
exports2.getAllResourcesFromDoc = getAllResourcesFromDoc;
|
|
134062
134063
|
exports2.getAllSelectedBlocks = getAllSelectedBlocks;
|
|
134063
134064
|
exports2.getAttributesAt = getAttributesAt;
|
|
134064
134065
|
exports2.getBlockBackground = getBlockBackground;
|
package/dist/types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Embed, Box, i18n, OnesEditor, OnesEditorUser, OnesEditorUserPermission, OnesEditorBlockHook, OnesEditorCommandProvider, LogLevel, Block, ShortcutRecords, OnesEditorBlockRenderer, BuildResourceUrlOptions, UploadResourceOptions, UploadResourceResult, MobileClient } from '../@ones-editor/core';
|
|
1
|
+
import { Embed, Box, i18n, OnesEditor, OnesEditorUser, OnesEditorUserPermission, OnesEditorBlockHook, OnesEditorCommandProvider, LogLevel, Block, ShortcutRecords, OnesEditorBlockRenderer, BuildResourceUrlOptions, UploadResourceOptions, UploadResourceResult, MobileClient, OnesEditorDoc } from '../@ones-editor/core';
|
|
2
2
|
import { DrawIoOptions } from '../@ones-editor/drawio-embed';
|
|
3
3
|
import { FlowCharEmbedOptions, MermaidEmbedOptions, PlantumlEmbedOptions } from '../@ones-editor/graph-embed';
|
|
4
4
|
import { ImageOptions } from '../@ones-editor/image-embed';
|
|
@@ -87,8 +87,8 @@ export interface CreateOnesEditorOptions {
|
|
|
87
87
|
events?: EditorEvents;
|
|
88
88
|
shortcuts?: ShortcutRecords[];
|
|
89
89
|
componentsOptions?: EditorComponentOptions;
|
|
90
|
-
buildResourceUrl?: (resourceId: string, options?: BuildResourceUrlOptions) => string;
|
|
91
|
-
uploadResource?: (file: File, options?: UploadResourceOptions) => Promise<UploadResourceResult>;
|
|
90
|
+
buildResourceUrl?: (doc: OnesEditorDoc, resourceId: string, options?: BuildResourceUrlOptions) => string;
|
|
91
|
+
uploadResource?: (doc: OnesEditorDoc, file: File, options?: UploadResourceOptions) => Promise<UploadResourceResult>;
|
|
92
92
|
autoNewLine?: boolean;
|
|
93
93
|
}
|
|
94
94
|
export interface CreateLocalEditorOptions {
|