Add MD050/strong-style (fixes #150).

This commit is contained in:
Sébastien Règne 2021-10-21 06:42:48 +02:00 committed by GitHub
parent 6294ad3ef0
commit ab9e5875a2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
23 changed files with 255 additions and 19 deletions

View file

@ -181,6 +181,22 @@ module.exports.fencedCodeBlockStyleFor =
}
};
/**
* Return the string representation of a emphasis or strong markup character.
*
* @param {string} markup Emphasis or strong string.
* @returns {string} String representation.
*/
module.exports.emphasisOrStrongStyleFor =
function emphasisOrStrongStyleFor(markup) {
switch (markup[0]) {
case "*":
return "asterisk";
default:
return "underscore";
}
};
/**
* Return the number of characters of indent for a token.
*