mirror of
https://github.com/typst/typst
synced 2025-07-27 14:27:56 +08:00
docs: fixup some comments
This commit is contained in:
parent
6717a18414
commit
09b2cd6de5
@ -192,10 +192,11 @@ pub enum TableHeaderScope {
|
||||
/// TODO: maybe generalize this and use it to mark html elements with `aria-hidden="true"`?
|
||||
#[elem(Locatable, Show)]
|
||||
pub struct ArtifactElem {
|
||||
/// The artifact kind.
|
||||
#[default(ArtifactKind::Other)]
|
||||
pub kind: ArtifactKind,
|
||||
|
||||
/// The content to underline.
|
||||
/// The content that is an artifact.
|
||||
#[required]
|
||||
pub body: Content,
|
||||
}
|
||||
|
@ -325,9 +325,8 @@ pub(crate) fn handle_start(gc: &mut GlobalContext, elem: &Content) {
|
||||
.and_then(StackEntryKind::as_standard_mut)
|
||||
.filter(|tag| tag.kind == TagKind::Figure);
|
||||
if let Some(figure_tag) = figure_tag {
|
||||
// Set alt text of outer figure tag, if not present.
|
||||
if figure_tag.alt_text.is_none() {
|
||||
// HACK: set alt text of outer figure tag, if the contained image
|
||||
// has alt text specified
|
||||
figure_tag.alt_text = alt;
|
||||
}
|
||||
return;
|
||||
|
Loading…
x
Reference in New Issue
Block a user