Skip to content

Conversation

@christophano
Copy link
Contributor

I've had an issue where abbreviations are being created for words that contain punctuation.
Example:

*[1A]: First
We should not abbreviate 1.1A

Is rendered as:

<p>We should not abbreviate 1.<abbr title="First">1A</abbr></p>

I've adjusted the AbbreviationParser to allow punctuation to embrace matches only if they are further embraced by \0 or whitespace.

@xoofx xoofx merged commit 0ea4dc7 into xoofx:master Sep 20, 2016
@xoofx
Copy link
Owner

xoofx commented Sep 20, 2016

Thanks for digging into these corner cases! Out of curiosity, are you using markdig for a particular project?

@christophano christophano deleted the bugfix/abbreviation-preceded-by-punctuation branch September 20, 2016 14:47
@christophano
Copy link
Contributor Author

No problem, this is by far the best markdown parser I've found, and being able to extend it is fantastic.
I am working on a small project that will store content (think multi volume regulations) as markdown with the aim that textual corrections and updates can eventually be done by admin staff rather than development staff.

@xoofx
Copy link
Owner

xoofx commented Sep 20, 2016

Thanks for the feedback, that's good to hear. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants