Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Follow GFM spec on EM and STRONG delimiters #1686

Merged
merged 26 commits into from Jul 13, 2020

Commits on May 21, 2020

  1. Copy the full SHA
    40493bb View commit details
    Browse the repository at this point in the history

Commits on May 29, 2020

  1. Now passes several more tests

    Added a check for the previous character to the  *em* Tokenizer. Needed to pass any tests where the em block starts with a punctuation character (e.g. commonmark example 368)
    calculuschild committed May 29, 2020
    Copy the full SHA
    4e2ec90 View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    283ab9c View commit details
    Browse the repository at this point in the history

Commits on May 30, 2020

  1. Fix Pedantic

    calculuschild committed May 30, 2020
    Copy the full SHA
    c38ee23 View commit details
    Browse the repository at this point in the history

Commits on Jun 12, 2020

  1. Properly handle reflinks that should be escaped

    Modifies the em rule after the block tokens are generated to detect known reflinks and skip over them so they don't get mistakenly italicized.
    calculuschild committed Jun 12, 2020
    Copy the full SHA
    7c6551e View commit details
    Browse the repository at this point in the history
  2. Lint

    calculuschild committed Jun 12, 2020
    Copy the full SHA
    bc17ded View commit details
    Browse the repository at this point in the history
  3. Lint 2

    calculuschild committed Jun 12, 2020
    Copy the full SHA
    ea203cf View commit details
    Browse the repository at this point in the history
  4. Updated rules for underscore em

    Now fixes three more cases
    calculuschild committed Jun 12, 2020
    Copy the full SHA
    556070b View commit details
    Browse the repository at this point in the history

Commits on Jun 17, 2020

  1. Moved logic into Tokenizer. No longer injecting Reflinks

    Reflinks are replaced with the string 'aaaa' of equal length to hide any asterisks or underscores that might have been inside, since these should not be included. Then, the resulting string is matched to the em regex. The positions of the captures are then used on the original string.
    calculuschild committed Jun 17, 2020
    Copy the full SHA
    4cbba07 View commit details
    Browse the repository at this point in the history
  2. Added fixes to Strong

    Fixes examples 391, 397, 399, 400, 401, 431, 443, 475, 476, 479, and 480
    calculuschild committed Jun 17, 2020
    Copy the full SHA
    335a660 View commit details
    Browse the repository at this point in the history
  3. Lint...

    calculuschild committed Jun 17, 2020
    Copy the full SHA
    e926e0c View commit details
    Browse the repository at this point in the history
  4. Copy the full SHA
    c60c9ba View commit details
    Browse the repository at this point in the history
  5. Copy the full SHA
    54218fe View commit details
    Browse the repository at this point in the history

Commits on Jun 18, 2020

  1. Remove redundant regex symbols

    Found a few more cases of redundant symbols in addition to fixes suggested during review.
    calculuschild committed Jun 18, 2020
    Copy the full SHA
    2a45677 View commit details
    Browse the repository at this point in the history

Commits on Jun 20, 2020

  1. mask reflinks

    UziTech committed Jun 20, 2020
    Copy the full SHA
    d233fd5 View commit details
    Browse the repository at this point in the history

Commits on Jun 30, 2020

  1. Merge pull request #1 from UziTech/mask-reflinks

    mask reflinks in a separate function
    calculuschild committed Jun 30, 2020
    Copy the full SHA
    56b6f5e View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    4db32dc View commit details
    Browse the repository at this point in the history
  3. Gaaaah lint

    calculuschild committed Jun 30, 2020
    Copy the full SHA
    4e7902e View commit details
    Browse the repository at this point in the history

Commits on Jul 2, 2020

  1. Fix unrestricted "any character" for REDOS

    And remove redundant unused capture group.
    calculuschild committed Jul 2, 2020
    1
    Copy the full SHA
    bd4f8c4 View commit details
    Browse the repository at this point in the history

Commits on Jul 8, 2020

  1. Removed Lookbehinds

    Beginning and End delimiters for EM and Strong must be searched in a separate regex to work without lookbehinds. This invalidates the regex that skips over blocks (code, html, etc.) that take precedence over EM or Strong blocks.
    
    Getting around this means we must now mask not only reflinks, but all enclosed blocks which were previously just skipped over in the Regex.
    
    Add one check for overlapping Strong block when testing EM, now passes Commonmark 390 and 471
    calculuschild committed Jul 8, 2020
    Copy the full SHA
    211b9f9 View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    cc778ad View commit details
    Browse the repository at this point in the history
  3. Lint

    calculuschild committed Jul 8, 2020
    Copy the full SHA
    226bbe7 View commit details
    Browse the repository at this point in the history

Commits on Jul 9, 2020

  1. Make strEnd const

    Co-authored-by: Tony Brix <tony@brix.ninja>
    calculuschild and UziTech committed Jul 9, 2020
    Copy the full SHA
    1fb141d View commit details
    Browse the repository at this point in the history
  2. Make emEnd const

    Co-authored-by: Tony Brix <tony@brix.ninja>
    calculuschild and UziTech committed Jul 9, 2020
    Copy the full SHA
    ad720c1 View commit details
    Browse the repository at this point in the history
  3. Copy the full SHA
    e27e6f9 View commit details
    Browse the repository at this point in the history
  4. Copy the full SHA
    6b729ed View commit details
    Browse the repository at this point in the history