diff --git a/examples/main.css b/examples/main.css index 025eefd..04019f9 100644 --- a/examples/main.css +++ b/examples/main.css @@ -1523,10 +1523,6 @@ iframe { .popup .menu { margin: 2px; } -.my-float { - margin-top: 7px; - opacity: 0.9; -} .toggleSize { font-size: 32px; color: white; diff --git a/index.html b/index.html index a587364..2ce816c 100644 --- a/index.html +++ b/index.html @@ -137,85 +137,85 @@
- +
diff --git a/lib.js b/lib.js index 132b925..6c3e1d5 100644 --- a/lib.js +++ b/lib.js @@ -10305,7 +10305,7 @@ function toggleMute(apply = false, event=false) { // TODO: I need to have this b if (session.muted == false) { session.muted = true; - getById("mutetoggle").className = "las la-microphone-slash my-float toggleSize"; + getById("mutetoggle").className = "las la-microphone-slash toggleSize"; if (!(session.cleanOutput)){ getById("mutebutton").classList.remove("float"); getById("mutebutton").classList.add("float2"); @@ -10331,7 +10331,7 @@ function toggleMute(apply = false, event=false) { // TODO: I need to have this b } else { session.muted = false; - getById("mutetoggle").className = "las la-microphone my-float toggleSize"; + getById("mutetoggle").className = "las la-microphone toggleSize"; if (!(session.cleanOutput)){ getById("mutebutton").classList.add("float"); @@ -10396,7 +10396,7 @@ function toggleSpeakerMute(apply = false) { // TODO: I need to have this be MUTE } if (session.speakerMuted == false) { // mute output session.speakerMuted = true; - getById("mutespeakertoggle").className = "las la-volume-mute my-float toggleSize"; + getById("mutespeakertoggle").className = "las la-volume-mute toggleSize"; if (!(session.cleanOutput)){ getById("mutespeakerbutton").className = "float2 red"; } @@ -10416,7 +10416,7 @@ function toggleSpeakerMute(apply = false) { // TODO: I need to have this be MUTE } else { session.speakerMuted = false; // unmute output - getById("mutespeakertoggle").className = "las la-volume-up my-float toggleSize"; + getById("mutespeakertoggle").className = "las la-volume-up toggleSize"; if (!(session.cleanOutput)){ getById("mutespeakerbutton").className = "float"; } @@ -10512,13 +10512,13 @@ function toggleChat(event = null) { // TODO: I need to have this be MUTE, toggle return false; }); session.chat = true; - getById("chattoggle").className = "las la-comment-dots my-float toggleSize"; + getById("chattoggle").className = "las la-comment-dots toggleSize"; getById("chatbutton").className = "float2"; getById("chatModule").style.display = "block"; getById("chatInput").focus(); // give it keyboard focus } else { session.chat = false; - getById("chattoggle").className = "las la-comment-alt my-float toggleSize"; + getById("chattoggle").className = "las la-comment-alt toggleSize"; getById("chatbutton").className = "float"; getById("chatModule").style.display = "none"; @@ -10661,7 +10661,7 @@ function toggleVideoMute(apply = false) { // TODO: I need to have this be MUTE, if (session.videoMuted == false) { session.videoMuted = true; - getById("mutevideotoggle").className = "las la-video-slash my-float toggleSize"; + getById("mutevideotoggle").className = "las la-video-slash toggleSize"; if (!(session.cleanOutput)){ getById("mutevideobutton").className = "float2 red"; getById("header").classList.add("red2"); @@ -10676,7 +10676,7 @@ function toggleVideoMute(apply = false) { // TODO: I need to have this be MUTE, } } else if (session.remoteVideoMuted){ // the director has muted this guest's video feed session.videoMuted = false; // just setting it back to the pre-toggled state - getById("mutevideotoggle").className = "las la-video my-float toggleSize"; + getById("mutevideotoggle").className = "las la-video toggleSize"; if (!(session.cleanOutput)){ getById("head8").classList.remove("hidden"); getById("header").classList.add("red2"); @@ -10691,7 +10691,7 @@ function toggleVideoMute(apply = false) { // TODO: I need to have this be MUTE, } else { session.videoMuted = false; - getById("mutevideotoggle").className = "las la-video my-float toggleSize"; + getById("mutevideotoggle").className = "las la-video toggleSize"; if (!(session.cleanOutput)){ getById("mutevideobutton").className = "float"; getById("header").classList.remove("red2"); @@ -10866,10 +10866,10 @@ function hangup2() { getById("screensharebutton").classList.remove("float2"); if (session.showDirector == false) { - getById("miniPerformer").innerHTML = ''; + getById("miniPerformer").innerHTML = ''; miniTranslate(getById("miniPerformer")); } else { - getById("miniPerformer").innerHTML = ''; + getById("miniPerformer").innerHTML = ''; } getById("miniPerformer").className = ""; } @@ -12033,12 +12033,12 @@ function blindAllGuests(ele, event=false){ ele.value = 0; ele.classList.remove("pressed"); ele.classList.remove("red"); - ele.innerHTML = ''; + ele.innerHTML = ''; } else { ele.value = 1; ele.classList.add("pressed"); ele.classList.add("red"); - ele.innerHTML = ''; + ele.innerHTML = ''; } } @@ -15369,14 +15369,14 @@ async function createRoomCallback(passAdd, passAdd2) { } if (session.showDirector == false) { - getById("miniPerformer").innerHTML = ''; + getById("miniPerformer").innerHTML = ''; miniTranslate(getById("miniPerformer")); getById("grabDirectorSoloLink").dataset.raw = "https://" + location.host + location.pathname + "?solo&sd&r=" + session.roomid + "&v="+session.streamID + passAdd2 + wss + token; getById("grabDirectorSoloLink").href = "https://" + location.host + location.pathname + "?solo&sd&r=" + session.roomid + "&v="+session.streamID + passAdd2 + wss + token; getById("grabDirectorSoloLink").innerText = "https://" + location.host + location.pathname + "?solo&sd&r=" + session.roomid + "&v="+session.streamID + passAdd2 + wss + token; getById("grabDirectorSoloLinkParent").classList.remove("hidden"); } else { - getById("miniPerformer").innerHTML = ''; + getById("miniPerformer").innerHTML = ''; } getById("miniPerformer").className = ""; @@ -22732,7 +22732,7 @@ function addDownloadLink(fileList, UUID, pc){ } if (session.chat == false) { - getById("chattoggle").className = "las la-comments my-float toggleSize puslate"; + getById("chattoggle").className = "las la-comments toggleSize puslate"; getById("chatbutton").className = "float"; if (getById("chatNotification").value) { @@ -29433,7 +29433,7 @@ function getChatMessage(msg, label = false, director = false, overlay = false) { updateMessages(); if (session.chat == false) { - getById("chattoggle").className = "las la-comments my-float toggleSize puslate"; + getById("chattoggle").className = "las la-comments toggleSize puslate"; getById("chatbutton").className = "float"; if (getById("chatNotification").value) { @@ -30173,7 +30173,7 @@ function recordLocalVideoToggle() { if (ele.dataset.state == "0") { ele.dataset.state = "1"; ele.style.backgroundColor = "red"; - ele.innerHTML = ''; + ele.innerHTML = ''; if ("recording" in session.videoElement) { } else { @@ -30194,7 +30194,7 @@ function recordLocalVideoToggle() { } ele.dataset.state = "0"; ele.style.backgroundColor = ""; - ele.innerHTML = ''; + ele.innerHTML = ''; if (session.director){ var elements = document.querySelectorAll('[data-action-type="recorder-local"][data-sid="' + session.streamID + '"]'); @@ -30339,7 +30339,7 @@ function recordLocalVideo(action = null, videoKbps = 6000, remote=false) { // ev if (remote){ getById("recordLocalbutton").dataset.state = "1"; getById("recordLocalbutton").style.backgroundColor = "red"; - getById("recordLocalbutton").innerHTML = ''; + getById("recordLocalbutton").innerHTML = ''; } return; } else { @@ -30369,7 +30369,7 @@ function recordLocalVideo(action = null, videoKbps = 6000, remote=false) { // ev if (remote){ getById("recordLocalbutton").dataset.state = "1"; getById("recordLocalbutton").style.backgroundColor = "red"; - getById("recordLocalbutton").innerHTML = ''; + getById("recordLocalbutton").innerHTML = ''; } } else if (action == "stop") { return; @@ -30377,7 +30377,7 @@ function recordLocalVideo(action = null, videoKbps = 6000, remote=false) { // ev if (!remote){ getById("recordLocalbutton").dataset.state = "1"; getById("recordLocalbutton").style.backgroundColor = "red"; - getById("recordLocalbutton").innerHTML = ''; + getById("recordLocalbutton").innerHTML = ''; } video.recording = true; } @@ -30419,17 +30419,17 @@ function recordLocalVideo(action = null, videoKbps = 6000, remote=false) { // ev if (getById("recordLocalbutton").dataset.state == 2) { getById("recordLocalbutton").dataset.state = "0"; getById("recordLocalbutton").style.backgroundColor = ""; - getById("recordLocalbutton").innerHTML = ''; + getById("recordLocalbutton").innerHTML = ''; restart = false; warnUser("Media Recording Stopped due to an error."); } else { - getById("recordLocalbutton").innerHTML = ''; + getById("recordLocalbutton").innerHTML = ''; getById("recordLocalbutton").dataset.state = "2"; } } else { getById("recordLocalbutton").dataset.state = "0"; getById("recordLocalbutton").style.backgroundColor = ""; - getById("recordLocalbutton").innerHTML = ''; + getById("recordLocalbutton").innerHTML = ''; if (notify){ if (!session.cleanOutput){ warnUser("A recording has stopped unexpectedly."); @@ -30996,7 +30996,7 @@ function changeGroupDirectorAPI(group, state=null, update=true){ ele.classList.add('float'); ele.style.display = "inline-block"; ele.role = "button"; - ele.innerHTML = '
'+group; + ele.innerHTML = '
'+group; eleGroup.appendChild(ele); ele.onclick = function(){ changeGroupDirectorAPI(this.dataset.group); diff --git a/main.css b/main.css index 3c6304b..56833f3 100644 --- a/main.css +++ b/main.css @@ -1,5 +1,6 @@ :root { /* Discord Greys - Dark to Lighter */ + --discord-grey-0: #121212; --discord-grey-1: #1e1f22; --discord-grey-2: #232428; --discord-grey-3: #2b2d31; @@ -62,8 +63,12 @@ color: #FFF; } -button:hover,[role="button"]:not(.column):hover{ - filter: brightness(90%); +button:hover,[role="button"] +:not(.column) +:not(.controlsGrid) +:not(#controlButtons) +:hover{ + filter: brightness(120%); } table { @@ -246,6 +251,9 @@ button.hint { .red { background-color: #840000 !important; } +.red:hover { + background-color: #b30c0c !important; +} .red2 { background-color: #840000 !important; @@ -1154,33 +1162,54 @@ button.glyphicon-button.active.focus { } #controlButtons { - position: fixed; - z-index: 995; - bottom: 0px; - width: 100%; - justify-content: center; - align-items: center; - height: 60px; - border: 0; - pointer-events: none; - display: flex; + display: flex; + position: fixed; + z-index: 995; + bottom: 0px; + width: 100%; + justify-content: center; + align-items: center; + height: 60px; + border: 0; + pointer-events: none; } #controlButtons:empty { display: none; } #subControlButtons { - display: flex; - border-radius: 38px; - background-color: #030303dd; - padding: 5px 7px; - position: absolute; - pointer-events: auto; + display: flex; + border-radius: 38px; + background-color: var(--discord-grey-0); + box-shadow: 0px 0px 10px rgba(0,0,0,1); + top: -10px; + position: absolute; + pointer-events: auto; + border: #cccccc22 1px solid; + border-radius: 10px; } + #subControlButtons:empty{ display:none; } +#subControlButtons div { + display: flex; + align-items: center; + justify-content: center; + background-color: var(--discord-grey-1); + opacity: unset; + border-radius: 8px; + transition: border-radius 200ms ease-in-out; + box-shadow: 1px 1px 3px rgba(0,0,0,0.75); +} + +#subControlButtons div:hover { + background-color: var(--discord-grey-3); + border-radius: 4px; +} + + #container.vidcon { height:100%; } @@ -2289,9 +2318,10 @@ span[data-action-type="stats-graphs-details-container"]>span{ opacity: 0.8; min-width: 45px; height: 45px; - background-color: #6666; + background-color: #66b16a66; + box-shadow: 1px 1px 3px rgba(0,0,0,0.75); color: #FFF; - border-radius: 38px; + border-radius: 8px; text-align: center; margin: 5px; pointer-events: auto; @@ -2302,6 +2332,7 @@ span[data-action-type="stats-graphs-details-container"]>span{ min-width: 45px; height: 45px; background-color: #8888; + box-shadow: 1px 1px 3px rgba(0,0,0,0.75); color: #FFF; border-radius: 38px; text-align: center; @@ -2367,19 +2398,10 @@ iframe { .popup .menu { margin: 2px; } -.my-float { - margin-top: 7px; - opacity: 0.9; -} .toggleSize { font-size: 32px; color: white; } -.controlsGrid-1x1 { - margin-left: auto; - margin-right: 0; - text-align: right; -} img { max-width: 100%; @@ -3571,6 +3593,8 @@ div#roomnotes2 { gap: 2px; } +.controlsGrid + .controlsGrid button i { font-size: 15px; } @@ -3616,7 +3640,6 @@ div#roomnotes2 { max-width: 100%; } - .darktheme .controlsGrid .director-message-box textarea { background-color: var(--discord-grey-4); color: var(--discord-text); diff --git a/main.js b/main.js index f70ef30..31a2840 100644 --- a/main.js +++ b/main.js @@ -888,7 +888,7 @@ async function main(){ // main asyncronous thread; mostly initializes the user s session.speakerMuted_default = session.speakerMuted; if (session.speakerMuted){ - getById("mutespeakertoggle").className = "las la-volume-mute my-float toggleSize"; + getById("mutespeakertoggle").className = "las la-volume-mute toggleSize"; //getById("mutespeakerbutton").className="hidden float2 red"; getById("mutespeakerbutton").classList.add("red"); getById("mutespeakerbutton").classList.add("float2"); @@ -4557,7 +4557,7 @@ async function main(){ // main asyncronous thread; mostly initializes the user s ele.classList.add('float'); ele.style.display = "inline-block"; ele.role = "button"; - ele.innerHTML = '
'+group; + ele.innerHTML = '
'+group; eleGroup.appendChild(ele); ele.onclick = function(){ changeGroupDirectorAPI(this.dataset.group);