Extends
- Immutable.Record
Members
Methods
Members
This property defines whether the user has permission to edit the group of this comment. The value of this field depends on the set of collaboration permissions defined in the JWT token.
It is only available when collaboration permissions is enabled on Server-Backed deployments.
Type:
- boolean
The time when the comment was created.
Type:
- Date
The name of the person who created the comment.
Type:
- string
Arbitrary JSON-serializable data the user can attach to the comment.
Type:
- object
This property is used to define the permission scope for a particular comment.
It is only available when collaboration permissions is enabled on Server-Backed deployments.
Type:
- string
A unique identifier for the comment. When comment is created in the UI, the viewer has to generate a unique ID.
Type:
- InstantID
This property defines whether this comment can be deleted or not. The value of this field depends on the set of collaboration permissions defined in the JWT token.
It is only available when collaboration permissions is enabled on Server-Backed deployments.
Type:
- boolean
This property defines whether this comment can be edited or not. The value of this field depends on the set of collaboration permissions defined in the JWT token.
It is only available when collaboration permissions is enabled on Server-Backed deployments.
Type:
- boolean
The page index that this comment resides at.
Type:
- number
If this comment is from the original PDF, then this ID is from that PDF note annotation that defined the comment.
Type:
- number
The ID of the annotation that this comment stems from. In PSPDFKit for Web, this should be either a PSPDFKit.Annotations.MarkupAnnotation or a PSPDFKit.Annotations.CommentMarkerAnnotation.
Type:
- InstantID
The text of the comment in xhtml/plain text format.
In case of XHTML, we support the following tags:
<b>
: Bold<i>
: Italic<span>
: Font color, background color and underline using thestyle
attribute (e.g.<span style="color: red; background-color: blue; text-decoration: underline">Hello</span>
)p
: Paragraph. You can use this to add a newline between paragraphs.a
: Link. You can use this to add a link to the comment. Thehref
attribute is required.
Type:
The time when the comment was last updated.
Type:
- Date
Methods
A method that returns a set of user IDs that are mentioned in the comment.
Returns:
A immutable set of user IDs that are mentioned in the comment.
- Type
- Immutable.Set.<string>
Example
const ids = comment.getMentionedUserIds()
Comment deserializer. Converts a comment object to a PSPDFKit.Comment.
Parameters:
Type | Description |
---|---|
object |
Returns:
- Type
- PSPDFKit.Comment
Comment serializer. Converts a comment to a InstantJSON compliant object.
Parameters:
Type | Description |
---|---|
PSPDFKit.Comment |
Returns:
- Type
- object