Skip to main content

Comment Model

The Comment class represents a comment on a post, capturing various attributes and interactions. Below are the details of the Comment model:

Properties

VariableTypeDescriptionOptional
idStringThe unique identifier of the comment.
isLikedboolIndicates whether the comment is liked by the user.
isEditedboolIndicates whether the comment has been edited.
userIdStringThe unique identifier of the user who created the comment.
textStringThe text content of the comment.
levelintThe level or depth of the comment in the hierarchy.
likesCountintThe count of likes received by the comment.
repliesCountintThe count of replies received by the comment.
createdAtintThe timestamp when the comment was created.
updatedAtintThe timestamp when the comment was last updated.
repliesList<Comment>List of comments as replies to the comment.
menuItemsList<PopupMenuItemModel>List of menu items associated with the comment.
parentCommentCommentThe parent comment if the comment is a reply.
uuidStringThe universally unique identifier (UUID) of the comment.
tempIdStringTemporary identifier for the comment used during creation.

PopupMenuItemModel

This model is used to represent the menu items for a comment.

Properties

VARIABLETYPEDESCRIPTIONOPTIONAL
idintID of the menu item.
titleStringTitle of the menu item.