Render the title of a referenced issue within markdown
When referencing issues, epics, or merge requests within markdown fields, there was previously no way to surface additional context about the issue other than the ID. You can now append
+ to an issue, epic, or merge request reference to additionally render the title.
Currently when you type an issue id, such as
"#1234", then the GFM (GitLab flavored markdown) will only render
"#1234" as a link to the issue.
This proposal adds the ability to also render the issue title itself. In particular, if you type
#1234+, then GitLab will render that as
#1234 Tried to add SSH key and got error as a link to the issue.
We should remove the tooltip if the
+ version of the issue is being displayed.
We should considering this for merge requests and epics too, and possibly other objects like snippets and commits. We can consider that when this is being implemented.
Implementation - very rough
- make sure a
+is the right character to use
- update reference regular expressions to recognize the new character
- find where we handle adding
(merged)to link titles, and add the title if the
+character has been used
- only remove the tooltip if the tooltip only displays the title. If it displays other information (status, etc), then it should probably remain.
- redact the titles when user does not have access
An issue number without a context is not valuable when you have thousands of issues. Having to write it out is a pain.
We expand issue titles, but only when they're not followed by text.
If they are, we restrict it to the number with a bit of the text, which can expand on hover.
To allow the old functionality to exist (for when you just need a short id), we can add a new syntax of adding
- to the end of the id. For instance
Alternatively, this new functionality would be hidden behind a new syntax
#2323+, but I prefer to make the default behavior the smarter behavior.
Links / references
This page may contain information related to upcoming products, features and functionality. It is important to note that the information presented is for informational purposes only, so please do not rely on the information for purchasing or planning purposes. Just like with all projects, the items mentioned on the page are subject to change or delay, and the development, release, and timing of any products, features, or functionality remain at the sole discretion of GitLab Inc.