Embedded snippets: Add Markdown preview
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
Description
Our new embedded snippets feature, available with 10.8, allows to put GitLab snippets on any website.
When working with Markdown snippets, one thing that is missing is the option to see the rendered Markdown preview.
Proposal
- Snippets based on Markdown remain to be shown in source code view by default, as is
- Add option to display snippets based on Markdown as Preview
- A new button group in the embedded snippet header allows to switch between Source and Preview ("Rendered file"), similar to the file viewer on the snippet page
Design proposal
- Draft by myself, subject to finalize before implementation
- New icon SVGs used:
code
,doc-text
(in place:doc-code
,download
)
Links / references
Example snippet
- GitLab Snippet page
- Embedded snippet example on GitLab Pages
cc @haseebeqx
Edited by 🤖 GitLab Bot 🤖