diff --git a/crates/typst/src/foundations/content.rs b/crates/typst/src/foundations/content.rs index 16ab0c04f..8a7346350 100644 --- a/crates/typst/src/foundations/content.rs +++ b/crates/typst/src/foundations/content.rs @@ -22,7 +22,7 @@ use crate::layout::{AlignElem, Alignment, Axes, Length, MoveElem, PadElem, Rel, use crate::model::{Destination, EmphElem, StrongElem}; use crate::syntax::Span; use crate::text::UnderlineElem; -use crate::util::fat; +use crate::util::{fat, BitSet}; /// A piece of document content. /// @@ -71,17 +71,25 @@ use crate::util::fat; #[derive(Clone, Hash)] #[allow(clippy::derived_hash_with_manual_eq)] pub struct Content { + /// The partially element-dependant inner data. inner: Arc>, + /// The element's source code location. span: Span, } /// The inner representation behind the `Arc`. #[derive(Hash)] struct Inner { + /// An optional label attached to the element. label: Option