Skip to content

Conversation

@ssddanbrown
Copy link
Member

@ssddanbrown ssddanbrown commented Jan 30, 2024

This PR aims to bring the recently added simple book/chapter/shelf description WYSIWYG inputs to comments.

Todo

  • Added WYSWIYG loading and UI for comments.
  • Add back-end changes for submission/saving.
  • Add link selector support.
  • Load in WYSWIYG content gracefully where possible.
  • Remove old redundant comment regen command.
  • Add HTML cleaning on comment show/usage?
  • Set issue to drop old text (markdown) comment column in a future update?
  • Testing
    • RTL
    • Dark mode
    • Update tests not to use Comment->text property.
    • Test editor loads if cannot comment all, but can edit existing comment.
    • Test display of comments
    • Test updating of comments with HTML
    • Test HTML content filtering on submit

Doc Updates

  • Update advisory about limited compatibility with old markdown content.
  • Update advisory on removal of the comment regen command.
  • Remove docs content for comment regen command.

Not supporting old content, existing HTML or updating yet.
Also fixed handling of editors when moved in DOM, to properly remove
then re-init before & after move to avoid issues.
- Updated existing tests with recent back-end changes, mainly to use
  HTML data.
- Removed old comment regen command that's no longer required.
- Added filter on load to help prevent potentially dangerous comment
  HTML in DB at load time (if it gets passed input filtering, or is
  existing).
- Added TinyMCE valid_elements for input wysiwygs, to gracefully degrade
  content at point of user-view, rather than surprising the user by
  stripping content, which TinyMCE would show, post-save.
@kernelry
Copy link

Will be possible to insert an image in WYSIWYG comment editor? 😁
similar to the old markdown Comment editor.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

3 participants