2020-06-02 08:50:32 +02:00
|
|
|
<head>
|
|
|
|
<meta charset="UTF-8" />
|
2020-06-14 10:10:26 +02:00
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
|
|
|
2020-06-02 08:50:32 +02:00
|
|
|
<title>Live stream test</title>
|
|
|
|
|
2020-06-14 08:38:09 +02:00
|
|
|
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
|
2020-06-02 09:27:54 +02:00
|
|
|
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
|
2020-06-14 07:36:12 +02:00
|
|
|
|
|
|
|
<!-- unpkg : use the latest version of Video.js -->
|
2020-06-14 08:38:09 +02:00
|
|
|
<link href="//unpkg.com/video.js/dist/video-js.min.css" rel="stylesheet">
|
|
|
|
<link href="https://unpkg.com/@videojs/themes@1/dist/fantasy/index.css" rel="stylesheet" />
|
|
|
|
<script src="//unpkg.com/video.js/dist/video.min.js"></script>
|
2020-06-02 08:50:32 +02:00
|
|
|
|
2020-06-03 00:37:36 +02:00
|
|
|
<script src="vendor/autolink.js"></script>
|
2020-06-14 08:38:09 +02:00
|
|
|
<link href="./styles/layout.css" rel="stylesheet" />
|
|
|
|
|
2020-06-02 08:50:32 +02:00
|
|
|
</head>
|
|
|
|
|
2020-06-04 10:31:47 +02:00
|
|
|
<body>
|
2020-06-14 05:15:31 +02:00
|
|
|
<div id="app-container" class="flex no-chat">
|
2020-06-04 10:31:47 +02:00
|
|
|
<header class="flex">
|
|
|
|
<h1>
|
2020-06-14 05:15:31 +02:00
|
|
|
😈 Owncast
|
2020-06-04 10:31:47 +02:00
|
|
|
</h1>
|
2020-06-14 05:15:31 +02:00
|
|
|
|
|
|
|
<div id="user-options-container" class="flex">
|
|
|
|
<div id="user-info">
|
|
|
|
<div id="user-info-display" title="Click to update user name" class="flex">
|
|
|
|
<img src="https://robohash.org/username123" id="username-avatar" class="rounded-full" />
|
2020-06-14 08:38:09 +02:00
|
|
|
<span id="username-display"></span>
|
2020-06-14 05:15:31 +02:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div id="user-info-change">
|
|
|
|
<input type="text"
|
|
|
|
id="username-change-input"
|
|
|
|
class="appearance-none block w-full bg-gray-200 text-gray-700 border border-black-500 rounded py-1 px-1 leading-tight focus:bg-white"
|
|
|
|
value="Random Username 123"
|
|
|
|
maxlength="100"
|
|
|
|
placeholder="Update username"
|
|
|
|
>
|
|
|
|
<button id="button-update-username" class="bg-blue-500 hover:bg-blue-700 text-white py-1 px-1 rounded user-btn">Update</button>
|
|
|
|
<button id="button-cancel-change" class="bg-gray-900 hover:bg-gray-800 py-1 px-2 rounded user-btn" title="cancel">X</button>
|
|
|
|
</div>
|
|
|
|
</div>
|
2020-06-14 07:15:58 +02:00
|
|
|
<div id="chat-toggle" class="flex">💬</div>
|
2020-06-14 05:15:31 +02:00
|
|
|
</div>
|
2020-06-04 12:15:27 +02:00
|
|
|
|
2020-06-04 10:31:47 +02:00
|
|
|
</header>
|
2020-06-14 05:15:31 +02:00
|
|
|
<div id="main-content-container" class="flex">
|
2020-06-04 10:31:47 +02:00
|
|
|
<!-- LEFT CONTAINER SIDE-->
|
|
|
|
<div class="flex main-cols left-col">
|
2020-06-02 08:50:32 +02:00
|
|
|
|
2020-06-04 12:15:27 +02:00
|
|
|
<div id="video-container" class="flex shadow-md">
|
2020-06-04 10:31:47 +02:00
|
|
|
<video
|
2020-06-14 22:04:04 +02:00
|
|
|
class="video-js"
|
2020-06-04 10:31:47 +02:00
|
|
|
id="video"
|
|
|
|
preload="auto"
|
|
|
|
controls
|
2020-06-14 07:15:58 +02:00
|
|
|
autoplay
|
|
|
|
muted
|
2020-06-14 07:36:12 +02:00
|
|
|
poster="https://goth.land/thumbnail.png"
|
|
|
|
data-setup='{}'
|
|
|
|
>
|
|
|
|
<source src="https://goth.land/hls/stream.m3u8" type="application/x-mpegURL"/>
|
|
|
|
</video>
|
2020-06-02 08:50:32 +02:00
|
|
|
</div>
|
2020-06-02 22:56:59 +02:00
|
|
|
|
2020-06-14 05:15:31 +02:00
|
|
|
<div id="stream-info">
|
2020-06-04 10:31:47 +02:00
|
|
|
{{ streamStatus }} {{ viewerCount }} {{ 'viewer' | plural(viewerCount) }}.
|
2020-06-14 07:45:22 +02:00
|
|
|
Max {{ sessionMaxViewerCount }} {{ 'viewer' | plural(sessionMaxViewerCount) }},
|
|
|
|
{{ overallMaxViewerCount }} overall.
|
2020-06-02 08:50:32 +02:00
|
|
|
</div>
|
2020-06-04 10:31:47 +02:00
|
|
|
</div>
|
2020-06-02 08:50:32 +02:00
|
|
|
|
2020-06-04 10:31:47 +02:00
|
|
|
<!-- RIGHT CONTAINER SIDE-->
|
|
|
|
<div class="flex main-cols right-col">
|
2020-06-04 12:15:27 +02:00
|
|
|
|
2020-06-04 10:31:47 +02:00
|
|
|
<div id="chat-container">
|
|
|
|
<div id="messages-container">
|
|
|
|
<div v-for="(message, index) in messages">
|
2020-06-09 23:12:50 +02:00
|
|
|
<div class="message flex">
|
2020-06-04 10:31:47 +02:00
|
|
|
<img
|
|
|
|
v-bind:src="message.image"
|
2020-06-09 23:12:50 +02:00
|
|
|
class="message-avatar rounded-full"
|
2020-06-04 10:31:47 +02:00
|
|
|
/>
|
2020-06-09 23:12:50 +02:00
|
|
|
<div class="message-content">
|
|
|
|
<p class="message-author">{{ message.author }}</p>
|
2020-06-14 09:24:26 +02:00
|
|
|
<p class="message-text" v-html="message.formatText()"></p>
|
2020-06-04 10:31:47 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2020-06-02 09:27:54 +02:00
|
|
|
</div>
|
2020-06-04 10:31:47 +02:00
|
|
|
|
2020-06-14 05:15:31 +02:00
|
|
|
<div id="message-input-container" class="shadow-md">
|
2020-06-14 09:24:26 +02:00
|
|
|
<form id="message-form" class="flex" /*@submit="submitChatForm"*/>
|
2020-06-14 05:15:31 +02:00
|
|
|
|
|
|
|
<input type="hidden" name="inputAuthor" id="self-message-author" v-model="message.author" />
|
2020-06-04 12:15:27 +02:00
|
|
|
|
|
|
|
<textarea
|
2020-06-14 09:24:26 +02:00
|
|
|
id="message-body-form"
|
2020-06-04 12:15:27 +02:00
|
|
|
placeholder="Message"
|
|
|
|
v-model="message.body"
|
2020-06-14 09:24:26 +02:00
|
|
|
class="appearance-none block w-full bg-gray-200 text-gray-700 border border-black-500 rounded py-2 px-2 my-2 focus:bg-white"
|
2020-06-14 05:15:31 +02:00
|
|
|
></textarea>
|
2020-06-04 12:15:27 +02:00
|
|
|
|
2020-06-14 05:15:31 +02:00
|
|
|
<div id="message-form-actions" class="flex">
|
2020-06-14 07:15:58 +02:00
|
|
|
<span id="message-form-warning"></span>
|
2020-06-14 05:15:31 +02:00
|
|
|
<button
|
2020-06-14 09:24:26 +02:00
|
|
|
id="button-submit-message"
|
2020-06-14 05:15:31 +02:00
|
|
|
class="bg-blue-500 hover:bg-blue-700 text-white font-bold py-1 px-2 rounded"
|
|
|
|
> Send
|
|
|
|
</button>
|
|
|
|
</div>
|
2020-06-04 12:15:27 +02:00
|
|
|
|
|
|
|
</form>
|
|
|
|
</div>
|
2020-06-02 08:50:32 +02:00
|
|
|
</div>
|
2020-06-04 10:31:47 +02:00
|
|
|
</div>
|
2020-06-02 09:27:54 +02:00
|
|
|
</div>
|
2020-06-02 08:50:32 +02:00
|
|
|
</div>
|
2020-05-24 02:57:49 +02:00
|
|
|
|
2020-06-15 00:18:43 +02:00
|
|
|
<script src="js/config.js"></script>
|
2020-06-14 08:38:09 +02:00
|
|
|
<script src="js/utils.js"></script>
|
2020-06-04 10:31:47 +02:00
|
|
|
<script src="js/message.js"></script>
|
|
|
|
<script src="js/app.js"></script>
|
|
|
|
</body>
|
|
|
|
</html>
|