Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Copy pasting rich content into an assessment rich text editor does not strip out HTML tags #3345

Closed
rtibbles opened this issue Mar 18, 2022 · 0 comments · Fixed by #3397
Closed
Assignees
Labels
DEV: frontend P0 - critical Priority: Release blocker or regression

Comments

@rtibbles
Copy link
Member

Observed behavior

Copy pasting rich text from e.g. Microsoft Word, can result in HTML being part of the pasted payload. This will then render properly in the context of our Markdown to HTML rich text editor in Studio, but will be properly escaped in Kolibri when rendered, leaving HTML tags rendered as bare text.

Expected behavior

Any HTML tags should be stripped during the process of converting to Markdown and not left in place.

User-facing consequences

Copy pasting into Studio from common rich text editors may result in a misleading experience, where it appears to render as intended in Studio, but not in the learning platform.

Additional information

Question data from Studio:

Karol <span style=\"letter-spacing: 0.03em;\" data-tomark-pass=\"\">__________________ talks in class</span>\n\n\n\n\n\n![](${☣ CONTENTSTORAGE}/ff8a561e4be676ab91f6905efd427467.png)\n\n\n\n\n\n<span style=\"letter-spacing: 0.03em;\" data-tomark-pass=\"\"></span>\n\n\n\n\n\n<span style=\"letter-spacing: 0.03em;\" data-tomark-pass=\"\"></span>

Displayed in Studio:
Screenshot from 2022-03-18 13-25-05

Rendered in Kolibri:
image

Steps to reproduce the issue

  1. Make some rich text content in Word.
  2. Copy paste it into a question in Studio.
  3. Publish and view in Kolibri
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DEV: frontend P0 - critical Priority: Release blocker or regression
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants