feat: add support for mj-html-attributes, mj-selector, and mj-html-attribtue#535
Open
codedninja wants to merge 2 commits intojdrouet:mainfrom
Open
feat: add support for mj-html-attributes, mj-selector, and mj-html-attribtue#535codedninja wants to merge 2 commits intojdrouet:mainfrom
codedninja wants to merge 2 commits intojdrouet:mainfrom
Conversation
…attribute Signed-off-by: Michael Pivonka <me@coded.ninja>
…tribute. Signed-off-by: Michael Pivonka <me@coded.ninja>
aed08de to
314a691
Compare
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #535 +/- ##
==========================================
- Coverage 92.89% 91.33% -1.56%
==========================================
Files 227 213 -14
Lines 12203 12869 +666
==========================================
+ Hits 11336 11754 +418
- Misses 867 1115 +248 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Do to the limitation of not wanting to parse the whole rendered HTML, this feature doesn't support CSS child combiner syntax. It only supports current element syntax. Examples of query selectors are listed below.
I do think there is a better way to inject the HTML attributes when calling
Tag::render_open()orTag::render_close()inpackages/mrml-core/src/prelude/render/tags.rs. Though I am still learning Rust, I couldn't think of a good way to do so yet.