fix: support Angular-style attributes and object/array literals in compiled templates

Lexer changes:
- Support quoted attribute names: '(click)'='play()' or "(click)"="play()"
- Support parenthesized attribute names: (click)='play()' (Angular/Vue event bindings)

Build templates changes:
- Object literals for style attribute converted to CSS: {color: 'red'} -> color:red;
- Object literals for other attributes: extract values as space-separated
- Array literals converted to space-separated: ['foo', 'bar'] -> foo bar
This commit is contained in:
2026-01-23 00:06:04 +05:30
parent e6a6c1d87f
commit 3de712452c
4 changed files with 358 additions and 3 deletions

View File

@@ -1,6 +1,6 @@
.{
.name = .pugz,
.version = "0.1.6",
.version = "0.1.7",
.fingerprint = 0x822db0790e17621d, // Changing this has security and trust implications.
.minimum_zig_version = "0.15.2",
.dependencies = .{},