Wykres commitów

11473 Commity (613c4328a26e6aa8a1d93f39da7dd5ed523d6e76)

Autor SHA1 Wiadomość Data
Karl Hobley b49c2e498b Update z-index of comments so they render behind main menu 2021-04-20 18:25:30 +01:00
Karl Hobley 15d931094b Add a test for UserProfile.updated_comments_notifications 2021-04-20 18:25:30 +01:00
jacobtoppm 86f993cd1d Remove the warning icon from the save warning 2021-04-20 18:25:30 +01:00
jacobtoppm 39487b7dad Move commenting js to _editor_js.html 2021-04-20 18:25:30 +01:00
jacobtoppm 831dceaad4 Add missing footer__container class to non-editor footers, and change footer
css to use class selector instead of element
2021-04-20 18:25:30 +01:00
jacobtoppm ca0154543a Use data-tab-nav to find tab nav everywhere 2021-04-20 18:25:30 +01:00
jacobtoppm 79baa145ac Add aria-describedby to comment textboxes 2021-04-20 18:25:30 +01:00
jacobtoppm 616f8e55b7 Remove non-tab li in tablist 2021-04-20 18:25:30 +01:00
jacobtoppm b6b43bcba2 Add menu role 2021-04-20 18:25:30 +01:00
Karl Hobley 5a945c9e61 Send notification emails when comments are updated 2021-04-20 18:25:30 +01:00
Karl Hobley 63c536eef3 Move CommentPanel to settings_panels
Pages often completely override content_panels since there is only one
field by default.

