Skip to content

Commit

Permalink
fix for nested figures
Browse files Browse the repository at this point in the history
Signed-off-by: Peter Stadler <stadlerpeter@yahoo.fr>
  • Loading branch information
peterstadler committed Aug 14, 2023
1 parent 3102f56 commit 4b70bc8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions modules/img.xqm
Original file line number Diff line number Diff line change
Expand Up @@ -205,8 +205,8 @@ declare %private function img:wikipedia-images($model as map(*), $lang as xs:str
let $caption :=
if($img/ancestor::xhtml:td[@class='infobox-image']) then
$img/ancestor::xhtml:td[@class='infobox-image']//xhtml:div[@class='infobox-caption']
else if($img/ancestor::xhtml:figure//xhtml:figcaption) then
$img/ancestor::xhtml:figure//xhtml:figcaption
else if($img/ancestor::xhtml:figure[1]/xhtml:figcaption) then
$img/ancestor::xhtml:figure[1]/xhtml:figcaption
else ()
return
if($thumbURI castable as xs:anyURI) then
Expand Down

0 comments on commit 4b70bc8

Please sign in to comment.