summaryrefslogtreecommitdiff
path: root/tests/typ/text
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2022-11-08 11:45:54 +0100
committerLaurenz <laurmaedje@gmail.com>2022-11-08 11:45:59 +0100
commita7a4cae2948176119e8995bd8e1868f2d0e65029 (patch)
tree123e8867c939373c1c5ce5a0d20f55192c2467c2 /tests/typ/text
parent0a41844cc4e645e87fe48aa31ed3a4fd40a6ab11 (diff)
Less style properties
Diffstat (limited to 'tests/typ/text')
-rw-r--r--tests/typ/text/indent.typ3
-rw-r--r--tests/typ/text/link.typ6
2 files changed, 5 insertions, 4 deletions
diff --git a/tests/typ/text/indent.typ b/tests/typ/text/indent.typ
index 92b12180..97044153 100644
--- a/tests/typ/text/indent.typ
+++ b/tests/typ/text/indent.typ
@@ -2,7 +2,8 @@
---
#set par(indent: 12pt, leading: 5pt)
-#set heading(size: 10pt, above: 8pt)
+#set heading(above: 8pt)
+#show heading: text.with(size: 10pt)
The first paragraph has no indent.
diff --git a/tests/typ/text/link.typ b/tests/typ/text/link.typ
index 8e777956..8c3e6ddd 100644
--- a/tests/typ/text/link.typ
+++ b/tests/typ/text/link.typ
@@ -16,6 +16,7 @@ call #link("tel:123") for more information.
---
// Test that the period is trimmed.
+#show link: underline
https://a.b.?q=%10#. \
Wahttp://link \
Nohttps:\//link \
@@ -23,20 +24,19 @@ Nohttp\://comment
---
// Styled with underline and color.
-#set link(fill: rgb("283663"))
+#show link: it => underline(text(fill: rgb("283663"), it))
You could also make the
#link("https://html5zombo.com/")[link look way more typical.]
---
// Transformed link.
#set page(height: 60pt)
-#set link(underline: false)
#let mylink = link("https://typst.org/")[LINK]
My cool #move(dx: 0.7cm, dy: 0.7cm, rotate(10deg, scale(200%, mylink)))
---
// Link containing a block.
-#link("https://example.com/", underline: false, block[
+#link("https://example.com/", block[
My cool rhino
#move(dx: 10pt, image("/res/rhino.png", width: 1cm))
])