Skip to content

Comment mark disappear #1994

@AntoLC

Description

@AntoLC

Describe the bug
We have users with different roles, on the same document we can have users that can write / read comments (admin / owner / editor etc...), and users with role that are not allowed to see the comments.

Depend these roles, we init or not comments:

comments: {
threadStore,
},

By doing like that, if a user has the comments feature and another user does not have it, the line disappear.

Test.Comments.-.Docs.webm

ThreadStoreAuth does not provide a way to block user to see comment:

export abstract class ThreadStoreAuth {
abstract canCreateThread(): boolean;
abstract canAddComment(thread: ThreadData): boolean;
abstract canUpdateComment(comment: CommentData): boolean;
abstract canDeleteComment(comment: CommentData): boolean;
abstract canDeleteThread(thread: ThreadData): boolean;
abstract canResolveThread(thread: ThreadData): boolean;
abstract canUnresolveThread(thread: ThreadData): boolean;
abstract canAddReaction(comment: CommentData, emoji?: string): boolean;
abstract canDeleteReaction(comment: CommentData, emoji?: string): boolean;
}

In our case, we will not want to see the "mark" neither on the text if the user is not allowed to see comments.

Misc

  • Browser: Any browser
  • I'm a sponsor and would appreciate if you could look into this sooner than later 💖

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions