+
+
+
+
Dashboard
-
diff --git a/docker-compose/requirements/nginx/static/javascript/profilPage/main.js b/docker-compose/requirements/nginx/static/javascript/profilPage/main.js
index 447f453..7194b64 100644
--- a/docker-compose/requirements/nginx/static/javascript/profilPage/main.js
+++ b/docker-compose/requirements/nginx/static/javascript/profilPage/main.js
@@ -6,7 +6,7 @@
/* By: edbernar `;
+ const ctx = document.getElementById('stats').getContext('2d');
+ createGraph(ctx, {win: userInfo.nbWin, lose: userInfo.nbLoss});
+ }
+ else if (actualPage == 1)
+ {
+ contentStats.innerHTML = `
+
Winrate100%
+Opponent give up rate0%
+Average goal number3.5
+Number of parties (last 30 days)10
+ `; + } + } + + buttonLeft.addEventListener('click', () => { + actualPage = actualPage == 0 ? 1 : 0; + changeDashboard(); + }); + buttonRight.addEventListener('click', () => { + actualPage = actualPage == 0 ? 1 : 0; + changeDashboard(); + }); + + changeDashboard(); +} diff --git a/docker-compose/requirements/nginx/static/style/profilPage/profil.css b/docker-compose/requirements/nginx/static/style/profilPage/profil.css index f1e134b..a15cd20 100644 --- a/docker-compose/requirements/nginx/static/style/profilPage/profil.css +++ b/docker-compose/requirements/nginx/static/style/profilPage/profil.css @@ -103,6 +103,7 @@ display: flex; justify-content: space-between; margin-top: 100px; + position: relative; } #profil .dashboard { @@ -111,6 +112,7 @@ height: 42vh; padding: 20px; text-align: center; + position: relative; } #profil .history #scroll-match { @@ -261,6 +263,36 @@ cursor: pointer; } +#profil .dashboard h3 { + margin-top: 10px; +} + +#profil .dashboard .button-dashboard { + background-color: #aeaeae; + color: white; + border: none; + padding: 10px 20px; + border-radius: 10px; + font-size: 1rem; + cursor: pointer; +} + +#profil .dashboard .button-dashboard:focus { + outline: none; +} + +#profil .contentStats .dashboard-line { + width: 100%; + text-align: left; + margin-bottom: 20px; + position: relative; +} + +#profil .contentStats .dashboard-line span { + font-weight: bold; + position: absolute; + right: 0; +} @media (max-width: 700px){ #profil .container {