diff --git a/server/public/assets/css/style.css b/server/public/assets/css/style.css index b1d37cfb..2396cdf3 100755 --- a/server/public/assets/css/style.css +++ b/server/public/assets/css/style.css @@ -3352,6 +3352,10 @@ nav ul li:hover, nav ul li.active { margin-top: auto !important; } + #channel-share-modal { + width: 100%; + } + #autocomplete-input { width: 100%; border-bottom: 1px solid #9e9e9e !important; diff --git a/server/public/assets/js/channel.js b/server/public/assets/js/channel.js index 29aca00a..3a013525 100644 --- a/server/public/assets/js/channel.js +++ b/server/public/assets/js/channel.js @@ -207,9 +207,14 @@ var Channel = { if(!client) { - var shareCodeUrl = window.location.protocol + "//client."+window.location.hostname+"/r/"+btoa(encodeURIComponent(chan.toLowerCase())); - document.getElementById("share-join-qr").setAttribute("src", "https://chart.googleapis.com/chart?chs=221x221&cht=qr&choe=UTF-8&chld=L|1&chl="+shareCodeUrl); - Helper.setHtml("#channel-name-join", "client." + window.location.hostname + "/" + encodeURIComponent(chan.toLowerCase())); + if(!Helper.mobilecheck()) { + var shareCodeUrl = window.location.protocol + "//client."+window.location.hostname+"/r/"+btoa(encodeURIComponent(chan.toLowerCase())); + document.getElementById("share-join-qr").setAttribute("src", "https://chart.googleapis.com/chart?chs=221x221&cht=qr&choe=UTF-8&chld=L|1&chl="+shareCodeUrl); + Helper.setHtml("#channel-name-join", "client." + window.location.hostname + "/" + encodeURIComponent(chan.toLowerCase())); + } else if(small_player) { + document.querySelector("#channel-share-modal .modal-content").innerHTML = "

To listen to this channel, go to

https://zoff.me/" + encodeURIComponent(chan.toLowerCase()) + "

circle-logo-zoff"; + M.Modal.getInstance(document.getElementById("channel-share-modal")).open(); + } } else { Helper.removeElement(".video-container"); Helper.removeElement(".offline-panel"); diff --git a/server/public/assets/js/functions.js b/server/public/assets/js/functions.js index 2c242f4e..cdb5f503 100644 --- a/server/public/assets/js/functions.js +++ b/server/public/assets/js/functions.js @@ -1236,7 +1236,7 @@ function before_toast(){ } function addJoinBox() { - document.querySelector("#video-container").insertAdjacentHTML("beforeend", '
Listen directly on https://zoff.me
'); + document.querySelector("#video-container").insertAdjacentHTML("beforeend", '
Listen directly on https://zoff.me
© KasperRT & Nixo
'); } function scrollChat() {