fix: set is compiling flag (#1293) (#1328)

This commit is contained in:
Myriad-Dreamin 2025-02-20 00:35:59 +08:00 committed by GitHub
parent 63e368c2bb
commit 5b72f760bb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -217,7 +217,10 @@ impl<F: CompilerFeat> WorldComputable<F> for CompilationTask<TypstPagedDocument>
.enabled;
Ok(enabled.then(|| {
let compiled = typst::compile(&graph.snap.world);
let mut world = graph.snap.world.clone();
world.set_is_compiling(true);
let compiled = typst::compile(&world);
world.set_is_compiling(false);
Warned {
output: compiled.output.map(Arc::new),
warnings: compiled.warnings,