diff options
author | Arjun Satarkar <me@arjunsatarkar.net> | 2024-07-26 14:20:14 +0000 |
---|---|---|
committer | Arjun Satarkar <me@arjunsatarkar.net> | 2024-07-26 14:23:53 +0000 |
commit | cd794243a5bba358d995e26ba024268e7d5d3f85 (patch) | |
tree | 2df6974cc40f736441f7b985ca95a7f897f4510e /priv/room.html.eex | |
parent | 37ab5213a368926506206cb21a438cb7fea3d530 (diff) | |
download | mediasync-cd794243a5bba358d995e26ba024268e7d5d3f85.tar mediasync-cd794243a5bba358d995e26ba024268e7d5d3f85.tar.gz mediasync-cd794243a5bba358d995e26ba024268e7d5d3f85.zip |
Add Discord Activity functionality (mostly) + general improvements
Diffstat (limited to 'priv/room.html.eex')
-rw-r--r-- | priv/room.html.eex | 43 |
1 files changed, 40 insertions, 3 deletions
diff --git a/priv/room.html.eex b/priv/room.html.eex index fd86768..9f2ed0f 100644 --- a/priv/room.html.eex +++ b/priv/room.html.eex @@ -4,6 +4,7 @@ <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> + <meta name="robots" content="noindex, nofollow"> <title>room | mediasync</title> <link rel="stylesheet" href="/static/main.css"> <link rel="stylesheet" href="/static/video.js/video-js.min.css"> @@ -11,17 +12,53 @@ body { margin: 0; } + + @font-face { + font-family: "FontAwesomeSolid"; + src: url("/static/fontawesome-free-6.6.0-web/webfonts/fa-solid-900.woff2") format("woff2"); + } + + .icon-home, .icon-users { + font-family: "FontAwesomeSolid"; + } + + .icon-home::before { + content: "\f015"; + } + + .icon-users::before { + content: "\f0c0" + } + + #state-button-active::after { + content: attr(data-text); + white-space: pre-wrap; + font-family: monospace; + text-align: left; + text-shadow: black 1px 1px; + position: fixed; + left: 0; + top: 0; + } </style> </head> <body> <div id="playerContainer"> <video-js id="player"> - <source src="<%= Plug.HTML.html_escape(video_url) %>"> + <source src="<%= Plug.HTML.html_escape(video_info.url) %>" + type="<%= Plug.HTML.html_escape(video_info.content_type) %>"> </video-js> </div> <script src="/static/video.js/video.min.js"></script> - <script src="/static/room.js"></script> + <script> + const WEBSOCKET_URL = location.origin.replace(/^http/, "ws") + "<%= websocket_path %>"; + const HOME_URL = <%= if home_url, do: ~s("#{home_url}"), else: "null" %>; + const STATE_ELEMENT_INITIAL_TEXT = "loading..."; + const STATE_URL = "<%= state_url %>"; + </script> + <script src="/static/room/main.js"></script> + <script src="/static/room/displayState.js"></script> </body> -</html>
\ No newline at end of file +</html> |