summaryrefslogtreecommitdiff
path: root/tests/suite/layout
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2024-06-03 10:12:52 +0200
committerGitHub <noreply@github.com>2024-06-03 08:12:52 +0000
commit755dd4112d58d54d6bce7d9a44a6d183ddadc772 (patch)
treeceb4a8a7ac2d941ae5b6dc7ae56a05cd4afb7473 /tests/suite/layout
parent23746ee18901e08852306f35639298ad234d3481 (diff)
Show block-level elements as blocks (#4310)
Diffstat (limited to 'tests/suite/layout')
-rw-r--r--tests/suite/layout/container.typ12
-rw-r--r--tests/suite/layout/flow/invisibles.typ2
2 files changed, 13 insertions, 1 deletions
diff --git a/tests/suite/layout/container.typ b/tests/suite/layout/container.typ
index 2479a44c..b6d30f30 100644
--- a/tests/suite/layout/container.typ
+++ b/tests/suite/layout/container.typ
@@ -96,6 +96,18 @@ Paragraph
lorem(8) + colbreak(),
)
+--- block-consistent-width ---
+// Test that block enforces consistent width across regions. Also use some
+// introspection to check that measurement is working correctly.
+#block(stroke: 1pt, inset: 5pt)[
+ #align(right)[Hi]
+ #colbreak()
+ Hello @netwok
+]
+
+#show bibliography: none
+#bibliography("/assets/bib/works.bib")
+
--- box-clip-rect ---
// Test box clipping with a rectangle
Hello #box(width: 1em, height: 1em, clip: false)[#rect(width: 3em, height: 3em, fill: red)]
diff --git a/tests/suite/layout/flow/invisibles.typ b/tests/suite/layout/flow/invisibles.typ
index 7e460373..28118cb9 100644
--- a/tests/suite/layout/flow/invisibles.typ
+++ b/tests/suite/layout/flow/invisibles.typ
@@ -31,7 +31,7 @@ Placed item in the first region.
// In-flow item with size zero in the first region.
#set page(height: 5cm, margin: 1cm)
In-flow, zero-sized item.
-#block(breakable: true, stroke: 1pt, inset: 0.5cm)[
+#block(breakable: true, stroke: 1pt, inset: 0.4cm)[
#set block(spacing: 0pt)
#line(length: 0pt)
#rect(height: 2cm, fill: gray)