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

Unable to handle case mismatch between start and end tags #250

Closed
Alteras1 opened this issue Aug 23, 2024 · 0 comments · Fixed by #251
Closed

Unable to handle case mismatch between start and end tags #250

Alteras1 opened this issue Aug 23, 2024 · 0 comments · Fixed by #251
Assignees
Labels
bug Something isn't working P1 Moderate Issue

Comments

@Alteras1
Copy link
Contributor

Alteras1 commented Aug 23, 2024

The engine is unable to properly close a tag if the ending tag has a different casing from the start tag.

For example:

[div style="border: 1px solid red"]
lorem ipsum
[/DIV]

gets parsed to

[
  {
    "tag": "div",
    "attrs": {
      "style": "border: 1px solid red"
    },
    "content": []
  },
  "\n",
  "lorem",
  " ",
  "ipsum",
  "\n"
]

On a secondary note: the orphaned closing tag is not added back into the output as plain text, giving the impression that it was accepted.

@JiLiZART JiLiZART self-assigned this Aug 23, 2024
@JiLiZART JiLiZART added bug Something isn't working P1 Moderate Issue labels Aug 23, 2024
@JiLiZART JiLiZART linked a pull request Sep 11, 2024 that will close this issue
JiLiZART added a commit that referenced this issue Oct 16, 2024
* chore: initial tests

* feat: parser test

* feat: add case free tags support

* fix: coverage upload

* fix: --disable=gcov

* fix: npm publish sha commit

* fix: change codecov to coveralls

* fix: change workflow pr build and publish

* chore: change coverage badge [skip ci]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working P1 Moderate Issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants