From c64a8726728c908e7000d75170f40f9b93e86208 Mon Sep 17 00:00:00 2001 From: Cyperghost Date: Thu, 11 Apr 2024 11:42:16 +0200 Subject: [PATCH] Use alignment in video and audio --- .../lib/system/bbcode/WoltLabSuiteMediaBBCode.class.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/wcfsetup/install/files/lib/system/bbcode/WoltLabSuiteMediaBBCode.class.php b/wcfsetup/install/files/lib/system/bbcode/WoltLabSuiteMediaBBCode.class.php index 71e381dcf0..90d9a6984d 100644 --- a/wcfsetup/install/files/lib/system/bbcode/WoltLabSuiteMediaBBCode.class.php +++ b/wcfsetup/install/files/lib/system/bbcode/WoltLabSuiteMediaBBCode.class.php @@ -57,9 +57,10 @@ final class WoltLabSuiteMediaBBCode extends AbstractBBCode } if ($parser->getOutputType() == 'text/html') { + $float = (!empty($openingTag['attributes'][2])) ? $openingTag['attributes'][2] : 'none'; + if ($media->isImage) { $thumbnailSize = (!empty($openingTag['attributes'][1])) ? $openingTag['attributes'][1] : 'original'; - $float = (!empty($openingTag['attributes'][2])) ? $openingTag['attributes'][2] : 'none'; $width = (!empty($openingTag['attributes'][3])) ? $openingTag['attributes'][3] : 'auto'; return WCF::getTPL()->fetch('mediaBBCodeTag', 'wcf', [ @@ -78,7 +79,7 @@ final class WoltLabSuiteMediaBBCode extends AbstractBBCode return WCF::getTPL()->fetch('mediaBBCodeTag', 'wcf', [ 'mediaLink' => $this->getLink($media), 'removeLinks' => $removeLinks, - 'float' => 'none', + 'float' => $float, 'media' => $media->getLocalizedVersion(MessageEmbeddedObjectManager::getInstance()->getActiveMessageLanguageID()), 'width' => 'auto', ]); -- 2.20.1