Skip to content

Commit

Permalink
Merge pull request #40 from os2ulf/feature/OS2UOL-113
Browse files Browse the repository at this point in the history
OS2UOL-113: Adjusted VideoComponent to ouse BaseImage component for v…
  • Loading branch information
SorenBonde authored Jun 10, 2024
2 parents 8b54d92 + 44d9833 commit fbe3df3
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions components/view-components/VideoPlayer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,21 +23,20 @@ const handleVideo = (videoItem: any) => {
class="video__wrapper"
@click="handleVideo(videoItem)"
>
<!-- TODO: use Base Image comp. once images transformed to proper structure -->
<img
:src="videoItem?.field_video_thumbnail?.src"
:alt="videoItem?.field_video_thumbnail?.alt"
<BaseImage
v-if="videoItem?.field_video_thumbnail"
:image="videoItem?.field_video_thumbnail"
class="video__thumbnail"
/>
<NuxtIcon class="video__play-icon" name="play" />
</div>

<!-- Here its an object -->
<div v-else @click="handleVideo(props.videoArr)">
<img
<BaseImage
v-if="videoItem?.field_video_thumbnail"
:image="videoItem?.field_video_thumbnail"
class="video__thumbnail"
:src="videoArr?.field_video_thumbnail?.src"
:alt="videoArr?.field_video_thumbnail?.alt"
/>
<NuxtIcon class="video__play-icon" name="play" />
</div>
Expand Down

0 comments on commit fbe3df3

Please sign in to comment.