Skip to content

BlockSuite API Documentation / @blocksuite/presets / CommentManager

Class: CommentManager

Constructors

new CommentManager(host)

new CommentManager(host): CommentManager

Parameters

host: EditorHost

Returns

CommentManager

Source

packages/presets/src/fragments/comment/comment-manager.ts:29

Properties

host

readonly host: EditorHost

Source

packages/presets/src/fragments/comment/comment-manager.ts:29

Accessors

_command

get private _command(): CommandManager

Returns

CommandManager

Source

packages/presets/src/fragments/comment/comment-manager.ts:165


commentsMap

get commentsMap(): Map<Map<unknown>>

Returns

Map<Map<unknown>>

Source

packages/presets/src/fragments/comment/comment-manager.ts:31

Methods

addComment()

addComment(selection, payload): Comment

Parameters

selection: TextSelection

payload: Pick<CommentContent, "text" | "author">

Returns

Comment

Source

packages/presets/src/fragments/comment/comment-manager.ts:102


getComments()

getComments(): Comment[]

Returns

Comment[]

Source

packages/presets/src/fragments/comment/comment-manager.ts:128


parseTextSelection()

parseTextSelection(selection): null | Object

Parameters

selection: TextSelection

Returns

null | Object

Source

packages/presets/src/fragments/comment/comment-manager.ts:35


Generated using TypeDoc and typedoc-plugin-markdown.