release: WRNexusJS 0.2.78

This commit is contained in:
2026-07-22 01:53:18 +05:30
parent 7ff5b3e8c5
commit c6fc0f1f63
60 changed files with 228 additions and 96 deletions
+27
View File
@@ -788,6 +788,33 @@ component PageHeader {
expect(output).toContain("dark:bg-white/10");
});
test("class directives accept single-quoted brace expressions", () => {
const output = generate(
parse(`
component MarketingSectionHeader {
props {
align = "start"
}
view {
<header
class="max-w-3xl"
class:mx-auto='{align === "center"}'
class:text-center='{align === "center"}'
>
Header
</header>
}
}
`),
);
expect(output).toContain('${(align === "center") ? " mx-auto" : ""}');
expect(output).toContain('${(align === "center") ? " text-center" : ""}');
expect(output).not.toContain('({align === "center"})');
expect(output).toContain("&quot;align === \\\\&quot;center\\\\&quot;&quot;");
});
test("components support each blocks", () => {
const output = generate(
parse(`