From ebd7b480c2a7bcf7d5bd2a184e93872074d5d51f Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Tue, 19 Mar 2019 22:43:06 +0100 Subject: [PATCH] Support for more content elements --- .../templates/articleListItems.tpl | 4 ++- .../install/files/style/ui/contentItem.scss | 26 ++++++++++++++++--- 2 files changed, 25 insertions(+), 5 deletions(-) diff --git a/com.woltlab.wcf/templates/articleListItems.tpl b/com.woltlab.wcf/templates/articleListItems.tpl index 695ca9630b..67fd5b2d55 100644 --- a/com.woltlab.wcf/templates/articleListItems.tpl +++ b/com.woltlab.wcf/templates/articleListItems.tpl @@ -8,6 +8,8 @@ {content} {if $article->isDeleted}{lang}wcf.message.status.deleted{/lang}{/if} {if ARTICLE_ENABLE_VISIT_TRACKING && $article->isNew()}{lang}wcf.message.new{/lang}{/if} + + {event name='contentItemBadges'} {/content} {/hascontent} @@ -38,7 +40,7 @@
{if $article->userID} - {$article->getUserProfile()->username} + {$article->getUserProfile()->username} {else} {$article->username} {/if} diff --git a/wcfsetup/install/files/style/ui/contentItem.scss b/wcfsetup/install/files/style/ui/contentItem.scss index e7c7f1b675..1a98b5e926 100644 --- a/wcfsetup/install/files/style/ui/contentItem.scss +++ b/wcfsetup/install/files/style/ui/contentItem.scss @@ -14,6 +14,7 @@ flex-direction: column; margin-bottom: 20px; max-width: calc(50% - 10px); /* IE 11 */ + position: relative; overflow: hidden; } @@ -50,17 +51,26 @@ position: relative; } -.contentItemBadges { +.contentItemBadges, +.contentItemOptions { align-items: flex-start; display: flex; flex-direction: column; - left: 10px; position: absolute; top: 10px; } -.contentItemBadge { - border: 1px solid currentColor; +.contentItemBadges { + left: 10px; +} + +.contentItemOptions { + right: 10px; + z-index: 1; +} + +.contentItemBadge, +.contentItemOption { flex: 0 auto; &:not(:first-child) { @@ -68,6 +78,10 @@ } } +.contentItemBadge { + border: 1px solid currentColor; +} + .contentItemLabels { margin-bottom: 5px; } @@ -88,6 +102,10 @@ margin-top: 10px; } +.contentItemContentLinks { + padding: 0 10px 10px 10px; +} + .contentItemMeta { align-items: center; border-top: 1px solid $wcfContentBorderInner; -- 2.20.1