Repository navigation
feat: render Markdown in rich parameter descriptions - #6098
Merged
Merged
Conversation
mafredri
reviewed
Feb 8, 2023
mafredri
left a comment
Member
There was a problem hiding this comment.
That markdown lib was an nice find! My main concern is the lossiness of the plaintext output, otherwise this looks good. 👍🏻
|
|
||
| ` + "`There are also code tags!`" | ||
|
|
||
| expected := "Provide the machine image See the registry for options. Minion This is bold text. This is bold text. This is italic text. Blockquotes can also be nested. Strikethrough. 1. Lorem ipsum dolor sit amet. 2. Consectetur adipiscing elit. 3. Integer molestie lorem at massa. There are also code tags!" |
Member
There was a problem hiding this comment.
Do we actually want the CLI output to be this lossy? For instance:
- Why do we not keep newlines?
- Why don't we print links? We could e.g. do something like:
See the registry (https://container.registry.blah/namespace) for options.
If newlines are not wanted here, perhaps we could call the field DescriptionCondensed instead of plaintext?
Member
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Fixes: #5931
This PR introduces an option to use Markdown tags in rich parameter descriptions.
CLI will switch to
description_plaintextto skip all tags. It uses glow to render the Markdown content as ASCII text.CLI:

Site:

Template: