diff --git a/routes/_components/status/Media.html b/routes/_components/status/Media.html index e60e852..2828cf7 100644 --- a/routes/_components/status/Media.html +++ b/routes/_components/status/Media.html @@ -5,7 +5,7 @@ <button type="button" class="play-video-button" aria-label="Play video: {{media.description || ''}}" - on:click="onClickPlayVideoButton(media, getSmallWidth(media), getSmallHeight(media), media.description)"> + on:click="onClickPlayVideoButton(media, media.description)"> <div class="svg-wrapper"> <svg> <use xlink:href="#fa-play-circle" /> @@ -132,8 +132,8 @@ maxMediaWidth: (mediaAttachments) => Math.max.apply(Math, mediaAttachments.map(media => media.meta && media.meta.small && typeof media.meta.small.width === 'number' ? media.meta.small.width : DEFAULT_MEDIA_WIDTH)) }, methods: { - async onClickPlayVideoButton(media, width, height, description) { - showVideoDialog(media.preview_url, media.url, width, height, description) + async onClickPlayVideoButton(media, description) { + showVideoDialog(media.preview_url, media.url, description) } }, events: { diff --git a/routes/_components/status/VideoDialog.html b/routes/_components/status/VideoDialog.html index 246abfb..d6dee45 100644 --- a/routes/_components/status/VideoDialog.html +++ b/routes/_components/status/VideoDialog.html @@ -1,8 +1,6 @@ <ModalDialog :shown> <video poster="{{poster}}" src="{{src}}" - width="{{width}}" - height="{{height}}" aria-label="Video: {{description || ''}}" controls /> diff --git a/routes/_utils/showVideoDialog.js b/routes/_utils/showVideoDialog.js index 8e8a6ba..fc6b908 100644 --- a/routes/_utils/showVideoDialog.js +++ b/routes/_utils/showVideoDialog.js @@ -1,14 +1,12 @@ import VideoDialog from '../_components/status/VideoDialog.html' import { createDialogElement } from './dialogs' -export function showVideoDialog(poster, src, width, height, description) { +export function showVideoDialog(poster, src, description) { let videoDialog = new VideoDialog({ target: createDialogElement('Video dialog'), data: { poster: poster, src: src, - width: width, - height: height, description: description } })