From 33a85ae945e55280cd821a82748b5332fefae7b2 Mon Sep 17 00:00:00 2001 From: Mikael Nordfeldth Date: Mon, 4 Aug 2014 18:33:57 +0200 Subject: [PATCH] Inline attachment layout improvement --- lib/inlineattachmentlist.php | 14 +------------- theme/base/css/display.css | 9 +++++++++ 2 files changed, 10 insertions(+), 13 deletions(-) diff --git a/lib/inlineattachmentlist.php b/lib/inlineattachmentlist.php index 04fddf3b30..b68701fb31 100644 --- a/lib/inlineattachmentlist.php +++ b/lib/inlineattachmentlist.php @@ -59,20 +59,8 @@ class InlineAttachmentList extends AttachmentList class InlineAttachmentListItem extends AttachmentListItem { function showLink() { - $this->out->elementStart('a', $this->linkAttr()); + $this->out->element('a', $this->linkAttr(), $this->title()); $this->showRepresentation(); - $this->out->elementEnd('a'); - } - - /** - * Build HTML attributes for the link - * @return array - */ - function linkAttr() - { - $attr = parent::linkAttr(); - $attr['class'] = 'attachment-thumbnail'; - return $attr; } /** diff --git a/theme/base/css/display.css b/theme/base/css/display.css index 792501e289..00bf5e5e3d 100644 --- a/theme/base/css/display.css +++ b/theme/base/css/display.css @@ -812,6 +812,15 @@ position:static; top: 1em; } +.notice.h-entry .attachments .inline-attachment * { + max-width: 100%; +} +.notice.h-entry .attachments .inline-attachment > a { + font-size: 0.88em; + line-height: 16px; + height: 16px; +} + #attachments { clear:both; float:left;