fix(message-parser): Link/URL parser issues #855
Merged
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.
TC-89 | TC-90 | TC-91 | TC-97
Proposed changes (including videos or screenshots)
This pull request fixes the following parsing problems:
The link parser was not parsing Emphasis elements (bold, italic, and strike). - TC-91
Current behavior:
Expected behavior
The link parser was not parsing some special chars - TC-90
The following markdown input produces:
Current behavior:
Expected behavior
PS: It was removed invalid TLD that starts with a number, but still highlights possible URLs like (
hugo.costa
) because if we map all possible and valids TLDs (1.5k+) the parser durations would be huge and would impact the performanceThe following markdown input produces:
Current behavior:
Expected behavior
Issue(s)
RocketChat/Rocket.Chat#26889
RocketChat/Rocket.Chat#23020
RocketChat/Rocket.Chat#26815
Further comments
The fix number 1 address the changes made in Core repository PR: RocketChat/Rocket.Chat#26971 and needs to be tested together
Full markdown used for testing: