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

[REQ] Impl attribute parsing and rendering #91

Open
mhatzl opened this issue Jun 19, 2023 · 1 comment
Open

[REQ] Impl attribute parsing and rendering #91

mhatzl opened this issue Jun 19, 2023 · 1 comment
Assignees

Comments

@mhatzl
Copy link
Contributor

mhatzl commented Jun 19, 2023

Attribute syntax changed from "JSON-like" to "CSS-like".
Therefore, parsing must be reworked.

Besides CSS properties, attributes also allow most HTML attributes to be set.
Unless other conflicts between CSS props and HTML attributes arise, all HTML attributes besides style, height, and width should be ok to use.

A restriction for HTML attributes is that they must not be allowed inside CSS at-rules, since Unimarkup cannot predict at compile time what at-rules should be chosen.

@mhatzl
Copy link
Contributor Author

mhatzl commented Nov 26, 2023

The id attribute is also not allowed in nested context, because an id must be unique per element.
Other HTML attributes in nested context should be allowed, but the behavior may differ between attributes. e.g. the class attribute should merge set classes, while disabled is taken only from the most inner one.

@mhatzl mhatzl self-assigned this Jan 20, 2024
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

No branches or pull requests

1 participant