[SHOPTIME-2458] Player / Chat / QR Code 공백으로 표시됨
[수정파일] src/views/PlayerPanel/PlayerOverlay/PlayerOverlayChat.jsx src/views/PlayerPanel/PlayerPanel.jsx [원인] QRCodeImage가 없으면 아무런 QRCode가 뜨지 않음 [대책] QRCodeImage가 없다면 chatUrl로 TQRCode로 QRCode 생성
This commit is contained in:
@@ -16,6 +16,7 @@ export default function PlayerOverlayChat({
|
||||
currentTime,
|
||||
videoVerticalVisible,
|
||||
imageQRCodeUrl,
|
||||
QRCodeUrl,
|
||||
}) {
|
||||
const dispatch = useDispatch();
|
||||
const chatData = useSelector((state) => state.play.chatData);
|
||||
@@ -83,7 +84,7 @@ export default function PlayerOverlayChat({
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
{!videoVerticalVisible && imageQRCodeUrl && (
|
||||
{(imageQRCodeUrl || QRCodeUrl) && !videoVerticalVisible && (
|
||||
<TButton
|
||||
className={css.messageBtn}
|
||||
onClick={handleQRCodeClick}
|
||||
@@ -108,7 +109,11 @@ export default function PlayerOverlayChat({
|
||||
|
||||
<div className={css.qrcodeContainer}>
|
||||
<div className={css.qrcode} aria-label="QR image">
|
||||
<CustomImage src={imageQRCodeUrl} />
|
||||
{imageQRCodeUrl ? (
|
||||
<CustomImage src={imageQRCodeUrl} />
|
||||
) : (
|
||||
<TQRCode text={QRCodeUrl} width="360" height="360" />
|
||||
)}
|
||||
</div>
|
||||
<h3 aria-label="To send a message, please scan the QR code.">
|
||||
{$L("To send a message, please scan the QR code.")}
|
||||
|
||||
@@ -1977,6 +1977,7 @@ const PlayerPanel = ({
|
||||
currentTime={currentTime}
|
||||
videoVerticalVisible={videoVerticalVisible}
|
||||
imageQRCodeUrl={playListInfo[selectedIndex]?.chatQrImgUrl}
|
||||
QRCodeUrl={playListInfo[selectedIndex]?.chatUrl}
|
||||
/>
|
||||
)}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user