fix(frontend): チャットに動画ファイルを送付すると、動画の表示が崩れてしまい視聴出来ない問題を修正

Fix #15854
This commit is contained in:
syuilo 2025-05-29 17:44:30 +09:00
parent 0f6b28f970
commit 85d339ee91
3 changed files with 20 additions and 3 deletions

View File

@ -52,6 +52,7 @@
- Enhance: シンタックスハイライトのエンジンをJavaScriptベースのものに変更
- フロントエンドの読み込みサイズを軽量化しました
- ほとんどの言語のハイライトは問題なく行えますが、互換性の問題により一部の言語が正常にハイライトできなくなる可能性があります。詳しくは https://shiki.style/references/engine-js-compat をご覧ください。
- Fix: チャットに動画ファイルを送付すると、動画の表示が崩れてしまい視聴出来ない問題を修正
- Fix: "時計"ウィジェット(Clock)において、Transparent設定が有効でも、その背景が透過されない問題を修正
- Fix: 一定時間操作がなかったら動画プレイヤーのコントロールを隠すように
- Fix: Twitchのクリップがプレイヤーで再生できない問題を修正

View File

@ -10,7 +10,8 @@ SPDX-License-Identifier: AGPL-3.0-only
tail === 'left' ? $style.left : $style.right,
negativeMargin === true && $style.negativeMargin,
shadow === true && $style.shadow,
accented === true && $style.accented
accented === true && $style.accented,
fullWidth === true && $style.fullWidth,
]"
>
<div :class="$style.bg">
@ -32,11 +33,13 @@ withDefaults(defineProps<{
negativeMargin?: boolean;
shadow?: boolean;
accented?: boolean;
fullWidth?: boolean;
}>(), {
tail: 'right',
negativeMargin: false,
shadow: false,
accented: false,
fullWidth: false,
});
</script>
@ -73,6 +76,14 @@ withDefaults(defineProps<{
margin-right: calc(calc(var(--fukidashi-radius) * .13) * -1);
}
}
&.fullWidth {
width: 100%;
&.content {
width: 100%;
}
}
}
.bg {
@ -85,6 +96,7 @@ withDefaults(defineProps<{
.content {
position: relative;
padding: 10px 14px;
box-sizing: border-box;
}
@container (max-width: 450px) {

View File

@ -6,9 +6,9 @@ SPDX-License-Identifier: AGPL-3.0-only
<template>
<div :class="[$style.root, { [$style.isMe]: isMe }]">
<MkAvatar :class="$style.avatar" :user="message.fromUser!" :link="!isMe" :preview="false"/>
<div :class="$style.body" @contextmenu.stop="onContextmenu">
<div :class="[$style.body, message.file != null ? $style.fullWidth : null]" @contextmenu.stop="onContextmenu">
<div :class="$style.header"><MkUserName v-if="!isMe && prefer.s['chat.showSenderName'] && message.fromUser != null" :user="message.fromUser"/></div>
<MkFukidashi :class="$style.fukidashi" :tail="isMe ? 'right' : 'left'" :accented="isMe">
<MkFukidashi :class="$style.fukidashi" :tail="isMe ? 'right' : 'left'" :fullWidth="message.file != null" :accented="isMe">
<Mfm
v-if="message.text"
ref="text"
@ -259,6 +259,10 @@ function showMenu(ev: MouseEvent, contextmenu = false) {
.body {
margin: 0 12px;
&.fullWidth {
width: 100%;
}
}
.header {