[IMP] mail: guard MediaPreviewComponent

Task-2797754

closes odoo/odoo#86827

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This commit is contained in:
Alexandre Kühn
2022-03-23 14:37:07 +01:00
parent 1a7840fc46
commit 16577265a8
@@ -2,8 +2,8 @@
<templates xml:space="preserve">
<t t-name="mail.MediaPreview" owl="1">
<div class="o_MediaPreview position-relative d-flex justify-content-center" t-attf-class="{{ className }}" t-ref="root">
<t t-if="mediaPreview">
<t t-if="mediaPreview">
<div class="o_MediaPreview position-relative d-flex justify-content-center" t-attf-class="{{ className }}" t-ref="root">
<video class="o_MediaPreview_videoDisplay shadow rounded bg-dark" height="480" width="640" autoplay="" t-ref="video"/>
<p t-if="mediaPreview.doesBrowserSupportMediaDevices and !mediaPreview.isVideoEnabled" class="o_MediaPreview_mediaDevicesStatus position-absolute text-light">
Camera is off
@@ -18,8 +18,8 @@
<button t-if="mediaPreview.isVideoEnabled" class="o_MediaPreview_disableVideoButton o_MediaPreview_button btn btn-dark btn-lg p-0 m-3 rounded-circle border-light fa fa-video-camera" t-on-click="mediaPreview.onClickDisableVideoButton"/>
</div>
<audio class="o_MediaPreview_audioPlayer" autoplay="" t-ref="audio"/>
</t>
</div>
</div>
</t>
</t>
</templates>