2026-09-22 21:57:22 +02:00
|
|
|
import * as React from "../../react";
|
2026-04-14 13:15:38 +00:00
|
|
|
import CoreViewModel from "../../ViewModel/Global/coreViewModel";
|
2026-04-18 11:55:01 +00:00
|
|
|
import ChatMessageViewModel from "../../ViewModel/Chat/chatMessageViewModel";
|
2026-04-14 13:15:38 +00:00
|
|
|
|
|
|
|
|
export function ReplyPreview(
|
|
|
|
|
coreViewModel: CoreViewModel,
|
|
|
|
|
chatMessageViewModel: ChatMessageViewModel,
|
|
|
|
|
) {
|
|
|
|
|
return (
|
2026-04-14 19:29:49 +00:00
|
|
|
<div class="reply-preview">
|
2026-04-14 19:35:58 +00:00
|
|
|
<div class="surface blur">
|
2026-04-14 13:15:38 +00:00
|
|
|
<span class="secondary">{chatMessageViewModel.sender}</span>
|
2026-04-15 12:47:10 +00:00
|
|
|
<b
|
|
|
|
|
class="ellipsis"
|
|
|
|
|
subscribe:innerText={chatMessageViewModel.body}
|
|
|
|
|
></b>
|
2026-04-14 13:15:38 +00:00
|
|
|
</div>
|
|
|
|
|
<button
|
2026-04-14 19:35:58 +00:00
|
|
|
class="standard square blur"
|
2026-04-14 13:15:38 +00:00
|
|
|
on:click={chatMessageViewModel.cancelReply}
|
2026-04-15 12:47:10 +00:00
|
|
|
aria-label={
|
|
|
|
|
coreViewModel.translations.chatPage.message
|
|
|
|
|
.cancelReplyAudioLabel
|
|
|
|
|
}
|
2026-04-14 13:15:38 +00:00
|
|
|
>
|
|
|
|
|
<span class="icon">close</span>
|
|
|
|
|
</button>
|
|
|
|
|
</div>
|
|
|
|
|
);
|
|
|
|
|
}
|