Skip to content

Style engine, additional documentation and extended capabilities#10

Merged
sn merged 2 commits intomainfrom
feature/style-engine
Nov 11, 2025
Merged

Style engine, additional documentation and extended capabilities#10
sn merged 2 commits intomainfrom
feature/style-engine

Conversation

@sn
Copy link
Owner

@sn sn commented Nov 11, 2025

This pull request introduces major new features and enhancements to the YDNATL library, focusing on a comprehensive external stylesheet system, theming, BEM naming convention, responsive design, and HTML parsing. The documentation (README.md) has been substantially expanded to cover these new capabilities, and a new example file demonstrates practical usage of the stylesheet system. Several internal improvements and API extensions have also been made to support these features.

Styling and Theming Enhancements

  • Added a robust external stylesheet system with support for reusable styles, theming (Modern, Classic, Minimal), CSS variables, BEM naming convention, and responsive breakpoints. This enables separation of styles from markup and scalable UI design. (README.md, examples/stylesheet_example.py) [1] [2] [3]
  • Introduced new API exports: CSSStyle, StyleSheet, and Theme for managing styles, themes, and CSS generation. These are now available directly from the main package. (src/ydnatl/__init__.py)

HTML Parsing Support

  • Added the ability to parse raw HTML strings into YDNATL elements, supporting both single elements and fragments with multiple roots. This feature is documented and exposed via from_html (function and class method). (README.md, src/ydnatl/__init__.py) [1] [2] [3]

Documentation and LLM Compatibility

  • Expanded documentation with detailed guides for the new styling and parsing features, including code examples, feature lists, and use cases. Added a dedicated LLM guide for AI/code generation tools, covering API signatures, patterns, and best practices. (README.md)
  • Updated version number to 1.0.7 to reflect these significant changes. (pyproject.toml)

Internal Improvements

  • Minor code style and formatting improvements in core files for consistency and readability. (src/ydnatl/core/element.py, src/ydnatl/core/fragment.py) [1] [2] [3] [4] [5]

These changes greatly enhance YDNATL’s flexibility, scalability, and ease of use for both manual coding and AI-driven code generation.

@sn sn self-assigned this Nov 11, 2025
@sn sn merged commit 91b025b into main Nov 11, 2025
0 of 5 checks passed
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 this pull request may close these issues.

1 participant