Add new HTML Window to close Nav
All checks were successful
Subsonics - Pipeline/pipeline/head This commit looks good

This commit is contained in:
CICD - Pipeline 2023-05-04 18:26:23 +02:00
parent 14d57184bf
commit cadfe8e572
12 changed files with 361 additions and 20 deletions

4
package-lock.json generated
View File

@ -1,12 +1,12 @@
{ {
"name": "subsonics-discord", "name": "subsonics-discord",
"version": "5.5", "version": "7.5",
"lockfileVersion": 2, "lockfileVersion": 2,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "subsonics-discord", "name": "subsonics-discord",
"version": "5.5", "version": "7.5",
"dependencies": { "dependencies": {
"cookie-parser": "^1.4.6", "cookie-parser": "^1.4.6",
"discord.js": "^14.9.0", "discord.js": "^14.9.0",

View File

@ -1,7 +1,7 @@
{ {
"name": "subsonics-discord", "name": "subsonics-discord",
"author": "Raphix", "author": "Raphix",
"version": "7.0", "version": "7.5",
"nodemonConfig": { "nodemonConfig": {
"ext": "js, html", "ext": "js, html",
"ignore": [ "ignore": [

View File

@ -1,12 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Submanager - </title>
</head>
<body>
</body>
</html>

155
src/close/close.css Normal file
View File

@ -0,0 +1,155 @@
@import url('https://fonts.googleapis.com/css2?family=Open+Sans&display=swap');
body {
background-color: #171717 !important;
font-family: 'Open Sans', sans-serif !important;
padding: 3%;
}
.top-title {
display: flex;
width: 100%;
flex-direction: row;
justify-content: center;
align-items: center;
color: white;
}
.top-logo {
width: 5vw;
border-radius: 10%;
}
.buttonClose {
background-color: transparent;
border: none;
border-radius: 15px;
cursor: pointer;
transition: all 0.3s ease 0s;
font-family: 'noto Sans', sans-serif;
font-weight: 500;
font-size: 15px;
color: white;
text-decoration: none;
-webkit-app-region: no-drag;
margin: 5px;
outline: none;
}
.text {
text-align: center;
font-size: 2vw;
color: white;
}
.boxtext {
margin-top: 5%;
border-radius: 15px;
background-color: #3d3d3d;
width: 50%;
padding: 3%;
margin-right: auto;
margin-left: auto;
}
.buttonClose:hover {
color: red;
}
.buttonClose:active {
color: rgb(255, 255, 255);
}
.buttonReduce {
background-color: transparent;
border: none;
border-radius: 15px;
cursor: pointer;
transition: all 0.3s ease 0s;
font-family: 'noto Sans', sans-serif;
font-weight: 500;
font-size: 13px;
color: white;
text-decoration: none;
-webkit-app-region: no-drag;
margin: 5px;
outline: none;
}
.buttonReduce:hover {
color: rgb(46, 196, 255);
}
.buttonReduce:active {
color: rgb(255, 255, 255);
}
header {
display: flex;
}
.content {
padding: 5%;
padding-top: 0;
}
.buttonFav {
background-color: transparent;
border: none;
border-radius: 15px;
cursor: pointer;
transition: all 0.3s ease 0s;
font-family: 'noto Sans', sans-serif;
font-weight: 500;
font-size: 13px;
color: white;
text-decoration: none;
-webkit-app-region: no-drag;
margin: 0;
outline: none;
}
.buttonFav:hover {
color: rgb(242, 255, 53);
}
.buttonFav:active {
color: rgb(255, 255, 255);
}
.title-t {
width: +30%;
margin-left: 1%;
margin-top: 1%;
}

21
src/close/close.html Normal file
View File

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="close.css">
<title>Subsonics - Submanager</title>
</head>
<body>
<div class="top-title">
<img class="top-logo" src="logo.png" alt="Logo">
<img class="title-t" src="title.png" alt="Logo">
</div>
<div class="boxtext">
<p class="text">Vous pouvez fermer cette fenêtre !</p>
<p class="text">En cas de problème, prévenez Raphix#8434 !</p>
</div>
</body>
</html>

BIN
src/close/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.0 KiB

BIN
src/close/title.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

155
src/error/error.css Normal file
View File

@ -0,0 +1,155 @@
@import url('https://fonts.googleapis.com/css2?family=Open+Sans&display=swap');
body {
background-color: #171717 !important;
font-family: 'Open Sans', sans-serif !important;
padding: 3%;
}
.top-title {
display: flex;
width: 100%;
flex-direction: row;
justify-content: center;
align-items: center;
color: white;
}
.top-logo {
width: 5vw;
border-radius: 10%;
}
.buttonClose {
background-color: transparent;
border: none;
border-radius: 15px;
cursor: pointer;
transition: all 0.3s ease 0s;
font-family: 'noto Sans', sans-serif;
font-weight: 500;
font-size: 15px;
color: white;
text-decoration: none;
-webkit-app-region: no-drag;
margin: 5px;
outline: none;
}
.text {
text-align: center;
font-size: 2vw;
color: rgb(255, 2, 2);
}
.boxtext {
margin-top: 5%;
border-radius: 15px;
background-color: #3d3d3d;
width: 50%;
padding: 3%;
margin-right: auto;
margin-left: auto;
}
.buttonClose:hover {
color: red;
}
.buttonClose:active {
color: rgb(255, 255, 255);
}
.buttonReduce {
background-color: transparent;
border: none;
border-radius: 15px;
cursor: pointer;
transition: all 0.3s ease 0s;
font-family: 'noto Sans', sans-serif;
font-weight: 500;
font-size: 13px;
color: white;
text-decoration: none;
-webkit-app-region: no-drag;
margin: 5px;
outline: none;
}
.buttonReduce:hover {
color: rgb(46, 196, 255);
}
.buttonReduce:active {
color: rgb(255, 255, 255);
}
header {
display: flex;
}
.content {
padding: 5%;
padding-top: 0;
}
.buttonFav {
background-color: transparent;
border: none;
border-radius: 15px;
cursor: pointer;
transition: all 0.3s ease 0s;
font-family: 'noto Sans', sans-serif;
font-weight: 500;
font-size: 13px;
color: white;
text-decoration: none;
-webkit-app-region: no-drag;
margin: 0;
outline: none;
}
.buttonFav:hover {
color: rgb(242, 255, 53);
}
.buttonFav:active {
color: rgb(255, 255, 255);
}
.title-t {
width: +30%;
margin-left: 1%;
margin-top: 1%;
}

21
src/error/error.html Normal file
View File

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="error.css">
<title>Subsonics - Submanager</title>
</head>
<body>
<div class="top-title">
<img class="top-logo" src="logo.png" alt="Logo">
<img class="title-t" src="title.png" alt="Logo">
</div>
<div class="boxtext">
<p class="text">Echec de connexion par Discord !</p>
<p class="text">Vous pouvez fermer cette fenêtre et réessayer !</p>
</div>
</body>
</html>

BIN
src/error/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.0 KiB

BIN
src/error/title.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

View File

@ -817,7 +817,7 @@ function startServer(client) {
if(req.query.error) { if(req.query.error) {
socket.emit("authFailed") socket.emit("authFailed")
res.send("SubSonics Manager : ERREUR : DISCORD AUTH FAILED !") res.sendFile(__dirname + path.sep + "error" + path.sep + "error.html")
log.server("Discord Auth : Erreur - Refus de connexion chez le service Discord : Token de Connexion : " + token + " associé à Client ID : " + socket.id) log.server("Discord Auth : Erreur - Refus de connexion chez le service Discord : Token de Connexion : " + token + " associé à Client ID : " + socket.id)
} else { } else {
@ -851,7 +851,7 @@ function startServer(client) {
res.clearCookie("authLoginFollow") res.clearCookie("authLoginFollow")
res.send("SubSonics Manager : Vous pouvez fermer cette fenêtre ! Si rien ne ce passe sur l'application, prévenez Raphix !") res.sendFile(__dirname + path.sep + "close" + path.sep + "close.html")
} catch(error) { } catch(error) {
@ -860,7 +860,7 @@ function startServer(client) {
} }
} else { } else {
res.send("SubSonics Manager : ERREUR : DISCORD AUTH FAILED !") res.sendFile(__dirname + path.sep + "error" + path.sep + "error.html")
} }
@ -868,12 +868,13 @@ function startServer(client) {
} }
} else { } else {
res.send("SubSonics Manager : ERREUR : AUCUN TOKEN ENREGISTRÉ !") res.sendFile(__dirname + path.sep + "error" + path.sep + "error.html")
} }
} else { } else {
res.send("SubSonics Manager : ERREUR : AUCUN TOKEN ENREGISTRÉ !") res.sendFile(__dirname + path.sep + "error" + path.sep + "error.html")
} }