@ckeditor/ckeditor5-revision-history 36.0.1 → 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.
- package/build/revision-history.js +1 -1
- package/package.json +22 -7
- package/src/augmentation.d.ts +25 -0
- package/src/augmentation.js +23 -0
- package/src/changeitem.d.ts +52 -0
- package/src/changeitem.js +1 -1
- package/src/editor/revisionviewereditor.d.ts +27 -0
- package/src/editor/revisionviewereditor.js +1 -1
- package/src/editor/revisionviewereditorui.d.ts +28 -0
- package/src/editor/revisionviewereditorui.js +1 -1
- package/src/editor/revisionviewereditoruiview.d.ts +43 -0
- package/src/editor/revisionviewereditoruiview.js +1 -1
- package/src/index.d.ts +10 -0
- package/src/index.js +1 -1
- package/src/revision.d.ts +153 -0
- package/src/revision.js +1 -1
- package/src/revisiondiff.d.ts +19 -0
- package/src/revisiondiff.js +1 -1
- package/src/revisionhistory.d.ts +93 -0
- package/src/revisionhistory.js +1 -1
- package/src/revisionhistoryadapter.d.ts +60 -0
- package/src/revisionhistoryadapter.js +23 -0
- package/src/revisionhistoryconfig.d.ts +60 -0
- package/src/revisionhistoryconfig.js +23 -0
- package/src/revisionsrepository.d.ts +43 -0
- package/src/revisionsrepository.js +1 -1
- package/src/revisiontracker.d.ts +72 -0
- package/src/revisiontracker.js +1 -1
- package/src/revisionviewer.d.ts +21 -0
- package/src/revisionviewer.js +1 -1
- package/src/ui/revision/createrevisionactionsdropdown.d.ts +9 -0
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.d.ts +4 -0
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.d.ts +4 -0
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.d.ts +91 -0
- package/src/ui/revision/revisionview.js +1 -1
- package/src/ui/revision/subrevisioncollapserview.d.ts +17 -0
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.d.ts +30 -0
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revision/utils.d.ts +4 -0
- package/src/ui/revision/utils.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.d.ts +80 -0
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
- package/src/ui/revisionhistory/revisionhistoryui.d.ts +21 -0
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.d.ts +39 -0
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.d.ts +4 -0
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.d.ts +25 -0
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.d.ts +40 -0
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/revisionssidebar/utils.d.ts +8 -0
- package/src/ui/revisionssidebar/utils.js +1 -1
- package/src/ui/revisionviewer/changedetailsview.d.ts +18 -0
- package/src/ui/revisionviewer/changedetailsview.js +1 -1
- package/src/ui/revisionviewer/changesnavigationview.d.ts +36 -0
- package/src/ui/revisionviewer/changesnavigationview.js +1 -1
- package/src/ui/revisionviewer/revisionviewerloadingoverlay.d.ts +22 -0
- package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
- package/src/ui/revisionviewer/revisionviewerui.d.ts +22 -0
- package/src/ui/revisionviewer/revisionviewerui.js +1 -1
- package/src/utils/common-translations.d.ts +7 -0
- package/src/utils/common-translations.js +1 -1
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import { Plugin, type PluginDependencies, type Editor } from 'ckeditor5/src/core';
|
|
2
|
+
import RevisionsRepository from './revisionsrepository';
|
|
3
|
+
import type { RevisionHistoryAdapter } from './revisionhistoryadapter';
|
|
4
|
+
import type { default as Revision, RevisionData } from './revision';
|
|
5
|
+
/**
|
|
6
|
+
* Creates and updates revisions based on changes of the editor content.
|
|
7
|
+
*
|
|
8
|
+
* There are always at least two revisions available for the document: the initial revision and the current revision.
|
|
9
|
+
* If those revisions have not been created for the document yet, they are created when the editor data is loaded.
|
|
10
|
+
*
|
|
11
|
+
* The initial revision contains the initial document data from when the document was loaded for the first time.
|
|
12
|
+
*
|
|
13
|
+
* The current revision contains all the unsaved document changes, that is changes which have not been saved yet as a specific revision.
|
|
14
|
+
* The current revision is always available and it is always the "top" revision (most recent).
|
|
15
|
+
*/
|
|
16
|
+
export default class RevisionTracker extends Plugin {
|
|
17
|
+
/**
|
|
18
|
+
* An adapter object that should communicate with the data source to fetch or save the revisions data.
|
|
19
|
+
*
|
|
20
|
+
* This property is also set through {@link module:revision-history/revisionhistory~RevisionHistory#adapter}.
|
|
21
|
+
*/
|
|
22
|
+
adapter: RevisionHistoryAdapter | null;
|
|
23
|
+
repository?: RevisionsRepository;
|
|
24
|
+
static get pluginName(): 'RevisionTracker';
|
|
25
|
+
static get requires(): PluginDependencies;
|
|
26
|
+
constructor(editor: Editor);
|
|
27
|
+
/**
|
|
28
|
+
* @inheritDoc
|
|
29
|
+
*/
|
|
30
|
+
init(): void;
|
|
31
|
+
afterInit(): Promise<void>;
|
|
32
|
+
/**
|
|
33
|
+
* Adds the new document changes to the current revision.
|
|
34
|
+
*
|
|
35
|
+
* This method should be called before document data and revision data is saved (for example, in the autosave callback).
|
|
36
|
+
*
|
|
37
|
+
* @returns Promise that is resolved after the revision is updated locally (the promise does not wait for the adapter update).
|
|
38
|
+
*/
|
|
39
|
+
update(): Promise<void>;
|
|
40
|
+
private _loadState;
|
|
41
|
+
/**
|
|
42
|
+
* Creates and saves a new revision.
|
|
43
|
+
*
|
|
44
|
+
* ```ts
|
|
45
|
+
* // Saves all the unsaved changes as a revision without a name.
|
|
46
|
+
* const myRevision = await revisionTracker.saveRevision();
|
|
47
|
+
*
|
|
48
|
+
* // Saves all the unsaved changes as a revision named 'My revision'.
|
|
49
|
+
* const myRevision = await revisionTracker.saveRevision( { name: 'My revision' } );
|
|
50
|
+
*
|
|
51
|
+
* // Saves a revision named 'My revision'.
|
|
52
|
+
* // It will include document data with all the changes up to document version `30`.
|
|
53
|
+
* // The revision will be on "top" of the closest revision with a lower document version.
|
|
54
|
+
* // The revision diff will include all the changes since the previous revision up to document version `30`.
|
|
55
|
+
* const myRevision = await revisionTracker.saveRevision( { name: 'My revision' }, 30 );
|
|
56
|
+
* ```
|
|
57
|
+
*
|
|
58
|
+
* A new revision can be created in the middle of the revision history. In such case, already existing revisions will be
|
|
59
|
+
* appropriately updated.
|
|
60
|
+
*
|
|
61
|
+
* @param revisionData Revision data to set on the created revision.
|
|
62
|
+
* @param version {@link module:engine/model/document~Document#version Document version} on which the revision is saved.
|
|
63
|
+
* If not set, the revision will be saved for the current (most recent) document state.
|
|
64
|
+
* @returns Promise that resolves with the created revision after it is saved locally (the promise does not wait for the
|
|
65
|
+
* adapter update).
|
|
66
|
+
*/
|
|
67
|
+
saveRevision(revisionData?: RevisionData, version?: number | null): Promise<Revision>;
|
|
68
|
+
/**
|
|
69
|
+
* Creates a revision basing on given revision data and adds it to the revision tracker and revision repository.
|
|
70
|
+
*/
|
|
71
|
+
addRevisionData(revisionData: RevisionData): Revision;
|
|
72
|
+
}
|
package/src/revisiontracker.js
CHANGED
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
const _0x450b=['RevisionsRepository','editor','_removeRevisionMarkers','clear','_startingRevisionId','bind','revision-end','addRevision','saveRevision','_getState','attributes','forEach','parse','merge','createRevision','revision:','_getBaseVids','item','_saveMetaData','get','_touched','_pendingAction','conversion','repository','_savedMetaData','update','createPositionFromPath','toView','_loadRevisionData','_handleMergeOperation','keys','affectsData','_prepareViewToSave','set','_getPreviousFrom','processor','insertionPosition','getChild','reverse','reinsert','path','useFillerType','sort','addRevisionData','_createFromRanges','version','marker','history','offsetSize','elementStart','_copyMarkers','values','_revisionDataBuilder','_handleMarkerOperation','_fixPosition','has','Users','PendingActions','getOperation','loadState','insertion','splitPosition','_isPendingUpdate','remove','length','_markers','pluginName','_calculateMetaData','_lastFrom','targetPosition','from','add','define','_touchedMarkers','position','plugins','parent','deletion','buildRevisionData','createPositionBefore','root','range','isEnabled','oldRange','deletions','max','isEqual','upcast','toVersion','stickiness','rootName','_removePendingAction','getRevisions','adapter','element','vid_start','init','start','_authorId','_setConversion','_execute','locale','_idsRoots','nodes','_cloneOperation','revisionHistory.resumeUnsavedRevision','getChildren','createPositionAt','offset','_createCurrentRevision','split','_initialRevisionId','_markChanges','_makeRevision','currentRevision','view','tableCell','_reset','vid','_generateTape','authors','_replaceEditorDataWithRevisionData','_addPendingAction','insertions','collaboration.channelId','_startingVersion','getRevision','trim','_source','documentFragment','_operations','creator','newRange','getData','default','then','sendBufferedUpdates','initialData','getRevisionDocumentData','end','insert','revision','createdAt','getLatestVersion','_removeMetaData','_handleOperation','stringify','_makeModelFromViewString','getTransformedByOperation','getAncestors','elementEnd','_handleSplitOperation','data','push','fromVersion','initial','_bufferUpdate','type','RevisionTracker','slice','editing','graveyardPosition','getCurrentRevisionId','previousPosition','_getVidAttributeName','string','$graveyard','_update','text','hasContent','markerToData','getUser','for','config','vid_end','children','_clone','_createInitialRevision','_revisionId','getAttribute','size','_continueCurrentRevision','_loadedStateData','keepParagraph','nodeAfter','_diffRoots','updateRevisions','source','_bufferedUpdates','find','getRootNames','toModel','move','data-revision-','document','createRangeIn','$text','ready','_loadState','startsWith','_fixOperation','getNodeByPath','afterInit','toData','_lastTo','resolve','map','sourcePosition','_fixRange','_rootNames','getTime','model','reInit','diffData','baseVersion','_findInsertionIndex','_handleMoveOperation','authorsIds','filter','howMany','_transformMarkers','_setAttribute','_baseRoots','getWalker','_processRootBeforeSave','markers','setRevisionData','getAttributes','childCount','_applyOperations','NEGATIVE_INFINITY','creatorId','_handleInsertOperation','userId','isReady','RealTimeCollaborationClient','_baseIdsRoots','_getViewJson','_getFromVersion','name','roots','_makeIdsRoot','delete','createRange','clone'];(function(_0x4bcc33,_0x450b7e){const _0x5c6d95=function(_0x27b188){while(--_0x27b188){_0x4bcc33['push'](_0x4bcc33['shift']());}};_0x5c6d95(++_0x450b7e);}(_0x450b,0x1a2));const _0x5c6d=function(_0x4bcc33,_0x450b7e){_0x4bcc33=_0x4bcc33-0x0;let _0x5c6d95=_0x450b[_0x4bcc33];return _0x5c6d95;};import{Users as _0x110f5e}from'ckeditor5-collaboration/src/collaboration-core';import{Plugin as _0x881c2f,PendingActions as _0x1cb1d5}from'ckeditor5/src/core';import{logWarning as _0x1ebf2e,uid as _0x187adc}from'ckeditor5/src/utils';import{Position as _0x302755,Range as _0x4bafe2,Element as _0x32778a,DocumentFragment as _0x5c8a1f,ViewText as _0xfc94e1,ViewElement as _0xa5b306,ViewContainerElement as _0x1a386b,ViewAttributeElement as _0x243804,ViewEmptyElement as _0xf4c31b,ViewRawElement as _0x1c1300,ViewUIElement as _0x49ced0,ViewDocumentFragment as _0x4ceba3}from'ckeditor5/src/engine';import _0x1ecbb8 from'./revisionsrepository';import{getTranslation as _0x2e38bf}from'./utils/common-translations';const V={'c':_0x1a386b,'a':_0x243804,'e':_0xf4c31b,'r':_0x1c1300,'u':_0x49ced0};export default class l extends _0x881c2f{static get[_0x5c6d('0x8a')](){return _0x5c6d('0xe6');}static get['requires'](){return[_0x110f5e,_0x1ecbb8,_0x1cb1d5];}constructor(..._0x4fd498){super(..._0x4fd498),this[_0x5c6d('0xa5')]=null,this['set'](_0x5c6d('0x3d'),!0x1),this[_0x5c6d('0x69')](_0x5c6d('0x9a'),!0x0),this[_0x5c6d('0xba')]=null;const _0x533961=_0x187adc();this[_0x5c6d('0xc8')]={'history':this[_0x5c6d('0x49')][_0x5c6d('0x26')][_0x5c6d('0x15')][_0x5c6d('0x77')],'getLatestVersion':()=>Promise['resolve'](this[_0x5c6d('0x49')][_0x5c6d('0x26')][_0x5c6d('0x15')][_0x5c6d('0x75')]),'getCurrentRevisionId':()=>_0x533961},this['_revisionDataBuilder']=new T(this[_0x5c6d('0x49')]),this[_0x5c6d('0xb7')]=this['editor']['config'][_0x5c6d('0x5b')](_0x5c6d('0xc4'))||_0x5c6d('0xe3'),this[_0x5c6d('0x69')]('isPendingUpdate',!0x1),this[_0x5c6d('0xf')]=new Map(),this[_0x5c6d('0x49')]['config'][_0x5c6d('0x90')](_0x5c6d('0xb1'),!0x0),this[_0x5c6d('0x9')]=null,this[_0x5c6d('0x49')][_0x5c6d('0x5e')][_0x5c6d('0xf4')](_0x5c6d('0x9f'))['dataToMarker']({'view':'revision'});}['init'](){this[_0x5c6d('0x5f')]=this['editor']['plugins'][_0x5c6d('0x5b')](_0x5c6d('0x48')),this[_0x5c6d('0xab')](),this[_0x5c6d('0x49')][_0x5c6d('0xe0')]['on'](_0x5c6d('0x18'),()=>{const _0x56cc3b=this[_0x5c6d('0x5f')]['getRevision'](0x0),_0x1f38a7=_0x56cc3b&&null===_0x56cc3b['creator']?_0x56cc3b:null;if(this[_0x5c6d('0x8')]=!!_0x1f38a7&&this[_0x5c6d('0x49')]['config'][_0x5c6d('0x5b')](_0x5c6d('0xb1')),this[_0x5c6d('0x49')][_0x5c6d('0x93')][_0x5c6d('0x7f')](_0x5c6d('0x3e'))){const _0x3d10d8=this['_source']['getCurrentRevisionId'](),_0x5efe75=this[_0x5c6d('0x5f')][_0x5c6d('0xc6')](_0x3d10d8);if(_0x5efe75)this['_startingVersion']=_0x5efe75[_0x5c6d('0xe2')],this[_0x5c6d('0x8')]=!0x1;else{const _0x28e2a1=this['_source'][_0x5c6d('0x77')][_0x5c6d('0xca')][_0x5c6d('0x10')](_0x4e82d2=>!_0x4e82d2['_isInit']),_0xb603e1=_0x28e2a1?_0x28e2a1['baseVersion']:this[_0x5c6d('0xc8')][_0x5c6d('0x77')][_0x5c6d('0x75')];_0x56cc3b?(_0x56cc3b[_0x5c6d('0xa0')]<_0xb603e1&&_0x56cc3b[_0x5c6d('0xef')]({'toVersion':_0xb603e1}),this[_0x5c6d('0x8')]?(this[_0x5c6d('0xc8')][_0x5c6d('0xea')]=()=>_0x1f38a7['id'],this[_0x5c6d('0xc5')]=_0x1f38a7[_0x5c6d('0xe2')]):(this[_0x5c6d('0xc5')]=_0x56cc3b['toVersion'],this[_0x5c6d('0x8')]=!0x1)):(this[_0x5c6d('0xc5')]=_0xb603e1,this[_0x5c6d('0x8')]=!0x1);}}else _0x1f38a7&&(this[_0x5c6d('0x49')][_0x5c6d('0x26')][_0x5c6d('0x15')]['history'][_0x5c6d('0x75')]=Math[_0x5c6d('0x9d')](_0x1f38a7[_0x5c6d('0xa0')],this[_0x5c6d('0x49')][_0x5c6d('0x26')][_0x5c6d('0x15')][_0x5c6d('0x77')][_0x5c6d('0x75')]),_0x1f38a7['fromVersion']===_0x1f38a7[_0x5c6d('0xa0')]?(0x0!==_0x1f38a7[_0x5c6d('0xe2')]&&(this[_0x5c6d('0xc8')][_0x5c6d('0xea')]=()=>_0x1f38a7['id']),this[_0x5c6d('0x8')]=!0x1):this[_0x5c6d('0x8')]&&(this[_0x5c6d('0xc8')]['getCurrentRevisionId']=()=>_0x1f38a7['id'],this[_0x5c6d('0xc5')]=_0x1f38a7[_0x5c6d('0xe2')])),this['_continueCurrentRevision']||(this[_0x5c6d('0xc5')]=this['editor']['model'][_0x5c6d('0x15')]['version']);this[_0x5c6d('0x7c')][_0x5c6d('0xa8')](this['_source'][_0x5c6d('0x77')]),this[_0x5c6d('0x4')](this['_startingVersion']),this[_0x5c6d('0xb5')](this[_0x5c6d('0xc5')]),this[_0x5c6d('0xa5')]&&this[_0x5c6d('0xd0')]();}),this[_0x5c6d('0x4d')](_0x5c6d('0x3d'))['to'](this,_0x5c6d('0x86'),_0x42adaf=>!_0x42adaf);}async[_0x5c6d('0x1d')](){if(this[_0x5c6d('0x5f')][_0x5c6d('0x88')]>0x0){const _0x46f72a=this[_0x5c6d('0x5f')][_0x5c6d('0xc6')](0x0),_0x2695c9=await this[_0x5c6d('0xd2')](_0x46f72a);this[_0x5c6d('0xc1')](_0x2695c9);}}['setSource'](_0x2c4a46){this[_0x5c6d('0xc8')]=_0x2c4a46;}async[_0x5c6d('0x61')](){const _0x14c163=await this[_0x5c6d('0xc8')]['getLatestVersion']();if(_0x14c163>this[_0x5c6d('0xba')]['toVersion']){await this[_0x5c6d('0x19')]();const _0xab4880=this[_0x5c6d('0x96')]({'revision':this[_0x5c6d('0xba')],'to':_0x14c163});_0xab4880[_0x5c6d('0xc0')]=_0xab4880[_0x5c6d('0x2c')][_0x5c6d('0x21')](_0x1f5b43=>this['editor']['plugins'][_0x5c6d('0x5b')](_0x5c6d('0x80'))[_0x5c6d('0xf3')](_0x1f5b43)),this[_0x5c6d('0xba')][_0x5c6d('0xef')](_0xab4880);}}async['_loadState'](){this[_0x5c6d('0x8')]&&!this[_0x5c6d('0x9')]&&(await this[_0x5c6d('0x64')](this['currentRevision']),this[_0x5c6d('0x7c')][_0x5c6d('0x83')](this[_0x5c6d('0xba')]),this[_0x5c6d('0x9')]={'fromVersion':this[_0x5c6d('0xba')]['fromVersion'],'authors':this[_0x5c6d('0xba')][_0x5c6d('0xc0')][_0x5c6d('0xe7')]()});}async[_0x5c6d('0x50')](_0x2b99f4={},_0x31b66e=null){const _0x3e4808=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x31b66e>this[_0x5c6d('0xba')]['toVersion']&&(_0x31b66e=null),null===_0x31b66e&&(_0x31b66e=await this[_0x5c6d('0xc8')][_0x5c6d('0xd7')]());const _0x5a12a0=this['_getFromVersion'](_0x31b66e),_0x32a7be=this[_0x5c6d('0x96')]({'from':_0x5a12a0,'to':_0x31b66e});if(this['currentRevision'][_0x5c6d('0xa0')]<_0x31b66e){const _0x4cae31=this['buildRevisionData']({'revision':this[_0x5c6d('0xba')],'from':_0x31b66e,'to':_0x31b66e});_0x4cae31[_0x5c6d('0xc0')]=[],_0x4cae31['authorsIds']=[],_0x4cae31['id']=this[_0x5c6d('0xba')]['id'],this[_0x5c6d('0xba')]['_update'](_0x4cae31,!0x0),delete _0x4cae31[_0x5c6d('0xc0')],_0x3e4808[_0x5c6d('0xe1')](_0x4cae31);}_0x2b99f4[_0x5c6d('0x3a')]=this[_0x5c6d('0x49')]['plugins'][_0x5c6d('0x5b')](_0x5c6d('0x80'))['me']['id'],_0x2b99f4[_0x5c6d('0x42')]=_0x2b99f4[_0x5c6d('0x42')]||null,_0x2b99f4['id']=_0x2b99f4['id']||_0x187adc(),_0x2b99f4={..._0x2b99f4,..._0x32a7be};const _0x1b6a9d=this[_0x5c6d('0x73')](_0x2b99f4);_0x3e4808[_0x5c6d('0xe1')](_0x2b99f4);const _0xf2a456=this[_0x5c6d('0x5f')]['getIndex'](_0x1b6a9d);if(0x0!==_0xf2a456){const _0xdc3099=this[_0x5c6d('0x5f')][_0x5c6d('0xc6')](_0xf2a456-0x1);if(_0xdc3099[_0x5c6d('0xe2')]!==_0x31b66e){const _0x3f7daf=this[_0x5c6d('0x7c')][_0x5c6d('0xcd')](_0x31b66e,_0xdc3099[_0x5c6d('0xa0')]),_0x1570fa={'id':_0xdc3099['id'],'diffData':_0x3f7daf[_0x5c6d('0x28')],'authorsIds':_0x3f7daf[_0x5c6d('0x2c')],'authors':_0x3f7daf[_0x5c6d('0x2c')][_0x5c6d('0x21')](_0x1a199d=>this[_0x5c6d('0x49')][_0x5c6d('0x93')][_0x5c6d('0x5b')](_0x5c6d('0x80'))[_0x5c6d('0xf3')](_0x1a199d)),'fromVersion':_0x31b66e};_0xdc3099===this[_0x5c6d('0xba')]&&(_0x1570fa[_0x5c6d('0xd6')]=new Date(_0x2b99f4[_0x5c6d('0xd6')][_0x5c6d('0x25')]()+0xa)),_0xdc3099[_0x5c6d('0xef')](_0x1570fa,!0x0),delete _0x1570fa[_0x5c6d('0xc0')],_0x3e4808['push'](_0x1570fa);}}if(this[_0x5c6d('0xa5')]){for(const _0x50ba19 of _0x3e4808)this['_bufferUpdate'](_0x50ba19['id'],_0x50ba19,!0x0);this[_0x5c6d('0xd0')]();}return _0x1b6a9d;}[_0x5c6d('0x73')](_0x86fd97){const _0x3c0a2e=this[_0x5c6d('0x5f')][_0x5c6d('0x56')](_0x86fd97);return this[_0x5c6d('0xa5')]&&_0x3c0a2e['on'](_0x5c6d('0xef'),(_0x313930,_0x33cfe5,_0x597451)=>{_0x597451||(this['_bufferUpdate'](_0x33cfe5['id'],_0x33cfe5,!0x0),this[_0x5c6d('0xd0')]());}),this[_0x5c6d('0x5f')][_0x5c6d('0x4f')](_0x3c0a2e,this['_findInsertionIndex'](_0x3c0a2e)),_0x3c0a2e;}async[_0x5c6d('0xd2')](_0x40fcf9){await this[_0x5c6d('0x64')](_0x40fcf9);const _0x4c3274={};for(const _0x38fdf2 in _0x40fcf9[_0x5c6d('0x28')]){const _0x1520f6=this[_0x5c6d('0x4a')](JSON[_0x5c6d('0x54')](_0x40fcf9[_0x5c6d('0x28')][_0x38fdf2][_0x5c6d('0xc3')])),_0x191354=this[_0x5c6d('0x49')][_0x5c6d('0xe8')][_0x5c6d('0xbb')][_0x5c6d('0x15')],_0x3b4e00=new _0x4ceba3(_0x191354,_0x1520f6[_0x5c6d('0x21')](_0x576925=>F(_0x576925,this['editor'])));this['editor']['data'][_0x5c6d('0x6b')][_0x5c6d('0x71')]('marked'),_0x4c3274[_0x38fdf2]=this[_0x5c6d('0x49')][_0x5c6d('0xe0')][_0x5c6d('0x6b')][_0x5c6d('0x1e')](_0x3b4e00),this[_0x5c6d('0x49')][_0x5c6d('0xe0')]['processor'][_0x5c6d('0x71')](_0x5c6d('0xce'));}return _0x4c3274;}[_0x5c6d('0xd0')](){if(0x0===this[_0x5c6d('0xf')][_0x5c6d('0x7')])return;if(this[_0x5c6d('0x86')])return;let _0xf7efca=Array[_0x5c6d('0x8e')](this[_0x5c6d('0xf')][_0x5c6d('0x7b')]());this[_0x5c6d('0xf')]['clear']();for(let _0x1a4c71=0x0;_0x1a4c71<_0xf7efca[_0x5c6d('0x88')];_0x1a4c71++){const _0x22c1cb=_0xf7efca[_0x1a4c71];let _0x40845f=!0x1;for(const _0x574289 of Object[_0x5c6d('0x66')](_0x22c1cb))void 0x0===_0x22c1cb[_0x574289]?delete _0x22c1cb[_0x574289]:'id'!==_0x574289&&(_0x40845f=!0x0);_0x40845f||(_0xf7efca[_0x1a4c71]=null);}if(_0xf7efca=_0xf7efca[_0x5c6d('0x2d')](_0x39d1fa=>null!==_0x39d1fa),!_0xf7efca['length'])return;for(let _0x4d873a=0x0;_0x4d873a<_0xf7efca[_0x5c6d('0x88')];_0x4d873a++){const _0x304de2=_0xf7efca[_0x4d873a];void 0x0!==_0x304de2[_0x5c6d('0xe2')]&&void 0x0===_0x304de2[_0x5c6d('0xa0')]&&(_0x304de2[_0x5c6d('0xa0')]=this[_0x5c6d('0x5f')][_0x5c6d('0xc6')](_0x304de2['id'])[_0x5c6d('0xa0')]),void 0x0!==_0x304de2['toVersion']&&void 0x0===_0x304de2[_0x5c6d('0xe2')]&&(_0x304de2['fromVersion']=this[_0x5c6d('0x5f')][_0x5c6d('0xc6')](_0x304de2['id'])[_0x5c6d('0xe2')]);}const _0x55f3fb=this[_0x5c6d('0x49')]['config'][_0x5c6d('0x5b')](_0x5c6d('0xc4'));this[_0x5c6d('0x86')]=!0x0,this[_0x5c6d('0xc2')](),this[_0x5c6d('0xa5')][_0x5c6d('0xd')](_0xf7efca,_0x55f3fb)['finally'](()=>{this[_0x5c6d('0x86')]=!0x1;})[_0x5c6d('0xcf')](_0x24a803=>{if(_0x24a803)for(const _0x5e5658 of _0x24a803)this[_0x5c6d('0x35')]({'id':_0x5e5658['id'],'createdAt':_0x5e5658[_0x5c6d('0xd6')]});this[_0x5c6d('0xa3')](),this['sendBufferedUpdates']();});}[_0x5c6d('0xc1')](_0x5ca096){let _0x32ae1d=this[_0x5c6d('0x49')][_0x5c6d('0x0')][_0x5c6d('0x5b')](_0x5c6d('0xd1'));if(void 0x0===_0x32ae1d){_0x32ae1d={};for(const _0x5b6d34 of this[_0x5c6d('0x49')]['model'][_0x5c6d('0x15')]['getRootNames']())_0x32ae1d[_0x5b6d34]='';}'string'==typeof _0x32ae1d&&(_0x32ae1d={'main':_0x32ae1d});let _0xad20be=!0x1;for(const _0x1e77e7 of Object[_0x5c6d('0x66')](_0x32ae1d))_0x5ca096[_0x1e77e7]&&(_0x32ae1d[_0x1e77e7]!==_0x5ca096[_0x1e77e7]&&''!==_0x32ae1d[_0x1e77e7][_0x5c6d('0xc7')]()&&(_0xad20be=!0x0),_0x32ae1d[_0x1e77e7]=_0x5ca096[_0x1e77e7]);_0xad20be&&_0x1ebf2e('editor-initial-data-replaced-with-revision-data'),this[_0x5c6d('0x49')][_0x5c6d('0x0')][_0x5c6d('0x69')](_0x5c6d('0xd1'),_0x32ae1d);}['_addPendingAction'](){if(!this[_0x5c6d('0x5d')]){const _0x520d64=this['editor'][_0x5c6d('0x93')]['get'](_0x5c6d('0x81'));this[_0x5c6d('0x5d')]=_0x520d64['add'](_0x2e38bf(this[_0x5c6d('0x49')][_0x5c6d('0xad')],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this[_0x5c6d('0x5d')]&&(this[_0x5c6d('0x49')]['plugins']['get'](_0x5c6d('0x81'))['remove'](this[_0x5c6d('0x5d')]),this[_0x5c6d('0x5d')]=null);}[_0x5c6d('0x2a')](_0x1b4562){const _0x1f759a=this[_0x5c6d('0x5f')][_0x5c6d('0xa4')]();_0x1f759a[_0x5c6d('0x6e')]();let _0x515c81=0x0;for(;_0x515c81<_0x1f759a[_0x5c6d('0x88')];){const _0x1e3461=_0x1f759a[_0x515c81];if(_0x1e3461===this[_0x5c6d('0xba')]){_0x515c81++;continue;}if(_0x1e3461['id']===this[_0x5c6d('0xb7')])break;const _0x490633=_0x1b4562[_0x5c6d('0xa0')]-_0x1e3461[_0x5c6d('0xa0')]||_0x1b4562[_0x5c6d('0xe2')]-_0x1e3461[_0x5c6d('0xe2')];if(_0x490633>0x0)break;if(_0x490633<0x0)_0x515c81++;else{if(!_0x1b4562['creator']&&_0x1e3461[_0x5c6d('0xcb')])break;if(_0x1e3461[_0x5c6d('0xcb')]||!_0x1b4562['creator']){if(_0x1b4562[_0x5c6d('0xd6')]>_0x1e3461[_0x5c6d('0xd6')])break;_0x515c81++;}else _0x515c81++;}}return _0x515c81;}[_0x5c6d('0x35')](_0x35815f){const _0x3a4efa=this['repository']['getRevision'](_0x35815f['id']);if(_0x35815f['createdAt']&&(_0x35815f[_0x5c6d('0xd6')]=new Date(_0x35815f[_0x5c6d('0xd6')])),_0x35815f[_0x5c6d('0x2c')]){const _0xfe923d=this[_0x5c6d('0x49')][_0x5c6d('0x93')][_0x5c6d('0x5b')](_0x5c6d('0x80'));_0x35815f[_0x5c6d('0xc0')]=_0x35815f[_0x5c6d('0x2c')][_0x5c6d('0x21')](_0xbe3836=>_0xfe923d[_0x5c6d('0xf3')](_0xbe3836));}_0x3a4efa[_0x5c6d('0xef')](_0x35815f,!0x0);}[_0x5c6d('0x96')]({revision:_0x1095a1=null,from:_0x173d39=null,to:_0x39b6e2=null}){_0x173d39=null!==_0x173d39?_0x173d39:_0x1095a1[_0x5c6d('0xe2')],_0x39b6e2=null!==_0x39b6e2?_0x39b6e2:_0x1095a1['toVersion'];const _0x2907fe=this[_0x5c6d('0x7c')][_0x5c6d('0xcd')](_0x173d39,_0x39b6e2),_0xbf231a={'diffData':_0x2907fe[_0x5c6d('0x28')],'authorsIds':_0x2907fe[_0x5c6d('0x2c')],'fromVersion':_0x173d39,'toVersion':_0x39b6e2};if(!_0x1095a1||_0x39b6e2!==_0x1095a1[_0x5c6d('0xa0')]){const _0x17d4f0=_0x39b6e2-0x1,_0x182040=this[_0x5c6d('0xc8')][_0x5c6d('0x77')][_0x5c6d('0x82')](_0x17d4f0);_0xbf231a[_0x5c6d('0xd6')]=_0x182040&&_0x182040['createdAt']||new Date();}if(this['_loadedStateData']&&_0x173d39===this['_loadedStateData']['fromVersion'])for(const _0xf4d0f8 of this['_loadedStateData']['authors'])_0xbf231a[_0x5c6d('0x2c')]['includes'](_0xf4d0f8['id'])||_0xbf231a['authorsIds']['push'](_0xf4d0f8['id']);return _0xbf231a;}['_loadRevisionData'](_0x25bc5b){if(!_0x25bc5b||_0x25bc5b['diffData'])return Promise[_0x5c6d('0x20')]();{const _0x3bc209=this[_0x5c6d('0x49')]['config'][_0x5c6d('0x5b')]('collaboration.channelId');return this[_0x5c6d('0xa5')][_0x5c6d('0xc6')]({'channelId':_0x3bc209,'revisionId':_0x25bc5b['id']})[_0x5c6d('0xcf')](_0x53ac2e=>{_0x25bc5b['diffData']=_0x53ac2e['diffData'];});}}[_0x5c6d('0xe4')](_0x187111,_0x5304c5,_0x4c2040){if(this[_0x5c6d('0xf')][_0x5c6d('0x7f')](_0x187111)){const _0x473bf5=this[_0x5c6d('0xf')][_0x5c6d('0x5b')](_0x187111);_0x5304c5=_0x4c2040?{..._0x473bf5,..._0x5304c5}:{..._0x5304c5,..._0x473bf5};}this[_0x5c6d('0xf')][_0x5c6d('0x69')](_0x187111,_0x5304c5);}[_0x5c6d('0x41')](_0x6a5ac){const _0x530438=this[_0x5c6d('0x5f')][_0x5c6d('0xa4')]();_0x530438[_0x5c6d('0x6e')](),_0x530438['shift']();const _0x271f78=_0x530438[_0x5c6d('0x10')](_0x2e06b4=>_0x2e06b4['toVersion']<=_0x6a5ac)[_0x5c6d('0xa0')];return _0x271f78<this[_0x5c6d('0xc5')]?this[_0x5c6d('0xc5')]:_0x271f78;}[_0x5c6d('0x4')](_0x57bc4f){const _0x839358=this[_0x5c6d('0x5f')]['getRevision'](this[_0x5c6d('0x5f')][_0x5c6d('0x88')]-0x1);if(_0x839358)this[_0x5c6d('0xb7')]=_0x839358['id'];else{const _0x4d59a6=!this['editor'][_0x5c6d('0x26')]['document'][_0x5c6d('0x43')][_0x5c6d('0x10')](_0x4e7192=>this[_0x5c6d('0x49')]['model'][_0x5c6d('0xf1')](_0x4e7192)),_0x1be2e1=this[_0x5c6d('0x49')][_0x5c6d('0x93')][_0x5c6d('0x5b')]('Users')['me']['id'],_0x43aadf=_0x2e38bf(this[_0x5c6d('0x49')][_0x5c6d('0xad')],_0x4d59a6?'Empty\x20document':'Initial\x20revision');this[_0x5c6d('0xb9')]({'from':_0x57bc4f,'to':_0x57bc4f,'id':this[_0x5c6d('0xb7')],'name':_0x43aadf,'creatorId':_0x1be2e1});}}[_0x5c6d('0xb5')](_0xb4beae){const _0x307be5=this[_0x5c6d('0xc8')][_0x5c6d('0xea')]();this[_0x5c6d('0xba')]=this['repository'][_0x5c6d('0xc6')](_0x307be5),this['currentRevision']||(this[_0x5c6d('0xba')]=this['_makeRevision']({'from':_0xb4beae,'to':_0xb4beae,'id':_0x307be5,'name':'','creatorId':null}));}[_0x5c6d('0xb9')]({name:_0x5caab9,from:_0x4ddc8b,to:_0x35034a,creatorId:_0x114a20,id:_0x1be6f8}){const _0x2b0582=this[_0x5c6d('0x96')]({'from':_0x4ddc8b,'to':_0x35034a});_0x2b0582[_0x5c6d('0x42')]=_0x5caab9,_0x2b0582[_0x5c6d('0x3a')]=_0x114a20,_0x2b0582['id']=_0x1be6f8;const _0x2df321=this[_0x5c6d('0x73')](_0x2b0582);return this[_0x5c6d('0xa5')]&&this[_0x5c6d('0xe4')](_0x2b0582['id'],_0x2b0582,!0x0),_0x2df321;}[_0x5c6d('0xab')](){this['editor']['conversion']['for']('dataDowncast')[_0x5c6d('0xf2')]({'model':_0x5c6d('0xd5')});}['_removeRevisionMarkers'](_0x5deec9){return(_0x5deec9=_0x5deec9['filter'](_0x1d9071=>!_0x1d9071['name']||'revision-start'!==_0x1d9071[_0x5c6d('0x42')]&&_0x5c6d('0x4e')!==_0x1d9071[_0x5c6d('0x42')]))[_0x5c6d('0x53')](_0x1c21b5=>{_0x5c6d('0xed')!=typeof _0x1c21b5&&(_0x1c21b5[_0x5c6d('0x2')]=this[_0x5c6d('0x4a')](_0x1c21b5[_0x5c6d('0x2')]),_0x1c21b5[_0x5c6d('0x52')]=_0x1c21b5[_0x5c6d('0x52')][_0x5c6d('0x2d')](_0x589e13=>!_0x589e13[0x0][_0x5c6d('0x1a')](_0x5c6d('0x14'))));}),_0x5deec9;}}function F(_0x2f0975,_0x1f3a66){const _0x264fcc=_0x1f3a66['editing'][_0x5c6d('0xbb')][_0x5c6d('0x15')];if(_0x5c6d('0xed')==typeof _0x2f0975)return new _0xfc94e1(_0x264fcc,_0x2f0975);{const _0x5b7868=_0x2f0975[_0x5c6d('0x2')][_0x5c6d('0x21')](_0x4ac7b0=>F(_0x4ac7b0,_0x1f3a66));return new(V[_0x2f0975['type']]||_0xa5b306)(_0x264fcc,_0x2f0975[_0x5c6d('0x42')],_0x2f0975[_0x5c6d('0x52')],_0x5b7868);}}class T{constructor(_0x3f0aee){this[_0x5c6d('0x49')]=_0x3f0aee,this[_0x5c6d('0x60')]=new Map(),this[_0x5c6d('0x8c')]=-0x1,this[_0x5c6d('0x1f')]=-0x1,this[_0x5c6d('0x89')]=new Map(),this['_diffRoots']=new Map(),this[_0x5c6d('0x31')]=new Map(),this['_idsRoots']=new Map(),this['_baseIdsRoots']=new Map(),this[_0x5c6d('0x5c')]=new Map(),this[_0x5c6d('0x91')]=new Map(),this[_0x5c6d('0x5')]=0x1,this['_rootNames']=this['editor'][_0x5c6d('0x26')][_0x5c6d('0x15')][_0x5c6d('0x11')](),this[_0x5c6d('0x24')][_0x5c6d('0xe1')](_0x5c6d('0xee'));}[_0x5c6d('0xa8')](_0x21fc2b){this[_0x5c6d('0xe')]=_0x21fc2b;const _0x5f357e=new Map();for(const _0x365799 of this[_0x5c6d('0x24')]){const _0x2cb670=J(this[_0x5c6d('0x49')]['model'][_0x5c6d('0x15')]['getRoot'](_0x365799));_0x5f357e['set'](_0x365799,_0x2cb670);}const _0x5775b1=Array[_0x5c6d('0x8e')](this['editor'][_0x5c6d('0x26')]['markers'])[_0x5c6d('0x21')](_0x5d0a84=>[_0x5d0a84[_0x5c6d('0x42')],_0x5d0a84['getRange']()]),_0x52fd15=this[_0x5c6d('0xe')]['version'];this[_0x5c6d('0x5a')](_0x52fd15,_0x5f357e,_0x5775b1),this[_0x5c6d('0x4c')]=this[_0x5c6d('0x5')];}['getData'](_0x48b6d9,_0x469412){if(this[_0x5c6d('0x8c')]===_0x48b6d9&&this[_0x5c6d('0x1f')]<=_0x469412)this[_0x5c6d('0x60')][_0x5c6d('0x7')]>0x1&&this[_0x5c6d('0xd8')](this['_lastTo']),this[_0x5c6d('0x38')](this[_0x5c6d('0x1f')],_0x469412,!0x0);else{if(!this[_0x5c6d('0x60')][_0x5c6d('0x7f')](_0x48b6d9)){const _0x12a66b=this[_0x5c6d('0x6a')](_0x48b6d9);this[_0x5c6d('0x8b')](_0x12a66b,_0x48b6d9,!0x1);}this[_0x5c6d('0x8b')](_0x48b6d9,_0x469412,!0x0);}return this[_0x5c6d('0x8c')]=_0x48b6d9,this[_0x5c6d('0x1f')]=_0x469412,this[_0x5c6d('0x51')]();}[_0x5c6d('0x83')](_0x1747cb){this['_reset'](),this[_0x5c6d('0x8c')]=_0x1747cb[_0x5c6d('0xe2')],this['_lastTo']=_0x1747cb[_0x5c6d('0xa0')];for(const _0x10af6a in _0x1747cb[_0x5c6d('0x28')]){const _0x463982=this[_0x5c6d('0xdb')](_0x1747cb['diffData'][_0x10af6a][_0x5c6d('0x9c')]);_0x463982['rootName']=_0x10af6a,this[_0x5c6d('0x31')][_0x5c6d('0x69')](_0x10af6a,_0x463982);const _0x1291a8=this['_makeIdsRoot'](_0x463982);this[_0x5c6d('0x3f')]['set'](_0x10af6a,_0x1291a8);for(const [_0x370e19,_0x162c2f]of _0x463982[_0x5c6d('0x34')]){if(!_0x370e19['startsWith']('revision:'))continue;const _0x3bb01b=_0x370e19[_0x5c6d('0xb6')](':')[0x2];for(const _0x384cae of _0x162c2f[_0x5c6d('0x32')]({'singleCharacters':!0x0})){const _0x40546d=this[_0x5c6d('0xec')](_0x384cae),_0x5995e1=_0x5c6d('0xde')==_0x384cae['type']?_0x384cae['previousPosition'][_0x5c6d('0x70')][_0x5c6d('0xe7')](0x0,-0x1):_0x384cae['previousPosition'][_0x5c6d('0x70')],_0x499266=_0x1291a8[_0x5c6d('0x1c')](_0x5995e1)[_0x5c6d('0x6')](_0x40546d);this[_0x5c6d('0x5c')][_0x5c6d('0x69')](_0x499266,{'userId':_0x3bb01b});}}}this[_0x5c6d('0x4c')]=this[_0x5c6d('0x5')];const _0xd2a5d0=[...Array(this[_0x5c6d('0x5')])[_0x5c6d('0x66')]()][_0x5c6d('0xe7')](0x1)[_0x5c6d('0x2d')](_0x24466b=>!this['_touched'][_0x5c6d('0x7f')](_0x24466b));let _0x5d012d=0x0;for(const _0x203ca2 in _0x1747cb[_0x5c6d('0x28')]){const _0xbebc13=this[_0x5c6d('0xdb')](_0x1747cb[_0x5c6d('0x28')][_0x203ca2][_0x5c6d('0xc3')]);_0xbebc13[_0x5c6d('0xa2')]=_0x203ca2,this[_0x5c6d('0xc')][_0x5c6d('0x69')](_0x203ca2,_0xbebc13);const _0x1f5a08=this[_0x5c6d('0x44')](_0xbebc13,Number['NEGATIVE_INFINITY']);this[_0x5c6d('0xae')][_0x5c6d('0x69')](_0x203ca2,_0x1f5a08);for(const [_0x145f36,_0xcb7670]of _0xbebc13[_0x5c6d('0x34')]){if(!_0x145f36['startsWith']('revision:'))continue;const _0x5b141f=_0x145f36[_0x5c6d('0xb6')](':')[0x2];for(const _0x1d4edf of _0xcb7670[_0x5c6d('0x32')]({'singleCharacters':!0x0})){const _0x5e33b3=this[_0x5c6d('0xec')](_0x1d4edf),_0x450b66=this[_0x5c6d('0x5')]++,_0xc5ebda=_0x5c6d('0xde')==_0x1d4edf['type']?_0x1d4edf['previousPosition'][_0x5c6d('0x70')][_0x5c6d('0xe7')](0x0,-0x1):_0x1d4edf[_0x5c6d('0xeb')][_0x5c6d('0x70')];_0x1f5a08['getNodeByPath'](_0xc5ebda)['_setAttribute'](_0x5e33b3,_0x450b66),this[_0x5c6d('0x5c')]['set'](_0x450b66,{'userId':_0x5b141f});}}for(const _0x4cc740 of this['editor'][_0x5c6d('0x26')][_0x5c6d('0x16')](_0xbebc13)[_0x5c6d('0x32')]({'singleCharacters':!0x0})){const _0x2f2290=this[_0x5c6d('0xec')](_0x4cc740),_0x72df2b='elementEnd'==_0x4cc740[_0x5c6d('0xe5')]?_0x4cc740[_0x5c6d('0xeb')][_0x5c6d('0x70')][_0x5c6d('0xe7')](0x0,-0x1):_0x4cc740[_0x5c6d('0xeb')][_0x5c6d('0x70')],_0x2c631d=_0x1f5a08[_0x5c6d('0x1c')](_0x72df2b);_0x2c631d[_0x5c6d('0x6')](_0x2f2290)>0x0||_0x2c631d['_setAttribute'](_0x2f2290,_0xd2a5d0[_0x5d012d++]);}const _0x2c2cb4=new _0x5c8a1f();_0x2c2cb4[_0x5c6d('0xa2')]=_0x5c6d('0xee'),this[_0x5c6d('0x31')][_0x5c6d('0x69')]('$graveyard',_0x2c2cb4),this[_0x5c6d('0x3f')]['set'](_0x5c6d('0xee'),this['_makeIdsRoot'](_0x2c2cb4,0x1));const _0x43dcf4=new _0x5c8a1f();_0x43dcf4[_0x5c6d('0xa2')]=_0x5c6d('0xee'),this[_0x5c6d('0xc')][_0x5c6d('0x69')](_0x5c6d('0xee'),_0x43dcf4),this[_0x5c6d('0xae')]['set'](_0x5c6d('0xee'),this[_0x5c6d('0x44')](_0x43dcf4,0x1));for(const [_0x519884,_0x315842]of _0xbebc13[_0x5c6d('0x34')])_0x519884[_0x5c6d('0x1a')](_0x5c6d('0x57'))||this[_0x5c6d('0x89')][_0x5c6d('0x69')](_0x519884,_0x315842);}const _0x4aed63=Array[_0x5c6d('0x8e')](this['_diffRoots'])[_0x5c6d('0x21')](([_0x591a72,_0x6c84d6])=>[_0x591a72,J(_0x6c84d6)]);this[_0x5c6d('0x5a')](this['_lastTo'],_0x4aed63,this['_markers']);}['_makeModelFromViewString'](_0x3f346e){const _0x56b5d2=JSON[_0x5c6d('0x54')](_0x3f346e),_0xf83a3f=this[_0x5c6d('0x49')][_0x5c6d('0xe8')][_0x5c6d('0xbb')]['document'],_0x3bc273=new _0x4ceba3(_0xf83a3f,_0x56b5d2[_0x5c6d('0x21')](_0x4b6a42=>F(_0x4b6a42,this[_0x5c6d('0x49')])));return this['editor'][_0x5c6d('0xe0')][_0x5c6d('0x12')](_0x3bc273);}['_saveEmptyMetaData'](){const _0x35088f=new Map();for(const _0x2d2097 of this[_0x5c6d('0x24')]){const _0x4dae75=new _0x5c8a1f();_0x4dae75[_0x5c6d('0xa2')]=_0x2d2097,_0x35088f[_0x5c6d('0x69')](_0x2d2097,_0x4dae75);}this[_0x5c6d('0x5a')](Number[_0x5c6d('0x39')],_0x35088f,[]);}[_0x5c6d('0x5a')](_0x3fc4ca,_0x2701b9,_0x185cf0){const _0x31efb8=new Map(_0x2701b9),_0x1ec6df=new Map();for(const [_0x532837,_0x554310]of _0x185cf0)_0x1ec6df[_0x5c6d('0x69')](_0x532837,{'start':_0x554310[_0x5c6d('0xa9')]['clone'](),'end':_0x554310[_0x5c6d('0xd3')][_0x5c6d('0x47')](),'rootName':_0x554310['root'][_0x5c6d('0xa2')]});this[_0x5c6d('0x60')][_0x5c6d('0x69')](_0x3fc4ca,{'roots':_0x31efb8,'markers':_0x1ec6df});}[_0x5c6d('0xd8')](_0x349484){this[_0x5c6d('0x60')][_0x5c6d('0x45')](_0x349484);}[_0x5c6d('0x27')](){this[_0x5c6d('0xbd')](),this[_0x5c6d('0x8c')]=-0x1,this[_0x5c6d('0x1f')]=-0x1,this['_savedMetaData']['clear'](),this[_0x5c6d('0xa8')](this['source']);}[_0x5c6d('0xbd')](){this[_0x5c6d('0x5c')][_0x5c6d('0x4b')](),this['_touchedMarkers']['clear'](),this[_0x5c6d('0xc')][_0x5c6d('0x4b')](),this['_baseRoots']['clear'](),this[_0x5c6d('0xae')]['clear'](),this['_baseIdsRoots'][_0x5c6d('0x4b')](),this[_0x5c6d('0x89')][_0x5c6d('0x4b')](),this[_0x5c6d('0x5')]=0x1,this[_0x5c6d('0x4c')]=this['_revisionId'];}[_0x5c6d('0x44')](_0x37c389,_0x14862b=null){let _0x19b24c=null;_0x37c389['is'](_0x5c6d('0xc9'))||(_0x19b24c=new _0x32778a(_0x37c389[_0x5c6d('0x42')],{'vid_start':null===_0x14862b?this[_0x5c6d('0x5')]++:_0x14862b++}));const _0xfd85cc=[];for(const _0x4f6d2f of _0x37c389[_0x5c6d('0xb2')]())if(_0x4f6d2f['is']('element')){_0xfd85cc[_0x5c6d('0xe1')](this[_0x5c6d('0x44')](_0x4f6d2f,_0x14862b));const _0x25d93e=_0xfd85cc[_0xfd85cc['length']-0x1];null!==_0x14862b&&(_0x14862b=_0x25d93e['is']('element',_0x5c6d('0x17'))?_0x25d93e[_0x5c6d('0x6')]('vid')+0x1:_0x25d93e[_0x5c6d('0x6')](_0x5c6d('0x1'))+0x1);}else for(let _0x51d40b=0x0;_0x51d40b<_0x4f6d2f[_0x5c6d('0x78')];_0x51d40b++)_0xfd85cc[_0x5c6d('0xe1')](new _0x32778a(_0x5c6d('0x17'),{'vid':null===_0x14862b?this[_0x5c6d('0x5')]++:_0x14862b++}));if(_0x37c389['is'](_0x5c6d('0xc9'))){const _0x35d0ae=new _0x5c8a1f(_0xfd85cc);return _0x35d0ae[_0x5c6d('0xa2')]=_0x37c389['rootName'],_0x35d0ae;}return _0x19b24c[_0x5c6d('0x30')]('vid_end',null===_0x14862b?this[_0x5c6d('0x5')]++:_0x14862b++),_0x19b24c['_insertChild'](0x0,_0xfd85cc),_0x19b24c;}[_0x5c6d('0x8b')](_0x2ecde6,_0x316241,_0x1d71a0){this[_0x5c6d('0xbd')]();const {roots:_0x177475,markers:_0x57fa92}=this['_savedMetaData'][_0x5c6d('0x5b')](_0x2ecde6);this[_0x5c6d('0x31')]=new Map(_0x177475);for(const [_0x535261,_0x2c1413]of this[_0x5c6d('0x31')])if(_0x5c6d('0xee')!==_0x535261&&(this['_diffRoots']['set'](_0x535261,J(_0x2c1413)),_0x1d71a0)){const _0xec1ec0=this[_0x5c6d('0x5')];this['_idsRoots']['set'](_0x535261,this[_0x5c6d('0x44')](_0x2c1413)),this[_0x5c6d('0x3f')][_0x5c6d('0x69')](_0x535261,this[_0x5c6d('0x44')](_0x2c1413,_0xec1ec0));}this[_0x5c6d('0x4c')]=this['_revisionId'],this[_0x5c6d('0xc')]['set'](_0x5c6d('0xee'),J(this['_baseRoots'][_0x5c6d('0x5b')](_0x5c6d('0xee')))),_0x1d71a0&&this[_0x5c6d('0xae')][_0x5c6d('0x69')](_0x5c6d('0xee'),this[_0x5c6d('0x44')](this['_baseRoots'][_0x5c6d('0x5b')](_0x5c6d('0xee'))));for(const [_0x442838,_0x5c01d1]of _0x57fa92){const _0x3458be=this[_0x5c6d('0x31')][_0x5c6d('0x5b')](_0x5c01d1[_0x5c6d('0xa2')]),_0x5cd135=this[_0x5c6d('0xc')][_0x5c6d('0x5b')](_0x5c01d1[_0x5c6d('0xa2')]),_0x18fb1e=new _0x4bafe2(this['_fixPosition'](_0x5c01d1[_0x5c6d('0xa9')],_0x3458be),this[_0x5c6d('0x7e')](_0x5c01d1[_0x5c6d('0xd3')],_0x3458be)),_0x5b3622=this[_0x5c6d('0x23')](_0x18fb1e,_0x5cd135);_0x3458be[_0x5c6d('0x34')]['set'](_0x442838,_0x18fb1e),this[_0x5c6d('0x89')][_0x5c6d('0x69')](_0x442838,_0x5b3622);}this[_0x5c6d('0x38')](_0x2ecde6,_0x316241,_0x1d71a0);}['_applyOperations'](_0xc6a9eb,_0x4a3480,_0x3e5a7e){for(const _0x124375 of this[_0x5c6d('0xe')]['getOperations'](_0xc6a9eb,_0x4a3480))this[_0x5c6d('0xd9')](_0x124375,_0x3e5a7e);for(const _0x2fe03d of this['_diffRoots'][_0x5c6d('0x7b')]())_0x2fe03d[_0x5c6d('0x34')]['clear']();for(const [_0x4d005e,_0x2bc741]of this[_0x5c6d('0x89')]){this[_0x5c6d('0xc')][_0x5c6d('0x5b')](_0x2bc741[_0x5c6d('0x98')][_0x5c6d('0xa2')])[_0x5c6d('0x34')][_0x5c6d('0x69')](_0x4d005e,_0x2bc741[_0x5c6d('0x47')]());}this[_0x5c6d('0x5a')](_0x4a3480,Array['from'](this[_0x5c6d('0xc')])[_0x5c6d('0x21')](([_0x2f643e,_0x5c2eaf])=>[_0x2f643e,J(_0x5c2eaf)]),this[_0x5c6d('0x89')]);}[_0x5c6d('0x6a')](_0x55aeb0){const _0x17378b=Array['from'](this[_0x5c6d('0x60')][_0x5c6d('0x66')]());_0x17378b[_0x5c6d('0x72')]((_0x4f3193,_0x233ec5)=>_0x4f3193-_0x233ec5),_0x17378b['reverse']();for(const _0x2c2681 of _0x17378b)if(_0x2c2681<_0x55aeb0)return _0x2c2681;return this['_saveEmptyMetaData'](),Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x5569c5,_0x1571c3){const _0x43b713=Array[_0x5c6d('0x8e')](_0x1571c3[_0x5c6d('0x34')])[_0x5c6d('0x21')](([_0x51b056,_0x331d8a])=>[_0x51b056,this[_0x5c6d('0x23')](_0x331d8a,_0x5569c5)]);_0x5569c5[_0x5c6d('0x34')]=new Map(_0x43b713);}[_0x5c6d('0x2f')](_0x4a6caf){for(const _0x3bf35e of this[_0x5c6d('0x89')][_0x5c6d('0x7b')]()){const _0x2ae764=_0x3bf35e[_0x5c6d('0xdc')](_0x4a6caf),_0x59a178=_0x4bafe2[_0x5c6d('0x74')](_0x2ae764);_0x3bf35e[_0x5c6d('0xa9')]=_0x59a178['start'],_0x3bf35e['end']=_0x59a178[_0x5c6d('0xd3')];}}['_handleOperation'](_0x36573a,_0x16558a){const _0x163f7f=this[_0x5c6d('0xb0')](_0x36573a,this[_0x5c6d('0xc')]);if(_0x5c6d('0x76')!==_0x36573a['type']&&(_0x163f7f[_0x5c6d('0xac')](),this[_0x5c6d('0x2f')](_0x163f7f)),_0x16558a)switch(_0x163f7f[_0x5c6d('0xe5')]){case _0x5c6d('0xd4'):this[_0x5c6d('0x3b')](_0x36573a);break;case _0x5c6d('0x13'):case _0x5c6d('0x87'):case _0x5c6d('0x6f'):this[_0x5c6d('0x2b')](_0x36573a);break;case _0x5c6d('0x55'):this[_0x5c6d('0x65')](_0x36573a);break;case _0x5c6d('0xb6'):this[_0x5c6d('0xdf')](_0x36573a);break;case _0x5c6d('0x76'):this['_handleMarkerOperation'](_0x36573a);}}['_cloneOperation'](_0x3babc1,_0x41426e){const _0x4feb26=_0x3babc1[_0x5c6d('0x47')]();return _0x4feb26['_authorId']=_0x3babc1['_authorId'],this[_0x5c6d('0x1b')](_0x4feb26,_0x41426e),_0x4feb26;}['_getBaseVids'](_0xdfd8f2){return _0xdfd8f2[_0x5c6d('0x21')](_0x10b44f=>{const _0x1e20d2=this[_0x5c6d('0xec')](_0x10b44f);return Number(_0x10b44f['item']['getAttribute'](_0x1e20d2));});}[_0x5c6d('0xbf')](_0x1a84f9,_0x5bb818){if(_0x1a84f9['is'](_0x5c6d('0xa6'),_0x5c6d('0x17')))_0x5bb818[_0x5c6d('0xe1')]({'item':_0x1a84f9,'type':_0x5c6d('0xf0')});else{_0x1a84f9['is']('element')&&_0x5bb818[_0x5c6d('0xe1')]({'item':_0x1a84f9,'type':_0x5c6d('0x79')});for(const _0x5dc22a of _0x1a84f9[_0x5c6d('0xb2')]())this['_generateTape'](_0x5dc22a,_0x5bb818);_0x1a84f9['is'](_0x5c6d('0xa6'))&&_0x5bb818[_0x5c6d('0xe1')]({'item':_0x1a84f9,'type':'elementEnd'});}return _0x5bb818;}['_getState'](){const _0x5c3008=this[_0x5c6d('0x49')][_0x5c6d('0x26')]['document'][_0x5c6d('0x11')](),_0x41418b=new Map(this[_0x5c6d('0x5c')]),_0x291493=new Map(_0x41418b),_0x7ef5eb=new Map(),_0xab11c8={'insertions':{},'deletions':{}},_0x542964={'insertions':{},'deletions':{}},_0x468d9b=new Map();for(const _0x3a0bbf of _0x5c3008){const _0x1f0a29=this[_0x5c6d('0xc')][_0x5c6d('0x5b')](_0x3a0bbf),_0x22e2f0=this[_0x5c6d('0x31')]['get'](_0x3a0bbf);_0xab11c8[_0x5c6d('0xc3')][_0x3a0bbf]=J(_0x1f0a29),_0xab11c8[_0x5c6d('0x9c')][_0x3a0bbf]=J(_0x22e2f0),this[_0x5c6d('0x7a')](_0xab11c8[_0x5c6d('0x9c')][_0x3a0bbf],_0x22e2f0),this[_0x5c6d('0x7a')](_0xab11c8[_0x5c6d('0xc3')][_0x3a0bbf],_0x1f0a29),_0x542964['insertions'][_0x3a0bbf]=this[_0x5c6d('0xbf')](this[_0x5c6d('0xae')]['get'](_0x3a0bbf),[]),_0x542964[_0x5c6d('0x9c')][_0x3a0bbf]=this['_generateTape'](this[_0x5c6d('0x3f')][_0x5c6d('0x5b')](_0x3a0bbf),[]);}for(const _0x23c0cb of _0x5c3008){const _0x5a1bd3=_0x542964[_0x5c6d('0xc3')][_0x23c0cb];for(const _0x18e984 of _0x5a1bd3){const _0x19d286=this[_0x5c6d('0xec')](_0x18e984),_0x5aa93a=_0x18e984[_0x5c6d('0x59')][_0x5c6d('0x6')](_0x19d286);_0x291493[_0x5c6d('0x45')](_0x5aa93a),_0x5aa93a>=this[_0x5c6d('0x4c')]&&_0x7ef5eb[_0x5c6d('0x69')](_0x5aa93a,_0x41418b[_0x5c6d('0x5b')](_0x5aa93a));}}for(const _0x4c2184 of _0x5c3008){const _0x4340ee=_0x542964[_0x5c6d('0xc3')][_0x4c2184],_0x25e346=this[_0x5c6d('0x58')](_0x542964[_0x5c6d('0x9c')][_0x4c2184]);let _0x14e679=0x0;for(const _0x12ce04 of _0x4340ee){const _0x3fc921=this['_getVidAttributeName'](_0x12ce04),_0x212e45=_0x12ce04[_0x5c6d('0x59')]['getAttribute'](_0x3fc921);if(!_0x7ef5eb[_0x5c6d('0x7f')](_0x212e45)&&!_0x468d9b['has'](_0x212e45)){if(_0x291493[_0x5c6d('0x7f')](_0x212e45))_0x14e679++;else{if(_0x212e45!=_0x25e346[_0x14e679]){const _0x28c74a=_0x41418b[_0x5c6d('0x5b')](_0x212e45)||_0x41418b[_0x5c6d('0x5b')](_0x25e346[_0x14e679]);for(;_0x212e45!=_0x25e346[_0x14e679];)_0x291493[_0x5c6d('0x7f')](_0x25e346[_0x14e679])||(_0x468d9b[_0x5c6d('0x69')](_0x25e346[_0x14e679],_0x28c74a),_0x41418b[_0x5c6d('0x69')](_0x25e346[_0x14e679],_0x28c74a)),_0x14e679++;}_0x14e679++;}}}}for(const _0x46e076 of _0x5c3008){const _0xf8b7f2=_0x542964[_0x5c6d('0xc3')][_0x46e076];for(const _0x298749 of _0xf8b7f2){const _0x6ef235=this[_0x5c6d('0xec')](_0x298749),_0x285268=_0x298749['item']['getAttribute'](_0x6ef235);if(_0x468d9b['has'](_0x285268)){const _0x32e1cb=_0x468d9b[_0x5c6d('0x5b')](_0x285268);_0x291493[_0x5c6d('0x7f')](_0x285268)||_0x291493[_0x5c6d('0x69')](_0x285268,{..._0x32e1cb}),_0x7ef5eb[_0x5c6d('0x69')](_0x285268,{..._0x32e1cb});}}}for(const _0xd0e85c of _0x291493['keys']())_0xd0e85c>=this[_0x5c6d('0x4c')]&&_0x291493[_0x5c6d('0x45')](_0xd0e85c);const _0x159f9c=new Map();for(const _0x49d1de of _0x5c3008){let _0x3efe2a=_0x542964[_0x5c6d('0xc3')][_0x49d1de];for(const _0x271173 of _0x3efe2a)if(_0x271173[_0x5c6d('0x59')]['is'](_0x5c6d('0xa6'),_0x5c6d('0xbc'))){const _0x375e18=this['_getVidAttributeName'](_0x271173),_0x438e86=_0x271173[_0x5c6d('0x59')][_0x5c6d('0x6')](_0x375e18);if(_0x7ef5eb[_0x5c6d('0x7f')](_0x438e86)){const _0x7b1b36=_0x271173[_0x5c6d('0x59')][_0x5c6d('0x94')]['parent'][_0x5c6d('0x6')](_0x5c6d('0xa7')),_0x2a95dc=_0x159f9c['get'](_0x7b1b36)||new Set();_0x2a95dc[_0x5c6d('0x8f')](_0x7ef5eb['get'](_0x438e86)['userId']),_0x159f9c['set'](_0x7b1b36,_0x2a95dc);}}_0x3efe2a=_0x542964[_0x5c6d('0x9c')][_0x49d1de];for(const _0x291e1d of _0x3efe2a)if(_0x291e1d[_0x5c6d('0x59')]['is']('element',_0x5c6d('0xbc'))){const _0x5eeaca=this[_0x5c6d('0xec')](_0x291e1d),_0x2b4dbc=_0x291e1d[_0x5c6d('0x59')]['getAttribute'](_0x5eeaca);if(_0x291493[_0x5c6d('0x7f')](_0x2b4dbc)){const _0x2e3d3b=_0x291e1d[_0x5c6d('0x59')][_0x5c6d('0x94')]['parent'][_0x5c6d('0x6')](_0x5c6d('0xa7')),_0x32fab2=_0x159f9c[_0x5c6d('0x5b')](_0x2e3d3b)||new Set();_0x32fab2[_0x5c6d('0x8f')](_0x291493[_0x5c6d('0x5b')](_0x2b4dbc)[_0x5c6d('0x3c')]),_0x159f9c['set'](_0x2e3d3b,_0x32fab2);}}for(const _0x434d90 of _0x159f9c[_0x5c6d('0x66')]())(_0x7ef5eb[_0x5c6d('0x7f')](_0x434d90)||_0x291493[_0x5c6d('0x7f')](_0x434d90))&&_0x159f9c[_0x5c6d('0x45')](_0x434d90);}for(const _0x22bdfa of _0x5c3008){const _0x37e0ae=_0x542964[_0x5c6d('0xc3')][_0x22bdfa];let _0x398451=null,_0x4f505a=null;for(const _0x4bf46d of _0x37e0ae){const _0x564e7f=this['_getVidAttributeName'](_0x4bf46d),_0x44ac76=_0x4bf46d[_0x5c6d('0x59')]['getAttribute'](_0x564e7f),_0x2fc53b=_0x159f9c[_0x5c6d('0x5b')](_0x44ac76);_0x2fc53b&&_0x5c6d('0x79')==_0x4bf46d['type']&&(_0x398451=Array['from'](_0x2fc53b)[0x0],_0x4f505a=_0x4bf46d[_0x5c6d('0x59')][_0x5c6d('0x6')](_0x5c6d('0x1'))),_0x398451&&(_0x291493[_0x5c6d('0x69')](_0x44ac76,{'userId':_0x398451}),_0x7ef5eb['set'](_0x44ac76,{'userId':_0x398451})),_0x44ac76==_0x4f505a&&(_0x398451=null,_0x4f505a=null);}}const _0x55eb86={},_0x3f1488=new Set();for(const _0x1d0c1b of _0x5c3008){const _0xc571e8=_0xab11c8[_0x5c6d('0x9c')][_0x1d0c1b],_0x532b7d=_0xab11c8[_0x5c6d('0xc3')][_0x1d0c1b];for(const {userId:_0x538a43}of this[_0x5c6d('0x91')][_0x5c6d('0x7b')]())null!==_0x538a43&&_0x3f1488[_0x5c6d('0x8f')](_0x538a43);this[_0x5c6d('0xb8')](_0x532b7d,_0x542964['insertions'][_0x1d0c1b],_0x7ef5eb,_0x5c6d('0x84'),_0x3f1488),this[_0x5c6d('0xb8')](_0xc571e8,_0x542964[_0x5c6d('0x9c')][_0x1d0c1b],_0x291493,_0x5c6d('0x95'),_0x3f1488),_0x55eb86[_0x1d0c1b]={'insertions':this[_0x5c6d('0x68')](_0x532b7d),'deletions':this['_prepareViewToSave'](_0xc571e8)};}return{'diffData':_0x55eb86,'authorsIds':Array[_0x5c6d('0x8e')](_0x3f1488)};}['_processRootBeforeSave'](_0x30aa81){for(const [,_0x1ee6dc]of _0x30aa81[_0x5c6d('0x34')]){const _0x40ff34=_0x1ee6dc[_0x5c6d('0xa9')][_0x5c6d('0xdd')]()['filter'](_0xf5a855=>_0x5c6d('0xbc')==_0xf5a855[_0x5c6d('0x42')]);for(const _0x339341 of _0x40ff34)0x1==_0x339341['childCount']&&_0x339341[_0x5c6d('0x6d')](0x0)['is'](_0x5c6d('0xa6'),'paragraph')&&_0x339341['getChild'](0x0)[_0x5c6d('0x30')](_0x5c6d('0xa'),!0x0);}}['_prepareViewToSave'](_0x6c4154){this[_0x5c6d('0x33')](_0x6c4154);const _0xc218c5=this[_0x5c6d('0x49')][_0x5c6d('0xe0')][_0x5c6d('0x63')](_0x6c4154,{}),_0x43988c=Array[_0x5c6d('0x8e')](_0xc218c5[_0x5c6d('0xb2')]())['map'](_0xbaaa8d=>this[_0x5c6d('0x40')](_0xbaaa8d));return JSON[_0x5c6d('0xda')](_0x43988c);}[_0x5c6d('0x40')](_0x115eaf){if(_0x115eaf['is'](_0x5c6d('0xf0')))return _0x115eaf['data'];return{'type':Object[_0x5c6d('0x66')](V)['find'](_0x29bc5f=>_0x115eaf instanceof V[_0x29bc5f]),'name':_0x115eaf[_0x5c6d('0x42')],'attributes':Array[_0x5c6d('0x8e')](_0x115eaf[_0x5c6d('0x36')]()),'children':Array[_0x5c6d('0x8e')](_0x115eaf[_0x5c6d('0xb2')]())[_0x5c6d('0x21')](_0x3dcf4b=>this[_0x5c6d('0x40')](_0x3dcf4b))};}[_0x5c6d('0xb8')](_0x571ebd,_0x2c6fa3,_0x359936,_0x23edb9,_0x2b49e6){let _0x1d664f=null,_0x1b7630=null,_0x1bd654=0x0;const _0x12ddca=this[_0x5c6d('0x49')]['model'];for(let _0x4bfb53=0x0;_0x4bfb53<_0x2c6fa3[_0x5c6d('0x88')];_0x4bfb53++){const _0x2efcc0=this[_0x5c6d('0xec')](_0x2c6fa3[_0x4bfb53]),_0x439116=_0x2c6fa3[_0x4bfb53][_0x5c6d('0x59')]['getAttribute'](_0x2efcc0),_0x280d75=_0x359936['get'](_0x439116),_0x41b6ee=_0x4bfb53==_0x2c6fa3[_0x5c6d('0x88')]-0x1;(!_0x1d664f&&_0x280d75&&(_0x1d664f=_0x280d75,_0x1b7630=_0x2c6fa3[_0x4bfb53]),_0x1d664f&&(!_0x280d75||_0x280d75[_0x5c6d('0x3c')]!=_0x1d664f[_0x5c6d('0x3c')]))&&(_0xa6794b(_0x280d75,j(_0x1b7630,_0x571ebd,_0x12ddca),j(_0x2c6fa3[_0x4bfb53],_0x571ebd,_0x12ddca)),_0x1d664f=_0x280d75||null,_0x1b7630=_0x280d75?_0x2c6fa3[_0x4bfb53]:null),_0x1d664f&&_0x41b6ee&&_0xa6794b(_0x280d75,j(_0x1b7630,_0x571ebd,_0x12ddca),B(_0x2c6fa3[_0x4bfb53],_0x571ebd,_0x12ddca));}function _0xa6794b(_0x36b51a,_0x56bc44,_0x226d0b){const _0xd94df9=_0x1d664f[_0x5c6d('0x3c')],_0x4ac696=_0x5c6d('0x57')+_0x23edb9+':'+_0xd94df9+':'+_0x1bd654++,_0x4b828b=_0x12ddca[_0x5c6d('0x46')](_0x56bc44,_0x226d0b);_0x571ebd[_0x5c6d('0x34')]['set'](_0x4ac696,_0x4b828b),null!==_0xd94df9&&_0x2b49e6['add'](_0xd94df9);}}[_0x5c6d('0xec')](_0x5554ad){switch(_0x5554ad[_0x5c6d('0xe5')]){case _0x5c6d('0x79'):return'vid_start';case _0x5c6d('0xde'):return _0x5c6d('0x1');default:return _0x5c6d('0xbe');}}[_0x5c6d('0x1b')](_0x32a910,_0xf66555){_0x32a910[_0x5c6d('0x29')]=null;for(const _0x2df786 in _0x32a910){if(_0x32a910[_0x2df786]instanceof _0x302755){const _0x29d1a9=_0xf66555['get'](_0x32a910[_0x2df786][_0x5c6d('0x98')]['rootName']);_0x32a910[_0x2df786]=this[_0x5c6d('0x7e')](_0x32a910[_0x2df786],_0x29d1a9);}if(_0x32a910[_0x2df786]instanceof _0x4bafe2){const _0x6b292=_0xf66555[_0x5c6d('0x5b')](_0x32a910[_0x2df786][_0x5c6d('0x98')][_0x5c6d('0xa2')]);_0x32a910[_0x2df786]=this[_0x5c6d('0x23')](_0x32a910[_0x2df786],_0x6b292);}}_0x32a910['root']&&(_0x32a910[_0x5c6d('0x98')]=_0xf66555[_0x5c6d('0x5b')](_0x32a910[_0x5c6d('0x98')][_0x5c6d('0xa2')]));}[_0x5c6d('0x23')](_0x13641d,_0x44c8c3){return this['editor'][_0x5c6d('0x26')][_0x5c6d('0x46')](this[_0x5c6d('0x7e')](_0x13641d[_0x5c6d('0xa9')],_0x44c8c3),this[_0x5c6d('0x7e')](_0x13641d[_0x5c6d('0xd3')],_0x44c8c3));}[_0x5c6d('0x7e')](_0x3e2958,_0x5a7fdb){return this[_0x5c6d('0x49')][_0x5c6d('0x26')][_0x5c6d('0x62')](_0x5a7fdb,_0x3e2958[_0x5c6d('0x70')],_0x3e2958[_0x5c6d('0xa1')]);}[_0x5c6d('0x3b')](_0x1e714c){const _0x5c7e45=this['_idsRoots'][_0x5c6d('0x5b')](_0x1e714c[_0x5c6d('0x92')][_0x5c6d('0x98')]['rootName']),_0xfa925b=this[_0x5c6d('0x7e')](_0x1e714c[_0x5c6d('0x92')],_0x5c7e45),_0x2b97ca=null===_0x1e714c['_authorId']?null:_0x1e714c[_0x5c6d('0xaa')]||this[_0x5c6d('0x49')][_0x5c6d('0x93')]['get']('Users')['me']['id'],_0x1d1032=_0xfa925b['parent'],_0x3c9f30=this[_0x5c6d('0x5')],_0x5b08d5=[];for(const _0x5cad70 of _0x1e714c[_0x5c6d('0xaf')])if(_0x5cad70['is']('element'))_0x5b08d5['push'](this[_0x5c6d('0x44')](_0x5cad70));else for(let _0xc30caf=0x0;_0xc30caf<_0x5cad70['offsetSize'];_0xc30caf++)_0x5b08d5[_0x5c6d('0xe1')](new _0x32778a(_0x5c6d('0x17'),{'vid':this[_0x5c6d('0x5')]++}));const _0x1f4c7e=this[_0x5c6d('0x5')];for(let _0x4aa123=_0x3c9f30;_0x4aa123<_0x1f4c7e;_0x4aa123++)this[_0x5c6d('0x5c')][_0x5c6d('0x69')](_0x4aa123,{'userId':_0x2b97ca});_0x1d1032['_insertChild'](_0xfa925b[_0x5c6d('0xb4')],_0x5b08d5);}[_0x5c6d('0x2b')](_0x27a67a){(_0x27a67a=this[_0x5c6d('0xb0')](_0x27a67a,this[_0x5c6d('0xae')]))[_0x5c6d('0xac')]();const _0x44aace=null===_0x27a67a[_0x5c6d('0xaa')]?null:_0x27a67a[_0x5c6d('0xaa')]||this[_0x5c6d('0x49')][_0x5c6d('0x93')][_0x5c6d('0x5b')](_0x5c6d('0x80'))['me']['id'],_0x5111fc=_0x27a67a['getMovedRangeStart'](),_0x26998b=_0x5111fc[_0x5c6d('0x94')],_0x1730c0=_0x5111fc[_0x5c6d('0xb4')];!function _0x296c64(_0x5a5427,_0x505919,_0x3ffe13,_0x3b989b){for(let _0x1bb696=_0x3ffe13;_0x1bb696<_0x3b989b;_0x1bb696++){const _0x460bd7=_0x505919[_0x5c6d('0x6d')](_0x1bb696);_0x460bd7['is'](_0x5c6d('0xa6'),_0x5c6d('0x17'))?_0x5a5427[_0x5c6d('0x69')](_0x460bd7['getAttribute'](_0x5c6d('0xbe')),{'userId':_0x44aace}):(_0x5a5427[_0x5c6d('0x69')](_0x460bd7[_0x5c6d('0x6')]('vid_start'),{'userId':_0x44aace}),_0x296c64(_0x5a5427,_0x460bd7,0x0,_0x460bd7[_0x5c6d('0x37')]),_0x5a5427['set'](_0x460bd7['getAttribute']('vid_end'),{'userId':_0x44aace}));}}(this[_0x5c6d('0x5c')],_0x26998b,_0x1730c0,_0x1730c0+_0x27a67a[_0x5c6d('0x2e')]);}[_0x5c6d('0x65')](_0x301648){const _0x4e53ce=null===(_0x301648=this['_cloneOperation'](_0x301648,this['_idsRoots']))[_0x5c6d('0xaa')]?null:_0x301648[_0x5c6d('0xaa')]||this[_0x5c6d('0x49')][_0x5c6d('0x93')][_0x5c6d('0x5b')](_0x5c6d('0x80'))['me']['id'],_0x122feb=_0x301648[_0x5c6d('0x8d')][_0x5c6d('0x94')],_0x35d225=_0x301648[_0x5c6d('0x22')][_0x5c6d('0x94')],_0x559904=_0x122feb['getAttribute'](_0x5c6d('0x1')),_0x376c0f=_0x35d225['getAttribute']('vid_start');_0x122feb['_setAttribute'](_0x5c6d('0x1'),_0x35d225['getAttribute']('vid_end')),_0x35d225[_0x5c6d('0x30')](_0x5c6d('0x1'),_0x559904),this['_touched'][_0x5c6d('0x69')](_0x376c0f,{'userId':_0x4e53ce}),this['_touched'][_0x5c6d('0x69')](_0x559904,{'userId':_0x4e53ce}),_0x301648[_0x5c6d('0xac')]();}[_0x5c6d('0xdf')](_0x109ffb){const _0x485705=null===(_0x109ffb=this[_0x5c6d('0xb0')](_0x109ffb,this[_0x5c6d('0xae')]))[_0x5c6d('0xaa')]?null:_0x109ffb[_0x5c6d('0xaa')]||this[_0x5c6d('0x49')][_0x5c6d('0x93')]['get']('Users')['me']['id'],_0x34b17c=_0x109ffb[_0x5c6d('0xe9')],_0x143fc5=_0x109ffb[_0x5c6d('0x85')][_0x5c6d('0x94')];_0x109ffb[_0x5c6d('0xac')]();const _0x1ae10a=_0x143fc5[_0x5c6d('0x6')](_0x5c6d('0x1')),_0x146f9c=_0x109ffb[_0x5c6d('0x6c')][_0x5c6d('0xb')];if(_0x34b17c){const _0x5b2771=_0x146f9c[_0x5c6d('0x6')](_0x5c6d('0x1')),_0x4aa338=_0x143fc5[_0x5c6d('0x6')](_0x5c6d('0x1'));_0x143fc5[_0x5c6d('0x30')](_0x5c6d('0x1'),_0x5b2771),_0x146f9c[_0x5c6d('0x30')](_0x5c6d('0x1'),_0x4aa338),this[_0x5c6d('0x5c')][_0x5c6d('0x69')](_0x143fc5[_0x5c6d('0x6')](_0x5c6d('0x1')),{'userId':_0x485705}),this[_0x5c6d('0x5c')]['set'](_0x146f9c[_0x5c6d('0x6')](_0x5c6d('0xa7')),{'userId':_0x485705});}else{const _0x2de100=this[_0x5c6d('0x5')]++,_0x5f3230=this[_0x5c6d('0x5')]++;_0x143fc5[_0x5c6d('0x30')](_0x5c6d('0x1'),_0x2de100),_0x146f9c['_setAttribute']('vid_start',_0x5f3230),_0x146f9c[_0x5c6d('0x30')](_0x5c6d('0x1'),_0x1ae10a),this[_0x5c6d('0x5c')][_0x5c6d('0x69')](_0x2de100,{'userId':_0x485705}),this['_touched']['set'](_0x5f3230,{'userId':_0x485705});}}[_0x5c6d('0x7d')](_0x3b00f6){if(!_0x3b00f6[_0x5c6d('0x67')])return;const _0x2b2a84=(_0x3b00f6=this[_0x5c6d('0xb0')](_0x3b00f6,this['_diffRoots']))['oldRange']?_0x3b00f6[_0x5c6d('0x9b')]['root']:null,_0x2b9d50=_0x3b00f6[_0x5c6d('0xcc')]?_0x3b00f6[_0x5c6d('0xcc')][_0x5c6d('0x98')]:null;_0x2b2a84&&this[_0x5c6d('0x89')][_0x5c6d('0x45')](_0x3b00f6[_0x5c6d('0x42')]),_0x2b9d50&&this['_markers'][_0x5c6d('0x69')](_0x3b00f6[_0x5c6d('0x42')],_0x3b00f6['newRange'][_0x5c6d('0x47')]());const _0xccd8e6=null===_0x3b00f6['_authorId']?null:_0x3b00f6[_0x5c6d('0xaa')]||this[_0x5c6d('0x49')][_0x5c6d('0x93')][_0x5c6d('0x5b')]('Users')['me']['id'],_0x41ef6b=_0x3b00f6[_0x5c6d('0x42')];if(!this[_0x5c6d('0x91')][_0x5c6d('0x7f')](_0x41ef6b))return void this[_0x5c6d('0x91')][_0x5c6d('0x69')](_0x41ef6b,{'range':_0x3b00f6[_0x5c6d('0x9b')],'userId':_0xccd8e6});const _0x3b25a0=this[_0x5c6d('0x91')][_0x5c6d('0x5b')](_0x41ef6b),_0x49185c=_0x3b25a0[_0x5c6d('0x99')],_0x36bc64=_0x3b00f6[_0x5c6d('0xcc')];null==_0x49185c&&null==_0x36bc64||_0x49185c&&_0x36bc64&&_0x49185c[_0x5c6d('0x9e')](_0x36bc64)?this[_0x5c6d('0x91')]['delete'](_0x3b00f6['name']):_0x3b25a0['userId']=_0xccd8e6;}}function J(_0x2aa62e){const _0x2962c8=new _0x5c8a1f();_0x2962c8[_0x5c6d('0xa2')]=_0x2aa62e[_0x5c6d('0xa2')];for(const _0x293abb of _0x2aa62e['getChildren']()){const _0x19b08f=_0x293abb[_0x5c6d('0x3')](!0x0);_0x2962c8['_appendChild'](_0x19b08f);}return _0x2962c8;}function j(_0x568906,_0x47672a,_0x599a82){const _0x1b5541=_0x5c6d('0xde')==_0x568906['type']?_0x599a82[_0x5c6d('0xb3')](_0x568906[_0x5c6d('0x59')],'end'):_0x599a82[_0x5c6d('0x97')](_0x568906[_0x5c6d('0x59')]);return _0x1b5541[_0x5c6d('0x98')]=_0x47672a,_0x1b5541;}function B(_0x279138,_0x53dc4b,_0x36ff34){const _0x3fe4a7=_0x5c6d('0x79')==_0x279138[_0x5c6d('0xe5')]?_0x36ff34[_0x5c6d('0xb3')](_0x279138[_0x5c6d('0x59')],0x0):_0x36ff34['createPositionAfter'](_0x279138[_0x5c6d('0x59')]);return _0x3fe4a7[_0x5c6d('0x98')]=_0x53dc4b,_0x3fe4a7;}
|
|
23
|
+
const _0x45a4=['text','root','_diffRoots','_reset','previousPosition','documentFragment','offset','_removeMetaData','baseVersion','_setAttribute','_handleSplitOperation','_savedMetaData','insertionPosition','_baseIdsRoots','_getState','history','_handleOperation','_execute','insert','getUser','requires','hasContent','for','bind','processor','_lastTo','getRevision','isReady','_removePendingAction','filter','markerToData','vid_end','end','_baseRoots','_continueCurrentRevision','marked','reInit','define','deletions','vid','item','ready','type','getNodeByPath','delete','_loadRevisionData','dataDowncast','insertion','getWalker','$graveyard','slice','createPositionAt','getRevisionDocumentData','stickiness','remove','update','childCount','elementEnd','source','pluginName','has','getRootNames','clear','path','view','createPositionBefore','getRevisions','length','fromVersion','_fixRange','_addPendingAction','config','stringify','_getFromVersion','_source','_touchedMarkers','name','toView','dataToMarker','version','set','nodeAfter','keepParagraph','_authorId','startsWith','Empty\x20document','_prepareViewToSave','_handleMoveOperation','_handleMarkerOperation','move','_loadedStateData','toModel','get','_createInitialRevision','getAttribute','nodes','collaboration.channelId','PENDING_ACTION_REVISION_HISTORY','creator','plugins','split','addRevision','size','_getViewJson','editor','merge','_saveMetaData','afterInit','_initialRevisionId','getOperation','getAttributes','_getVidAttributeName','from','getCurrentRevisionId','getRoot','paragraph','_bufferedUpdates','toVersion','locale','tableCell','_idsRoots','diffData','_isPendingUpdate','getLatestVersion','_cloneOperation','_createCurrentRevision','oldRange','Users','_startingVersion','elementStart','_setConversion','affectsData','RevisionsRepository','upcast','_replaceEditorDataWithRevisionData','createRange','data','getData','_getBaseVids','sendBufferedUpdates','getTime','targetPosition','setRevisionData','_appendChild','editing','attributes','insertions','clone','_startingRevisionId','offsetSize','initial','getRange','createRangeIn','RealTimeCollaborationClient','then','start','_touched','vid_start','_removeRevisionMarkers','_copyMarkers','_calculateMetaData','buildRevisionData','parent','_transformMarkers','_findInsertionIndex','getChildren','_fixOperation','revision','document','getAncestors','keys','init','useFillerType','position','RevisionTracker','_fixPosition','_applyOperations','_loadState','$text','push','_handleInsertOperation','_processRootBeforeSave','getOperations','_revisionDataBuilder','markers','createPositionAfter','_rootNames','_markers','authorsIds','_insertChild','userId','authors','find','_markChanges','string','addRevisionData','_operations','reverse','initialData','createPositionFromPath','_makeModelFromViewString','sort','_lastFrom','_handleMergeOperation','_isInit','revision:','map','adapter','element','add','_generateTape','trim','loadState','getTransformedByOperation','max','_update','graveyardPosition','newRange','_bufferUpdate','children','marker','rootName','revision-end','values','PendingActions','repository','_makeIdsRoot','getChild','reinsert','currentRevision','creatorId','setSource','_pendingAction','_makeRevision','_revisionId','conversion','model','createdAt','_createFromRanges'];(function(_0xf90af3,_0x45a497){const _0xe08c20=function(_0x26780d){while(--_0x26780d){_0xf90af3['push'](_0xf90af3['shift']());}};_0xe08c20(++_0x45a497);}(_0x45a4,0xa5));const _0xe08c=function(_0xf90af3,_0x45a497){_0xf90af3=_0xf90af3-0x0;let _0xe08c20=_0x45a4[_0xf90af3];return _0xe08c20;};import{Users as _0x4623a4}from'ckeditor5-collaboration/src/collaboration-core';import{Plugin as _0x2fd8db,PendingActions as _0x2532ec}from'ckeditor5/src/core';import{logWarning as _0x6ec304,uid as _0x37c5ee}from'ckeditor5/src/utils';import{Position as _0x3a19a0,Range as _0x18b630,Element as _0x45e8ea,DocumentFragment as _0x588493,ViewText as _0x9a4db5,ViewElement as _0xc72f6f,ViewContainerElement as _0x43cfc1,ViewAttributeElement as _0x2c176b,ViewEmptyElement as _0x46fdea,ViewRawElement as _0x4ffca5,ViewUIElement as _0x328a24,ViewDocumentFragment as _0x409a7f}from'ckeditor5/src/engine';import _0x114a5e from'./revisionsrepository';import{getTranslation as _0x2bf8a0}from'./utils/common-translations';const V={'c':_0x43cfc1,'a':_0x2c176b,'e':_0x46fdea,'r':_0x4ffca5,'u':_0x328a24};export default class l extends _0x2fd8db{static get[_0xe08c('0x85')](){return _0xe08c('0x9');}static get[_0xe08c('0x5e')](){return[_0x4623a4,_0x114a5e,_0x2532ec];}constructor(_0x40dfa7){super(_0x40dfa7),this[_0xe08c('0x2a')]=null,this[_0xe08c('0x40')]=null,this[_0xe08c('0x12')]=new T(this['editor']),this[_0xe08c('0xb6')]=this[_0xe08c('0xb2')][_0xe08c('0x91')]['get'](_0xe08c('0xaa'))||_0xe08c('0xe0'),this[_0xe08c('0xbe')]=new Map(),this['_loadedStateData']=null;const _0x4840eb=_0x37c5ee();this[_0xe08c('0x94')]={'history':this[_0xe08c('0xb2')][_0xe08c('0x47')]['document'][_0xe08c('0x59')],'getLatestVersion':()=>Promise['resolve'](this[_0xe08c('0xb2')][_0xe08c('0x47')][_0xe08c('0x3')][_0xe08c('0x99')]),'getCurrentRevisionId':()=>_0x4840eb},this[_0xe08c('0x9a')]('isReady',!0x1),this['set']('isEnabled',!0x0),this[_0xe08c('0x9a')]('_isPendingUpdate',!0x1),this[_0xe08c('0xb2')]['config'][_0xe08c('0x6f')]('revisionHistory.resumeUnsavedRevision',!0x0),this[_0xe08c('0xb2')][_0xe08c('0x46')][_0xe08c('0x60')](_0xe08c('0xcf'))[_0xe08c('0x98')]({'view':'revision'});}[_0xe08c('0x6')](){this['repository']=this[_0xe08c('0xb2')][_0xe08c('0xad')][_0xe08c('0xa6')](_0xe08c('0xce')),this[_0xe08c('0xcc')](),this['editor']['data']['on'](_0xe08c('0x73'),()=>{const _0x4857fd=this[_0xe08c('0x3c')][_0xe08c('0x64')](0x0),_0x85f8d1=_0x4857fd&&null===_0x4857fd[_0xe08c('0xac')]?_0x4857fd:null;if(this[_0xe08c('0x6c')]=!!_0x85f8d1&&this[_0xe08c('0xb2')]['config'][_0xe08c('0xa6')]('revisionHistory.resumeUnsavedRevision'),this['editor'][_0xe08c('0xad')]['has'](_0xe08c('0xe3'))){const _0x1a9145=this['_source'][_0xe08c('0xbb')](),_0x1f6452=this[_0xe08c('0x3c')][_0xe08c('0x64')](_0x1a9145);if(_0x1f6452)this['_startingVersion']=_0x1f6452[_0xe08c('0x8e')],this[_0xe08c('0x6c')]=!0x1;else{const _0x1c91a7=this[_0xe08c('0x94')][_0xe08c('0x59')][_0xe08c('0x1f')][_0xe08c('0x1b')](_0x1c55b6=>!_0x1c55b6[_0xe08c('0x27')]),_0x12125c=_0x1c91a7?_0x1c91a7[_0xe08c('0x52')]:this[_0xe08c('0x94')][_0xe08c('0x59')][_0xe08c('0x99')];_0x4857fd?(_0x4857fd['toVersion']<_0x12125c&&_0x4857fd['_update']({'toVersion':_0x12125c}),this[_0xe08c('0x6c')]?(this[_0xe08c('0x94')][_0xe08c('0xbb')]=()=>_0x85f8d1['id'],this[_0xe08c('0xca')]=_0x85f8d1[_0xe08c('0x8e')]):(this[_0xe08c('0xca')]=_0x4857fd['toVersion'],this[_0xe08c('0x6c')]=!0x1)):(this[_0xe08c('0xca')]=_0x12125c,this[_0xe08c('0x6c')]=!0x1);}}else _0x85f8d1&&(this['editor'][_0xe08c('0x47')][_0xe08c('0x3')][_0xe08c('0x59')][_0xe08c('0x99')]=Math[_0xe08c('0x31')](_0x85f8d1[_0xe08c('0xbf')],this['editor'][_0xe08c('0x47')][_0xe08c('0x3')][_0xe08c('0x59')]['version']),_0x85f8d1[_0xe08c('0x8e')]===_0x85f8d1[_0xe08c('0xbf')]?(0x0!==_0x85f8d1[_0xe08c('0x8e')]&&(this[_0xe08c('0x94')]['getCurrentRevisionId']=()=>_0x85f8d1['id']),this[_0xe08c('0x6c')]=!0x1):this[_0xe08c('0x6c')]&&(this['_source'][_0xe08c('0xbb')]=()=>_0x85f8d1['id'],this[_0xe08c('0xca')]=_0x85f8d1[_0xe08c('0x8e')])),this['_continueCurrentRevision']||(this[_0xe08c('0xca')]=this[_0xe08c('0xb2')][_0xe08c('0x47')][_0xe08c('0x3')][_0xe08c('0x99')]);this[_0xe08c('0x12')][_0xe08c('0x6')](this[_0xe08c('0x94')][_0xe08c('0x59')]),this[_0xe08c('0xa7')](this[_0xe08c('0xca')]),this[_0xe08c('0xc7')](this[_0xe08c('0xca')]),this[_0xe08c('0x2a')]&&this['sendBufferedUpdates']();}),this[_0xe08c('0x61')](_0xe08c('0x65'))['to'](this,_0xe08c('0xc4'),_0x4eaebe=>!_0x4eaebe);}async[_0xe08c('0xb5')](){if(this[_0xe08c('0x3c')][_0xe08c('0x8d')]>0x0){const _0x92bdbf=this[_0xe08c('0x3c')][_0xe08c('0x64')](0x0),_0x2e2164=await this[_0xe08c('0x7e')](_0x92bdbf);this[_0xe08c('0xd0')](_0x2e2164);}}[_0xe08c('0x42')](_0x3e6ae4){this['_source']=_0x3e6ae4;}async[_0xe08c('0x81')](){const _0xa9ab01=await this[_0xe08c('0x94')]['getLatestVersion']();if(_0xa9ab01>this[_0xe08c('0x40')][_0xe08c('0xbf')]){await this[_0xe08c('0xc')]();const _0x464929=this[_0xe08c('0xeb')]({'revision':this[_0xe08c('0x40')],'to':_0xa9ab01});_0x464929['authors']=_0x464929['authorsIds'][_0xe08c('0x29')](_0x5b9161=>this[_0xe08c('0xb2')]['plugins'][_0xe08c('0xa6')](_0xe08c('0xc9'))[_0xe08c('0x5d')](_0x5b9161)),this['currentRevision']['_update'](_0x464929);}}async[_0xe08c('0xc')](){this['_continueCurrentRevision']&&!this[_0xe08c('0xa4')]&&(await this[_0xe08c('0x77')](this[_0xe08c('0x40')]),this[_0xe08c('0x12')]['loadState'](this['currentRevision']),this[_0xe08c('0xa4')]={'fromVersion':this[_0xe08c('0x40')][_0xe08c('0x8e')],'authors':this[_0xe08c('0x40')]['authors']['slice']()});}async['saveRevision'](_0x26414b={},_0x44cdfd=null){const _0x3d1598=[];await this[_0xe08c('0xc')](),this[_0xe08c('0x6c')]=!0x1,_0x44cdfd>this[_0xe08c('0x40')][_0xe08c('0xbf')]&&(_0x44cdfd=null),null===_0x44cdfd&&(_0x44cdfd=await this[_0xe08c('0x94')][_0xe08c('0xc5')]());const _0xc622e3=this['_getFromVersion'](_0x44cdfd),_0x2b0680=this['buildRevisionData']({'from':_0xc622e3,'to':_0x44cdfd});if(this[_0xe08c('0x40')][_0xe08c('0xbf')]<_0x44cdfd){const _0x144b6a=this[_0xe08c('0xeb')]({'revision':this['currentRevision'],'from':_0x44cdfd,'to':_0x44cdfd});_0x144b6a['authors']=[],_0x144b6a[_0xe08c('0x17')]=[],_0x144b6a['id']=this[_0xe08c('0x40')]['id'],this[_0xe08c('0x40')][_0xe08c('0x32')](_0x144b6a,!0x0),delete _0x144b6a[_0xe08c('0x1a')],_0x3d1598[_0xe08c('0xe')](_0x144b6a);}_0x26414b['creatorId']=this[_0xe08c('0xb2')][_0xe08c('0xad')]['get']('Users')['me']['id'],_0x26414b[_0xe08c('0x96')]=_0x26414b[_0xe08c('0x96')]||null,_0x26414b['id']=_0x26414b['id']||_0x37c5ee(),_0x26414b={..._0x26414b,..._0x2b0680};const _0x4d76cc=this[_0xe08c('0x1e')](_0x26414b);_0x3d1598[_0xe08c('0xe')](_0x26414b);const _0x2c2286=this['repository']['getIndex'](_0x4d76cc);if(0x0!==_0x2c2286){const _0x12aa58=this[_0xe08c('0x3c')][_0xe08c('0x64')](_0x2c2286-0x1);if(_0x12aa58[_0xe08c('0x8e')]!==_0x44cdfd){const _0x3cc61b=this[_0xe08c('0x12')][_0xe08c('0xd3')](_0x44cdfd,_0x12aa58[_0xe08c('0xbf')]),_0x2e92c5={'id':_0x12aa58['id'],'diffData':_0x3cc61b['diffData'],'authorsIds':_0x3cc61b[_0xe08c('0x17')],'authors':_0x3cc61b[_0xe08c('0x17')][_0xe08c('0x29')](_0x5d02eb=>this['editor'][_0xe08c('0xad')][_0xe08c('0xa6')](_0xe08c('0xc9'))[_0xe08c('0x5d')](_0x5d02eb)),'fromVersion':_0x44cdfd};_0x12aa58===this[_0xe08c('0x40')]&&(_0x2e92c5[_0xe08c('0x48')]=new Date(_0x26414b['createdAt'][_0xe08c('0xd6')]()+0xa)),_0x12aa58[_0xe08c('0x32')](_0x2e92c5,!0x0),delete _0x2e92c5['authors'],_0x3d1598[_0xe08c('0xe')](_0x2e92c5);}}if(this[_0xe08c('0x2a')]){for(const _0x126cb0 of _0x3d1598)this['_bufferUpdate'](_0x126cb0['id'],_0x126cb0,!0x0);this[_0xe08c('0xd5')]();}return _0x4d76cc;}[_0xe08c('0x1e')](_0x5eea17){const _0x46a821=this[_0xe08c('0x3c')]['createRevision'](_0x5eea17);return this[_0xe08c('0x2a')]&&_0x46a821['on'](_0xe08c('0x32'),(_0x10351f,_0x3fef8d,_0x3bfe14)=>{_0x3bfe14||(this[_0xe08c('0x35')](_0x3fef8d['id'],_0x3fef8d,!0x0),this[_0xe08c('0xd5')]());}),this[_0xe08c('0x3c')][_0xe08c('0xaf')](_0x46a821,this[_0xe08c('0xee')](_0x46a821)),_0x46a821;}async[_0xe08c('0x7e')](_0x487bbe){await this[_0xe08c('0x77')](_0x487bbe);const _0x3383a7={};for(const _0x4fda3f in _0x487bbe['diffData']){const _0x28dc16=this[_0xe08c('0xe8')](JSON['parse'](_0x487bbe[_0xe08c('0xc3')][_0x4fda3f]['insertions'])),_0x2e3adc=this['editor'][_0xe08c('0xda')][_0xe08c('0x8a')][_0xe08c('0x3')],_0x3037c5=new _0x409a7f(_0x2e3adc,_0x28dc16[_0xe08c('0x29')](_0x430662=>F(_0x430662,this[_0xe08c('0xb2')])));this[_0xe08c('0xb2')][_0xe08c('0xd2')]['processor'][_0xe08c('0x7')](_0xe08c('0x6d')),_0x3383a7[_0x4fda3f]=this[_0xe08c('0xb2')][_0xe08c('0xd2')][_0xe08c('0x62')]['toData'](_0x3037c5),this[_0xe08c('0xb2')]['data'][_0xe08c('0x62')]['useFillerType']('default');}return _0x3383a7;}[_0xe08c('0xd5')](){if(0x0===this['_bufferedUpdates']['size'])return;if(this[_0xe08c('0xc4')])return;let _0x1ee2c3=Array[_0xe08c('0xba')](this['_bufferedUpdates']['values']());this[_0xe08c('0xbe')][_0xe08c('0x88')]();for(let _0x3e8bc5=0x0;_0x3e8bc5<_0x1ee2c3[_0xe08c('0x8d')];_0x3e8bc5++){const _0x55c4f9=_0x1ee2c3[_0x3e8bc5];let _0x254c5c=!0x1;for(const _0xffe922 of Object[_0xe08c('0x5')](_0x55c4f9))void 0x0===_0x55c4f9[_0xffe922]?delete _0x55c4f9[_0xffe922]:'id'!==_0xffe922&&(_0x254c5c=!0x0);_0x254c5c||(_0x1ee2c3[_0x3e8bc5]=null);}if(_0x1ee2c3=_0x1ee2c3[_0xe08c('0x67')](_0x3fa2db=>null!==_0x3fa2db),!_0x1ee2c3[_0xe08c('0x8d')])return;for(let _0x5bcc3f=0x0;_0x5bcc3f<_0x1ee2c3[_0xe08c('0x8d')];_0x5bcc3f++){const _0x47539c=_0x1ee2c3[_0x5bcc3f];void 0x0!==_0x47539c[_0xe08c('0x8e')]&&void 0x0===_0x47539c[_0xe08c('0xbf')]&&(_0x47539c['toVersion']=this[_0xe08c('0x3c')][_0xe08c('0x64')](_0x47539c['id'])[_0xe08c('0xbf')]),void 0x0!==_0x47539c[_0xe08c('0xbf')]&&void 0x0===_0x47539c['fromVersion']&&(_0x47539c[_0xe08c('0x8e')]=this[_0xe08c('0x3c')][_0xe08c('0x64')](_0x47539c['id'])['fromVersion']);}const _0x27a76d=this[_0xe08c('0xb2')][_0xe08c('0x91')][_0xe08c('0xa6')](_0xe08c('0xaa'));this[_0xe08c('0xc4')]=!0x0,this[_0xe08c('0x90')](),this[_0xe08c('0x2a')]['updateRevisions'](_0x1ee2c3,_0x27a76d)['finally'](()=>{this[_0xe08c('0xc4')]=!0x1;})[_0xe08c('0xe4')](_0x2c9f88=>{if(_0x2c9f88)for(const _0x59d58c of _0x2c9f88)this[_0xe08c('0xd8')]({'id':_0x59d58c['id'],'createdAt':_0x59d58c[_0xe08c('0x48')]});this[_0xe08c('0x66')](),this[_0xe08c('0xd5')]();});}[_0xe08c('0xd0')](_0x3c13a3){let _0x56cb88=this['editor'][_0xe08c('0x91')][_0xe08c('0xa6')](_0xe08c('0x21'));if(void 0x0===_0x56cb88){_0x56cb88={};for(const _0x278232 of this['editor']['model'][_0xe08c('0x3')][_0xe08c('0x87')]())_0x56cb88[_0x278232]='';}_0xe08c('0x1d')==typeof _0x56cb88&&(_0x56cb88={'main':_0x56cb88});let _0x2f6fad=!0x1;for(const _0x4ff293 of Object['keys'](_0x56cb88))_0x3c13a3[_0x4ff293]&&(_0x56cb88[_0x4ff293]!==_0x3c13a3[_0x4ff293]&&''!==_0x56cb88[_0x4ff293][_0xe08c('0x2e')]()&&(_0x2f6fad=!0x0),_0x56cb88[_0x4ff293]=_0x3c13a3[_0x4ff293]);_0x2f6fad&&_0x6ec304('editor-initial-data-replaced-with-revision-data'),this['editor'][_0xe08c('0x91')][_0xe08c('0x9a')]('initialData',_0x56cb88);}[_0xe08c('0x90')](){if(!this['_pendingAction']){const _0x5c2fed=this[_0xe08c('0xb2')][_0xe08c('0xad')]['get'](_0xe08c('0x3b'));this[_0xe08c('0x43')]=_0x5c2fed[_0xe08c('0x2c')](_0x2bf8a0(this['editor']['locale'],_0xe08c('0xab')));}}[_0xe08c('0x66')](){this[_0xe08c('0x43')]&&(this[_0xe08c('0xb2')][_0xe08c('0xad')][_0xe08c('0xa6')](_0xe08c('0x3b'))[_0xe08c('0x80')](this['_pendingAction']),this[_0xe08c('0x43')]=null);}[_0xe08c('0xee')](_0x3610c9){const _0x391477=this[_0xe08c('0x3c')][_0xe08c('0x8c')]();_0x391477[_0xe08c('0x20')]();let _0xacac58=0x0;for(;_0xacac58<_0x391477[_0xe08c('0x8d')];){const _0x3f8e0a=_0x391477[_0xacac58];if(_0x3f8e0a===this[_0xe08c('0x40')]){_0xacac58++;continue;}if(_0x3f8e0a['id']===this['_initialRevisionId'])break;const _0x39c4fc=_0x3610c9[_0xe08c('0xbf')]-_0x3f8e0a['toVersion']||_0x3610c9['fromVersion']-_0x3f8e0a[_0xe08c('0x8e')];if(_0x39c4fc>0x0)break;if(_0x39c4fc<0x0)_0xacac58++;else{if(!_0x3610c9[_0xe08c('0xac')]&&_0x3f8e0a[_0xe08c('0xac')])break;if(_0x3f8e0a[_0xe08c('0xac')]||!_0x3610c9[_0xe08c('0xac')]){if(_0x3610c9[_0xe08c('0x48')]>_0x3f8e0a[_0xe08c('0x48')])break;_0xacac58++;}else _0xacac58++;}}return _0xacac58;}[_0xe08c('0xd8')](_0x46fd5c){const _0x4e5311=this[_0xe08c('0x3c')][_0xe08c('0x64')](_0x46fd5c['id']);if(_0x46fd5c[_0xe08c('0x48')]&&(_0x46fd5c[_0xe08c('0x48')]=new Date(_0x46fd5c[_0xe08c('0x48')])),_0x46fd5c[_0xe08c('0x17')]){const _0x3c695e=this[_0xe08c('0xb2')]['plugins'][_0xe08c('0xa6')]('Users');_0x46fd5c[_0xe08c('0x1a')]=_0x46fd5c['authorsIds'][_0xe08c('0x29')](_0x21e4a0=>_0x3c695e['getUser'](_0x21e4a0));}_0x4e5311['_update'](_0x46fd5c,!0x0);}[_0xe08c('0xeb')]({revision:_0x2a6be7=null,from:_0x2cf3a3=null,to:_0x1cc586=null}){_0x2cf3a3=null!==_0x2cf3a3?_0x2cf3a3:_0x2a6be7[_0xe08c('0x8e')],_0x1cc586=null!==_0x1cc586?_0x1cc586:_0x2a6be7[_0xe08c('0xbf')];const _0x3bd308=this[_0xe08c('0x12')][_0xe08c('0xd3')](_0x2cf3a3,_0x1cc586),_0x49d84b={'diffData':_0x3bd308[_0xe08c('0xc3')],'authorsIds':_0x3bd308[_0xe08c('0x17')],'fromVersion':_0x2cf3a3,'toVersion':_0x1cc586};if(!_0x2a6be7||_0x1cc586!==_0x2a6be7[_0xe08c('0xbf')]){const _0x445c48=_0x1cc586-0x1,_0x6bde10=this['_source']['history'][_0xe08c('0xb7')](_0x445c48);_0x49d84b['createdAt']=_0x6bde10&&_0x6bde10[_0xe08c('0x48')]||new Date();}if(this[_0xe08c('0xa4')]&&_0x2cf3a3===this['_loadedStateData'][_0xe08c('0x8e')])for(const _0x64174a of this[_0xe08c('0xa4')][_0xe08c('0x1a')])_0x49d84b['authorsIds']['includes'](_0x64174a['id'])||_0x49d84b[_0xe08c('0x17')][_0xe08c('0xe')](_0x64174a['id']);return _0x49d84b;}['_loadRevisionData'](_0x8240f5){if(!_0x8240f5||_0x8240f5['diffData'])return Promise['resolve']();{const _0x5b7e7d=this['editor'][_0xe08c('0x91')]['get'](_0xe08c('0xaa'));return this[_0xe08c('0x2a')][_0xe08c('0x64')]({'channelId':_0x5b7e7d,'revisionId':_0x8240f5['id']})[_0xe08c('0xe4')](_0x43b67d=>{_0x8240f5['diffData']=_0x43b67d[_0xe08c('0xc3')];});}}[_0xe08c('0x35')](_0xddf155,_0x488beb,_0x343f13){if(this[_0xe08c('0xbe')][_0xe08c('0x86')](_0xddf155)){const _0x35f227=this[_0xe08c('0xbe')][_0xe08c('0xa6')](_0xddf155);_0x488beb=_0x343f13?{..._0x35f227,..._0x488beb}:{..._0x488beb,..._0x35f227};}this[_0xe08c('0xbe')]['set'](_0xddf155,_0x488beb);}[_0xe08c('0x93')](_0xf0e0e3){const _0x2ed5e7=this[_0xe08c('0x3c')][_0xe08c('0x8c')]();_0x2ed5e7[_0xe08c('0x20')](),_0x2ed5e7['shift']();const _0x3ec06d=_0x2ed5e7[_0xe08c('0x1b')](_0xc0fbd1=>_0xc0fbd1[_0xe08c('0xbf')]<=_0xf0e0e3)[_0xe08c('0xbf')];return _0x3ec06d<this[_0xe08c('0xca')]?this[_0xe08c('0xca')]:_0x3ec06d;}[_0xe08c('0xa7')](_0xbe5993){const _0x4abe7b=this[_0xe08c('0x3c')][_0xe08c('0x64')](this[_0xe08c('0x3c')]['length']-0x1);if(_0x4abe7b)this[_0xe08c('0xb6')]=_0x4abe7b['id'];else{const _0x56f476=!this[_0xe08c('0xb2')]['model'][_0xe08c('0x3')]['roots'][_0xe08c('0x1b')](_0x103577=>this['editor']['model'][_0xe08c('0x5f')](_0x103577)),_0x3c3775=this[_0xe08c('0xb2')][_0xe08c('0xad')][_0xe08c('0xa6')](_0xe08c('0xc9'))['me']['id'],_0x44d218=_0x2bf8a0(this['editor'][_0xe08c('0xc0')],_0x56f476?_0xe08c('0x9f'):'Initial\x20revision');this[_0xe08c('0x44')]({'from':_0xbe5993,'to':_0xbe5993,'id':this[_0xe08c('0xb6')],'name':_0x44d218,'creatorId':_0x3c3775});}}[_0xe08c('0xc7')](_0x1196af){const _0x5bf210=this[_0xe08c('0x94')]['getCurrentRevisionId']();this['currentRevision']=this['repository'][_0xe08c('0x64')](_0x5bf210),this['currentRevision']||(this[_0xe08c('0x40')]=this['_makeRevision']({'from':_0x1196af,'to':_0x1196af,'id':_0x5bf210,'name':'','creatorId':null}));}[_0xe08c('0x44')]({name:_0x39568e,from:_0x1ad87d,to:_0xc74caf,creatorId:_0x2d641a,id:_0xbeed2e}){const _0x4186ce=this['buildRevisionData']({'from':_0x1ad87d,'to':_0xc74caf});_0x4186ce[_0xe08c('0x96')]=_0x39568e,_0x4186ce[_0xe08c('0x41')]=_0x2d641a,_0x4186ce['id']=_0xbeed2e;const _0x261c4=this[_0xe08c('0x1e')](_0x4186ce);return this[_0xe08c('0x2a')]&&this[_0xe08c('0x35')](_0x4186ce['id'],_0x4186ce,!0x0),_0x261c4;}['_setConversion'](){this[_0xe08c('0xb2')][_0xe08c('0x46')][_0xe08c('0x60')](_0xe08c('0x78'))[_0xe08c('0x68')]({'model':_0xe08c('0x2')});}[_0xe08c('0xe8')](_0x50ec08){return(_0x50ec08=_0x50ec08[_0xe08c('0x67')](_0x4634bd=>!_0x4634bd['name']||'revision-start'!==_0x4634bd[_0xe08c('0x96')]&&_0xe08c('0x39')!==_0x4634bd[_0xe08c('0x96')]))['forEach'](_0x3f62ef=>{_0xe08c('0x1d')!=typeof _0x3f62ef&&(_0x3f62ef['children']=this[_0xe08c('0xe8')](_0x3f62ef['children']),_0x3f62ef[_0xe08c('0xdb')]=_0x3f62ef['attributes'][_0xe08c('0x67')](_0xa33251=>!_0xa33251[0x0][_0xe08c('0x9e')]('data-revision-')));}),_0x50ec08;}}function F(_0x5b4ad4,_0x42a73d){const _0x17741e=_0x42a73d[_0xe08c('0xda')][_0xe08c('0x8a')]['document'];if('string'==typeof _0x5b4ad4)return new _0x9a4db5(_0x17741e,_0x5b4ad4);{const _0x14bfe4=_0x5b4ad4[_0xe08c('0x36')]['map'](_0x574ad3=>F(_0x574ad3,_0x42a73d));return new(V[_0x5b4ad4[(_0xe08c('0x74'))]]||_0xc72f6f)(_0x17741e,_0x5b4ad4[_0xe08c('0x96')],_0x5b4ad4[_0xe08c('0xdb')],_0x14bfe4);}}class T{constructor(_0x2bbc2f){this[_0xe08c('0xb2')]=_0x2bbc2f,this[_0xe08c('0x55')]=new Map(),this[_0xe08c('0x25')]=-0x1,this[_0xe08c('0x63')]=-0x1,this[_0xe08c('0x16')]=new Map(),this[_0xe08c('0x4c')]=new Map(),this[_0xe08c('0x6b')]=new Map(),this[_0xe08c('0xc2')]=new Map(),this[_0xe08c('0x57')]=new Map(),this['_touched']=new Map(),this[_0xe08c('0x95')]=new Map(),this['_revisionId']=0x1,this['_rootNames']=this[_0xe08c('0xb2')]['model']['document'][_0xe08c('0x87')](),this[_0xe08c('0x15')]['push'](_0xe08c('0x7b'));}[_0xe08c('0x6')](_0x41c8bd){this['source']=_0x41c8bd;const _0x7b8706=new Map();for(const _0x57a0f7 of this[_0xe08c('0x15')]){const _0x386713=J(this[_0xe08c('0xb2')][_0xe08c('0x47')]['document'][_0xe08c('0xbc')](_0x57a0f7));_0x7b8706['set'](_0x57a0f7,_0x386713);}const _0x226a08=Array['from'](this[_0xe08c('0xb2')][_0xe08c('0x47')][_0xe08c('0x13')])[_0xe08c('0x29')](_0x115036=>[_0x115036[_0xe08c('0x96')],_0x115036[_0xe08c('0xe1')]()]),_0x2b65c9=this[_0xe08c('0x84')]['version'];this['_saveMetaData'](_0x2b65c9,_0x7b8706,_0x226a08),this[_0xe08c('0xde')]=this[_0xe08c('0x45')];}[_0xe08c('0xd3')](_0x5b569b,_0x1bd82a){if(this['_lastFrom']===_0x5b569b&&this[_0xe08c('0x63')]<=_0x1bd82a)this['_savedMetaData'][_0xe08c('0xb0')]>0x1&&this[_0xe08c('0x51')](this[_0xe08c('0x63')]),this[_0xe08c('0xb')](this[_0xe08c('0x63')],_0x1bd82a,!0x0);else{if(!this['_savedMetaData'][_0xe08c('0x86')](_0x5b569b)){const _0xc7139f=this['_getPreviousFrom'](_0x5b569b);this['_calculateMetaData'](_0xc7139f,_0x5b569b,!0x1);}this[_0xe08c('0xea')](_0x5b569b,_0x1bd82a,!0x0);}return this['_lastFrom']=_0x5b569b,this[_0xe08c('0x63')]=_0x1bd82a,this[_0xe08c('0x58')]();}[_0xe08c('0x2f')](_0x3824bd){this[_0xe08c('0x4d')](),this[_0xe08c('0x25')]=_0x3824bd[_0xe08c('0x8e')],this[_0xe08c('0x63')]=_0x3824bd[_0xe08c('0xbf')];for(const _0x389777 in _0x3824bd[_0xe08c('0xc3')]){const _0x35d647=this['_makeModelFromViewString'](_0x3824bd[_0xe08c('0xc3')][_0x389777][_0xe08c('0x70')]);_0x35d647[_0xe08c('0x38')]=_0x389777,this[_0xe08c('0x6b')][_0xe08c('0x9a')](_0x389777,_0x35d647);const _0x5cbef3=this[_0xe08c('0x3d')](_0x35d647);this[_0xe08c('0x57')][_0xe08c('0x9a')](_0x389777,_0x5cbef3);for(const [_0x45a5e6,_0x2970c9]of _0x35d647[_0xe08c('0x13')]){if(!_0x45a5e6[_0xe08c('0x9e')]('revision:'))continue;const _0x13f80c=_0x45a5e6['split'](':')[0x2];for(const _0x271932 of _0x2970c9[_0xe08c('0x7a')]({'singleCharacters':!0x0})){const _0x48d8e1=this['_getVidAttributeName'](_0x271932),_0x176437=_0xe08c('0x83')==_0x271932[_0xe08c('0x74')]?_0x271932[_0xe08c('0x4e')]['path'][_0xe08c('0x7c')](0x0,-0x1):_0x271932[_0xe08c('0x4e')][_0xe08c('0x89')],_0x994f93=_0x5cbef3[_0xe08c('0x75')](_0x176437)[_0xe08c('0xa8')](_0x48d8e1);this[_0xe08c('0xe6')]['set'](_0x994f93,{'userId':_0x13f80c});}}}this['_startingRevisionId']=this[_0xe08c('0x45')];const _0x2ecae5=[...Array(this[_0xe08c('0x45')])[_0xe08c('0x5')]()]['slice'](0x1)[_0xe08c('0x67')](_0x224d3=>!this[_0xe08c('0xe6')]['has'](_0x224d3));let _0x10e51c=0x0;for(const _0x1b3606 in _0x3824bd[_0xe08c('0xc3')]){const _0xa98682=this['_makeModelFromViewString'](_0x3824bd[_0xe08c('0xc3')][_0x1b3606][_0xe08c('0xdc')]);_0xa98682[_0xe08c('0x38')]=_0x1b3606,this[_0xe08c('0x4c')][_0xe08c('0x9a')](_0x1b3606,_0xa98682);const _0x170ffd=this[_0xe08c('0x3d')](_0xa98682,Number['NEGATIVE_INFINITY']);this[_0xe08c('0xc2')]['set'](_0x1b3606,_0x170ffd);for(const [_0x52bebd,_0x43bbe1]of _0xa98682[_0xe08c('0x13')]){if(!_0x52bebd[_0xe08c('0x9e')](_0xe08c('0x28')))continue;const _0x18deab=_0x52bebd[_0xe08c('0xae')](':')[0x2];for(const _0x5f1924 of _0x43bbe1[_0xe08c('0x7a')]({'singleCharacters':!0x0})){const _0x143312=this[_0xe08c('0xb9')](_0x5f1924),_0x18afed=this[_0xe08c('0x45')]++,_0x25cdb4=_0xe08c('0x83')==_0x5f1924[_0xe08c('0x74')]?_0x5f1924[_0xe08c('0x4e')][_0xe08c('0x89')][_0xe08c('0x7c')](0x0,-0x1):_0x5f1924[_0xe08c('0x4e')][_0xe08c('0x89')];_0x170ffd[_0xe08c('0x75')](_0x25cdb4)[_0xe08c('0x53')](_0x143312,_0x18afed),this[_0xe08c('0xe6')][_0xe08c('0x9a')](_0x18afed,{'userId':_0x18deab});}}for(const _0x3df0b4 of this['editor']['model'][_0xe08c('0xe2')](_0xa98682)[_0xe08c('0x7a')]({'singleCharacters':!0x0})){const _0x25ef70=this[_0xe08c('0xb9')](_0x3df0b4),_0x548ede=_0xe08c('0x83')==_0x3df0b4['type']?_0x3df0b4['previousPosition'][_0xe08c('0x89')][_0xe08c('0x7c')](0x0,-0x1):_0x3df0b4[_0xe08c('0x4e')]['path'],_0x1c820b=_0x170ffd[_0xe08c('0x75')](_0x548ede);_0x1c820b['getAttribute'](_0x25ef70)>0x0||_0x1c820b[_0xe08c('0x53')](_0x25ef70,_0x2ecae5[_0x10e51c++]);}const _0x339412=new _0x588493();_0x339412[_0xe08c('0x38')]='$graveyard',this[_0xe08c('0x6b')]['set'](_0xe08c('0x7b'),_0x339412),this[_0xe08c('0x57')][_0xe08c('0x9a')](_0xe08c('0x7b'),this['_makeIdsRoot'](_0x339412,0x1));const _0x1e62ab=new _0x588493();_0x1e62ab[_0xe08c('0x38')]='$graveyard',this[_0xe08c('0x4c')][_0xe08c('0x9a')](_0xe08c('0x7b'),_0x1e62ab),this[_0xe08c('0xc2')]['set'](_0xe08c('0x7b'),this['_makeIdsRoot'](_0x1e62ab,0x1));for(const [_0x12be67,_0x175c59]of _0xa98682[_0xe08c('0x13')])_0x12be67[_0xe08c('0x9e')]('revision:')||this['_markers'][_0xe08c('0x9a')](_0x12be67,_0x175c59);}const _0x21032b=Array[_0xe08c('0xba')](this[_0xe08c('0x4c')])[_0xe08c('0x29')](([_0x1eae6e,_0x1810d8])=>[_0x1eae6e,J(_0x1810d8)]);this['_saveMetaData'](this['_lastTo'],_0x21032b,this[_0xe08c('0x16')]);}[_0xe08c('0x23')](_0x150a12){const _0x1ff70c=JSON['parse'](_0x150a12),_0x5155db=this[_0xe08c('0xb2')]['editing']['view'][_0xe08c('0x3')],_0x1ada4c=new _0x409a7f(_0x5155db,_0x1ff70c[_0xe08c('0x29')](_0x2be2ac=>F(_0x2be2ac,this[_0xe08c('0xb2')])));return this['editor']['data'][_0xe08c('0xa5')](_0x1ada4c);}['_saveEmptyMetaData'](){const _0xcce444=new Map();for(const _0xe98fb8 of this[_0xe08c('0x15')]){const _0x13e70a=new _0x588493();_0x13e70a[_0xe08c('0x38')]=_0xe98fb8,_0xcce444[_0xe08c('0x9a')](_0xe98fb8,_0x13e70a);}this[_0xe08c('0xb4')](Number['NEGATIVE_INFINITY'],_0xcce444,[]);}[_0xe08c('0xb4')](_0x8b875f,_0xf1a587,_0x2b1885){const _0x2419e5=new Map(_0xf1a587),_0x2a6431=new Map();for(const [_0x3ba63a,_0x474713]of _0x2b1885)_0x2a6431['set'](_0x3ba63a,{'start':_0x474713[_0xe08c('0xe5')]['clone'](),'end':_0x474713['end'][_0xe08c('0xdd')](),'rootName':_0x474713['root'][_0xe08c('0x38')]});this[_0xe08c('0x55')][_0xe08c('0x9a')](_0x8b875f,{'roots':_0x2419e5,'markers':_0x2a6431});}[_0xe08c('0x51')](_0x3154a7){this[_0xe08c('0x55')][_0xe08c('0x76')](_0x3154a7);}[_0xe08c('0x6e')](){this[_0xe08c('0x4d')](),this['_lastFrom']=-0x1,this[_0xe08c('0x63')]=-0x1,this[_0xe08c('0x55')][_0xe08c('0x88')](),this[_0xe08c('0x6')](this[_0xe08c('0x84')]);}['_reset'](){this[_0xe08c('0xe6')]['clear'](),this[_0xe08c('0x95')][_0xe08c('0x88')](),this[_0xe08c('0x4c')][_0xe08c('0x88')](),this['_baseRoots'][_0xe08c('0x88')](),this[_0xe08c('0xc2')][_0xe08c('0x88')](),this[_0xe08c('0x57')][_0xe08c('0x88')](),this['_markers']['clear'](),this[_0xe08c('0x45')]=0x1,this[_0xe08c('0xde')]=this['_revisionId'];}[_0xe08c('0x3d')](_0x3637bc,_0x47ffce=null){let _0x1a4d9d=null;_0x3637bc['is'](_0xe08c('0x4f'))||(_0x1a4d9d=new _0x45e8ea(_0x3637bc[_0xe08c('0x96')],{'vid_start':null===_0x47ffce?this[_0xe08c('0x45')]++:_0x47ffce++}));const _0x57197d=[];for(const _0x6d24e5 of _0x3637bc['getChildren']())if(_0x6d24e5['is'](_0xe08c('0x2b'))){_0x57197d[_0xe08c('0xe')](this[_0xe08c('0x3d')](_0x6d24e5,_0x47ffce));const _0x38d081=_0x57197d[_0x57197d[_0xe08c('0x8d')]-0x1];null!==_0x47ffce&&(_0x47ffce=_0x38d081['is'](_0xe08c('0x2b'),_0xe08c('0xd'))?_0x38d081[_0xe08c('0xa8')](_0xe08c('0x71'))+0x1:_0x38d081[_0xe08c('0xa8')](_0xe08c('0x69'))+0x1);}else for(let _0x2f95a4=0x0;_0x2f95a4<_0x6d24e5['offsetSize'];_0x2f95a4++)_0x57197d['push'](new _0x45e8ea(_0xe08c('0xd'),{'vid':null===_0x47ffce?this['_revisionId']++:_0x47ffce++}));if(_0x3637bc['is'](_0xe08c('0x4f'))){const _0x50213f=new _0x588493(_0x57197d);return _0x50213f[_0xe08c('0x38')]=_0x3637bc[_0xe08c('0x38')],_0x50213f;}return _0x1a4d9d[_0xe08c('0x53')](_0xe08c('0x69'),null===_0x47ffce?this[_0xe08c('0x45')]++:_0x47ffce++),_0x1a4d9d[_0xe08c('0x18')](0x0,_0x57197d),_0x1a4d9d;}[_0xe08c('0xea')](_0x1ec7ac,_0x19c75c,_0xc6cb73){this[_0xe08c('0x4d')]();const {roots:_0xa1ee06,markers:_0x51dc0c}=this[_0xe08c('0x55')]['get'](_0x1ec7ac);this[_0xe08c('0x6b')]=new Map(_0xa1ee06);for(const [_0x41e39f,_0x2bae2d]of this[_0xe08c('0x6b')])if('$graveyard'!==_0x41e39f&&(this[_0xe08c('0x4c')][_0xe08c('0x9a')](_0x41e39f,J(_0x2bae2d)),_0xc6cb73)){const _0x4795cc=this[_0xe08c('0x45')];this[_0xe08c('0xc2')][_0xe08c('0x9a')](_0x41e39f,this[_0xe08c('0x3d')](_0x2bae2d)),this[_0xe08c('0x57')][_0xe08c('0x9a')](_0x41e39f,this[_0xe08c('0x3d')](_0x2bae2d,_0x4795cc));}this[_0xe08c('0xde')]=this[_0xe08c('0x45')],this[_0xe08c('0x4c')][_0xe08c('0x9a')](_0xe08c('0x7b'),J(this[_0xe08c('0x6b')][_0xe08c('0xa6')](_0xe08c('0x7b')))),_0xc6cb73&&this[_0xe08c('0xc2')][_0xe08c('0x9a')](_0xe08c('0x7b'),this[_0xe08c('0x3d')](this[_0xe08c('0x6b')][_0xe08c('0xa6')](_0xe08c('0x7b'))));for(const [_0x537765,_0x5d8579]of _0x51dc0c){const _0x567e91=this[_0xe08c('0x6b')][_0xe08c('0xa6')](_0x5d8579[_0xe08c('0x38')]),_0x465fc2=this[_0xe08c('0x4c')][_0xe08c('0xa6')](_0x5d8579['rootName']),_0x1c7165=new _0x18b630(this[_0xe08c('0xa')](_0x5d8579[_0xe08c('0xe5')],_0x567e91),this[_0xe08c('0xa')](_0x5d8579['end'],_0x567e91)),_0x339c0d=this['_fixRange'](_0x1c7165,_0x465fc2);_0x567e91[_0xe08c('0x13')]['set'](_0x537765,_0x1c7165),this[_0xe08c('0x16')][_0xe08c('0x9a')](_0x537765,_0x339c0d);}this[_0xe08c('0xb')](_0x1ec7ac,_0x19c75c,_0xc6cb73);}[_0xe08c('0xb')](_0x28de3e,_0x5882ad,_0x434157){for(const _0x65494a of this[_0xe08c('0x84')][_0xe08c('0x11')](_0x28de3e,_0x5882ad))this['_handleOperation'](_0x65494a,_0x434157);for(const _0x38a725 of this[_0xe08c('0x4c')][_0xe08c('0x3a')]())_0x38a725[_0xe08c('0x13')][_0xe08c('0x88')]();for(const [_0x41c5c4,_0x23b9d3]of this[_0xe08c('0x16')]){this[_0xe08c('0x4c')][_0xe08c('0xa6')](_0x23b9d3[_0xe08c('0x4b')][_0xe08c('0x38')])['markers'][_0xe08c('0x9a')](_0x41c5c4,_0x23b9d3[_0xe08c('0xdd')]());}this[_0xe08c('0xb4')](_0x5882ad,Array['from'](this['_diffRoots'])['map'](([_0x1bf2ef,_0x2d7e03])=>[_0x1bf2ef,J(_0x2d7e03)]),this['_markers']);}['_getPreviousFrom'](_0x3a6a81){const _0x160cef=Array[_0xe08c('0xba')](this[_0xe08c('0x55')][_0xe08c('0x5')]());_0x160cef[_0xe08c('0x24')]((_0x299369,_0x1cf472)=>_0x299369-_0x1cf472),_0x160cef['reverse']();for(const _0xcee2ae of _0x160cef)if(_0xcee2ae<_0x3a6a81)return _0xcee2ae;return this['_saveEmptyMetaData'](),Number['NEGATIVE_INFINITY'];}[_0xe08c('0xe9')](_0x3e9f9d,_0x30737a){const _0x5a9bcb=Array[_0xe08c('0xba')](_0x30737a[_0xe08c('0x13')])[_0xe08c('0x29')](([_0x57a8f0,_0x4ee401])=>[_0x57a8f0,this['_fixRange'](_0x4ee401,_0x3e9f9d)]);_0x3e9f9d[_0xe08c('0x13')]=new Map(_0x5a9bcb);}['_transformMarkers'](_0x231b92){for(const _0x57e46b of this[_0xe08c('0x16')]['values']()){const _0x48ed0c=_0x57e46b[_0xe08c('0x30')](_0x231b92),_0x2a0801=_0x18b630[_0xe08c('0x49')](_0x48ed0c);_0x57e46b[_0xe08c('0xe5')]=_0x2a0801[_0xe08c('0xe5')],_0x57e46b['end']=_0x2a0801[_0xe08c('0x6a')];}}[_0xe08c('0x5a')](_0xe035f7,_0xa1c44){const _0xd73914=this[_0xe08c('0xc6')](_0xe035f7,this[_0xe08c('0x4c')]);if(_0xe08c('0x37')!==_0xe035f7[_0xe08c('0x74')]&&(_0xd73914[_0xe08c('0x5b')](),this[_0xe08c('0xed')](_0xd73914)),_0xa1c44)switch(_0xd73914[_0xe08c('0x74')]){case _0xe08c('0x5c'):this[_0xe08c('0xf')](_0xe035f7);break;case _0xe08c('0xa3'):case'remove':case _0xe08c('0x3f'):this['_handleMoveOperation'](_0xe035f7);break;case _0xe08c('0xb3'):this[_0xe08c('0x26')](_0xe035f7);break;case _0xe08c('0xae'):this[_0xe08c('0x54')](_0xe035f7);break;case _0xe08c('0x37'):this[_0xe08c('0xa2')](_0xe035f7);}}[_0xe08c('0xc6')](_0x2a526c,_0x57b76a){const _0x489c7f=_0x2a526c['clone']();return _0x489c7f[_0xe08c('0x9d')]=_0x2a526c[_0xe08c('0x9d')],this['_fixOperation'](_0x489c7f,_0x57b76a),_0x489c7f;}[_0xe08c('0xd4')](_0x1632c8){return _0x1632c8[_0xe08c('0x29')](_0x2bd1a2=>{const _0x52584c=this[_0xe08c('0xb9')](_0x2bd1a2);return Number(_0x2bd1a2[_0xe08c('0x72')]['getAttribute'](_0x52584c));});}['_generateTape'](_0x4e2b01,_0x459860){if(_0x4e2b01['is'](_0xe08c('0x2b'),_0xe08c('0xd')))_0x459860[_0xe08c('0xe')]({'item':_0x4e2b01,'type':_0xe08c('0x4a')});else{_0x4e2b01['is']('element')&&_0x459860['push']({'item':_0x4e2b01,'type':_0xe08c('0xcb')});for(const _0x237d79 of _0x4e2b01['getChildren']())this[_0xe08c('0x2d')](_0x237d79,_0x459860);_0x4e2b01['is'](_0xe08c('0x2b'))&&_0x459860[_0xe08c('0xe')]({'item':_0x4e2b01,'type':_0xe08c('0x83')});}return _0x459860;}[_0xe08c('0x58')](){const _0xa8163f=this[_0xe08c('0xb2')]['model'][_0xe08c('0x3')]['getRootNames'](),_0x31ae5f=new Map(this[_0xe08c('0xe6')]),_0x3a7b8b=new Map(_0x31ae5f),_0x355854=new Map(),_0x3cf27f={'insertions':{},'deletions':{}},_0x67cb26={'insertions':{},'deletions':{}},_0x5d4b47=new Map();for(const _0x14b827 of _0xa8163f){const _0x263667=this['_diffRoots'][_0xe08c('0xa6')](_0x14b827),_0x24b5ad=this[_0xe08c('0x6b')][_0xe08c('0xa6')](_0x14b827);_0x3cf27f['insertions'][_0x14b827]=J(_0x263667),_0x3cf27f['deletions'][_0x14b827]=J(_0x24b5ad),this[_0xe08c('0xe9')](_0x3cf27f[_0xe08c('0x70')][_0x14b827],_0x24b5ad),this[_0xe08c('0xe9')](_0x3cf27f[_0xe08c('0xdc')][_0x14b827],_0x263667),_0x67cb26['insertions'][_0x14b827]=this[_0xe08c('0x2d')](this['_idsRoots'][_0xe08c('0xa6')](_0x14b827),[]),_0x67cb26[_0xe08c('0x70')][_0x14b827]=this['_generateTape'](this[_0xe08c('0x57')][_0xe08c('0xa6')](_0x14b827),[]);}for(const _0x308404 of _0xa8163f){const _0x572a02=_0x67cb26[_0xe08c('0xdc')][_0x308404];for(const _0x3f03f4 of _0x572a02){const _0x52da7e=this['_getVidAttributeName'](_0x3f03f4),_0x33420a=_0x3f03f4['item'][_0xe08c('0xa8')](_0x52da7e);_0x3a7b8b[_0xe08c('0x76')](_0x33420a),_0x33420a>=this[_0xe08c('0xde')]&&_0x355854[_0xe08c('0x9a')](_0x33420a,_0x31ae5f['get'](_0x33420a));}}for(const _0x5c43fd of _0xa8163f){const _0x1dd50=_0x67cb26['insertions'][_0x5c43fd],_0x2030df=this[_0xe08c('0xd4')](_0x67cb26[_0xe08c('0x70')][_0x5c43fd]);let _0x3ac49b=0x0;for(const _0x5ee59e of _0x1dd50){const _0x503f97=this[_0xe08c('0xb9')](_0x5ee59e),_0x180c8e=_0x5ee59e[_0xe08c('0x72')]['getAttribute'](_0x503f97);if(!_0x355854['has'](_0x180c8e)&&!_0x5d4b47[_0xe08c('0x86')](_0x180c8e)){if(_0x3a7b8b[_0xe08c('0x86')](_0x180c8e))_0x3ac49b++;else{if(_0x180c8e!=_0x2030df[_0x3ac49b]){const _0x5d500b=_0x31ae5f['get'](_0x180c8e)||_0x31ae5f[_0xe08c('0xa6')](_0x2030df[_0x3ac49b]);for(;_0x180c8e!=_0x2030df[_0x3ac49b];)_0x3a7b8b[_0xe08c('0x86')](_0x2030df[_0x3ac49b])||(_0x5d4b47[_0xe08c('0x9a')](_0x2030df[_0x3ac49b],_0x5d500b),_0x31ae5f[_0xe08c('0x9a')](_0x2030df[_0x3ac49b],_0x5d500b)),_0x3ac49b++;}_0x3ac49b++;}}}}for(const _0x2c15dc of _0xa8163f){const _0x31323f=_0x67cb26[_0xe08c('0xdc')][_0x2c15dc];for(const _0x5ee702 of _0x31323f){const _0x13b768=this[_0xe08c('0xb9')](_0x5ee702),_0x573f90=_0x5ee702[_0xe08c('0x72')][_0xe08c('0xa8')](_0x13b768);if(_0x5d4b47[_0xe08c('0x86')](_0x573f90)){const _0x2fb456=_0x5d4b47[_0xe08c('0xa6')](_0x573f90);_0x3a7b8b[_0xe08c('0x86')](_0x573f90)||_0x3a7b8b[_0xe08c('0x9a')](_0x573f90,{..._0x2fb456}),_0x355854[_0xe08c('0x9a')](_0x573f90,{..._0x2fb456});}}}for(const _0x10be4e of _0x3a7b8b[_0xe08c('0x5')]())_0x10be4e>=this[_0xe08c('0xde')]&&_0x3a7b8b[_0xe08c('0x76')](_0x10be4e);const _0x1dcd0a=new Map();for(const _0x47141c of _0xa8163f){let _0x371bf4=_0x67cb26['insertions'][_0x47141c];for(const _0x211a26 of _0x371bf4)if(_0x211a26[_0xe08c('0x72')]['is']('element',_0xe08c('0xc1'))){const _0x19f5e6=this[_0xe08c('0xb9')](_0x211a26),_0x40809a=_0x211a26['item'][_0xe08c('0xa8')](_0x19f5e6);if(_0x355854[_0xe08c('0x86')](_0x40809a)){const _0x1baa41=_0x211a26[_0xe08c('0x72')][_0xe08c('0xec')][_0xe08c('0xec')]['getAttribute'](_0xe08c('0xe7')),_0xfb2f7a=_0x1dcd0a[_0xe08c('0xa6')](_0x1baa41)||new Set();_0xfb2f7a[_0xe08c('0x2c')](_0x355854[_0xe08c('0xa6')](_0x40809a)[_0xe08c('0x19')]),_0x1dcd0a[_0xe08c('0x9a')](_0x1baa41,_0xfb2f7a);}}_0x371bf4=_0x67cb26[_0xe08c('0x70')][_0x47141c];for(const _0x8e149d of _0x371bf4)if(_0x8e149d[_0xe08c('0x72')]['is'](_0xe08c('0x2b'),_0xe08c('0xc1'))){const _0x50f9e2=this['_getVidAttributeName'](_0x8e149d),_0x121240=_0x8e149d[_0xe08c('0x72')][_0xe08c('0xa8')](_0x50f9e2);if(_0x3a7b8b[_0xe08c('0x86')](_0x121240)){const _0x14b6e6=_0x8e149d['item']['parent'][_0xe08c('0xec')]['getAttribute'](_0xe08c('0xe7')),_0xd8309a=_0x1dcd0a[_0xe08c('0xa6')](_0x14b6e6)||new Set();_0xd8309a[_0xe08c('0x2c')](_0x3a7b8b[_0xe08c('0xa6')](_0x121240)[_0xe08c('0x19')]),_0x1dcd0a[_0xe08c('0x9a')](_0x14b6e6,_0xd8309a);}}for(const _0x198f81 of _0x1dcd0a[_0xe08c('0x5')]())(_0x355854['has'](_0x198f81)||_0x3a7b8b[_0xe08c('0x86')](_0x198f81))&&_0x1dcd0a[_0xe08c('0x76')](_0x198f81);}for(const _0x3e5204 of _0xa8163f){const _0x455ef5=_0x67cb26['insertions'][_0x3e5204];let _0x3591fa=null,_0x7dd944=null;for(const _0xaa9f8c of _0x455ef5){const _0x354dd6=this[_0xe08c('0xb9')](_0xaa9f8c),_0x532454=_0xaa9f8c[_0xe08c('0x72')][_0xe08c('0xa8')](_0x354dd6),_0x2b4c03=_0x1dcd0a[_0xe08c('0xa6')](_0x532454);_0x2b4c03&&'elementStart'==_0xaa9f8c[_0xe08c('0x74')]&&(_0x3591fa=Array[_0xe08c('0xba')](_0x2b4c03)[0x0],_0x7dd944=_0xaa9f8c[_0xe08c('0x72')][_0xe08c('0xa8')]('vid_end')),_0x3591fa&&(_0x3a7b8b[_0xe08c('0x9a')](_0x532454,{'userId':_0x3591fa}),_0x355854['set'](_0x532454,{'userId':_0x3591fa})),_0x532454==_0x7dd944&&(_0x3591fa=null,_0x7dd944=null);}}const _0x4cd568={},_0x1709bc=new Set();for(const _0xb9ffb8 of _0xa8163f){const _0x3cc1a0=_0x3cf27f[_0xe08c('0x70')][_0xb9ffb8],_0x256724=_0x3cf27f[_0xe08c('0xdc')][_0xb9ffb8];for(const {userId:_0x1383d4}of this['_touchedMarkers'][_0xe08c('0x3a')]())null!==_0x1383d4&&_0x1709bc[_0xe08c('0x2c')](_0x1383d4);this[_0xe08c('0x1c')](_0x256724,_0x67cb26[_0xe08c('0xdc')][_0xb9ffb8],_0x355854,_0xe08c('0x79'),_0x1709bc),this['_markChanges'](_0x3cc1a0,_0x67cb26['deletions'][_0xb9ffb8],_0x3a7b8b,'deletion',_0x1709bc),_0x4cd568[_0xb9ffb8]={'insertions':this[_0xe08c('0xa0')](_0x256724),'deletions':this[_0xe08c('0xa0')](_0x3cc1a0)};}return{'diffData':_0x4cd568,'authorsIds':Array[_0xe08c('0xba')](_0x1709bc)};}['_processRootBeforeSave'](_0x594426){for(const [,_0x3eda62]of _0x594426[_0xe08c('0x13')]){const _0x15ea00=_0x3eda62['start'][_0xe08c('0x4')]()[_0xe08c('0x67')](_0x1fbbbe=>_0xe08c('0xc1')==_0x1fbbbe['name']);for(const _0x570714 of _0x15ea00)0x1==_0x570714[_0xe08c('0x82')]&&_0x570714[_0xe08c('0x3e')](0x0)['is'](_0xe08c('0x2b'),_0xe08c('0xbd'))&&_0x570714[_0xe08c('0x3e')](0x0)['_setAttribute'](_0xe08c('0x9c'),!0x0);}}[_0xe08c('0xa0')](_0x4833d8){this[_0xe08c('0x10')](_0x4833d8);const _0x5b05be=this[_0xe08c('0xb2')][_0xe08c('0xd2')][_0xe08c('0x97')](_0x4833d8,{}),_0x1d20fb=Array[_0xe08c('0xba')](_0x5b05be[_0xe08c('0x0')]())[_0xe08c('0x29')](_0x42ed40=>this[_0xe08c('0xb1')](_0x42ed40));return JSON[_0xe08c('0x92')](_0x1d20fb);}[_0xe08c('0xb1')](_0x67ab){if(_0x67ab['is']('$text'))return _0x67ab[_0xe08c('0xd2')];{const _0x543380=_0x67ab;return{'type':Object['keys'](V)[_0xe08c('0x1b')](_0x54ad89=>_0x67ab instanceof V[_0x54ad89]),'name':_0x543380['name'],'attributes':Array['from'](_0x543380[_0xe08c('0xb8')]()),'children':Array[_0xe08c('0xba')](_0x543380['getChildren']())['map'](_0xa965c6=>this[_0xe08c('0xb1')](_0xa965c6))};}}[_0xe08c('0x1c')](_0x167743,_0xf7e92a,_0xeb02dd,_0xa81418,_0x251882){let _0x2b6bbf=null,_0xb4abb2=null,_0xf6605b=0x0;const _0x200b79=this['editor'][_0xe08c('0x47')];for(let _0x5b77b0=0x0;_0x5b77b0<_0xf7e92a[_0xe08c('0x8d')];_0x5b77b0++){const _0x399124=this['_getVidAttributeName'](_0xf7e92a[_0x5b77b0]),_0x1d34ee=_0xf7e92a[_0x5b77b0]['item'][_0xe08c('0xa8')](_0x399124),_0x432868=_0xeb02dd['get'](_0x1d34ee),_0x50fce2=_0x5b77b0==_0xf7e92a[_0xe08c('0x8d')]-0x1;(!_0x2b6bbf&&_0x432868&&(_0x2b6bbf=_0x432868,_0xb4abb2=_0xf7e92a[_0x5b77b0]),_0x2b6bbf&&(!_0x432868||_0x432868[_0xe08c('0x19')]!=_0x2b6bbf[_0xe08c('0x19')]))&&(_0x55fd5c(_0x432868,j(_0xb4abb2,_0x167743,_0x200b79),j(_0xf7e92a[_0x5b77b0],_0x167743,_0x200b79)),_0x2b6bbf=_0x432868||null,_0xb4abb2=_0x432868?_0xf7e92a[_0x5b77b0]:null),_0x2b6bbf&&_0x50fce2&&_0x55fd5c(_0x432868,j(_0xb4abb2,_0x167743,_0x200b79),B(_0xf7e92a[_0x5b77b0],_0x167743,_0x200b79));}function _0x55fd5c(_0x51144a,_0x2f08c5,_0x2003aa){const _0x245883=_0x2b6bbf[_0xe08c('0x19')],_0x3a1ea=_0xe08c('0x28')+_0xa81418+':'+_0x245883+':'+_0xf6605b++,_0x1b2c13=_0x200b79[_0xe08c('0xd1')](_0x2f08c5,_0x2003aa);_0x167743[_0xe08c('0x13')][_0xe08c('0x9a')](_0x3a1ea,_0x1b2c13),null!==_0x245883&&_0x251882[_0xe08c('0x2c')](_0x245883);}}[_0xe08c('0xb9')](_0x896b6d){switch(_0x896b6d['type']){case _0xe08c('0xcb'):return _0xe08c('0xe7');case _0xe08c('0x83'):return _0xe08c('0x69');default:return _0xe08c('0x71');}}[_0xe08c('0x1')](_0x42addd,_0xe3658){_0x42addd[_0xe08c('0x52')]=null;for(const _0x541a59 in _0x42addd){const _0x182740=_0x42addd[_0x541a59];if(_0x182740 instanceof _0x3a19a0){const _0x5d2e04=_0xe3658['get'](_0x182740[_0xe08c('0x4b')]['rootName']);_0x42addd[_0x541a59]=this[_0xe08c('0xa')](_0x182740,_0x5d2e04);}if(_0x182740 instanceof _0x18b630){const _0x4a3b58=_0xe3658['get'](_0x182740[_0xe08c('0x4b')][_0xe08c('0x38')]);_0x42addd[_0x541a59]=this['_fixRange'](_0x182740,_0x4a3b58);}}_0x42addd[_0xe08c('0x4b')]&&(_0x42addd[_0xe08c('0x4b')]=_0xe3658['get'](_0x42addd[_0xe08c('0x4b')]['rootName']));}[_0xe08c('0x8f')](_0x2a483f,_0x4355d7){return this['editor'][_0xe08c('0x47')][_0xe08c('0xd1')](this[_0xe08c('0xa')](_0x2a483f[_0xe08c('0xe5')],_0x4355d7),this[_0xe08c('0xa')](_0x2a483f[_0xe08c('0x6a')],_0x4355d7));}['_fixPosition'](_0x63fc86,_0x4c6a49){return this[_0xe08c('0xb2')][_0xe08c('0x47')]['createPositionFromPath'](_0x4c6a49,_0x63fc86[_0xe08c('0x89')],_0x63fc86[_0xe08c('0x7f')]);}[_0xe08c('0xf')](_0x25d625){const _0x1cb41d=this[_0xe08c('0xc2')]['get'](_0x25d625[_0xe08c('0x8')][_0xe08c('0x4b')][_0xe08c('0x38')]),_0x4de156=this['_fixPosition'](_0x25d625['position'],_0x1cb41d),_0x294d13=null===_0x25d625[_0xe08c('0x9d')]?null:_0x25d625[_0xe08c('0x9d')]||this[_0xe08c('0xb2')][_0xe08c('0xad')][_0xe08c('0xa6')]('Users')['me']['id'],_0x17f000=_0x4de156[_0xe08c('0xec')],_0x5f035f=this[_0xe08c('0x45')],_0x28b763=[];for(const _0x1c2556 of _0x25d625[_0xe08c('0xa9')])if(_0x1c2556['is'](_0xe08c('0x2b')))_0x28b763['push'](this[_0xe08c('0x3d')](_0x1c2556));else for(let _0x1f1379=0x0;_0x1f1379<_0x1c2556[_0xe08c('0xdf')];_0x1f1379++)_0x28b763[_0xe08c('0xe')](new _0x45e8ea(_0xe08c('0xd'),{'vid':this[_0xe08c('0x45')]++}));const _0x10072d=this['_revisionId'];for(let _0x45f000=_0x5f035f;_0x45f000<_0x10072d;_0x45f000++)this[_0xe08c('0xe6')][_0xe08c('0x9a')](_0x45f000,{'userId':_0x294d13});_0x17f000[_0xe08c('0x18')](_0x4de156[_0xe08c('0x50')],_0x28b763);}[_0xe08c('0xa1')](_0x1ab13f){(_0x1ab13f=this[_0xe08c('0xc6')](_0x1ab13f,this[_0xe08c('0xc2')]))[_0xe08c('0x5b')]();const _0x33f72c=null===_0x1ab13f[_0xe08c('0x9d')]?null:_0x1ab13f[_0xe08c('0x9d')]||this[_0xe08c('0xb2')][_0xe08c('0xad')][_0xe08c('0xa6')]('Users')['me']['id'],_0x4a7b4d=_0x1ab13f['getMovedRangeStart'](),_0x402f53=_0x4a7b4d[_0xe08c('0xec')],_0x44b21c=_0x4a7b4d['offset'];!function _0x3f532c(_0xafa5b6,_0x5c86b6,_0x38d0ee,_0x504e6c){for(let _0x3f4308=_0x38d0ee;_0x3f4308<_0x504e6c;_0x3f4308++){const _0x27b436=_0x5c86b6[_0xe08c('0x3e')](_0x3f4308);_0x27b436['is'](_0xe08c('0x2b'),_0xe08c('0xd'))?_0xafa5b6['set'](_0x27b436[_0xe08c('0xa8')](_0xe08c('0x71')),{'userId':_0x33f72c}):(_0xafa5b6['set'](_0x27b436[_0xe08c('0xa8')](_0xe08c('0xe7')),{'userId':_0x33f72c}),_0x3f532c(_0xafa5b6,_0x27b436,0x0,_0x27b436['childCount']),_0xafa5b6[_0xe08c('0x9a')](_0x27b436[_0xe08c('0xa8')](_0xe08c('0x69')),{'userId':_0x33f72c}));}}(this['_touched'],_0x402f53,_0x44b21c,_0x44b21c+_0x1ab13f['howMany']);}[_0xe08c('0x26')](_0x28fd9f){const _0x3d93ef=null===(_0x28fd9f=this['_cloneOperation'](_0x28fd9f,this[_0xe08c('0xc2')]))['_authorId']?null:_0x28fd9f[_0xe08c('0x9d')]||this[_0xe08c('0xb2')][_0xe08c('0xad')][_0xe08c('0xa6')](_0xe08c('0xc9'))['me']['id'],_0x55fdf1=_0x28fd9f[_0xe08c('0xd7')][_0xe08c('0xec')],_0x1a315e=_0x28fd9f['sourcePosition'][_0xe08c('0xec')],_0x2ef7ac=_0x55fdf1[_0xe08c('0xa8')]('vid_end'),_0x6fcc80=_0x1a315e[_0xe08c('0xa8')](_0xe08c('0xe7'));_0x55fdf1['_setAttribute'](_0xe08c('0x69'),_0x1a315e[_0xe08c('0xa8')](_0xe08c('0x69'))),_0x1a315e[_0xe08c('0x53')](_0xe08c('0x69'),_0x2ef7ac),this[_0xe08c('0xe6')][_0xe08c('0x9a')](_0x6fcc80,{'userId':_0x3d93ef}),this[_0xe08c('0xe6')][_0xe08c('0x9a')](_0x2ef7ac,{'userId':_0x3d93ef}),_0x28fd9f[_0xe08c('0x5b')]();}[_0xe08c('0x54')](_0x3f1953){const _0x26e8fe=null===(_0x3f1953=this[_0xe08c('0xc6')](_0x3f1953,this['_idsRoots']))[_0xe08c('0x9d')]?null:_0x3f1953[_0xe08c('0x9d')]||this['editor']['plugins'][_0xe08c('0xa6')](_0xe08c('0xc9'))['me']['id'],_0x379ed4=_0x3f1953[_0xe08c('0x33')],_0x3de718=_0x3f1953['splitPosition'][_0xe08c('0xec')];_0x3f1953[_0xe08c('0x5b')]();const _0x5f1f34=_0x3de718[_0xe08c('0xa8')]('vid_end'),_0x2eeae2=_0x3f1953[_0xe08c('0x56')][_0xe08c('0x9b')];if(_0x379ed4){const _0x2277af=_0x2eeae2['getAttribute']('vid_end'),_0x18e2f3=_0x3de718['getAttribute'](_0xe08c('0x69'));_0x3de718[_0xe08c('0x53')](_0xe08c('0x69'),_0x2277af),_0x2eeae2[_0xe08c('0x53')](_0xe08c('0x69'),_0x18e2f3),this[_0xe08c('0xe6')]['set'](_0x3de718[_0xe08c('0xa8')](_0xe08c('0x69')),{'userId':_0x26e8fe}),this[_0xe08c('0xe6')][_0xe08c('0x9a')](_0x2eeae2['getAttribute']('vid_start'),{'userId':_0x26e8fe});}else{const _0x124780=this['_revisionId']++,_0x3a2382=this[_0xe08c('0x45')]++;_0x3de718[_0xe08c('0x53')](_0xe08c('0x69'),_0x124780),_0x2eeae2[_0xe08c('0x53')](_0xe08c('0xe7'),_0x3a2382),_0x2eeae2[_0xe08c('0x53')]('vid_end',_0x5f1f34),this[_0xe08c('0xe6')][_0xe08c('0x9a')](_0x124780,{'userId':_0x26e8fe}),this[_0xe08c('0xe6')][_0xe08c('0x9a')](_0x3a2382,{'userId':_0x26e8fe});}}[_0xe08c('0xa2')](_0x1bda00){if(!_0x1bda00[_0xe08c('0xcd')])return;const _0x3cfe8d=(_0x1bda00=this['_cloneOperation'](_0x1bda00,this[_0xe08c('0x4c')]))[_0xe08c('0xc8')]?_0x1bda00[_0xe08c('0xc8')][_0xe08c('0x4b')]:null,_0x9943f4=_0x1bda00['newRange']?_0x1bda00['newRange']['root']:null;_0x3cfe8d&&this[_0xe08c('0x16')]['delete'](_0x1bda00[_0xe08c('0x96')]),_0x9943f4&&this['_markers']['set'](_0x1bda00['name'],_0x1bda00[_0xe08c('0x34')][_0xe08c('0xdd')]());const _0x24a8cd=null===_0x1bda00[_0xe08c('0x9d')]?null:_0x1bda00[_0xe08c('0x9d')]||this[_0xe08c('0xb2')][_0xe08c('0xad')][_0xe08c('0xa6')]('Users')['me']['id'],_0x442312=_0x1bda00[_0xe08c('0x96')];if(!this[_0xe08c('0x95')]['has'](_0x442312))return void this[_0xe08c('0x95')][_0xe08c('0x9a')](_0x442312,{'range':_0x1bda00[_0xe08c('0xc8')],'userId':_0x24a8cd});const _0x12b544=this[_0xe08c('0x95')][_0xe08c('0xa6')](_0x442312),_0x260c98=_0x12b544['range'],_0xfdc8ac=_0x1bda00[_0xe08c('0x34')];null==_0x260c98&&null==_0xfdc8ac||_0x260c98&&_0xfdc8ac&&_0x260c98['isEqual'](_0xfdc8ac)?this[_0xe08c('0x95')][_0xe08c('0x76')](_0x1bda00[_0xe08c('0x96')]):_0x12b544[_0xe08c('0x19')]=_0x24a8cd;}}function J(_0x55a7de){const _0x908456=new _0x588493();_0x908456['rootName']=_0x55a7de[_0xe08c('0x38')];for(const _0x55d30d of _0x55a7de[_0xe08c('0x0')]()){const _0x44212a=_0x55d30d['_clone'](!0x0);_0x908456[_0xe08c('0xd9')](_0x44212a);}return _0x908456;}function j(_0x27dd33,_0x10e681,_0x2d1e71){const _0xc60e4a='elementEnd'==_0x27dd33[_0xe08c('0x74')]?_0x2d1e71['createPositionAt'](_0x27dd33[_0xe08c('0x72')],_0xe08c('0x6a')):_0x2d1e71[_0xe08c('0x8b')](_0x27dd33[_0xe08c('0x72')]);return _0x2d1e71[_0xe08c('0x22')](_0x10e681,_0xc60e4a[_0xe08c('0x89')],_0xc60e4a[_0xe08c('0x7f')]);}function B(_0x4a6ffe,_0xec4d7e,_0x3411c5){const _0x4b865f=_0xe08c('0xcb')==_0x4a6ffe['type']?_0x3411c5[_0xe08c('0x7d')](_0x4a6ffe[_0xe08c('0x72')],0x0):_0x3411c5[_0xe08c('0x14')](_0x4a6ffe['item']);return _0x3411c5[_0xe08c('0x22')](_0xec4d7e,_0x4b865f['path'],_0x4b865f['stickiness']);}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import '../theme/revisionviewer.css';
|
|
2
|
+
/**
|
|
3
|
+
function printTape( tape ) {
|
|
4
|
+
const elements = tape.map(
|
|
5
|
+
item => item.item.data ? item.item.data : item.type == 'elementStart' ? '<' + item.item.name + '>' : '</' + item.item.name + '>'
|
|
6
|
+
).join( '' );
|
|
7
|
+
|
|
8
|
+
const signs = tape.map( v => {
|
|
9
|
+
const item = v.item;
|
|
10
|
+
const sign = ( v.isAdded || v.isAddSuggestion ) ? v.isRemoved ? '=' : '+' : v.isRemoved ? '-' : ' ';
|
|
11
|
+
const len = item.data ? item.data.length : v.type == 'elementStart' ? item.name.length + 2 : item.name.length + 3;
|
|
12
|
+
|
|
13
|
+
return sign.repeat( len );
|
|
14
|
+
} ).join( '' );
|
|
15
|
+
|
|
16
|
+
console.log( elements );
|
|
17
|
+
console.log( signs );
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
window.printTape = printTape;
|
|
21
|
+
/**/
|