Skip to content

Commit

Permalink
New Update :p
Browse files Browse the repository at this point in the history
This update, includes new menu, new main screen, reloading visuals and interacting with our API 🐌 enjoy :P
  • Loading branch information
snaildos committed Mar 11, 2021
1 parent dd425ca commit 567bb5f
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 3 deletions.
32 changes: 29 additions & 3 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
<script>
window.jQuery = window.$ = require('jquery');
const loudness = require('loudness')
const axios = require('axios')
</script>
<script>
// Needs window render
Expand Down Expand Up @@ -33,6 +34,7 @@
<script src="./YoutubeJS/video.js"></script>
<link href="./YoutubeJS/video-js.css" rel="stylesheet">
<script src="./YoutubeJS/Youtube.js"></script>
<link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css">
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js"></script>
<title>SnailFM</title>
Expand Down Expand Up @@ -99,10 +101,14 @@
display: none;
}

.hiddentext {
.video-stream html5-main-video {
display: none;
}

.hiddentext {
text-indent: -9999px;
}

.settings {
position: absolute;
top: 30px;
Expand Down Expand Up @@ -160,6 +166,10 @@
.sidenav a {font-size: 18px;}
}

.nowplay {
font-size: 25px;
}

#cookie{
display: none; /* Hidden by default */
position: fixed; /* Stay in place */
Expand Down Expand Up @@ -259,11 +269,13 @@ <h3>Powered by <b>SnailDOS</b></h3>
ipcRenderer.send('restart_app');
}
</script>

<p>
<h1 class="hiddentext">h</h1>
</p>
<video
id="vid1"
class="video-js vjs-default-skin center"
width="700" height="300"
width="0" height="0"
controls
poster="play.png"
data-setup='{ "techOrder": ["youtube"], "sources": [{ "type": "video/youtube", "src": "https://www.youtube.com/watch?v=KRr1ZPF-mp4"}] }'
Expand All @@ -277,6 +289,20 @@ <h3>Powered by <b>SnailDOS</b></h3>
});
</script>

<body>
<p id='nowPlaying' class="nowplay">Nothing</p>
<script>
setInterval(()=>{
axios.get('http://api.snaildos.tk/now/playing').then((value) => {
document.getElementById('nowPlaying').innerText = value.data.playing || 'Nothing'
})
},1000);
</script>
<p>
<h2 class="hiddentext">h</h2>
</p>
<button onclick="window.location.reload();" class="w3-btn w3-black">Reload</button>

<div id="mySidenav" class="sidenav">
<a href="javascript:void(0)" class="closebtn" onclick="closeNav()">&times;</a>
<a href="myaccount.html">My Account</a>
Expand Down
13 changes: 13 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
"dependencies": {
"discord-rpc": "^3.1.4",
"isdev": "^1.0.1",
"axios": "^0.21.1",
"jquery": "^3.6.0",
"electron-updater": "^4.0.6",
"loudness": "^0.4.0"
Expand Down

0 comments on commit 567bb5f

Please sign in to comment.