Skip to content

Add Commonmark support to Content Editor

Enrique Alcántara requested to merge 325735-content-editor-commonmark into master

What does this MR do?

Adds Commonmark support to the Content Editor component. In other words, it allows displaying and editing the types of content described in the Commonmark specification:.

There are some caveats that I mention in the following table. They are related to the way the Content Editor generates Markdown like the bullet-list style. We don’t need to address formatting preferences in the Editor MVC and that’s the reason I avoid further customization in this MR.

Content Type Notes
Paragraph
Heading
ThematicBreak
Blockquote
BulletList CAVEAT: Does not remember preferred bullet: * or - yet. I think this requirement shouldn’t be part of the MVC
OrderedList CAVEAT: Does not remember whether to only use 1.s or 1., 2., 3. yet. I think this requirement shouldn’t be part of the MVC
ListItem
Link definitions and references CAVEAT: the editor will convert these into normal links. We need some backend support to output reference definitions when they are used in existing Markdown. I think this requirement shouldn’t be part of the MVC
Link
Image
Code block
Text
Emphasis
Strong
InlineCode

Screenshots (strongly suggested)

This MR does not introduce user-facing changes.

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team

Related to #325735 (closed)

Edited by Enrique Alcántara

Merge request reports

Loading