From efd1853d069fbd1476e82d015da4d0d04cfaccc0 Mon Sep 17 00:00:00 2001 From: Laurenz Date: Mon, 7 Nov 2022 12:21:12 +0100 Subject: Show it! - New show rule syntax - Set if syntax - Removed wrap syntax --- tests/typ/structure/desc.typ | 2 +- tests/typ/structure/heading.typ | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'tests/typ/structure') diff --git a/tests/typ/structure/desc.typ b/tests/typ/structure/desc.typ index e12bbd16..af1b2986 100644 --- a/tests/typ/structure/desc.typ +++ b/tests/typ/structure/desc.typ @@ -37,7 +37,7 @@ No: list \ --- // Test grid like show rule. -#show it: desc as table( +#show desc: it => table( columns: 2, padding: 3pt, ..it.items.map(item => (emph(item.term), item.body)).flatten(), diff --git a/tests/typ/structure/heading.typ b/tests/typ/structure/heading.typ index d37d8796..d08b3687 100644 --- a/tests/typ/structure/heading.typ +++ b/tests/typ/structure/heading.typ @@ -1,7 +1,7 @@ // Test headings. --- -#show node: heading as text(blue, node.body) +#show heading: it => text(blue, it.body) = No heading @@ -46,8 +46,8 @@ multiline. = Heading #set heading(family: "Roboto", fill: eastern) -#show it: heading as it.body -#show it: strong as it.body + [!] +#show heading: it => it.body +#show strong: it => it.body + [!] ===== Heading 🌍 #heading(level: 5)[Heading] -- cgit v1.2.3