Moving CommentPanel to settings_panels means it's less likely to be
overriden by mistake.
2021-04-20 18:25:30 +01:00
Karl Hobley 66e03c4e1d Set test email backend to Console 2021-04-20 18:25:30 +01:00
Karl Hobley 89de1f86b8 Add updated_comments_notifications field to UserProfile 2021-04-20 18:25:30 +01:00
Karl Hobley 48ec577271 Make send_notification more generic 2021-04-20 18:25:30 +01:00
jacobtoppm a18b1fa2b8 Show comments by default only if there are pre-existing comments 2021-04-20 18:25:30 +01:00
jacobtoppm 1c04d84f38 Highlight whole field when adding Draftail comment with collapsed selection 2021-04-20 18:25:30 +01:00
jacobtoppm 7e1c68401c Combine commenting migrations 2021-04-20 18:25:30 +01:00
jacobtoppm ef638faf76 Allow CommentableEditor to be extended with plugins, controls, decorators 2021-04-20 18:25:30 +01:00
Jacob Topp-Mugglestone 13672e702c Add initial draft of commenting update notes (#7025)
* Add initial draft of commenting update notes

* Add code example for CommentPanel upgrade consideration

* Remove unnecessary Draftail text format upgrade note
2021-04-20 18:25:30 +01:00
jacobtoppm 64f1cbdfd4 Remove completed TODO 2021-04-20 18:25:30 +01:00
Karl Hobley 9e98e680e9 Add PageSubscription model and hook up the comment notifications switch 2021-04-20 18:25:30 +01:00
jacobtoppm 25257de151 Prevent empty comment and reply submissions. 2021-04-20 18:25:30 +01:00
Jacob Topp-Mugglestone d727b2b922 Feature/commenting a11y pass 1 (#7016)
* Add a keyboard shortcut to Draftail for adding/focusing comments

* Increase the timeout for unfocusing comments to reflect doing it on mousedown

* Update react-focus-trap and add focus trap to comments

* Remove extra focusing logic and replace with focusTrap initialFocus argument

* Add forceFocus to tests

* Remove todo

* Update Draftail to 1.4.1 to allow plugin keyBindingFns to be called

* Remove now unneeded icon hiding css due to Draftail update

* Add data-comment-add class to buttons to prevent comment unfocus

* Prevent comment button showing on streamfield root, and attach contentpath to field parent for single field

* Add keyboard shortcut for field level comments

* Consolidate comments keyboard shortcut check in case we change, and use keyCode instead of key

* Formatting and eslint fixes

* Update tests
2021-04-20 18:25:30 +01:00
jacobtoppm dd90405aac Resolve comments when invalidating a contentpath, and delete unsaved comments 2021-04-20 18:25:30 +01:00
Karl Hobley 7cf38f8750 Put add comment button on single_field_panel.html 2021-04-20 18:25:30 +01:00
Karl Hobley b2562e612c Add new icons 2021-04-20 18:25:30 +01:00
Karl Hobley 6e88b6c620 Fix new comments going to the top 2021-04-20 18:25:30 +01:00
Karl Hobley 0bb606a67d Hide buttons by default 2021-04-20 18:25:30 +01:00
Karl Hobley 5c8f8be904 Move comments toggle code into comments.js 2021-04-20 18:25:30 +01:00
Karl Hobley 1257816568 Add initCommentsInterface function 2021-04-20 18:25:30 +01:00
Karl Hobley 7411e278e0 Merge comments.js into entrypoint 2021-04-20 18:25:30 +01:00
Karl Hobley d4ba41f770 Make commentApp a module global (rather than putting it on the window) 2021-04-20 18:25:30 +01:00
Karl Hobley 17f1798178 Implement commenting on field blocks 2021-04-20 18:25:30 +01:00
Karl Hobley 06d2e0daec Add comments at the field level rather than in each widget 2021-04-20 18:25:30 +01:00
Karl Hobley 2cbeed858f Dynamically resize fields when comments are enabled 2021-04-20 18:25:30 +01:00
Karl Hobley 03367519f6 Add a missing space 2021-04-20 18:25:30 +01:00
jacobtoppm 5c7c08fc0b Split out CommentableEditor utility functions, and add basic tests 2021-04-20 18:25:30 +01:00
Karl Hobley 99bccfdd57 Delete comments when block is deleted (#6957) 2021-04-20 18:25:30 +01:00
Jacob Topp-Mugglestone 9eedf30f70 Feature/inline comment focus on add (#6983)
* Use unfocus on mousedown for Draftail compatibility, and add comment adders to exceptions

* Focus comment on timeout to avoid losing focus to rerendering Draftail

* Stop editor from stealing focus, and add unfocus exception class to comment button

* Remove unused eslint disable

* Fix forwarded ref

* Remove unnecessary memo
2021-04-20 18:25:30 +01:00
Karl Hobley 99a65d3443 Separate layout calculations for each tab 2021-04-20 18:25:30 +01:00
Karl Hobley c0588c1511 Only refresh comment positions on current tab
Prevents comments on other tabs moving to the top of the page
2021-04-20 18:25:30 +01:00
Karl Hobley e2ee17bb59 Make comment app track which tab comments are on 2021-04-20 18:25:30 +01:00
Karl Hobley 576c30cbad Make commenting track which tab is currently active 2021-04-20 18:25:30 +01:00
Karl Hobley e0d4381661 Add data attrs/events so that we can tell which tab is active 2021-04-20 18:25:30 +01:00
Karl Hobley 3aafb4e705 Commenting: Tweak the sizes to more closely match the design (#6978)
* Commenting: Tweak the sizes to more closely match the design

* Further UI tweaks

- Address feedback from review
- Add a TextArea component that dynamically expands

* Remove duplicate focusing logic

* Linting

* Revert "Remove duplicate focusing logic"

This reverts commit 340c965788.

* Remove textarea focus
2021-04-20 18:25:30 +01:00
Karl Hobley a5624a3e09 Replace comment icon with comment-dots 2021-04-20 18:25:30 +01:00
Karl Hobley 3174ffee08 Add commenting controls 2021-04-20 18:25:30 +01:00
Jacob Topp-Mugglestone 779f50aa3c Draftail comment styling
* Add right hand alignment and teal colour to Draftail comment control

* Add css fix for empty comment styles

* Update comment highlight colours
2021-04-20 18:25:30 +01:00
Jacob Topp-Mugglestone ebdb3efbe6 Feature/comment resolving (#6975)
* Prevent deleted comments being undeleted when the page form is invalid

* Add resolved state for comments
2021-04-20 18:25:30 +01:00
Jacob Topp-Mugglestone d64dad9739 Add save warning to page editor for comments and edits 2021-04-20 18:25:30 +01:00