{if $media->caption}
<span class="mediaBBCodeCaption">
- {if $media->captionEnableHtml}
- {@$media->caption}
- {else}
- {$media->caption}
- {/if}
+ <span class="mediaBBCodeCaptionAlignment">
+ {if $media->captionEnableHtml}
+ {@$media->caption}
+ {else}
+ {$media->caption}
+ {/if}
+ </span>
</span>
{/if}
</span>
{if $media->caption}
<span class="mediaBBCodeCaption">
- {if $media->captionEnableHtml}
- {@$media->caption}
- {else}
- {$media->caption}
- {/if}
+ <span class="mediaBBCodeCaptionAlignment">
+ {if $media->captionEnableHtml}
+ {@$media->caption}
+ {else}
+ {$media->caption}
+ {/if}
+ </span>
</span>
{/if}
</span>
.mediaBBCode {
- display: inline-block;
+ display: table;
max-width: 100%;
.mediaBBCodeCaption {
color: $wcfContentDimmedText;
- display: block;
+ // https://stackoverflow.com/a/11652170/782822
+ display: table-caption;
+ caption-side: bottom;
margin-top: 5px;
text-align: center;
@include wcfFontSmall;
+
+ .mediaBBCodeCaptionAlignment {
+ // https://stackoverflow.com/a/43627669/782822
+ display: inline-block;
+ text-align: justify;
+ }
}
video {