feat(ew): comments - #1073
Conversation
|
Thanks for your contribution and for your patience! |
done. routed canvas stuff through canvasBus and canvas > panel through |
| let visible = false; | ||
| let hideTimer = null; | ||
| const syncPanelOpen = () => getController()?.setPanelOpen(visible); | ||
| const observer = new IntersectionObserver((entries) => { |
There was a problem hiding this comment.
I think intersection observer might be slightly overkill here - tool-panel already knows which is the currently active panel. Couldnt we expose this so all who want to know which panel is active only refer to it?
There was a problem hiding this comment.
we don't show the comment markers in the canvas if the rail is closed entirely, which is what this is for. doing the above would cause the them to still be visible if a user had the comments panel open, then closed the right rail entirely.
There was a problem hiding this comment.
There is already an event which is fired when the panel is closed. Couldn't we listen to that instead, and thus wouldn't a combination of this + what is the panel currently active cover this case without the need for an observer?
To be merged with adobe/da-nx#562
Summary
Collaborative comments for Experience Workspace.
Users can select text, an image or a table (block) and attach a comment. Each comment is stored as a .json file in
.da/comments/{docId}/{commentId}.jsonWhen a selection is made, a comment icon is also added to the toolbar in EW to initiate a thread.
Supports replies/threads, resolve/unresolve & orphan threads (user comments on something, the content is deleted while the comment is still active).
Comment data will survive if a page is moved to another folder.
Keyboard Shortcuts
CMD+Option+M— if there is a selection, will start composing a new thread.CMD+Enterto submit a comment/replyRead-Only Users
Read only users who should have access to comment only would need to be given write permissions to
/{site}/.da/comments/ + **in the DA config.Layout Mode
Layout mode currently doesn't show a toolbar at all when a block is selected. The comment button should be made available there as part of the work done in SITES-46128Blocks now have a toolbar since this PR was originally raised. This is now supported.
How Has This Been Tested?
Screenshots (if appropriate)
Types of changes
Checklist