diff --git a/crates/typst/src/engine.rs b/crates/typst/src/engine.rs index 85fa4301f..7f094578b 100644 --- a/crates/typst/src/engine.rs +++ b/crates/typst/src/engine.rs @@ -73,10 +73,10 @@ impl Route<'_> { /// The maximum stack nesting depth. pub const MAX_SHOW_RULE_DEPTH: usize = 64; - /// The maxmium layout nesting depth. + /// The maximum layout nesting depth. pub const MAX_LAYOUT_DEPTH: usize = 72; - /// The maxmium function call nesting depth. + /// The maximum function call nesting depth. pub const MAX_CALL_DEPTH: usize = 80; } diff --git a/crates/typst/src/model/bibliography.rs b/crates/typst/src/model/bibliography.rs index 936c44fed..fa35936b3 100644 --- a/crates/typst/src/model/bibliography.rs +++ b/crates/typst/src/model/bibliography.rs @@ -836,13 +836,13 @@ impl<'a> Generator<'a> { ) -> Option, Content)>> { let rendered = rendered.bibliography.as_ref()?; - // Determine for each citation key where it first occured, so that we + // Determine for each citation key where it first occurred, so that we // can link there. - let mut first_occurances = HashMap::new(); + let mut first_occurrences = HashMap::new(); for info in &self.infos { for subinfo in &info.subinfos { let key = subinfo.key.as_str(); - first_occurances.entry(key).or_insert(info.location); + first_occurrences.entry(key).or_insert(info.location); } } @@ -866,7 +866,7 @@ impl<'a> Generator<'a> { // Render the first field. let mut prefix = item.first_field.as_ref().map(|elem| { let mut content = renderer.display_elem_child(elem, &mut None); - if let Some(location) = first_occurances.get(item.key.as_str()) { + if let Some(location) = first_occurrences.get(item.key.as_str()) { let dest = Destination::Location(*location); content = content.linked(dest); } diff --git a/tests/ref/compiler/shorthand.png b/tests/ref/compiler/shorthand.png index 719fa771a..4507177bc 100644 Binary files a/tests/ref/compiler/shorthand.png and b/tests/ref/compiler/shorthand.png differ diff --git a/tests/typ/compiler/shorthand.typ b/tests/typ/compiler/shorthand.typ index 2b7cb5141..54ae74738 100644 --- a/tests/typ/compiler/shorthand.typ +++ b/tests/typ/compiler/shorthand.typ @@ -1,7 +1,7 @@ // Test shorthands for unicode codepoints. --- -The non-breaking space~does work, soft-?hypen also does. +The non-breaking space~does work, soft-?hyphen also does. --- // Make sure non-breaking and normal space always diff --git a/tests/typ/visualize/gradient-math.typ b/tests/typ/visualize/gradient-math.typ index 03d7c477f..f16e5c58a 100644 --- a/tests/typ/visualize/gradient-math.typ +++ b/tests/typ/visualize/gradient-math.typ @@ -54,7 +54,7 @@ $ A = mat( $ x_"1,2" = frac(-b +- sqrt(b^2 - 4 a c), 2 a) $ --- -// Test miscelaneous +// Test miscellaneous #show math.equation: set text(fill: gradient.linear(..color.map.rainbow)) #show math.equation: box