# Epic COMMS-1 - Internal comments in the work package activity tab

Project: Stream Communicator
Status: closed
URL: https://community.openproject.org/work_packages/COMMS-1

## Detailed specification

### Motivation and background information

**As a** project member  
**I want to** add internal comments in work packages  
**So that I** can add context information that I only share with a subgroup of certain people (such that the information is not shared with all project member and non members)

### Acceptance criteria

  - Administration: there are new role permissions:
    
      - View internal comments
    
      - Write internal comments
    
      - Edit own internal comments
    
      - Edit others' internal comments (for moderation)

  - When I write a comment, I can choose to make it internal
    
      - There is a checkbox to enable this
    
      - There is a "More info" button that takes the user to the documentation of the feature.
    
      - The background colour of the comment box will change the to same colour as top info line of Internal comments in the Activity stream to reassure the user that this mode is indeed active with a clear visual signal.
    
      - [Primer colours](https://primer.style/foundations/color/base-scales) to use:
        
          - **Background info line:** `display-brown-bgColor-muted`
        
          - **Background body**: `bgColor-default`
        
          - **Text:** `fgColor-default`
        
          - **Outline:** `display-brown-borderColor-emphasis`
        
          - These colours will automatically adjust to dark mode (Primer feature)

  - If a comment is internal, it is easily distinguishable from other comments (that are public) so I can be reassured that they can't be publicly visible.
    
      - Internal comments appear in a different colour scheme (defined above)
    
      - There is a lock icon on the top right corner to the left of the More icon.
        
          - There is an alt text: "Only visible to a limited group of members."
        
          - *This will eventually show a Primer tooltip and lead to the Members page on click. See out of scope.*
    
      - If there is also an unread badge, this will appear to the *left* of the lock icon
    
      - Normal (public) comments with *not* have an unlocked icon

  - Quoting is possible. However, when quoting a internal comment, that comment must also be confidential by default
    
      - The 'Internal comment' checkbox is checked
        
          - *Risk: the user inadvertently some how unchecks this but leaks the comment. But they could just also well copy/paste a internal comment.*
    
      - This is to limit the risk of accidental/inadvertent leaking of the comment.

  - Notifications: internal comments will also appear in the notification center just like comments if I have access to them
    
      - Same with email notifications

  - It should not be possible to *@mention* users who will not be able to view the internal comment (i.e, the drop-down needs to exclude users without the requisite permissions)
    
      - If a user who does not have the permissions to view Internal comments is mentioned in a regular comment and the 'Internal comment' checkbox is *then* checked, the @mention is turned into plain text.
    
      - Unchecking the "Internal comment" checkbox will *not* re-convert previously stripped @mentions back to links.

  - If were part of a role that afforded you the ability to view internal comments and you are subsequently removed from this role such that you no longer have this permission:
    
      - You can no longer view or post such comments in the Activity tab
    
      - The Notification centre should not break (because it can no longer find the missing notification)
    
      - The notifications will stop, but for unread and past notifications:
        
          - Internal comments are now hidden
        
          - No other changes (to \# of notifications, badges...)
    
      - *Risk: Any email notification sent cannot obviously be retracted.*

  - There is no visible numbering of activity comments anymore for all comments (internal or otherwise),
    
      - Ideally, old links with `#activity-<comment-number>` still work.
    
      - Copying the URL of a comment will have a new URL scheme including a real, persistent ID and not a generated number anymore so that it stays the same even when other comments are added or removed from the activity, e.g. \#comment-\<journal-id\>
    
      - When that URL is opened the browser will auto-scroll to have the comment in the visible viewport.

  - When there is not Enterprise token, or the token does not allow this feature:
    
      - We still show the permissions in the role administration and leave them editable.
    
      - We don't show the toggle/checkbox to make a new comment a internal comment.
    
      - We show a banner at the project setting for enabling the feature.

  - internal comments can be enabed/disabled at a project level
    
      - There will be in a new tab called 'Internal comments' in the new consolidated 'Work packages' page in Project settings.
    
      - In this tab, there is a single checkbox with:
        
          - Label: "Enable internal comments"
        
          - Caption: "Internal comments allow an internal team to communicate amongst themselves privately. These are only visible to select roles that have the necessary permissions and will not be visible publicly. Read more."
            
              - The "Read more" is a link that links to the documentation for this feature.
    
    <br>

**Mobile specificities**

  - On narrow screens, internal comments on the timeline are displayed the same way as the mobile rendering of normal comments, but with the additional elements:
    
      - Different background colours
    
      - The lock icon

  - When writing a comment, the "Internal comment" action uses the same string, but the 'Read more' link is hidden

**Permissions and visibility considerations**

  - The 'Last updated' field will be updated when an internal comment is posted; even users who do *not* have the permissions to view them will see that something has changed, but will be unable to see what that is.
    
      - Relevant: <mention class="mention" data-id="62473" data-type="work_package" data-text="##62473">##62473</mention>

  - It is important the visibility of Internal comments is also permission-controlled in other places where Activity is reported:
    
      - Project activity
    
      - User activity

**Translation considerations**

  - Action: "Internal comment"
    
      - DE: ""
    
      - FR: "Commentaire interne"
    
      - ES: ""

  - Feature name: "Internal comments"
    
      - DE: ""
    
      - FR: "Commentaires internes"
    
      - ES: ""

  - Permission: "View internal comments"
    
      - DE: ""
    
      - FR: "Lire des commentaires internes"
    
      - ES: ""

### Out of scope

  - When writing a comment, if "Restrict visibility" is checked, there is a link that lets the user view *who* can view these restricted-visibility comments.

  - This will take the user to the Members page of that project with the 'View comments with restricted visibility' permission filter enabled.

  - This page does not yet exist, we'll create a ticket for it.

  - On a restricted visibility comment on the Activity stream:
    
      - Hovering on the lock icon (on non-mobile screens) should display a tooltip: "Only visible to certain members. Click for more info."
    
      - Clicking on this lock icon will take the user to the Members page of that project with the 'View restricted visibility comment' permission filter enabled.

  - The "Show everything" view filter on the top right has two additional options:
    
      - "Restricted visibility comments only"
    
      - "Show everything publicly visible"

  - The ability to specify a custom scope per confidential note (eg. selecting individual users or groups)

  - Notifications that adapt to a change in role where you no longer have the permissions to view restricted visibility comments:
    
      - If the notification is aggregated,
        
          - Keep the notification, but remove those updates that are no longer relevant
    
      - If the notification is singular (only for restricted comments)
        
          - Hide the notification entirely

| Attribute | Value |
| --- | --- |
| Mockups | https://www.figma.com/design/w0YoqQ5v0JGNT5NS5NZJZq/Comments-with-restricted-visibility?node-id=0-1 |

## Planning

| Attribute | Value |
| --- | --- |
| Roadmap |  |
| Date |  |
| Votes | 8 |
| List |  |
| Target versions | 16.0.0 |
| Sprint |  |
| Backlog bucket |  |
| Relevance |  |

## Subitems

| ID | Type | Subject | Status | Assignee | Target versions | Project | Priority | Spent time |
| --- | --- | --- | --- | --- | --- | --- | --- | --- |
| COMMS-256 | Feature | Group work package-related project settings in a new entry called 'Work packages' | closed |  | 15.5.0 | Stream Communicator | Medium |  |
| COMMS-195 | Feature | Amend work package comment href from `#activity-<journal-sequence>` to `#comment-<journal-id>` with backwards compatibility for old links | closed |  | 16.0.0 | Stream Communicator | Medium |  |
| COMMS-199 | Feature | Introduce internal comments | closed |  | 16.0.0 | Stream Communicator | Medium |  |
| COMMS-219 | Feature | Enterprise/Professional upsale banners for internal comments | closed |  | 16.0.0 | Stream Communicator | Medium |  |
| COMMS-277 | Feature | Don't show work package comment inline attachments in Files tab | closed |  | 16.0.0 | Stream Communicator | Medium |  |
| COMMS-295 | Feature | Show warning if a user tries to uncheck the 'Internal comment' checkbox when there's already text in the comment box | closed |  | 16.0.0 | Stream Communicator | Medium |  |
| COMMS-299 | Feature | Additional protections for internal comments in places where comments are accessed | closed |  | 16.0.0 | Stream Communicator | Medium |  |
| COMMS-314 | Feature | Remove internal comments feature flag | closed |  | 16.0.0 | Stream Communicator | Medium |  |
| COMMS-316 | Feature | Remove work package comment ID URL feature flag | closed |  | 16.0.0 | Stream Communicator | Medium |  |
| COMMS-194 | Open Point | How do we call confidential/helpdesk/restricted/internal comments? | decided |  |  | Stream Communicator | Medium |  |
| COMMS-211 | Open Point | How can internal comments be enabled/disabled at a project level? | decided |  |  | Stream Communicator | Medium |  |
| COMMS-212 | Open Point | Should someone be able to make a previously-posted internal comment public? | resolved |  |  | Stream Communicator | Medium |  |
| COMMS-213 | Open Point | What happens if you check the 'Internal comment' checkbox after after having mentioned somebody? | resolved |  |  | Stream Communicator | Medium |  |
| COMMS-218 | Open Point | What plans will have the feature “internal comments”? | resolved | Niels Lindenthal |  | Stream Communicator | Medium |  |
| COMMS-294 | Open Point | Should we introduce a project setting to make comments restricted by default? | decided |  |  | Stream Communicator | Medium |  |

## Bugs and other work packages

| ID | Type | Subject | Status | Assignee | Target versions | Module |
| --- | --- | --- | --- | --- | --- | --- |
| COMMS-294 | Open Point | Should we introduce a project setting to make comments restricted by default? | decided |  |  |  |
| COMMS-211 | Open Point | How can internal comments be enabled/disabled at a project level? | decided |  |  |  |
| COMMS-194 | Open Point | How do we call confidential/helpdesk/restricted/internal comments? | decided |  |  |  |
| COMMS-218 | Open Point | What plans will have the feature “internal comments”? | resolved | Niels Lindenthal |  |  |
| COMMS-213 | Open Point | What happens if you check the 'Internal comment' checkbox after after having mentioned somebody? | resolved |  |  |  |
| COMMS-212 | Open Point | Should someone be able to make a previously-posted internal comment public? | resolved |  |  |  |

## Details

| Attribute | Value |
| --- | --- |
| Module |  |
| Enterprise plan | Enterprise / Professional (PRO) |
| Labels |  |

## People

| Attribute | Value |
| --- | --- |
| Assignee |  |
| Accountable | Kabiru Mwenja |
| Product manager |  |
| Feature Lead |  |
| Designer | Parimal Satyal |
| Developers | Kabiru Mwenja, Bruno Pagno |
| Requested by | ZenDiS |
| Interest by |  |

## Estimates and progress

| Attribute | Value |
| --- | --- |
| Work |  |

## Description

### **Example use case:**

*   A client or partner should have access to a work package to collaborate closely. However this partner should not have access to all information.
