@ckeditor/ckeditor5-revision-history 36.0.0 → 37.0.0-rc.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.
Files changed (68) hide show
  1. package/build/revision-history.js +1 -1
  2. package/package.json +23 -8
  3. package/src/augmentation.d.ts +25 -0
  4. package/src/augmentation.js +23 -0
  5. package/src/changeitem.d.ts +52 -0
  6. package/src/changeitem.js +1 -1
  7. package/src/editor/revisionviewereditor.d.ts +27 -0
  8. package/src/editor/revisionviewereditor.js +1 -1
  9. package/src/editor/revisionviewereditorui.d.ts +28 -0
  10. package/src/editor/revisionviewereditorui.js +1 -1
  11. package/src/editor/revisionviewereditoruiview.d.ts +43 -0
  12. package/src/editor/revisionviewereditoruiview.js +1 -1
  13. package/src/index.d.ts +10 -0
  14. package/src/index.js +1 -1
  15. package/src/revision.d.ts +153 -0
  16. package/src/revision.js +1 -1
  17. package/src/revisiondiff.d.ts +19 -0
  18. package/src/revisiondiff.js +1 -1
  19. package/src/revisionhistory.d.ts +93 -0
  20. package/src/revisionhistory.js +1 -1
  21. package/src/revisionhistoryadapter.d.ts +60 -0
  22. package/src/revisionhistoryadapter.js +23 -0
  23. package/src/revisionhistoryconfig.d.ts +60 -0
  24. package/src/revisionhistoryconfig.js +23 -0
  25. package/src/revisionsrepository.d.ts +43 -0
  26. package/src/revisionsrepository.js +1 -1
  27. package/src/revisiontracker.d.ts +72 -0
  28. package/src/revisiontracker.js +1 -1
  29. package/src/revisionviewer.d.ts +21 -0
  30. package/src/revisionviewer.js +1 -1
  31. package/src/ui/revision/createrevisionactionsdropdown.d.ts +9 -0
  32. package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
  33. package/src/ui/revision/revisionauthorview.d.ts +4 -0
  34. package/src/ui/revision/revisionauthorview.js +1 -1
  35. package/src/ui/revision/revisionnameview.d.ts +4 -0
  36. package/src/ui/revision/revisionnameview.js +1 -1
  37. package/src/ui/revision/revisionview.d.ts +91 -0
  38. package/src/ui/revision/revisionview.js +1 -1
  39. package/src/ui/revision/subrevisioncollapserview.d.ts +17 -0
  40. package/src/ui/revision/subrevisioncollapserview.js +1 -1
  41. package/src/ui/revision/subrevisionview.d.ts +30 -0
  42. package/src/ui/revision/subrevisionview.js +1 -1
  43. package/src/ui/revision/utils.d.ts +4 -0
  44. package/src/ui/revision/utils.js +1 -1
  45. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.d.ts +80 -0
  46. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
  47. package/src/ui/revisionhistory/revisionhistoryui.d.ts +21 -0
  48. package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
  49. package/src/ui/revisionssidebar/revisionssidebar.d.ts +39 -0
  50. package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
  51. package/src/ui/revisionssidebar/revisionssidebarheaderview.d.ts +4 -0
  52. package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
  53. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.d.ts +25 -0
  54. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
  55. package/src/ui/revisionssidebar/revisionssidebarview.d.ts +40 -0
  56. package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
  57. package/src/ui/revisionssidebar/utils.d.ts +8 -0
  58. package/src/ui/revisionssidebar/utils.js +1 -1
  59. package/src/ui/revisionviewer/changedetailsview.d.ts +18 -0
  60. package/src/ui/revisionviewer/changedetailsview.js +1 -1
  61. package/src/ui/revisionviewer/changesnavigationview.d.ts +36 -0
  62. package/src/ui/revisionviewer/changesnavigationview.js +1 -1
  63. package/src/ui/revisionviewer/revisionviewerloadingoverlay.d.ts +22 -0
  64. package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
  65. package/src/ui/revisionviewer/revisionviewerui.d.ts +22 -0
  66. package/src/ui/revisionviewer/revisionviewerui.js +1 -1
  67. package/src/utils/common-translations.d.ts +7 -0
  68. package/src/utils/common-translations.js +1 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ckeditor/ckeditor5-revision-history",
3
- "version": "36.0.0",
3
+ "version": "37.0.0-rc.0",
4
4
  "description": "Document revision history feature for CKEditor 5.",
5
5
  "license": "SEE LICENSE IN LICENSE.md",
6
6
  "author": "CKSource (http://cksource.com/)",
@@ -24,14 +24,29 @@
24
24
  "versioning"
25
25
  ],
26
26
  "main": "src/index.js",
27
+ "scripts": {
28
+ "dll:build": "webpack",
29
+ "build": "tsc -p ./tsconfig.json",
30
+ "postversion": "npm run build"
31
+ },
32
+ "files": [
33
+ "build",
34
+ "lang",
35
+ "src/**/*.js",
36
+ "src/**/*.d.ts",
37
+ "theme",
38
+ "ckeditor5-metadata.json",
39
+ "CHANGELOG.md"
40
+ ],
27
41
  "dependencies": {
28
- "@ckeditor/ckeditor5-core": "^36.0.0",
29
- "@ckeditor/ckeditor5-ui": "^36.0.0",
30
- "@ckeditor/ckeditor5-undo": "^36.0.0",
31
- "@ckeditor/ckeditor5-editor-classic": "^36.0.0",
32
- "ckeditor5": "^36.0.0",
33
- "ckeditor5-collaboration": "^36.0.0",
42
+ "@ckeditor/ckeditor5-editor-classic": "^37.0.0-rc.0",
43
+ "@ckeditor/ckeditor5-ui": "^37.0.0-rc.0",
44
+ "@ckeditor/ckeditor5-undo": "^37.0.0-rc.0",
45
+ "ckeditor5": "^37.0.0-rc.0",
46
+ "ckeditor5-collaboration": "^36.0.1",
34
47
  "lodash-es": "^4.17.15",
35
48
  "luxon": "^1.25.0"
36
- }
49
+ },
50
+ "types": "src/index.d.ts",
51
+ "obfuscated": true
37
52
  }
