Methods

For general method usage, see: Methods (Next) and Methods (Editor).

Revision methods

getRevisionState

Description: Get current revision state (enabled, panel visibility, author filter, markup mode, etc.).

Parameters: None

Returns: Object

setRevisionMarkupMode

Description: Set the markup mode.

Parameters:

  • mode: 'final-markup' | 'final' | 'original-markup' | 'original'

Returns: Boolean

setRevisionUsers

Description: Set the author filter for the revision stream.

Parameters:

  • users: String[], default ['all']

Note: Passing an empty array [] hides all revision records. Use ['all'] to clear filtering.

Returns: Boolean

getRevisions

Description: Get revision records in the current document (filtered by setRevisionUsers).

Parameters: None

Returns: Array

Common fields:

  • id / revisionId: revision id (used for accept/reject)
  • from / to: document range
  • type: 'insertion' | 'deletion'
  • userId / userName: author info
  • date: timestamp (minute granularity)
  • isNodeChange: whether this record represents a node-level change
  • nodeType: node type (present for node changes)

acceptRevision / rejectRevision

Description: Accept/reject a specific revision by id.

Parameters:

  • id: revision id from getRevisions() (id or revisionId)

Returns: Boolean

acceptAllRevisions / rejectAllRevisions

Description: Accept/reject all revisions in the document.

Parameters: None

Returns: Boolean