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

CSS fails to parse when comment is at the end of a block #255

Closed
DanHodges opened this issue Aug 12, 2021 · 1 comment · Fixed by #256
Closed

CSS fails to parse when comment is at the end of a block #255

DanHodges opened this issue Aug 12, 2021 · 1 comment · Fixed by #256

Comments

@DanHodges
Copy link
Contributor

DanHodges commented Aug 12, 2021

val myCss = 
    """
      |.some-class {
      |  font-size: 5px;
      |/*
      |  font-color: red;
      |*/
      |}""".stripMargin

Fails to parse using parse(myCss, CssRulesParser.ruleList(_))
This seems to only happen when the multiline comment is last in the block-

val myCss =
    """
      |.some-class {
      |  font-size: 5px;
      |/*
      |  font-color: red;
      |*/
      |  margin: 3px;
      |}""".stripMargin

parses successfully.

@DanHodges DanHodges changed the title Multiline css comments don't parse when comment is at the end of a block Multiline css comments fail to parse when comment is at the end of a block Aug 12, 2021
@DanHodges
Copy link
Contributor Author

DanHodges commented Aug 13, 2021

Upon further investigation - it appears this happens with single and multiline comments.
Screen Shot 2021-08-13 at 4 59 53 PM
Screen Shot 2021-08-13 at 4 59 41 PM

@DanHodges DanHodges changed the title Multiline css comments fail to parse when comment is at the end of a block CSS fails to parse when comment is at the end of a block Aug 13, 2021
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 a pull request may close this issue.

1 participant