summaryrefslogtreecommitdiff
path: root/crates/typst-library/src/layout/place.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/typst-library/src/layout/place.rs')
-rw-r--r--crates/typst-library/src/layout/place.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/crates/typst-library/src/layout/place.rs b/crates/typst-library/src/layout/place.rs
index 64cbd9a8..c8e83383 100644
--- a/crates/typst-library/src/layout/place.rs
+++ b/crates/typst-library/src/layout/place.rs
@@ -106,7 +106,10 @@ impl Layout for PlaceElem {
.at(self.span());
}
- let child = self.body().aligned(alignment.unwrap_or_else(|| Align::CENTER));
+ let child = self
+ .body()
+ .clone()
+ .aligned(alignment.unwrap_or_else(|| Align::CENTER));
let pod = Regions::one(base, Axes::splat(false));
let frame = child.layout(vt, styles, pod)?.into_frame();