Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add design for video meta data #73

Merged
merged 5 commits into from
Jul 27, 2020
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lecture2gether-vue/src/components/Player.vue
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ export default class L2gPlayer extends Vue {
// videojs options
muted: false,
language: 'en',
width: '750px',
fluid: true,
playbackRates: [0.75, 1.0, 1.25, 1.5, 1.75, 2.0],
sources,
techOrder: ['youtube', 'html5'],
Expand Down
2 changes: 1 addition & 1 deletion lecture2gether-vue/src/components/Toolbar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ export default class Toolbar extends Vue {
width: 100%;
max-width: 100%;
transition: all 0.8s ease;
margin-bottom: 128px;
margin-bottom: 32px;
}

.searchbar-cover-collapsed {
Expand Down
58 changes: 50 additions & 8 deletions lecture2gether-vue/src/components/VideoMetaData.vue
Original file line number Diff line number Diff line change
@@ -1,15 +1,35 @@
<template>
<div class="video-meta-data" style="visibility: hidden;">
<div class="title">
<div class="video-meta-data pa-6">
<div class="video-title display-1"
v-if="videoMetaData.title !== null"
>
lilioid marked this conversation as resolved.
Show resolved Hide resolved
{{ videoMetaData.title }}
<v-btn icon
:href="videoMetaData.url"
target="_blank"
v-if="videoMetaData.url !== null"
>
<v-icon>mdi-open-in-new</v-icon>
</v-btn>
</div>
<a class="creator" :href="videoMetaData.creatorLink">
{{ videoMetaData.creator }}
</a>
<div class="date">
{{ videoDate }}
<div>
<a class="creator body-1 meta-data-link"
:href="videoMetaData.creatorLink"
v-if="videoMetaData.creator !== null"
>
{{ videoMetaData.creator }}
</a>
<div class="date body-1"
v-if="videoMetaData.date !== null"
>
{{ videoDate }}
</div>
</div>
<a class="license" :href="videoMetaData.licenseLink">
<v-spacer></v-spacer>
<a class="license body-1 meta-data-link"
:href="videoMetaData.licenseLink"
v-if="videoMetaData.license !== null"
>
License: {{ videoMetaData.license }}
</a>
</div>
Expand All @@ -34,4 +54,26 @@ export default class VideoMetaData extends Vue {
</script>

<style scoped lang="scss">
.video-meta-data {
text-align: left;
display: grid;
grid-gap: 1em;
grid-template-columns: auto 1fr auto;
}

.video-title {
grid-column: span 3;
}

.meta-data-link {
color: #222222 !important;
}

.meta-data-link:link {
text-decoration: none;
}

.meta-data-link:hover {
text-decoration: underline;
}
</style>
17 changes: 7 additions & 10 deletions lecture2gether-vue/src/views/Room.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
<template>
<div>
<PasswordDialog v-if="this.$store.getters.authRequired" class="password-dialog"></PasswordDialog>
<l2g-player v-if="!this.$store.getters.authRequired && this.$store.state.player.videoUrl" class="l2g-player"></l2g-player>
<v-row>
<v-spacer></v-spacer>
<PasswordDialog v-if="this.$store.getters.authRequired" class="password-dialog"></PasswordDialog>
<l2g-player v-if="!this.$store.getters.authRequired && this.$store.state.player.videoUrl" class="l2g-player"></l2g-player>
<v-spacer></v-spacer>
</v-row>
<v-overlay :value="!roomExists" light>
<v-card class="room-card pa-12">
<h2 class="display-1 heading ">Room does not exist (anymore)!</h2>
Expand Down Expand Up @@ -69,14 +73,7 @@ export default class L2gPlayerView extends Vue {
width: 100%!important;
}
.l2g-player {
margin: auto;
//hacky way to force centered video.
//this size has to be the same as the video
//width in src/components/Player.vue
width: 100vw;
max-width: 750px;
lilioid marked this conversation as resolved.
Show resolved Hide resolved
}

.password-dialog {
margin: auto;
}
</style>