diff --git a/src/components/VideoPlayer.vue b/src/components/VideoPlayer.vue index 3251c43..9903cfb 100644 --- a/src/components/VideoPlayer.vue +++ b/src/components/VideoPlayer.vue @@ -35,11 +35,12 @@ export default { }, computed: { styleObject() { - if (!this.objectFit) { + if (!this.objectFit && !this.objectPosition) { return {}; } return { objectFit: this.objectFit, + objectPosition: this.objectPosition, }; }, }, diff --git a/src/core/playerProps.js b/src/core/playerProps.js index 57f5e43..973f99a 100644 --- a/src/core/playerProps.js +++ b/src/core/playerProps.js @@ -19,6 +19,10 @@ export default { type: String, default: 'cover', }, + objectPosition: { + type: String, + default: 'center', + }, playsWhen: { type: String, default: 'canplay',