Show event onlineAddress

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel 2019-10-14 14:38:21 +02:00
parent cad508a9bb
commit e0826b4e87
No known key found for this signature in database
GPG key ID: A061B9DDE0CA0773

View file

@ -118,6 +118,10 @@ import {ParticipantRole} from "@/types/event.model";
</div>
</b-modal>
</div>
<span class="online-address" v-if="event.onlineAddress">
<b-icon icon="link"></b-icon>
<a :href="event.onlineAddress">{{ urlToHostname(event.onlineAddress) }}</a>
</span>
<div class="organizer">
<span>
<span v-if="event.organizerActor">
@ -544,6 +548,9 @@ export default class Event extends EventMixin {
return this.event.options.maximumAttendeeCapacity - this.event.participantStats.participants;
}
urlToHostname(url: string): string {
return (new URL(url)).hostname;
}
}
</script>
<style lang="scss" scoped>
@ -627,6 +634,10 @@ export default class Event extends EventMixin {
}
}
span.online-address {
display: flex;
}
div.organizer {
display: inline-flex;
padding-top: 10px;