improve rumble and twitch orgies

pull/195/head
Aevann 2023-08-24 04:08:54 +03:00
parent f8f6e5f37f
commit aaaa412710
2 changed files with 21 additions and 29 deletions

View File

@ -1,3 +1,7 @@
lite-youtube {
max-width: min(20vw,500px) !important;
}
.orgy-top-container {
display: flex;
justify-content: space-around;
@ -16,18 +20,12 @@
flex-grow: 2;
}
.rumble-player {
aspect-ratio: 16/9;
max-width: min(70vw,500px) !important;
width: 500px;
}
#orgy-file-container {
width: 70vw;
max-width: 100vw !important;
}
#orgy-file-container > video {
#orgy-file-container > * {
max-height: 100% !important;
margin: 0 !important;
height: 98% !important;
@ -44,7 +42,7 @@
#orgy-col {
padding: 0px;
}
#orgy-file-container > video {
#orgy-file-container > * {
height: 100% !important;
width: 100% !important;
}
@ -68,7 +66,7 @@ body > .container {
resize: none !important;
}
#orgy-file-container > lite-youtube {
#orgy-file-container > :not(video) {
height: 90% !important;
width: 95% !important;
max-width: 95% !important;
@ -76,13 +74,13 @@ body > .container {
}
@media (max-width: 900px) {
#orgy-file-container > lite-youtube {
#orgy-file-container > :not(video) {
height: 100% !important;
width: 100% !important;
max-width: 100% !important;
}
}
lite-youtube {
max-width: min(20vw,500px) !important;
#orgy-file-container > iframe {
aspect-ratio: 16/9;
}

View File

@ -12,27 +12,21 @@
<div id="orgy-col" class="col text-left pt-3">
<h2 id="orgy-title">{{orgy.title}}</h1>
<div>
{% if orgy.type == 'youtube' %}
<p id="orgy-file-container" class="resizable">
<p id="orgy-file-container" class="resizable">
{% if orgy.type == 'youtube' %}
<lite-youtube videoid="{{orgy.data}}" params="autoplay=1&modestbranding=1"/>
</p>
{% elif orgy.type == 'rumble' %}
<iframe class="rumble rumble-player" width="100%" src="{{orgy.data}}" frameborder="0" allowfullscreen></iframe>
{% elif orgy.type == 'twitch' %}
<iframe
src="https://player.twitch.tv/?channel={{orgy.data}}&parent={{site}}"
class="rumble-player"
allowfullscreen>
</iframe>
{% elif orgy.type == 'file' %}
<meta name="referrer" content="strict-origin-when-cross-origin">
<p id="orgy-file-container" class="resizable">
{% elif orgy.type == 'rumble' %}
<iframe src="{{orgy.data}}" frameborder="0" allowfullscreen></iframe>
{% elif orgy.type == 'twitch' %}
<iframe src="https://player.twitch.tv/?channel={{orgy.data}}&parent={{site}}" frameborder="0" allowfullscreen></iframe>
{% elif orgy.type == 'file' %}
<meta name="referrer" content="strict-origin-when-cross-origin">
<video id="orgy-file" data-created_utc="{{orgy.created_utc}}" controls preload="none" src="{{orgy.data}}">
<track label="English" kind="subtitles" srclang="en" src="/assets/subtitles/2.vtt" default>
</video>
</p>
<script defer src="{{'js/orgy_file.js' | asset}}"></script>
{% endif %}
<script defer src="{{'js/orgy_file.js' | asset}}"></script>
{% endif %}
</p>
{{macros.chat_users_list()}}
</div>
</div>