@agilehub/agile-editor 1.7.0 → 1.8.0
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 -0
- package/dist/agile-editor.css +1 -1
- package/dist/agile-editor.js +17696 -18074
- package/dist/i18n-DCR9QpaV.js +2785 -0
- package/dist/types/components/editor/courseware-dialog.vue.d.ts +3 -0
- package/dist/types/components/editor/smart-sheet-dialog.vue.d.ts +3 -0
- package/dist/types/components/index.d.ts +2 -1
- package/dist/types/components/index.vue.d.ts +355 -19
- package/dist/types/components/menus/button.vue.d.ts +1 -1
- package/dist/types/components/menus/toolbar/insert/courseware.vue.d.ts +3 -0
- package/dist/types/components/menus/toolbar/insert/smart-sheet.vue.d.ts +3 -0
- package/dist/types/components/preview-toolbar/index.vue.d.ts +2 -2
- package/dist/types/components/toolbar/classic.vue.d.ts +14 -14
- package/dist/types/components/toolbar/ribbon.vue.d.ts +14 -14
- package/dist/types/composables/i18n.d.ts +351 -15
- package/dist/types/extensions/bookmark-transaction.d.ts +4 -0
- package/dist/types/extensions/bubble-note.d.ts +1 -0
- package/dist/types/extensions/courseware/annotation-session.d.ts +4 -0
- package/dist/types/extensions/courseware/index.d.ts +49 -0
- package/dist/types/extensions/courseware/model.d.ts +20 -0
- package/dist/types/extensions/courseware/node-view.vue.d.ts +93 -0
- package/dist/types/extensions/courseware/reader.vue.d.ts +22 -0
- package/dist/types/extensions/smart-sheet/index.d.ts +47 -0
- package/dist/types/extensions/smart-sheet/model.d.ts +18 -0
- package/dist/types/extensions/smart-sheet/node-view.vue.d.ts +93 -0
- package/dist/types/extensions/smart-sheet/viewer.vue.d.ts +36 -0
- package/dist/types/i18n.d.ts +351 -15
- package/dist/types/utils/bubble-note-icon.d.ts +1 -0
- package/dist/types/utils/document-formatting.d.ts +41 -37
- package/dist/types/utils/document-import.d.ts +2 -0
- package/dist/types/utils/html-element-id.d.ts +9 -2
- package/dist/types/utils/md5.d.ts +2 -0
- package/dist/viewer-CyuLA7YS.js +97 -0
- package/docs/FORMATTING_TEMPLATES.md +253 -250
- package/docs/FORMATTING_TEMPLATE_BUSINESS_GUIDE.md +536 -0
- package/docs/README.md +1 -0
- package/docs/configuration.md +25 -0
- package/package.json +165 -162
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
declare const __VLS_export: import("vue").DefineComponent<globalThis.ExtractPropTypes<{
|
|
2
|
+
editor: {
|
|
3
|
+
type: PropType<import("@tiptap/core").NodeViewProps["editor"]>;
|
|
4
|
+
required: true;
|
|
5
|
+
};
|
|
6
|
+
node: {
|
|
7
|
+
type: PropType<import("@tiptap/core").NodeViewProps["node"]>;
|
|
8
|
+
required: true;
|
|
9
|
+
};
|
|
10
|
+
decorations: {
|
|
11
|
+
type: PropType<import("@tiptap/core").NodeViewProps["decorations"]>;
|
|
12
|
+
required: true;
|
|
13
|
+
};
|
|
14
|
+
selected: {
|
|
15
|
+
type: PropType<import("@tiptap/core").NodeViewProps["selected"]>;
|
|
16
|
+
required: true;
|
|
17
|
+
};
|
|
18
|
+
extension: {
|
|
19
|
+
type: PropType<import("@tiptap/core").NodeViewProps["extension"]>;
|
|
20
|
+
required: true;
|
|
21
|
+
};
|
|
22
|
+
getPos: {
|
|
23
|
+
type: PropType<import("@tiptap/core").NodeViewProps["getPos"]>;
|
|
24
|
+
required: true;
|
|
25
|
+
};
|
|
26
|
+
updateAttributes: {
|
|
27
|
+
type: PropType<import("@tiptap/core").NodeViewProps["updateAttributes"]>;
|
|
28
|
+
required: true;
|
|
29
|
+
};
|
|
30
|
+
deleteNode: {
|
|
31
|
+
type: PropType<import("@tiptap/core").NodeViewProps["deleteNode"]>;
|
|
32
|
+
required: true;
|
|
33
|
+
};
|
|
34
|
+
view: {
|
|
35
|
+
type: PropType<import("@tiptap/core").NodeViewProps["view"]>;
|
|
36
|
+
required: true;
|
|
37
|
+
};
|
|
38
|
+
innerDecorations: {
|
|
39
|
+
type: PropType<import("@tiptap/core").NodeViewProps["innerDecorations"]>;
|
|
40
|
+
required: true;
|
|
41
|
+
};
|
|
42
|
+
HTMLAttributes: {
|
|
43
|
+
type: PropType<import("@tiptap/core").NodeViewProps["HTMLAttributes"]>;
|
|
44
|
+
required: true;
|
|
45
|
+
};
|
|
46
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<globalThis.ExtractPropTypes<{
|
|
47
|
+
editor: {
|
|
48
|
+
type: PropType<import("@tiptap/core").NodeViewProps["editor"]>;
|
|
49
|
+
required: true;
|
|
50
|
+
};
|
|
51
|
+
node: {
|
|
52
|
+
type: PropType<import("@tiptap/core").NodeViewProps["node"]>;
|
|
53
|
+
required: true;
|
|
54
|
+
};
|
|
55
|
+
decorations: {
|
|
56
|
+
type: PropType<import("@tiptap/core").NodeViewProps["decorations"]>;
|
|
57
|
+
required: true;
|
|
58
|
+
};
|
|
59
|
+
selected: {
|
|
60
|
+
type: PropType<import("@tiptap/core").NodeViewProps["selected"]>;
|
|
61
|
+
required: true;
|
|
62
|
+
};
|
|
63
|
+
extension: {
|
|
64
|
+
type: PropType<import("@tiptap/core").NodeViewProps["extension"]>;
|
|
65
|
+
required: true;
|
|
66
|
+
};
|
|
67
|
+
getPos: {
|
|
68
|
+
type: PropType<import("@tiptap/core").NodeViewProps["getPos"]>;
|
|
69
|
+
required: true;
|
|
70
|
+
};
|
|
71
|
+
updateAttributes: {
|
|
72
|
+
type: PropType<import("@tiptap/core").NodeViewProps["updateAttributes"]>;
|
|
73
|
+
required: true;
|
|
74
|
+
};
|
|
75
|
+
deleteNode: {
|
|
76
|
+
type: PropType<import("@tiptap/core").NodeViewProps["deleteNode"]>;
|
|
77
|
+
required: true;
|
|
78
|
+
};
|
|
79
|
+
view: {
|
|
80
|
+
type: PropType<import("@tiptap/core").NodeViewProps["view"]>;
|
|
81
|
+
required: true;
|
|
82
|
+
};
|
|
83
|
+
innerDecorations: {
|
|
84
|
+
type: PropType<import("@tiptap/core").NodeViewProps["innerDecorations"]>;
|
|
85
|
+
required: true;
|
|
86
|
+
};
|
|
87
|
+
HTMLAttributes: {
|
|
88
|
+
type: PropType<import("@tiptap/core").NodeViewProps["HTMLAttributes"]>;
|
|
89
|
+
required: true;
|
|
90
|
+
};
|
|
91
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
92
|
+
declare const _default: typeof __VLS_export;
|
|
93
|
+
export default _default;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { ReaderMode } from '@agilehub/vue-pdf-flipbook';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
title: string;
|
|
4
|
+
url: string;
|
|
5
|
+
documentId: string;
|
|
6
|
+
fileSize?: number;
|
|
7
|
+
initialMode?: ReaderMode;
|
|
8
|
+
allowAnnotations?: boolean;
|
|
9
|
+
fullscreen?: boolean;
|
|
10
|
+
};
|
|
11
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
12
|
+
close: () => any;
|
|
13
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
14
|
+
onClose?: () => any;
|
|
15
|
+
}>, {
|
|
16
|
+
fullscreen: boolean;
|
|
17
|
+
fileSize: number;
|
|
18
|
+
initialMode: ReaderMode;
|
|
19
|
+
allowAnnotations: boolean;
|
|
20
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
21
|
+
declare const _default: typeof __VLS_export;
|
|
22
|
+
export default _default;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 插件作用:定义智能表格文件节点及插入命令。
|
|
3
|
+
* 使用方法:通过插入菜单上传 xlsx,并在预览弹层中编辑和导出。
|
|
4
|
+
* 注意事项:节点只保存文件元数据,编辑内容不写入文档或本地存储。
|
|
5
|
+
*/
|
|
6
|
+
import { Node } from '@tiptap/core';
|
|
7
|
+
import { type SmartSheetData } from './model';
|
|
8
|
+
interface SmartSheetDialogState {
|
|
9
|
+
visible: boolean;
|
|
10
|
+
session: number;
|
|
11
|
+
position: number | null;
|
|
12
|
+
data: SmartSheetData | null;
|
|
13
|
+
}
|
|
14
|
+
declare module '@tiptap/core' {
|
|
15
|
+
interface Storage {
|
|
16
|
+
smartSheet: {
|
|
17
|
+
dialog: SmartSheetDialogState;
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
interface Commands<ReturnType> {
|
|
21
|
+
smartSheet: {
|
|
22
|
+
insertSmartSheet: (data: SmartSheetData) => ReturnType;
|
|
23
|
+
updateSmartSheet: (data: SmartSheetData, position: number) => ReturnType;
|
|
24
|
+
openSmartSheet: (position?: number | null) => ReturnType;
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
declare const _default: Node<any, {
|
|
29
|
+
dialog: {
|
|
30
|
+
visible: boolean;
|
|
31
|
+
session: number;
|
|
32
|
+
position: number | null;
|
|
33
|
+
data: {
|
|
34
|
+
id: string;
|
|
35
|
+
title: string;
|
|
36
|
+
description: string;
|
|
37
|
+
defaultExpanded: boolean;
|
|
38
|
+
fileId: string;
|
|
39
|
+
name: string;
|
|
40
|
+
url: string;
|
|
41
|
+
size: number;
|
|
42
|
+
type: string;
|
|
43
|
+
};
|
|
44
|
+
};
|
|
45
|
+
}>;
|
|
46
|
+
export default _default;
|
|
47
|
+
export type { SmartSheetData } from './model';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export declare const SMART_SHEET_MIME = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";
|
|
2
|
+
export declare const SMART_SHEET_TITLE_MAX_LENGTH = 50;
|
|
3
|
+
export interface SmartSheetData {
|
|
4
|
+
id: string;
|
|
5
|
+
title: string;
|
|
6
|
+
description: string;
|
|
7
|
+
defaultExpanded: boolean;
|
|
8
|
+
fileId: string;
|
|
9
|
+
name: string;
|
|
10
|
+
url: string;
|
|
11
|
+
size: number;
|
|
12
|
+
type: string;
|
|
13
|
+
}
|
|
14
|
+
export declare const getSmartSheetId: (url: string) => string;
|
|
15
|
+
export declare const createEmptySmartSheetData: () => SmartSheetData;
|
|
16
|
+
export declare const normalizeSmartSheetData: (value: unknown) => SmartSheetData;
|
|
17
|
+
export declare const parseSmartSheetData: (value: string | null) => SmartSheetData;
|
|
18
|
+
export declare const serializeSmartSheetData: (value: unknown) => string;
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
declare const __VLS_export: import("vue").DefineComponent<globalThis.ExtractPropTypes<{
|
|
2
|
+
editor: {
|
|
3
|
+
type: PropType<import("@tiptap/core").NodeViewProps["editor"]>;
|
|
4
|
+
required: true;
|
|
5
|
+
};
|
|
6
|
+
node: {
|
|
7
|
+
type: PropType<import("@tiptap/core").NodeViewProps["node"]>;
|
|
8
|
+
required: true;
|
|
9
|
+
};
|
|
10
|
+
decorations: {
|
|
11
|
+
type: PropType<import("@tiptap/core").NodeViewProps["decorations"]>;
|
|
12
|
+
required: true;
|
|
13
|
+
};
|
|
14
|
+
selected: {
|
|
15
|
+
type: PropType<import("@tiptap/core").NodeViewProps["selected"]>;
|
|
16
|
+
required: true;
|
|
17
|
+
};
|
|
18
|
+
extension: {
|
|
19
|
+
type: PropType<import("@tiptap/core").NodeViewProps["extension"]>;
|
|
20
|
+
required: true;
|
|
21
|
+
};
|
|
22
|
+
getPos: {
|
|
23
|
+
type: PropType<import("@tiptap/core").NodeViewProps["getPos"]>;
|
|
24
|
+
required: true;
|
|
25
|
+
};
|
|
26
|
+
updateAttributes: {
|
|
27
|
+
type: PropType<import("@tiptap/core").NodeViewProps["updateAttributes"]>;
|
|
28
|
+
required: true;
|
|
29
|
+
};
|
|
30
|
+
deleteNode: {
|
|
31
|
+
type: PropType<import("@tiptap/core").NodeViewProps["deleteNode"]>;
|
|
32
|
+
required: true;
|
|
33
|
+
};
|
|
34
|
+
view: {
|
|
35
|
+
type: PropType<import("@tiptap/core").NodeViewProps["view"]>;
|
|
36
|
+
required: true;
|
|
37
|
+
};
|
|
38
|
+
innerDecorations: {
|
|
39
|
+
type: PropType<import("@tiptap/core").NodeViewProps["innerDecorations"]>;
|
|
40
|
+
required: true;
|
|
41
|
+
};
|
|
42
|
+
HTMLAttributes: {
|
|
43
|
+
type: PropType<import("@tiptap/core").NodeViewProps["HTMLAttributes"]>;
|
|
44
|
+
required: true;
|
|
45
|
+
};
|
|
46
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<globalThis.ExtractPropTypes<{
|
|
47
|
+
editor: {
|
|
48
|
+
type: PropType<import("@tiptap/core").NodeViewProps["editor"]>;
|
|
49
|
+
required: true;
|
|
50
|
+
};
|
|
51
|
+
node: {
|
|
52
|
+
type: PropType<import("@tiptap/core").NodeViewProps["node"]>;
|
|
53
|
+
required: true;
|
|
54
|
+
};
|
|
55
|
+
decorations: {
|
|
56
|
+
type: PropType<import("@tiptap/core").NodeViewProps["decorations"]>;
|
|
57
|
+
required: true;
|
|
58
|
+
};
|
|
59
|
+
selected: {
|
|
60
|
+
type: PropType<import("@tiptap/core").NodeViewProps["selected"]>;
|
|
61
|
+
required: true;
|
|
62
|
+
};
|
|
63
|
+
extension: {
|
|
64
|
+
type: PropType<import("@tiptap/core").NodeViewProps["extension"]>;
|
|
65
|
+
required: true;
|
|
66
|
+
};
|
|
67
|
+
getPos: {
|
|
68
|
+
type: PropType<import("@tiptap/core").NodeViewProps["getPos"]>;
|
|
69
|
+
required: true;
|
|
70
|
+
};
|
|
71
|
+
updateAttributes: {
|
|
72
|
+
type: PropType<import("@tiptap/core").NodeViewProps["updateAttributes"]>;
|
|
73
|
+
required: true;
|
|
74
|
+
};
|
|
75
|
+
deleteNode: {
|
|
76
|
+
type: PropType<import("@tiptap/core").NodeViewProps["deleteNode"]>;
|
|
77
|
+
required: true;
|
|
78
|
+
};
|
|
79
|
+
view: {
|
|
80
|
+
type: PropType<import("@tiptap/core").NodeViewProps["view"]>;
|
|
81
|
+
required: true;
|
|
82
|
+
};
|
|
83
|
+
innerDecorations: {
|
|
84
|
+
type: PropType<import("@tiptap/core").NodeViewProps["innerDecorations"]>;
|
|
85
|
+
required: true;
|
|
86
|
+
};
|
|
87
|
+
HTMLAttributes: {
|
|
88
|
+
type: PropType<import("@tiptap/core").NodeViewProps["HTMLAttributes"]>;
|
|
89
|
+
required: true;
|
|
90
|
+
};
|
|
91
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
92
|
+
declare const _default: typeof __VLS_export;
|
|
93
|
+
export default _default;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
src: string;
|
|
3
|
+
fileName?: string;
|
|
4
|
+
editable?: boolean;
|
|
5
|
+
recalc?: boolean;
|
|
6
|
+
};
|
|
7
|
+
declare var __VLS_23: any;
|
|
8
|
+
type __VLS_Slots = {} & {
|
|
9
|
+
header?: (props: typeof __VLS_23) => any;
|
|
10
|
+
};
|
|
11
|
+
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
12
|
+
getViewer: () => any;
|
|
13
|
+
isDirty: () => boolean;
|
|
14
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
15
|
+
error: (message: string) => any;
|
|
16
|
+
ready: (workbook: unknown) => any;
|
|
17
|
+
"cell-change": (payload: unknown) => any;
|
|
18
|
+
"dirty-change": (dirty: boolean) => any;
|
|
19
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
20
|
+
onError?: (message: string) => any;
|
|
21
|
+
onReady?: (workbook: unknown) => any;
|
|
22
|
+
"onCell-change"?: (payload: unknown) => any;
|
|
23
|
+
"onDirty-change"?: (dirty: boolean) => any;
|
|
24
|
+
}>, {
|
|
25
|
+
fileName: string;
|
|
26
|
+
editable: boolean;
|
|
27
|
+
recalc: boolean;
|
|
28
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
29
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
30
|
+
declare const _default: typeof __VLS_export;
|
|
31
|
+
export default _default;
|
|
32
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
33
|
+
new (): {
|
|
34
|
+
$slots: S;
|
|
35
|
+
};
|
|
36
|
+
};
|