Skip to content

Some tinyMCE plugins do not work in the comment field #164

Description

@srobotta

Moodle Version in use

Moodle 5.1.4

** Plugin Version **

PDF Annotator v1.5 release 9

Describe the bug

Several tinyMCE plugins do not work when the tiny is loaded in the comment section to add an annotation. I have a detailed description for the Course Elements Plugin provided: bycs-lp/moodle-tiny_elements#55

When I use the pin tool, I cannot use the "insert code sample" from the tinyMCE. The first time it seems to work but no code is inserted, the second time I try to use the insert code sample, as soon as I try to write some code, the modal automatically closes without having a chance to edit further.

What all these bugs have in common is that apparently the event listener do not work correctly.

To Reproduce
Steps to reproduce the behavior:

  1. Given there is a pdf annotation activity and I open it.
  2. I click on the pin icon in the tool bar of the pdf annotator.
  3. I clock somewhere in the PDF to add a pin with a comment.
  4. In the tinyMCE I click the menü item insert -> code sample.
  5. I add some code and click save so that the modal closes.
  6. I click "Create annotation"
  7. I click at another place in the PDF and repeat the steps to add a maker with an annotation.
  8. I cannot reliably add another code sample.
    Expected behavior
    A clear and concise description of what you expected to happen.

Desktop (please complete the following information):

  • OS: Linux Fedora 43
  • Browser: Firefox
  • Version: 149.0.2

Additional context

The bug is not always reliable reproducable. Inserting code usually works at the first time but not afterwards. It might work in a separate answer to a comment. However, from a user perspective, it does not exactly what it should.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions