Skip to content

bug(markdown) Code blocks surrounded by single backtick then triple backticks #230

@yellis

Description

@yellis

Describe the bug
Pasting fenced code block into inline code block results in the following being saved
image

A side issue here might be that the inline code block menu button has much more prominence than the fenced code block button, so users go to it first and dont think of fenced code block (could also be something that the interface is expecting too much from the user here).

To Reproduce

  1. Create inline code block (can use menu)
  2. Paste in fenced code block
  3. Note: the inline code block ticks are still there, and if saved, will be orphaned ticks surrounding the fenced code block.

Expected behavior
Pasting a fenced code block into an inline code block results in only the fenced code block being inserted, and the preceding and following inline code block ticks being removed.

Screenshots
https://i.stack.imgur.com/F9la7.gif

Desktop (please complete the following information):
Windows 10 Chrome Latest

Additional context
Code blocks surrounded by single backtick then triple backticks. Answer on that page has further repro info.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingmode - markdownAffects the editor's markdown input mode

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions