diff --git a/dark/fonts/Poppins-Regular.ttf b/dark/fonts/Poppins-Regular.ttf
deleted file mode 100644
index be06e7f..0000000
Binary files a/dark/fonts/Poppins-Regular.ttf and /dev/null differ
diff --git a/dark/style.css b/dark/style.css
deleted file mode 100644
index ba549a5..0000000
--- a/dark/style.css
+++ /dev/null
@@ -1,166 +0,0 @@
-*{
- padding:0;
- margin:0;
- border-radius:5px;
- overflow:hidden;
-}
-@font-face{
- font-family: Poppins;
- src: url(fonts/Poppins-Regular.ttf);
-}
-h1,h2{
- padding:5px;
- font-family: Poppins;
- color:white;
-}
-html{
- width:100%;
- height:100%;
- text-align:center;
- margin:auto;
- align-items:center;
- align-content: center;
- justify-content: center;
- border-radius:5px;
- background:none;
-}
-
-body{
- box-sizing: border-box;
- width:100%;
- height:100%;
- display:flex;
- flex-direction:column-reverse;
- border-radius:10px;
- animation-duration:500ms;
- //background-color:rgba(0,0,0,.7);
- //background-image: linear-gradient(to bottom, rgba(255,0,0,0), rgba(42, 238, 245,1));
-}
-.section{
- cursor:pointer;
- display:flex;
- margin:auto;
- width:100%;
- height:100%;
- border-radius:30px;
- justify-content:center;
- align-items:center;
- word-wrap: normal;
- overflow:hidden;
- background-color:#36393F;
-}
-#textBox{
- margin-top:15px;
- height:25%;
- margin-bottom:20px;
- background-color:#36393F;
- --webkit-animation: BackgroundAnim 30s ease infinite;
- animation: BackgroundAnim 30s ease infinite;
- --moz-animation: BackgroundAnim 30s ease infinite;
- overflow: hidden;
- box-shadow: 0 15px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);
- color:white;
-}
-video{
- width:125%;
- height:125%;
- position:absolute;
- z-index:-1;
-}
-#mainWindow{
- margin-top:15px;
- height:75%;
- box-shadow: 0 15px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);
-}
-.albumBackground>h1{
- border-radius:0px;
- background-color: rgba(0,0,0,.5);
- padding:5px;
-}
-.colorBackground{
- --webkit-animation: MoveUpDown 6s infinite ease-in-out;
- animation: MoveUpDown 6s infinite ease-in-out;
- --moz-animation: MoveUpDown 6s infinite ease-in-out;
- background-color:
-}
-.notification{
- height:20%;
- margin-top:15%;
-}
-.showingLyrics{
- justify-content: flex-start;
- align-items: flex-start;
- overflow-y:scroll;
-}
-.albumBackground{
- font-size: 10px;
- background-size: 100vw auto;
- height:100%;
- background-position: center;
- animation:none;
- --webkit-animation: MoveUpDown 4s infinite ease-in-out;
- animation: MoveUpDown 4s infinite ease-in-out;
- --moz-animation: MoveUpDown 4s infinite ease-in-out;
-}
-#inputField{
- font-family: Poppins;
- width:97%;
- height:97%;
- margin:auto;
- flex-direction: column;
- margin-bottom:auto;
- color:white;
- //background:rgba(250,250,250,.4);
- background:none;
- border-radius:5px;
- font-size:30px;
- outline:none;
- border:none;
- text-align:center;
-}
-#inputField:focus{
- outline:none;
-}
-@-webkit-keyframes MoveUpDown {
- 0%, 100% {
- transform: translate(0,0);
-
- }
- 50% {
- transform: translate(0,-20px);
- }
-}
-@keyframes MoveUpDown {
- 0%, 100% {
- transform: translate(0,0);
-
- }
- 50% {
- transform: translate(0,-20px);
- }
-}
-@-moz-keyframes MoveUpDown {
- 0%, 100% {
- transform: translate(0,0);
-
- }
- 50% {
- transform: translate(0,-20px);
- }
-}
-
-@-webkit-keyframes BackgroundAnim {
- 0%{background-position:28% 0%}
- 50%{background-position:73% 100%}
- 100%{background-position:28% 0%}
-}
-@-moz-keyframes BackgroundAnim {
- 0%{background-position:28% 0%}
- 50%{background-position:73% 100%}
- 100%{background-position:28% 0%}
-}
-@keyframes BackgroundAnim {
- 0%{background-position:28% 0%}
- 50%{background-position:73% 100%}
- 100%{background-position:28% 0%}
-}
diff --git a/extraResources/ico.png b/extraResources/ico.png
deleted file mode 100644
index 1bd5fd1..0000000
Binary files a/extraResources/ico.png and /dev/null differ
diff --git a/extraResources/icon.ico b/extraResources/icon.ico
deleted file mode 100644
index aa1e80e..0000000
Binary files a/extraResources/icon.ico and /dev/null differ
diff --git a/extraResources/icon@1x.png b/extraResources/icon@1x.png
deleted file mode 100644
index aa278b9..0000000
Binary files a/extraResources/icon@1x.png and /dev/null differ
diff --git a/extraResources/icon@2x.png b/extraResources/icon@2x.png
deleted file mode 100644
index 30204c2..0000000
Binary files a/extraResources/icon@2x.png and /dev/null differ
diff --git a/extraResources/oldIcon.png b/extraResources/oldIcon.png
deleted file mode 100644
index 87bea28..0000000
Binary files a/extraResources/oldIcon.png and /dev/null differ
diff --git a/extraResources/style.css b/extraResources/style.css
deleted file mode 100644
index cd2cb3a..0000000
--- a/extraResources/style.css
+++ /dev/null
@@ -1,226 +0,0 @@
-*{
- padding:0;
- margin:0;
- border-radius:5px;
- overflow:hidden;
-}
-@font-face{
- font-family: Poppins;
- src: url(fonts/Poppins-Regular.ttf);
-}
-h1,h2{
- padding:5px;
- font-family: Poppins;
- color:white;
-}
-html{
- width:100%;
- height:100%;
- text-align:center;
- margin:auto;
- align-items:center;
- align-content: center;
- justify-content: center;
- border-radius:5px;
- background:none;
-}
-
-body{
- box-sizing: border-box;
- width:100%;
- height:100%;
- display:flex;
- flex-direction:column-reverse;
- border-radius:10px;
- animation-duration:500ms;
-}
-#mainWindow:hover > #output{
- opacity:0;
-}
-#mainWindow:hover > #miniPlayerControls{
- opacity:1;
- background-color:rgba(0,0,0,0.5)
-}
-#output{
- width:100%;
- transition-duration: 250ms;
- opacity: 1;
-}
-.section{
- //cursor:pointer;
- display:flex;
- margin:auto;
- width:90%;
- border-radius:30px;
- justify-content:center;
- align-items:center;
- word-wrap: normal;
- overflow:hidden;
-}
-#miniPlayerControls{
- display:flex;
- flex-direction: row;
- width:100%;
- height:100%;
- justify-content: center;
- align-items: center;
- color:white;
- position:absolute;
- z-index:0;
- opacity: 0;
- transition-duration: 250ms;
-}
-.svg-inline--fa{
- font-size:30px !important;
- position: relative;
- z-index: 1;
-}
-#textBox{
- background:rgba(0,0,0,.5);
- margin-top:15px;
- height:25%;
- margin-bottom:20px;
- --webkit-animation: BackgroundAnim 30s ease infinite;
- animation: BackgroundAnim 30s ease infinite;
- --moz-animation: BackgroundAnim 30s ease infinite;
- overflow: hidden;
- box-shadow: none !important;
- background-size: 800% 800%;
- box-shadow: 0 15px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);
- color:white;
-}
-video{
- width:125%;
- height:125%;
- position:absolute;
- z-index:-1;
-}
-#mainWindow{
- height:80%;
- margin-top:50px;
- box-shadow: 0 15px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);
-}
-svg{
- pointer-events: none;
-}
-.mediaButton{
- width:100%;
- height:100%;
- cursor:pointer;
- position: relative;
- z-index: 2;
- display:flex;
- justify-content: center;
- align-items: center;
-}
-.miniPlayerMode{
- margin-top:auto;
- margin-bottom:0;
-}
-.albumBackground>h1{
- border-radius:0px;
- background-color: rgba(0,0,0,.5);
- padding:5px;
-}
-.colorBackground{
- --webkit-animation: MoveUpDown 6s infinite ease-in-out;
- animation: MoveUpDown 6s infinite ease-in-out;
- --moz-animation: MoveUpDown 6s infinite ease-in-out;
- background-color:none;
-}
-.notification{
- height:20%;
- margin-top:15%;
-}
-.showingLyrics{
- justify-content: flex-start;
- align-items: flex-start;
- overflow-y:scroll;
-}
-.albumBackground{
- font-size: 10px;
- background-size: 100vw auto;
- height:100%;
- background-position: center;
- animation:none;
- --webkit-animation: MoveUpDown 6s infinite ease-in-out;
- animation: MoveUpDown 6s infinite ease-in-out;
- --moz-animation: MoveUpDown 6s infinite ease-in-out;
-}
-#inputField{
- font-family: Poppins;
- width:97%;
- height:97%;
- margin:auto;
- flex-direction: column;
- margin-bottom:auto;
- color:white;
- background:none;
- border-radius:5px;
- font-size:30px;
- outline:none;
- border:none;
- text-align:center;
-}
-#inputField:focus{
- outline:none;
- background:none;
-}
-#configMenu{
- width:100%;
- height:100%;
- display:none;
- justify-content: center;
- align-items: center;
-}
-.configItem{
- margin:auto;
- height:100%;
-}
-.configInput{
- outline:none;
-}
-
-@-webkit-keyframes MoveUpDown {
- 0%, 100% {
- transform: translate(0,0);
-
- }
- 50% {
- transform: translate(0,-20px);
- }
-}
-@keyframes MoveUpDown {
- 0%, 100% {
- transform: translate(0,0);
-
- }
- 50% {
- transform: translate(0,-20px);
- }
-}
-@-moz-keyframes MoveUpDown {
- 0%, 100% {
- transform: translate(0,0);
-
- }
- 50% {
- transform: translate(0,-20px);
- }
-}
-
-@-webkit-keyframes BackgroundAnim {
- 0%{background-position:28% 0%}
- 50%{background-position:73% 100%}
- 100%{background-position:28% 0%}
-}
-@-moz-keyframes BackgroundAnim {
- 0%{background-position:28% 0%}
- 50%{background-position:73% 100%}
- 100%{background-position:28% 0%}
-}
-@keyframes BackgroundAnim {
- 0%{background-position:28% 0%}
- 50%{background-position:73% 100%}
- 100%{background-position:28% 0%}
-}
diff --git a/extraResources/test.ico b/extraResources/test.ico
deleted file mode 100644
index c6de2f0..0000000
Binary files a/extraResources/test.ico and /dev/null differ
diff --git a/extraResources/test.png b/extraResources/test.png
deleted file mode 100644
index 51ebe1b..0000000
Binary files a/extraResources/test.png and /dev/null differ
diff --git a/extraResources/winIcon.ico b/extraResources/winIcon.ico
deleted file mode 100644
index 347a986..0000000
Binary files a/extraResources/winIcon.ico and /dev/null differ
diff --git a/extraResources/winIconNew.ico b/extraResources/winIconNew.ico
deleted file mode 100644
index 3648bac..0000000
Binary files a/extraResources/winIconNew.ico and /dev/null differ
diff --git a/index.html b/index.html
index 240e40a..6ff2dfe 100644
--- a/index.html
+++ b/index.html
@@ -6,13 +6,14 @@
Howdy!
diff --git a/main.js b/main.js
index aa0508f..7d3e43d 100644
--- a/main.js
+++ b/main.js
@@ -6,7 +6,7 @@ var execa = require("execa");
var currentInput;
var win;
const unhandled = require('electron-unhandled');
-var dirPath = app.getAppPath();
+var dirPath = __dirname;
unhandled();
// Enable live reload for Electron too
@@ -110,6 +110,7 @@ function createWindow () {
win.hide();
});
win.on('blur', function(event){
+ console.log("blurring")
if(!spotifyMiniPlayer || !spotifyAuthSuccess || !isPlaying){
appShowing = false;
win.webContents.send('slideOut')
@@ -119,7 +120,6 @@ function createWindow () {
}else{
win.webContents.send('miniPlayer');
}
-
})
win.on('show', function(event){
if(spotifyAuthSuccess){
@@ -219,9 +219,8 @@ function spotifyAuth(){
}
})
//Open spotify auth link, get access code
- var url = "https://accounts.spotify.com/en/authorize?response_type=code&client_id=eb0929c190354d7ea0b7e8a065ad68ed&scope=user-modify-playback-state%20user-read-currently-playing%20user-read-playback-state%20user-top-read&redirect_uri=https%3A%2F%2Fgithub.com%2F";
+ var url = "https://accounts.spotify.com/en/authorize?response_type=code&client_id=eb0929c190354d7ea0b7e8a065ad68ed&scope=user-modify-playback-state%20user-read-currently-playing%20user-read-playback-state%20user-top-read&redirect_uri=https%3A%2F%2Fstrnadchristopher.github.io%2FarizonaPage%2F";
authWindow.loadURL(url)
- authWindow.hide();
var url = "";
authWindow.on('page-title-updated', function(event, title){
url = authWindow.webContents.getURL();
@@ -253,7 +252,7 @@ function getTokens(){
form: {
"grant_type": "authorization_code",
"code": accessCode,
- "redirect_uri": "https://github.com/"
+ "redirect_uri": "https://strnadchristopher.github.io/arizonaPage/"
},
headers: {'Authorization': "Basic ZWIwOTI5YzE5MDM1NGQ3ZWEwYjdlOGEwNjVhZDY4ZWQ6OWQ4NTRhMzY3OThhNGNlODljOTRiNmFlOWFlYjdmOTA="
},
@@ -271,6 +270,7 @@ function getTokens(){
spotifyAuthSuccess = true;
//win.webContents.send('statusUpdate', '')
console.log("Authorization successful");
+ win.webContents.send('statusUpdate', "Spotify Authorized");
var t=setInterval(checkSpotifyArt,15000);
checkSpotifyArt();
})
@@ -283,7 +283,7 @@ function refreshToken(){
form: {
"grant_type": "refresh_token",
"code": rToken,
- "redirect_uri": "https://github.com/"
+ "redirect_uri": "https://strnadchristopher.github.io/arizonaPage/"
},
headers: {'Authorization': "Basic ZWIwOTI5YzE5MDM1NGQ3ZWEwYjdlOGEwNjVhZDY4ZWQ6OWQ4NTRhMzY3OThhNGNlODljOTRiNmFlOWFlYjdmOTA="
},
@@ -432,7 +432,7 @@ async function getTrackInfo(){
var artworkURL;
var shouldUpdateTrack = true;
function checkSpotifyArt(){
- if(spotifyAuthSuccess && isPlaying && spotifyMiniPlayer){
+ if(spotifyAuthSuccess && spotifyMiniPlayer){
console.log("Checking for song change.");
getTrackInfo();
}else{
@@ -446,7 +446,11 @@ async function getLyrics(trackData){
if(ourSong.status.failed) return console.log('Bad Response');
//console.log(ourSong.content[0].lyrics);
//parentPort.postMessage("*" + ourSong.content[0].lyrics);
- win.webContents.send('lyrics',ourSong.content[0].lyrics)
+ if(ourSong.content[0].lyrics != ""){
+ win.webContents.send('lyrics',ourSong.content[0].lyrics)
+ }else{
+ win.webContents.send('statusUpdate',"Couldn't find lyrics.")
+ }
}
app.whenReady().then(function(){
diff --git a/renderer.js b/renderer.js
index 70f2b8d..943627d 100644
--- a/renderer.js
+++ b/renderer.js
@@ -158,15 +158,8 @@ function switchState(state){
var username, assistantName, assistantShortcut, theme, cusW, cusH, secondScreen, useSpotify, spotifyMiniPlayer, showTitleOnMiniPlayer;
//READ Config
var configLoad = require("./loadConfig.js");
-function loadConfig(){
- var initConfig = configLoad.config();
- try {
- if (fs.existsSync(__dirname + "/themes/" + parsedData["theme"] + "/bg.mp4")) {
- bgVid = true;
- }
- } catch(err) {
- console.error(err)
- }
+function getPath(){
+ return __dirname;
}
var config;
function populateConfigMenu(){
@@ -175,7 +168,7 @@ function populateConfigMenu(){
var configString = "";
var values = Object.values(config);
var keys = Object.keys(config);
- configString += "
"
+ configString += "
"
for(var i = 0; i < values.length; i++){
configString += "" + keys[i] + " :
";
}
@@ -200,8 +193,10 @@ function saveConfig(event){
ipcRenderer.send('console',jString)
switchState("default")
}
-function requestSpotifyAuth(){
+function requestSpotifyAuth(event){
+ event.preventDefault();
ipcRenderer.send('requestSpotifyAuth')
+ switchState("default");
}
function toggleMusic(){
ipcRenderer.send("toggleMusic");
diff --git a/themes/dark/fonts/Poppins-Regular.ttf b/themes/dark/fonts/Poppins-Regular.ttf
deleted file mode 100644
index be06e7f..0000000
Binary files a/themes/dark/fonts/Poppins-Regular.ttf and /dev/null differ
diff --git a/themes/dark/style.css b/themes/dark/style.css
deleted file mode 100644
index dc2496a..0000000
--- a/themes/dark/style.css
+++ /dev/null
@@ -1,219 +0,0 @@
-*{
- padding:0;
- margin:0;
- border-radius:5px;
- overflow:hidden;
-}
-@font-face{
- font-family: Poppins;
- src: url(fonts/Poppins-Regular.ttf);
-}
-h1,h2{
- padding:5px;
- font-family: Poppins;
- color:white;
-}
-html{
- width:100%;
- height:100%;
- text-align:center;
- margin:auto;
- align-items:center;
- align-content: center;
- justify-content: center;
- border-radius:5px;
- background:none;
-}
-
-body{
- box-sizing: border-box;
- width:100%;
- height:100%;
- display:flex;
- flex-direction:column-reverse;
- border-radius:10px;
- animation-duration:500ms;
-}
-#mainWindow:hover > #output{
- opacity:0;
-}
-#mainWindow:hover > #miniPlayerControls{
- opacity:1;
- background-color:rgba(0,0,0,0.5)
-}
-#output{
- width:100%;
- transition-duration: 250ms;
- opacity: 1;
-}
-.section{
- cursor:pointer;
- display:flex;
- margin:auto;
- width:90%;
- border-radius:30px;
- justify-content:center;
- align-items:center;
- word-wrap: normal;
- overflow:hidden;
-}
-#miniPlayerControls{
- display:flex;
- flex-direction: row;
- width:100%;
- height:100%;
- justify-content: center;
- align-items: center;
- color:white;
- position:absolute;
- z-index:0;
- opacity: 0;
- transition-duration: 250ms;
-}
-.svg-inline--fa{
- margin:auto;
- width:100%;
- height:100%;
- display:flex;
- justify-content: center;
- align-items: center;
- font-size:30px !important;
-}
-#textBox{
- background:rgba(0,0,0,.5);
- margin-top:15px;
- height:25%;
- margin-bottom:20px;
- --webkit-animation: BackgroundAnim 30s ease infinite;
- animation: BackgroundAnim 30s ease infinite;
- --moz-animation: BackgroundAnim 30s ease infinite;
- overflow: hidden;
- box-shadow: none !important;
- background-size: 800% 800%;
- box-shadow: 0 15px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);
- color:white;
-}
-video{
- width:125%;
- height:125%;
- width:auto;
- height:auto;
- position:absolute;
- z-index:-1;
-}
-#mainWindow{
- height:80%;
- margin-top:50px;
- box-shadow: 0 15px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23);
-}
-.miniPlayerMode{
- margin-top:auto;
- margin-bottom:0;
-}
-.albumBackground>h1{
- border-radius:0px;
- background-color: rgba(0,0,0,.5);
- padding:5px;
-}
-.colorBackground{
- --webkit-animation: MoveUpDown 6s infinite ease-in-out;
- animation: MoveUpDown 6s infinite ease-in-out;
- --moz-animation: MoveUpDown 6s infinite ease-in-out;
- background-color:none;
-}
-.notification{
- height:20%;
- margin-top:15%;
-}
-.showingLyrics{
- justify-content: flex-start;
- align-items: flex-start;
- overflow-y:scroll;
-}
-.albumBackground{
- font-size: 10px;
- background-size: 100vw auto;
- height:100%;
- background-position: center;
- animation:none;
- --webkit-animation: MoveUpDown 6s infinite ease-in-out;
- animation: MoveUpDown 6s infinite ease-in-out;
- --moz-animation: MoveUpDown 6s infinite ease-in-out;
-}
-#inputField{
- font-family: Poppins;
- width:97%;
- height:97%;
- margin:auto;
- flex-direction: column;
- margin-bottom:auto;
- color:white;
- background:none;
- border-radius:5px;
- font-size:30px;
- outline:none;
- border:none;
- text-align:center;
-}
-#inputField:focus{
- outline:none;
- background:none;
-}
-#configMenu{
- width:100%;
- height:100%;
- display:none;
- justify-content: center;
- align-items: center;
-}
-.configItem{
- margin:auto;
- height:100%;
-}
-.configInput{
- outline:none;
-}
-
-@-webkit-keyframes MoveUpDown {
- 0%, 100% {
- transform: translate(0,0);
-
- }
- 50% {
- transform: translate(0,-20px);
- }
-}
-@keyframes MoveUpDown {
- 0%, 100% {
- transform: translate(0,0);
-
- }
- 50% {
- transform: translate(0,-20px);
- }
-}
-@-moz-keyframes MoveUpDown {
- 0%, 100% {
- transform: translate(0,0);
-
- }
- 50% {
- transform: translate(0,-20px);
- }
-}
-
-@-webkit-keyframes BackgroundAnim {
- 0%{background-position:28% 0%}
- 50%{background-position:73% 100%}
- 100%{background-position:28% 0%}
-}
-@-moz-keyframes BackgroundAnim {
- 0%{background-position:28% 0%}
- 50%{background-position:73% 100%}
- 100%{background-position:28% 0%}
-}
-@keyframes BackgroundAnim {
- 0%{background-position:28% 0%}
- 50%{background-position:73% 100%}
- 100%{background-position:28% 0%}
-}
diff --git a/themes/lava/style.css b/themes/lava/style.css
index dc2496a..b5f394a 100644
--- a/themes/lava/style.css
+++ b/themes/lava/style.css
@@ -47,7 +47,6 @@ body{
opacity: 1;
}
.section{
- cursor:pointer;
display:flex;
margin:auto;
width:90%;
@@ -66,18 +65,32 @@ body{
align-items: center;
color:white;
position:absolute;
- z-index:0;
+ z-index:5;
opacity: 0;
transition-duration: 250ms;
}
-.svg-inline--fa{
+.mediaButton{
+ width:auto;
+ height:30px;
margin:auto;
- width:100%;
- height:100%;
+ cursor:pointer;
display:flex;
justify-content: center;
align-items: center;
- font-size:30px !important;
+ filter: brightness(0) invert(1);
+}
+#configButton{
+ width:30px;
+ height:30px;
+ position:absolute;
+ bottom:10px;
+ right:10px;
+ filter: brightness(0) invert(1);
+ cursor:pointer;
+}
+#backButton{
+ -webkit-transform: scaleX(-1);
+ transform: scaleX(-1);
}
#textBox{
background:rgba(0,0,0,.5);
@@ -96,8 +109,6 @@ body{
video{
width:125%;
height:125%;
- width:auto;
- height:auto;
position:absolute;
z-index:-1;
}
@@ -165,10 +176,13 @@ video{
display:none;
justify-content: center;
align-items: center;
+ background-color:rgba(0, 0, 0, 0.5);
}
.configItem{
- margin:auto;
+ font-family: Poppins;
+ width:100%;
height:100%;
+ color:white;
}
.configInput{
outline:none;
@@ -177,7 +191,6 @@ video{
@-webkit-keyframes MoveUpDown {
0%, 100% {
transform: translate(0,0);
-
}
50% {
transform: translate(0,-20px);