summaryrefslogtreecommitdiff
path: root/docs/src/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'docs/src/lib.rs')
-rw-r--r--docs/src/lib.rs8
1 files changed, 5 insertions, 3 deletions
diff --git a/docs/src/lib.rs b/docs/src/lib.rs
index 7ddc1c70..563d565c 100644
--- a/docs/src/lib.rs
+++ b/docs/src/lib.rs
@@ -39,10 +39,12 @@ static FONTS: Lazy<(Prehashed<FontBook>, Vec<Font>)> = Lazy::new(|| {
static LIBRARY: Lazy<Prehashed<Library>> = Lazy::new(|| {
let mut lib = typst_library::build();
- lib.styles.set(PageNode::WIDTH, Smart::Custom(Abs::pt(240.0).into()));
- lib.styles.set(PageNode::HEIGHT, Smart::Auto);
lib.styles
- .set(PageNode::MARGIN, Sides::splat(Some(Smart::Custom(Abs::pt(15.0).into()))));
+ .set(PageNode::set_width(Smart::Custom(Abs::pt(240.0).into())));
+ lib.styles.set(PageNode::set_height(Smart::Auto));
+ lib.styles.set(PageNode::set_margin(Sides::splat(Some(Smart::Custom(
+ Abs::pt(15.0).into(),
+ )))));
typst::eval::set_lang_items(lib.items.clone());
Prehashed::new(lib)
});