cyp/app/index.html
2022-01-13 13:32:34 +08:00

193 lines
5.2 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!doctype html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width" />
<title>Control Your Player</title>
<link rel="stylesheet" href="cyp.css" />
<style>
/* Float cancel and delete buttons and add an equal width */
.popupbtn {
background-color: rgb(141, 0, 0);
color: rgb(255, 255, 255);
padding: 14px 20px;
margin: 8px 0;
border: none;
cursor: pointer;
width: 100%;
opacity: 0.9;
display: block !important;
box-sizing: border-box;
}
.popupbtn:hover {
opacity:1;
}
/* Add padding and center-align text to the container */
.popupcontainer {
padding: 16px;
text-align: center;
}
/* The Modal (background) */
.popupmodal {
display: none; /* Hidden by default */
position: fixed; /* Stay in place */
z-index: 2; /* Sit on top */
left: 0;
top: 0;
width: 100%; /* Full width */
height: 100%; /* Full height */
overflow: auto; /* Enable scroll if needed */
background-color: #474e5d;
padding-top: 50px;
}
/* Modal Content/Box */
.popupmodal-content {
background-color: #fefefe;
margin: 5% auto 15% auto; /* 5% from the top, 15% from the bottom and centered */
border: 1px solid #888;
width: 80%; /* Could be more or less, depending on screen size */
}
/* Style the horizontal ruler */
.popup-hr {
border: 1px solid #f1f1f1;
margin-bottom: 25px;
}
/* The Modal Close Button (x) */
.popup-close {
position: absolute;
right: 35px;
top: 15px;
font-size: 40px;
font-weight: bold;
color: #f1f1f1;
}
.popup-close:hover,
.popup-close:focus {
color: #f44336;
cursor: pointer;
}
/* Clear floats */
.popup-clearfix::after {
content: "";
clear: both;
display: table;
}
</style>
<link rel="icon" href="https://emojimage.toad.cz/🎵" />
<meta name="mobile-web-app-capable" content="yes" />
</head>
<body>
<div id="warningpopup" class="popupmodal">
<span onclick="document.getElementById('warningpopup').style.display='none'" class="popup-close" title="x">×</span>
<div class="popupmodal-content">
<div class="popupcontainer">
<h2>Warning</h2>
<p>Be aware there may be other users listening to the same stream.</p>
<p>Pausing or changing volume on the server will affect them as well.</p>
<p>Please avoid server-side pausing or volume change if possible.</p>
<p>You can find client-side volume and pause control in the Settings Panel.</p>
<div class="popup-clearfix">
<button type="button" onclick="document.getElementById('warningpopup').style.display='none'" class="popupbtn">OK</button>
</div>
</div>
</div>
</div>
<cyp-app theme="dark" color="dodgerblue">
<header>
<cyp-player>
<span class="art"></span>
<div class="info">
<span class="title"></span>
<span class="subtitle"></span>
<div class="timeline">
<span class="elapsed"></span>
<x-range step="0.1"></x-range>
<span class="duration"></span>
</div>
</div>
<div class="controls">
<div class="playback">
<button class="prev" data-icon="rewind"></button>
<button class="play" data-icon="play"></button>
<button class="pause" data-icon="pause"></button>
<button class="next" data-icon="fast-forward"></button>
</div>
<div class="volume">
<button class="mute" data-icon="volume-high volume-off"></button>
<x-range></x-range>
</div>
</div>
<div class="misc">
<button class="repeat" data-icon="repeat"></button>
<button class="random" data-icon="shuffle"></button>
</div>
</cyp-player>
</header>
<main>
<cyp-queue></cyp-queue>
<cyp-playlists></cyp-playlists>
<cyp-library></cyp-library>
<cyp-yt></cyp-yt>
<cyp-settings>
<dl>
<dt>Theme</dt>
<dd>
<select name="theme">
<option value="auto">Auto</option>
<option value="dark">Dark</option>
<option value="light">Light</option>
</select>
</dd>
<dt>Color</dt>
<dd>
<label>
<input type="radio" name="color" value="dodgerblue" />
Blue
</label>
<label>
<input type="radio" name="color" value="darkorange" />
Orange
</label>
<label>
<input type="radio" name="color" value="limegreen" />
Green
</label>
</dd>
<dt>YouTube results</dt>
<dd>
<select name="yt-limit">
<option value="1">1</option>
<option value="3">3</option>
<option value="5">5</option>
<option value="10">10</option>
</select>
</dd>
</dl>
</cyp-settings>
</main>
<footer>
<cyp-menu>
<button data-for="queue" data-icon="music">
<div>
<span>Queue</span>
<span class="queue-length"></span>
</div>
</button>
<button data-for="playlists" data-icon="playlist-music"><span>Playlists</span></button>
<button data-for="library" data-icon="library-music"><span>Library</span></button>
<button data-for="yt" data-icon="download"><span>YouTube</span></button>
<button data-for="settings" data-icon="settings"><span>Settings</span></button>
</cyp-menu>
</footer>
</cyp-app>
<script type="module" src="cyp.js?2"></script>
</body>
</html>