@@ -0,0 +1,25 @@
1
+ import type { RevisionHistoryConfig, RevisionsRepository, RevisionViewerLoadingOverlay, RevisionHistoryUI, RevisionTracker, RevisionViewer, RestoreRevisionCommand, ShowChangeCommand, RevisionsSidebar, RevisionViewerUI } from './index';
2
+ declare module '@ckeditor/ckeditor5-core' {
3
+ interface EditorConfig {
4
+ /**
5
+ * The configuration of the revision history feature.
6
+ * Introduced by the {@link module:revision-history/revisionhistory~RevisionHistory} feature.
7
+ */
8
+ revisionHistory?: RevisionHistoryConfig;
9
+ }
10
+ interface PluginsMap {
11
+ [RevisionsRepository.pluginName]: RevisionsRepository;
12
+ [RevisionViewerLoadingOverlay.pluginName]: RevisionViewerLoadingOverlay;
13
+ [RevisionHistoryUI.pluginName]: RevisionHistoryUI;
14
+ [RevisionTracker.pluginName]: RevisionTracker;
15
+ [RevisionViewer.pluginName]: RevisionViewer;
16
+ [RevisionViewer.pluginName]: RevisionViewer;
17
+ [RevisionsSidebar.pluginName]: RevisionsSidebar;
18
+ [RevisionViewerUI.pluginName]: RevisionViewerUI;
19
+ }
20
+ interface CommandsMap {
21
+ restoreRevision: RestoreRevisionCommand;
22
+ showPreviousChange: ShowChangeCommand<'backward'>;
23
+ showNextChange: ShowChangeCommand<'forward'>;
24
+ }
25
+ }
@@ -0,0 +1,23 @@
1
+ /*
2
+ * Copyright (c) 2016 - 2023, CKSource Holding sp. z o.o. All rights reserved.
3
+ *
4
+ *
5
+ *
6
+ *
7
+ * +---------------------------------------------------------------------------------+
8
+ * | |
9
+ * | Hello stranger! |
10
+ * | |
11
+ * | |
12
+ * | What you're currently looking at is the source code of a legally protected, |
13
+ * | proprietary software. Any attempts to deobfuscate / disassemble this code |
14
+ * | are forbidden and will result in legal consequences. |
15
+ * | |
16
+ * | |
17
+ * +---------------------------------------------------------------------------------+
18
+ *
19
+ *
20
+ *
21
+ *
22
+ */
23
+ export{};
@@ -0,0 +1,52 @@
1
+ /**
2
+ * @module revision-history/changeitem
3
+ */
4
+ import type { User } from 'ckeditor5-collaboration/src/collaboration-core';
5
+ declare const ChangeItem_base: {
6
+ new (): import("ckeditor5/src/utils").Observable;
7
+ prototype: import("ckeditor5/src/utils").Observable;
8
+ };
9
+ /**
10
+ * Represents a singular change entry in the revision or in the revisions comparison.
11
+ */
12
+ export default class ChangeItem extends ChangeItem_base {
13
+ /**
14
+ * Unique change item id.
15
+ */
16
+ readonly id: string;
17
+ /**
18
+ * User who created the change.
19
+ */
20
+ readonly author: User;
21
+ /**
22
+ * Change type.
23
+ */
24
+ readonly type: string;
25
+ /**
26
+ * Additional details about the change.
27
+ */
28
+ readonly data: Record<string, unknown>;
29
+ /**
30
+ * The date when the change was created.
31
+ *
32
+ * @observable
33
+ */
34
+ readonly createdAt: Date;
35
+ constructor(data: ChangeItemInput);
36
+ toJSON(): ChangeItemJSON;
37
+ }
38
+ export interface ChangeItemInput {
39
+ id?: string;
40
+ author: User;
41
+ type: string;
42
+ data: Record<string, unknown>;
43
+ createdAt: Date;
44
+ }
45
+ export interface ChangeItemJSON {
46
+ id: string;
47
+ authorId: string;
48
+ type: string;
49
+ data: Record<string, unknown>;
50
+ createdAt: Date;
51
+ }
52
+ export {};
package/src/changeitem.js CHANGED
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- var _0x1a05=['data','toJSON','set','author','type','createdAt'];(function(_0x17115b,_0x1a057b){var _0x2464a9=function(_0x1602a4){while(--_0x1602a4){_0x17115b['push'](_0x17115b['shift']());}};_0x2464a9(++_0x1a057b);}(_0x1a05,0xc4));var _0x2464=function(_0x17115b,_0x1a057b){_0x17115b=_0x17115b-0x0;var _0x2464a9=_0x1a05[_0x17115b];return _0x2464a9;};import{ObservableMixin as _0x4d5f79,mix as _0x4e0e1e,uid as _0x278fff}from'ckeditor5/src/utils';export default class h{constructor(_0x266422){this['id']=_0x266422['id']||_0x278fff(),this[_0x2464('0x5')]=_0x266422['author'],this[_0x2464('0x0')]=_0x266422['type'],this[_0x2464('0x2')]=_0x266422[_0x2464('0x2')]||{},this[_0x2464('0x4')](_0x2464('0x1'),_0x266422[_0x2464('0x1')]);}[_0x2464('0x3')](){return{'id':this['id'],'authorId':this[_0x2464('0x5')]['id'],'type':this[_0x2464('0x0')],'data':this['data'],'createdAt':this['createdAt']};}}_0x4e0e1e(h,_0x4d5f79);
23
+ var _0x1906=['createdAt','set','data','type','author'];(function(_0x3256f1,_0x190648){var _0x35a335=function(_0x408bed){while(--_0x408bed){_0x3256f1['push'](_0x3256f1['shift']());}};_0x35a335(++_0x190648);}(_0x1906,0x137));var _0x35a3=function(_0x3256f1,_0x190648){_0x3256f1=_0x3256f1-0x0;var _0x35a335=_0x1906[_0x3256f1];return _0x35a335;};import{ObservableMixin as _0x1b91be,uid as _0x1233b6}from'ckeditor5/src/utils';export default class r extends _0x1b91be(){constructor(_0x23d2d0){super(),this['id']=_0x23d2d0['id']||_0x1233b6(),this[_0x35a3('0x3')]=_0x23d2d0[_0x35a3('0x3')],this[_0x35a3('0x2')]=_0x23d2d0[_0x35a3('0x2')],this[_0x35a3('0x1')]=_0x23d2d0[_0x35a3('0x1')]||{},this[_0x35a3('0x0')](_0x35a3('0x4'),_0x23d2d0['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this[_0x35a3('0x3')]['id'],'type':this[_0x35a3('0x2')],'data':this['data'],'createdAt':this[_0x35a3('0x4')]};}}
@@ -0,0 +1,27 @@
1
+ /**
2
+ * @license Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
3
+ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
+ */
5
+ /**
6
+ * @module revision-history/editor/revisionviewereditor
7
+ */
8
+ import { Editor, type EditorConfig } from 'ckeditor5/src/core';
9
+ import RevisionViewerEditorUI from './revisionviewereditorui';
10
+ declare const RevisionViewerEditor_base: import("@ckeditor/ckeditor5-utils").Mixed<import("@ckeditor/ckeditor5-utils").Mixed<typeof Editor, import("ckeditor5/src/core").ElementApi>, import("ckeditor5/src/core").DataApi>;
11
+ /**
12
+ * Editor class used to show revision comparisons.
13
+ */
14
+ export default class RevisionViewerEditor extends RevisionViewerEditor_base {
15
+ get ui(): RevisionViewerEditorUI;
16
+ /**
17
+ * @param sourceElement Editor source element.
18
+ * @param config Editor configuration.
19
+ */
20
+ constructor(sourceElement: HTMLElement, config?: EditorConfig);
21
+ /**
22
+ * @inheritDoc
23
+ */
24
+ destroy(): Promise<unknown>;
25
+ static create(sourceElement: HTMLElement, config?: EditorConfig): Promise<RevisionViewerEditor>;
26
+ }
27
+ export {};
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x4280=['createRoot','initialData','config','locale','create','sourceElement','fire','destroy','init','document','data','editing','get','view','updateSourceElement','model'];(function(_0x415b19,_0x428089){const _0x198d5c=function(_0x5d423b){while(--_0x5d423b){_0x415b19['push'](_0x415b19['shift']());}};_0x198d5c(++_0x428089);}(_0x4280,0x176));const _0x198d=function(_0x415b19,_0x428089){_0x415b19=_0x415b19-0x0;let _0x198d5c=_0x4280[_0x415b19];return _0x198d5c;};import{Editor as _0x4af650,DataApiMixin as _0x50db7d,ElementApiMixin as _0x10d4d9}from'ckeditor5/src/core';import{mix as _0x372817}from'ckeditor5/src/utils';import _0x4dabc6 from'./revisionviewereditorui';import _0x5abd3a from'./revisionviewereditoruiview';export default class m extends _0x4af650{constructor(_0x223435,_0x45e0bc){super(_0x45e0bc),this[_0x198d('0xf')]=_0x223435,this[_0x198d('0x9')][_0x198d('0x3')][_0x198d('0xa')]();const _0x27d2fe=new _0x5abd3a(this[_0x198d('0xd')],this[_0x198d('0x5')][_0x198d('0x7')],{'shouldToolbarGroupWhenFull':!0x0});this['ui']=new _0x4dabc6(this,_0x27d2fe);}[_0x198d('0x1')](){return this[_0x198d('0x8')](),this['ui'][_0x198d('0x1')](),super[_0x198d('0x1')]();}static async[_0x198d('0xe')](_0x288a96,_0x1ac789){const _0x1fe488=new this(_0x288a96,_0x1ac789);return await _0x1fe488['initPlugins'](),await _0x1fe488['ui'][_0x198d('0x2')](_0x288a96),await _0x1fe488[_0x198d('0x4')][_0x198d('0x2')](_0x1fe488[_0x198d('0xc')][_0x198d('0x6')](_0x198d('0xb'))),_0x1fe488[_0x198d('0x0')]('ready'),_0x1fe488;}}_0x372817(m,_0x50db7d),_0x372817(m,_0x10d4d9);
23
+ const _0x3bab=['init','config','view','sourceElement','updateSourceElement','fire','_ui','initialData','destroy','create'];(function(_0x227def,_0x3babcc){const _0x3d59fa=function(_0x4089c5){while(--_0x4089c5){_0x227def['push'](_0x227def['shift']());}};_0x3d59fa(++_0x3babcc);}(_0x3bab,0xf5));const _0x3d59=function(_0x227def,_0x3babcc){_0x227def=_0x227def-0x0;let _0x3d59fa=_0x3bab[_0x227def];return _0x3d59fa;};import{Editor as _0xcd0608,DataApiMixin as _0x4a4ec1,ElementApiMixin as _0x12f569}from'ckeditor5/src/core';import _0x4605be from'./revisionviewereditorui';import _0x3049db from'./revisionviewereditoruiview';export default class d extends _0x4a4ec1(_0x12f569(_0xcd0608)){get['ui'](){return this['_ui'];}constructor(_0xad80ab,_0x2b4fa0){super(_0x2b4fa0),this[_0x3d59('0x8')]=_0xad80ab,this['model']['document']['createRoot']();const _0x2ebc40=new _0x3049db(this['locale'],this['editing'][_0x3d59('0x7')],{'shouldToolbarGroupWhenFull':!0x0});this[_0x3d59('0x1')]=new _0x4605be(this,_0x2ebc40);}[_0x3d59('0x3')](){return this[_0x3d59('0x9')](),this['ui'][_0x3d59('0x3')](),super[_0x3d59('0x3')]();}static async[_0x3d59('0x4')](_0x26873c,_0x392fcb){const _0x41e5a8=new this(_0x26873c,_0x392fcb);return await _0x41e5a8['initPlugins'](),await _0x41e5a8['ui'][_0x3d59('0x5')](_0x26873c),await _0x41e5a8['data'][_0x3d59('0x5')](_0x41e5a8[_0x3d59('0x6')]['get'](_0x3d59('0x2'))),_0x41e5a8[_0x3d59('0x0')]('ready'),_0x41e5a8;}}
@@ -0,0 +1,28 @@
1
+ /**
2
+ * @license Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
3
+ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
+ */
5
+ /**
6
+ * @module revision-history/editor/revisionviewereditorui
7
+ */
8
+ import type { Editor } from 'ckeditor5/src/core';
9
+ import { EditorUI } from 'ckeditor5/src/ui';
10
+ import type RevisionViewerEditorUIView from './revisionviewereditoruiview';
11
+ export default class RevisionViewerEditorUI extends EditorUI {
12
+ get view(): RevisionViewerEditorUIView;
13
+ constructor(editor: Editor, view: RevisionViewerEditorUIView);
14
+ /**
15
+ * @inheritDoc
16
+ */
17
+ get element(): HTMLElement | null;
18
+ /**
19
+ * Initializes the UI.
20
+ *
21
+ * @param replacementElement The DOM element that will be the source for the created editor.
22
+ */
23
+ init(replacementElement: HTMLElement): void;
24
+ /**
25
+ * @inheritDoc
26
+ */
27
+ destroy(): void;
28
+ }
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x29ce=['_initToolbar','stickyPanel','get','viewportOffset','ready','name','replace','config','_elementReplacer','editor','addToolbar','fillFromConfig','bind','getRoot','destroy','init','_toolbarConfig','setEditableElement','toolbar','focusTracker','rootName','componentFactory','attachDomRoot','view','viewportTopOffset','element','limiterElement','editable','restore'];(function(_0x380aa5,_0x29ce22){const _0x4a1085=function(_0x50f7fa){while(--_0x50f7fa){_0x380aa5['push'](_0x380aa5['shift']());}};_0x4a1085(++_0x29ce22);}(_0x29ce,0x72));const _0x4a10=function(_0x380aa5,_0x29ce22){_0x380aa5=_0x380aa5-0x0;let _0x4a1085=_0x29ce[_0x380aa5];return _0x4a1085;};import{EditorUI as _0x20331d,normalizeToolbarConfig as _0x254963}from'ckeditor5/src/ui';import{ElementReplacer as _0xd94cb5}from'ckeditor5/src/utils';export default class rt extends _0x20331d{constructor(_0x3d1a7a,_0x65fcd8){super(_0x3d1a7a),this[_0x4a10('0x19')]=_0x65fcd8,this[_0x4a10('0x12')]=_0x254963(_0x3d1a7a[_0x4a10('0x9')][_0x4a10('0x4')](_0x4a10('0x14'))),this['_elementReplacer']=new _0xd94cb5();}get[_0x4a10('0x1b')](){return this[_0x4a10('0x19')][_0x4a10('0x1b')];}[_0x4a10('0x11')](_0x2db08a){const _0x1fe05d=this[_0x4a10('0xb')],_0x1f4817=this[_0x4a10('0x19')],_0x3ead66=_0x1fe05d['editing'][_0x4a10('0x19')],_0x37b051=_0x1f4817[_0x4a10('0x0')],_0x574242=_0x3ead66['document'][_0x4a10('0xf')]();_0x37b051[_0x4a10('0x7')]=_0x574242[_0x4a10('0x16')],_0x1f4817['render']();const _0x332189=_0x37b051['element'];this[_0x4a10('0x13')](_0x37b051[_0x4a10('0x7')],_0x332189),_0x1f4817[_0x4a10('0x0')][_0x4a10('0xe')]('isFocused')['to'](this[_0x4a10('0x15')]),_0x3ead66[_0x4a10('0x18')](_0x332189),this['_elementReplacer'][_0x4a10('0x8')](_0x2db08a,this[_0x4a10('0x1b')]),this['_initToolbar'](),this['fire'](_0x4a10('0x6'));}[_0x4a10('0x10')](){super[_0x4a10('0x10')]();const _0x3dbbe0=this[_0x4a10('0x19')],_0x25e40d=this[_0x4a10('0xb')]['editing'][_0x4a10('0x19')];this[_0x4a10('0xa')][_0x4a10('0x1')](),_0x25e40d['detachDomRoot'](_0x3dbbe0[_0x4a10('0x0')][_0x4a10('0x7')]),_0x3dbbe0[_0x4a10('0x10')]();}[_0x4a10('0x2')](){const _0x42fcb2=this['view'];_0x42fcb2[_0x4a10('0x3')]['bind']('isActive')['to'](this[_0x4a10('0x15')],'isFocused'),_0x42fcb2[_0x4a10('0x3')][_0x4a10('0x1c')]=_0x42fcb2[_0x4a10('0x1b')],_0x42fcb2[_0x4a10('0x3')][_0x4a10('0xe')](_0x4a10('0x1a'))['to'](this,_0x4a10('0x5'),({top:_0x2d3447})=>_0x2d3447),_0x42fcb2[_0x4a10('0x14')][_0x4a10('0xd')](this[_0x4a10('0x12')],this[_0x4a10('0x17')]),this[_0x4a10('0xc')](_0x42fcb2[_0x4a10('0x14')]);}}
23
+ const _0x4625=['addToolbar','fillFromConfig','init','viewportTopOffset','_initToolbar','render','limiterElement','_toolbarConfig','focusTracker','restore','toolbar','bind','name','rootName','isFocused','isActive','_elementReplacer','_view','ready','attachDomRoot','replace','destroy','getRoot','viewportOffset','componentFactory','editing','editable','element','view','fire','stickyPanel'];(function(_0xf140c0,_0x46251b){const _0x205e15=function(_0x45c340){while(--_0x45c340){_0xf140c0['push'](_0xf140c0['shift']());}};_0x205e15(++_0x46251b);}(_0x4625,0xa3));const _0x205e=function(_0xf140c0,_0x46251b){_0xf140c0=_0xf140c0-0x0;let _0x205e15=_0x4625[_0xf140c0];return _0x205e15;};import{EditorUI as _0x32eaa0,normalizeToolbarConfig as _0x5c753a}from'ckeditor5/src/ui';import{ElementReplacer as _0x514642}from'ckeditor5/src/utils';export default class tt extends _0x32eaa0{get[_0x205e('0x14')](){return this['_view'];}constructor(_0x52d90f,_0x314918){super(_0x52d90f),this[_0x205e('0x9')]=_0x314918,this['_toolbarConfig']=_0x5c753a(_0x52d90f['config']['get']('toolbar')),this[_0x205e('0x8')]=new _0x514642();}get['element'](){return this['view'][_0x205e('0x13')];}[_0x205e('0x19')](_0x1d5eec){const _0x534a48=this['editor'],_0x310108=this[_0x205e('0x14')],_0x57e9ad=_0x534a48[_0x205e('0x11')][_0x205e('0x14')],_0x5ee9fd=_0x310108[_0x205e('0x12')],_0x273e4a=_0x57e9ad['document'][_0x205e('0xe')]();_0x5ee9fd[_0x205e('0x4')]=_0x273e4a[_0x205e('0x5')],_0x310108[_0x205e('0x1c')]();const _0xd7a79a=_0x5ee9fd[_0x205e('0x13')];this['setEditableElement'](_0x5ee9fd[_0x205e('0x4')],_0xd7a79a),_0x310108['editable'][_0x205e('0x3')](_0x205e('0x6'))['to'](this[_0x205e('0x0')]),_0x57e9ad[_0x205e('0xb')](_0xd7a79a),this[_0x205e('0x8')][_0x205e('0xc')](_0x1d5eec,this[_0x205e('0x13')]),this[_0x205e('0x1b')](),this[_0x205e('0x15')](_0x205e('0xa'));}[_0x205e('0xd')](){super[_0x205e('0xd')]();const _0x57f6af=this[_0x205e('0x14')],_0xa08a31=this['editor'][_0x205e('0x11')][_0x205e('0x14')];this[_0x205e('0x8')][_0x205e('0x1')](),_0xa08a31['detachDomRoot'](_0x57f6af['editable']['name']),_0x57f6af['destroy']();}[_0x205e('0x1b')](){const _0x500f48=this['view'];_0x500f48[_0x205e('0x16')]['bind'](_0x205e('0x7'))['to'](this[_0x205e('0x0')],_0x205e('0x6')),_0x500f48['stickyPanel'][_0x205e('0x1d')]=_0x500f48[_0x205e('0x13')],_0x500f48[_0x205e('0x16')][_0x205e('0x3')](_0x205e('0x1a'))['to'](this,_0x205e('0xf'),({top:_0x20a90a})=>_0x20a90a),_0x500f48['toolbar'][_0x205e('0x18')](this[_0x205e('0x1e')],this[_0x205e('0x10')]),this[_0x205e('0x17')](_0x500f48[_0x205e('0x2')]);}}
@@ -0,0 +1,43 @@
1
+ /**
2
+ * @license Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
3
+ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
+ */
5
+ /**
6
+ * @module revision-history/editor/revisionviewereditoruiview
7
+ */
8
+ import { BoxedEditorUIView, InlineEditableUIView, StickyPanelView, ToolbarView } from 'ckeditor5/src/ui';
9
+ import type { View } from 'ckeditor5/src/engine';
10
+ import type { Locale } from 'ckeditor5/src/utils';
11
+ import '@ckeditor/ckeditor5-editor-classic/theme/classiceditor.css';
12
+ export default class RevisionViewerEditorUIView extends BoxedEditorUIView {
13
+ /**
14
+ * Sticky panel view instance. This is a parent view of a {@link #toolbar}
15
+ * that makes toolbar sticky.
16
+ */
17
+ readonly stickyPanel: StickyPanelView;
18
+ /**
19
+ * Toolbar view instance.
20
+ */
21
+ readonly toolbar: ToolbarView;
22
+ get editable(): InlineEditableUIView;
23
+ /**
24
+ * Creates an instance of the classic editor UI view.
25
+ *
26
+ * @param locale The {@link module:core/editor/editor~Editor#locale} instance.
27
+ * @param editingView The editing view instance this view is related to.
28
+ * @param options Configuration options for the view instance.
29
+ */
30
+ constructor(locale: Locale, editingView: View, options?: RevisionViewerEditorUIViewOptions);
31
+ /**
32
+ * @inheritDoc
33
+ */
34
+ render(): void;
35
+ }
36
+ export interface RevisionViewerEditorUIViewOptions {
37
+ /**
38
+ * When set `true` enables automatic items grouping
39
+ * in the main {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#toolbar toolbar}.
40
+ * See {@link module:ui/toolbar/toolbarview~ToolbarOptions#shouldGroupWhenFull} to learn more.
41
+ */
42
+ shouldToolbarGroupWhenFull?: boolean;
43
+ }
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- var _0x2881=['stickyPanel','add','main','toolbar','render','shouldToolbarGroupWhenFull','editable'];(function(_0x230a9d,_0x28812b){var _0x1d5254=function(_0x44d323){while(--_0x44d323){_0x230a9d['push'](_0x230a9d['shift']());}};_0x1d5254(++_0x28812b);}(_0x2881,0xf7));var _0x1d52=function(_0x230a9d,_0x28812b){_0x230a9d=_0x230a9d-0x0;var _0x1d5254=_0x2881[_0x230a9d];return _0x1d5254;};import{BoxedEditorUIView as _0x1b18c1,InlineEditableUIView as _0x11d930,StickyPanelView as _0x326940,ToolbarView as _0x12f37d}from'ckeditor5/src/ui';import'@ckeditor/ckeditor5-editor-classic/theme/classiceditor.css';export default class et extends _0x1b18c1{constructor(_0xfa1fe5,_0x3743ec,_0x16ef82={}){super(_0xfa1fe5),this['stickyPanel']=new _0x326940(_0xfa1fe5),this['toolbar']=new _0x12f37d(_0xfa1fe5,{'shouldGroupWhenFull':_0x16ef82[_0x1d52('0x3')]}),this['editable']=new _0x11d930(_0xfa1fe5,_0x3743ec);}[_0x1d52('0x2')](){super[_0x1d52('0x2')](),this[_0x1d52('0x5')]['content']['add'](this[_0x1d52('0x1')]),this['top'][_0x1d52('0x6')](this[_0x1d52('0x5')]),this[_0x1d52('0x0')][_0x1d52('0x6')](this[_0x1d52('0x4')]);}}
23
+ var _0x4e95=['_editable','editable','add','shouldToolbarGroupWhenFull','main','stickyPanel','toolbar','top','render','content'];(function(_0x20e9dd,_0x4e9556){var _0x221e1a=function(_0x1a39d7){while(--_0x1a39d7){_0x20e9dd['push'](_0x20e9dd['shift']());}};_0x221e1a(++_0x4e9556);}(_0x4e95,0xee));var _0x221e=function(_0x20e9dd,_0x4e9556){_0x20e9dd=_0x20e9dd-0x0;var _0x221e1a=_0x4e95[_0x20e9dd];return _0x221e1a;};import{BoxedEditorUIView as _0x2049ab,InlineEditableUIView as _0x1809bd,StickyPanelView as _0x215dfd,ToolbarView as _0x385fbd}from'ckeditor5/src/ui';import'@ckeditor/ckeditor5-editor-classic/theme/classiceditor.css';export default class it extends _0x2049ab{get[_0x221e('0x3')](){return this[_0x221e('0x2')];}constructor(_0x4e59f5,_0x123a82,_0x3f0d1f={}){super(_0x4e59f5),this[_0x221e('0x7')]=new _0x215dfd(_0x4e59f5),this['toolbar']=new _0x385fbd(_0x4e59f5,{'shouldGroupWhenFull':_0x3f0d1f[_0x221e('0x5')]}),this[_0x221e('0x2')]=new _0x1809bd(_0x4e59f5,_0x123a82);}[_0x221e('0x0')](){super[_0x221e('0x0')](),this[_0x221e('0x7')][_0x221e('0x1')]['add'](this[_0x221e('0x8')]),this[_0x221e('0x9')][_0x221e('0x4')](this[_0x221e('0x7')]),this[_0x221e('0x6')]['add'](this[_0x221e('0x3')]);}}
package/src/index.d.ts ADDED
@@ -0,0 +1,10 @@
1
+ export { default as RevisionHistory } from './revisionhistory';
2
+ export { default as RevisionsRepository } from './revisionsrepository';
3
+ export { default as RevisionViewerLoadingOverlay } from './ui/revisionviewer/revisionviewerloadingoverlay';
4
+ export { default as RevisionHistoryUI } from './ui/revisionhistory/revisionhistoryui';
5
+ export { default as RevisionTracker } from './revisiontracker';
6
+ export { default as RevisionViewer, type RestoreRevisionCommand, type ShowChangeCommand } from './revisionviewer';
7
+ export { default as RevisionsSidebar } from './ui/revisionssidebar/revisionssidebar';
8
+ export { default as RevisionViewerUI } from './ui/revisionviewer/revisionviewerui';
9
+ export type { RevisionHistoryConfig } from './revisionhistoryconfig';
10
+ import './augmentation';
package/src/index.js CHANGED
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- export{default as RevisionHistory}from'./revisionhistory';export{default as RevisionTracker}from'./revisiontracker';
23
+ export{default as RevisionHistory}from'./revisionhistory';export{default as RevisionsRepository}from'./revisionsrepository';export{default as RevisionViewerLoadingOverlay}from'./ui/revisionviewer/revisionviewerloadingoverlay';export{default as RevisionHistoryUI}from'./ui/revisionhistory/revisionhistoryui';export{default as RevisionTracker}from'./revisiontracker';export{default as RevisionViewer}from'./revisionviewer';export{default as RevisionsSidebar}from'./ui/revisionssidebar/revisionssidebar';export{default as RevisionViewerUI}from'./ui/revisionviewer/revisionviewerui';import'./augmentation';
@@ -0,0 +1,153 @@
1
+ /**
2
+ * @module revision-history/revision
3
+ * @publicApi
4
+ */
5
+ import type { User } from 'ckeditor5-collaboration/src/collaboration-core';
6
+ declare const Revision_base: {
7
+ new (): import("ckeditor5/src/utils").Observable;
8
+ prototype: import("ckeditor5/src/utils").Observable;
9
+ };
10
+ /**
11
+ * Represents a revision.
12
+ */
13
+ export default class Revision extends Revision_base {
14
+ /**
15
+ * Unique revision id.
16
+ */
17
+ id: string;
18
+ /**
19
+ * The user who created the revision.
20
+ *
21
+ * The `null` value means the revision was created automatically.
22
+ */
23
+ creator: User | null;
24
+ /**
25
+ * All users who contributed to this revision.
26
+ *
27
+ * This value can be empty if there are no changes in the revision.
28
+ */
29
+ authors: Array<User>;
30
+ /**
31
+ * Contains data describing changes saved in this revision.
32
+ *
33
+ * An object, where the keys are the names of roots and the values are strings with the revision data for those roots.
34
+ */
35
+ diffData: any;
36
+ /**
37
+ * Document version at which the revision ends.
38
+ *
39
+ * The revision includes changes introduced by {@link module:engine/model/operation/operation~Operation operations}
40
+ * with base versions starting from {@link module:revision-history/revision~Revision#fromVersion `fromVersion`} (inclusive) up to
41
+ * {@link module:revision-history/revision~Revision#toVersion `toVersion`} (exclusive).
42
+ */
43
+ toVersion: number;
44
+ /**
45
+ * Document version from which the revision starts.
46
+ *
47
+ * The revision includes changes introduced by {@link module:engine/model/operation/operation~Operation operations}
48
+ * with base versions starting from {@link module:revision-history/revision~Revision#fromVersion `fromVersion`} (inclusive) up to
49
+ * {@link module:revision-history/revision~Revision#toVersion `toVersion`} (exclusive).
50
+ */
51
+ fromVersion: number;
52
+ /**
53
+ * The revision name.
54
+ *
55
+ * If revision has not been named yet, this is an empty string.
56
+ *
57
+ * @observable
58
+ */
59
+ name: string;
60
+ /**
61
+ * The date when the revision was created or most recently updated.
62
+ *
63
+ * @observable
64
+ */
65
+ createdAt: Date;
66
+ /**
67
+ * Revision custom attributes. See also {@link #setAttribute} and {@link #removeAttribute}.
68
+ *
69
+ * @observable
70
+ */
71
+ attributes: Record<string, unknown>;
72
+ constructor(data: RevisionData);
73
+ /**
74
+ * Sets the revision name.
75
+ */
76
+ setName(name: string): void;
77
+ /**
78
+ * Adds revision attribute.
79
+ *
80
+ * Revision attributes are custom data that can be set and used by features built around revisions.
81
+ * Use it to store your feature data together with other revision data.
82
+ *
83
+ * ```ts
84
+ * revision.setAttribute( 'isImportant', true );
85
+ * ```
86
+ *
87
+ * You can group multiple values in an object, using the dot notation:
88
+ *
89
+ * ```ts
90
+ * revision.setAttribute( 'customData.type', 'image' );
91
+ * revision.setAttribute( 'customData.src', 'foo.jpg' );
92
+ * ```
93
+ *
94
+ * The attributes set on the revision can be accessed through the `attribute` property:
95
+ *
96
+ * ```ts
97
+ * const isImportant = revision.attributes.isImportant;
98
+ * const type = revision.attributes.customData.type;
99
+ * ```
100
+ *
101
+ * You can also observe the `attributes` property or bind other properties to it:
102
+ *
103
+ * ```ts
104
+ * myObj.bind( 'customData' ).to( revision, 'attributes', attributes => attributes.customData );
105
+ * revision.on( 'change:attributes', ( evt, propName, newValue, oldValue ) => { ... } );
106
+ * ```
107
+ *
108
+ * Whenever `setAttribute()` or `removeAttribute()` is called, the `attributes` property
109
+ * is re-set and the observables are refreshed.
110
+ */
111
+ setAttribute(name: string, value: unknown): void;
112
+ /**
113
+ * Removes the revision attribute.
114
+ *
115
+ * See also {@link #setAttribute}
116
+ */
117
+ removeAttribute(name: string): void;
118
+ toJSON(): RevisionJSON;
119
+ }
120
+ /**
121
+ * @eventName _update
122
+ */
123
+ export interface RevisionUpdateEvent {
124
+ name: '_update';
125
+ args: [RevisionJSON, boolean];
126
+ }
127
+ export interface RevisionJSON {
128
+ id: string;
129
+ name: string;
130
+ creatorId: string | null;
131
+ authorsIds: Array<string>;
132
+ diffData: any;
133
+ createdAt: Date;
134
+ attributes: Record<string, unknown>;
135
+ fromVersion: number;
136
+ toVersion: number;
137
+ }
138
+ export interface RevisionData {
139
+ id?: string;
140
+ name?: string | null;
141
+ creator?: User | null;
142
+ creatorId?: string | null;
143
+ authors?: Array<User>;
144
+ authorsIds?: Array<string>;
145
+ diffData?: any;
146
+ data?: any;
147
+ createdAt?: Date;
148
+ attributes?: Record<string, unknown>;
149
+ fromVersion?: number;
150
+ toVersion?: number;
151
+ isEmptyCurrent?: boolean;
152
+ }
153
+ export {};
package/src/revision.js CHANGED
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x22f9=['toVersion','map','removeAttribute','set','diffData','creatorId','name','attributes','fire','setName','authors','authorsIds','_update','createdAt','fromVersion','creator'];(function(_0x2b7d6a,_0x22f972){const _0x263dce=function(_0x3b9283){while(--_0x3b9283){_0x2b7d6a['push'](_0x2b7d6a['shift']());}};_0x263dce(++_0x22f972);}(_0x22f9,0x11a));const _0x263d=function(_0x2b7d6a,_0x22f972){_0x2b7d6a=_0x2b7d6a-0x0;let _0x263dce=_0x22f9[_0x2b7d6a];return _0x263dce;};import{ObservableMixin as _0x49899c,mix as _0x3faeec,uid as _0x423c34}from'ckeditor5/src/utils';import{cloneDeep as _0x2a3705,set as _0x478557,unset as _0x23bc5c}from'lodash-es';export default class n{constructor(_0x50c039){this['id']=_0x50c039['id']||_0x423c34(),this['set'](_0x263d('0xc'),_0x50c039[_0x263d('0xc')]||''),this[_0x263d('0x5')]=_0x50c039['creator']||null,this[_0x263d('0x0')]=_0x50c039['authors']||[],this['set'](_0x263d('0x3'),_0x50c039[_0x263d('0x3')]||new Date()),this[_0x263d('0xa')]=_0x50c039[_0x263d('0xa')]||null,this[_0x263d('0x9')](_0x263d('0xd'),_0x50c039['attributes']||{}),this[_0x263d('0x6')]=_0x50c039['toVersion']||0x0,this[_0x263d('0x4')]=_0x50c039[_0x263d('0x4')]||0x0;}[_0x263d('0xf')](_0x124aca){this['_update']({'name':_0x124aca});}['setAttribute'](_0x9e5ee1,_0x445081){const _0x2dfe83=_0x2a3705(this[_0x263d('0xd')]);_0x478557(_0x2dfe83,_0x9e5ee1,_0x445081),this[_0x263d('0x2')]({'attributes':_0x2dfe83});}[_0x263d('0x8')](_0x3eedc8){const _0x1fc279=_0x2a3705(this[_0x263d('0xd')]);_0x23bc5c(_0x1fc279,_0x3eedc8),this[_0x263d('0x2')]({'attributes':_0x1fc279});}['_update'](_0x4b977f,_0x5ebba2=!0x1){let _0x14e1cd=!0x1;const _0x16f272={'id':this['id']};for(const _0x72c50a of[_0x263d('0xc'),_0x263d('0x3'),_0x263d('0xa'),_0x263d('0x0'),_0x263d('0xd'),_0x263d('0x6'),_0x263d('0x4'),_0x263d('0xb')]){const _0x36fa1f=_0x4b977f[_0x72c50a];void 0x0!==_0x36fa1f&&_0x36fa1f!==this[_0x72c50a]&&(this[_0x72c50a]=_0x36fa1f,_0x16f272[_0x72c50a]=_0x36fa1f,_0x14e1cd=!0x0);}_0x14e1cd&&(_0x16f272[_0x263d('0x0')]&&(_0x16f272[_0x263d('0x1')]=_0x16f272[_0x263d('0x0')][_0x263d('0x7')](_0x4b6ec5=>_0x4b6ec5['id']),delete _0x16f272[_0x263d('0x0')]),this[_0x263d('0xe')](_0x263d('0x2'),_0x16f272,_0x5ebba2));}['toJSON'](){return{'id':this['id'],'name':this[_0x263d('0xc')],'creatorId':this['creator']?this[_0x263d('0x5')]['id']:null,'authorsIds':this[_0x263d('0x0')][_0x263d('0x7')](_0x5ab669=>_0x5ab669['id']),'diffData':this[_0x263d('0xa')],'createdAt':this[_0x263d('0x3')],'attributes':this['attributes'],'fromVersion':this[_0x263d('0x4')],'toVersion':this[_0x263d('0x6')]};}}_0x3faeec(n,_0x49899c);
23
+ const _0x342b=['creatorId','creator','attributes','map','authorsIds','createdAt','fromVersion','name','_update','toVersion','setAttribute','diffData','toJSON','authors','setName','removeAttribute'];(function(_0x371fd1,_0x342bf2){const _0x1604fd=function(_0x1bb579){while(--_0x1bb579){_0x371fd1['push'](_0x371fd1['shift']());}};_0x1604fd(++_0x342bf2);}(_0x342b,0x14b));const _0x1604=function(_0x371fd1,_0x342bf2){_0x371fd1=_0x371fd1-0x0;let _0x1604fd=_0x342b[_0x371fd1];return _0x1604fd;};import{ObservableMixin as _0x3ce2e4,uid as _0x4d5cd2}from'ckeditor5/src/utils';import{cloneDeep as _0x275990,set as _0x3ca8ad,unset as _0x3a4636}from'lodash-es';export default class a extends _0x3ce2e4(){constructor(_0x8b5741){super(),this['id']=_0x8b5741['id']||_0x4d5cd2(),this[_0x1604('0x6')]=_0x8b5741[_0x1604('0x6')]||null,this[_0x1604('0x2')]=_0x8b5741[_0x1604('0x2')]||[],this[_0x1604('0x0')]=_0x8b5741[_0x1604('0x0')]||null,this[_0x1604('0xe')]=_0x8b5741[_0x1604('0xe')]||0x0,this[_0x1604('0xb')]=_0x8b5741[_0x1604('0xb')]||0x0,this['set'](_0x1604('0xc'),_0x8b5741[_0x1604('0xc')]||''),this['set'](_0x1604('0xa'),_0x8b5741[_0x1604('0xa')]||new Date()),this['set'](_0x1604('0x7'),_0x8b5741[_0x1604('0x7')]||{});}[_0x1604('0x3')](_0x449839){this[_0x1604('0xd')]({'name':_0x449839});}[_0x1604('0xf')](_0x55ccac,_0x16543b){const _0x110470=_0x275990(this[_0x1604('0x7')]);_0x3ca8ad(_0x110470,_0x55ccac,_0x16543b),this[_0x1604('0xd')]({'attributes':_0x110470});}[_0x1604('0x4')](_0x259970){const _0x365d3a=_0x275990(this['attributes']);_0x3a4636(_0x365d3a,_0x259970),this[_0x1604('0xd')]({'attributes':_0x365d3a});}[_0x1604('0xd')](_0x10649b,_0x3036d5=!0x1){let _0x2e2120=!0x1;const _0x7c2e60={'id':this['id']},_0x55a79b=['name',_0x1604('0xa'),_0x1604('0x0'),_0x1604('0x2'),_0x1604('0x7'),_0x1604('0xe'),'fromVersion',_0x1604('0x5')];for(const _0x199a6d of _0x55a79b){const _0xd95713=_0x10649b[_0x199a6d];void 0x0!==_0xd95713&&_0xd95713!==this[_0x199a6d]&&(this[_0x199a6d]=_0xd95713,_0x7c2e60[_0x199a6d]=_0xd95713,_0x2e2120=!0x0);}_0x2e2120&&(_0x7c2e60[_0x1604('0x2')]&&(_0x7c2e60[_0x1604('0x9')]=_0x7c2e60[_0x1604('0x2')][_0x1604('0x8')](_0x5a6968=>_0x5a6968['id']),delete _0x7c2e60[_0x1604('0x2')]),this['fire'](_0x1604('0xd'),_0x7c2e60,_0x3036d5));}[_0x1604('0x1')](){return{'id':this['id'],'name':this[_0x1604('0xc')],'creatorId':this[_0x1604('0x6')]?this[_0x1604('0x6')]['id']:null,'authorsIds':this[_0x1604('0x2')][_0x1604('0x8')](_0x1e2a9e=>_0x1e2a9e['id']),'diffData':this['diffData'],'createdAt':this[_0x1604('0xa')],'attributes':this[_0x1604('0x7')],'fromVersion':this[_0x1604('0xb')],'toVersion':this['toVersion']};}}
@@ -0,0 +1,19 @@
1
+ /**
2
+ * @module revision-history/revisiondiff
3
+ */
4
+ import { Collection } from 'ckeditor5/src/utils';
5
+ import type { DocumentFragment } from 'ckeditor5/src/engine';
6
+ import type ChangeItem from './changeitem';
7
+ /**
8
+ * Represents a difference between two document revisions.
9
+ */
10
+ export default class RevisionDiff {
11
+ readonly newRevisionId: string;
12
+ readonly oldRevisionId: string;
13
+ readonly changes: Collection<ChangeItem>;
14
+ constructor(newRevisionId: string, oldRevisionId: string);
15
+ }
16
+ export interface DiffData {
17
+ model: Record<string, DocumentFragment>;
18
+ changes: Array<ChangeItem>;
19
+ }
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- const _0x3355=['oldRevisionId','_setData','add','changes','newRevisionId'];(function(_0x22c079,_0x33553d){const _0xa19dff=function(_0x271b81){while(--_0x271b81){_0x22c079['push'](_0x22c079['shift']());}};_0xa19dff(++_0x33553d);}(_0x3355,0xf6));const _0xa19d=function(_0x22c079,_0x33553d){_0x22c079=_0x22c079-0x0;let _0xa19dff=_0x3355[_0x22c079];return _0xa19dff;};import{Collection as _0x44880c}from'ckeditor5/src/utils';export default class f{constructor(_0x4630c9,_0x3408c3){this[_0xa19d('0x3')]=_0x4630c9,this[_0xa19d('0x4')]=_0x3408c3,this[_0xa19d('0x2')]=new _0x44880c();}[_0xa19d('0x0')](_0x57daab){for(const _0x452c45 of _0x57daab[_0xa19d('0x2')])this[_0xa19d('0x2')][_0xa19d('0x1')](_0x452c45);}}
23
+ const _0x1805=['add','_setData','changes','newRevisionId'];(function(_0x4e3fe8,_0x18053f){const _0x2de4a0=function(_0x4718b4){while(--_0x4718b4){_0x4e3fe8['push'](_0x4e3fe8['shift']());}};_0x2de4a0(++_0x18053f);}(_0x1805,0x1ad));const _0x2de4=function(_0x4e3fe8,_0x18053f){_0x4e3fe8=_0x4e3fe8-0x0;let _0x2de4a0=_0x1805[_0x4e3fe8];return _0x2de4a0;};import{Collection as _0x379c72}from'ckeditor5/src/utils';export default class f{constructor(_0x4c6f45,_0x3ff7cf){this[_0x2de4('0x2')]=_0x4c6f45,this['oldRevisionId']=_0x3ff7cf,this[_0x2de4('0x1')]=new _0x379c72();}[_0x2de4('0x0')](_0x2ca1ed){for(const _0x38d5f0 of _0x2ca1ed[_0x2de4('0x1')])this['changes'][_0x2de4('0x3')](_0x38d5f0);}}