From 94259759473e60e9fb3823864031e827f09cc607 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Sat, 28 May 2022 15:21:18 +0200 Subject: [PATCH] emoji: prevent image enlargement (outside of figure elements) Accidentally scaled to full width since commit v1.12-0-g70012d8c59 (2020-05-06) [dieren: image figures captioned by names] not accounting for these preexisting icons. --- base.css | 2 +- word/edit.plp | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/base.css b/base.css index cc3625f..f4a4943 100644 --- a/base.css +++ b/base.css @@ -677,7 +677,7 @@ figure { margin: 0; position: relative; } -img { +figure img { vertical-align: bottom; width: 100%; } diff --git a/word/edit.plp b/word/edit.plp index 4a6daaa..2968642 100644 --- a/word/edit.plp +++ b/word/edit.plp @@ -261,20 +261,20 @@ for my $col (@wordcols) { my ($attr, @span) = ref $info eq 'ARRAY' ? @{$info} : $info; next if delete $attr->{hidden} and not $row->{$col}; my $title = ref $attr ? delete $attr->{-label} : $attr; - printf '
  • ', $col, $title; + printf '

  • ', $col, $title; printf ''; print $row->input($col => $attr); if (my $imgsrc = $attr->{-src}) { my $hide = $col eq 'source'; - printf '', $col unless $hide; + printf '
    ', $col unless $hide; printf('%s', $_, $row->{form}, $hide && qq( id="${col}preview" hidden) ) for grep { -e } $imgsrc->($row); - printf '' unless $hide; + printf '
    ' unless $hide; } print $row->input($_ => delete $wordcol{$_}) for @span; print '
    '; - say '

  • '; + say ''; } if (not $row->{ref}) { -- 2.30.0