Skip to content

Commit b83e219

Browse files
authored
Merge pull request #184 from LeadOn/develop
5.2.3
2 parents 32e21c0 + 117ac51 commit b83e219

7 files changed

Lines changed: 271 additions & 258 deletions

File tree

package-lock.json

Lines changed: 202 additions & 202 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "gameon-front",
3-
"version": "5.2.2",
3+
"version": "5.2.3",
44
"scripts": {
55
"ng": "ng",
66
"start": "ng serve",
@@ -10,19 +10,19 @@
1010
},
1111
"private": true,
1212
"dependencies": {
13-
"@angular/animations": "^19.2.7",
14-
"@angular/cdk": "^19.2.10",
15-
"@angular/common": "^19.2.7",
16-
"@angular/compiler": "^19.2.7",
17-
"@angular/core": "^19.2.7",
18-
"@angular/forms": "^19.2.7",
19-
"@angular/platform-browser": "^19.2.7",
20-
"@angular/platform-browser-dynamic": "^19.2.7",
21-
"@angular/router": "^19.2.7",
13+
"@angular/animations": "^19.2.9",
14+
"@angular/cdk": "^19.2.14",
15+
"@angular/common": "^19.2.9",
16+
"@angular/compiler": "^19.2.9",
17+
"@angular/core": "^19.2.9",
18+
"@angular/forms": "^19.2.9",
19+
"@angular/platform-browser": "^19.2.9",
20+
"@angular/platform-browser-dynamic": "^19.2.9",
21+
"@angular/router": "^19.2.9",
2222
"@fortawesome/angular-fontawesome": "^1.0.0",
2323
"@fortawesome/free-solid-svg-icons": "^6.7.2",
2424
"@ngrx/store": "^19.1.0",
25-
"@tailwindcss/postcss": "^4.1.4",
25+
"@tailwindcss/postcss": "^4.1.5",
2626
"chart.js": "^4.4.9",
2727
"flowbite": "^3.1.2",
2828
"keycloak-angular": "^19.0.2",
@@ -34,9 +34,9 @@
3434
"zone.js": "~0.15.0"
3535
},
3636
"devDependencies": {
37-
"@angular-devkit/build-angular": "^19.2.8",
38-
"@angular/cli": "^19.2.8",
39-
"@angular/compiler-cli": "^19.2.7",
37+
"@angular-devkit/build-angular": "^19.2.10",
38+
"@angular/cli": "^19.2.10",
39+
"@angular/compiler-cli": "^19.2.9",
4040
"@types/jasmine": "~5.1.0",
4141
"autoprefixer": "^10.4.20",
4242
"jasmine-core": "~5.1.0",

src/app/routes/profile/profile.component.html

Lines changed: 34 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
/>
3636

3737
<span
38-
class="mt-2 text-xl font-semibold text-primary dark:text-primaryDark"
38+
class="text-primary dark:text-primaryDark mt-2 text-xl font-semibold"
3939
>{{ currentPlayer.nickname }}</span
4040
>
4141
<span class="text-gray-500 dark:text-gray-400">{{
@@ -46,28 +46,28 @@
4646

4747
<div class="mt-8">
4848
<div
49-
class="mt-4 flex animate-fade justify-between px-4"
49+
class="animate-fade mt-4 flex justify-between px-4"
5050
*ngIf="
5151
loading == false && isAdmin == true && (player$ | async) as currentPlayer
5252
"
5353
>
54-
<span class="text-lg font-semibold text-primary dark:text-primaryDark"
54+
<span class="text-primary dark:text-primaryDark text-lg font-semibold"
5555
>Administration</span
5656
>
5757
</div>
5858

5959
<section
6060
id="player-admin"
61-
class="mt-4 animate-fade px-4"
61+
class="animate-fade mt-4 px-4"
6262
*ngIf="
6363
loading == false && isAdmin == true && (player$ | async) as currentPlayer
6464
"
6565
>
6666
<div
67-
class="rounded-lg bg-bgLight p-4 text-sm drop-shadow-lg dark:bg-bgDark"
67+
class="bg-bgLight dark:bg-bgDark rounded-lg p-4 text-sm drop-shadow-lg"
6868
>
6969
<div
70-
class="flex cursor-pointer flex-row justify-between text-customRed"
70+
class="text-customRed flex cursor-pointer flex-row justify-between"
7171
[routerLink]="['/admin']"
7272
>
7373
<a
@@ -81,7 +81,7 @@
8181
<hr class="my-4" />
8282

8383
<div
84-
class="flex cursor-pointer flex-row justify-between text-customYellow"
84+
class="text-customYellow flex cursor-pointer flex-row justify-between"
8585
[cdkCopyToClipboard]="token"
8686
>
8787
<a
@@ -94,24 +94,24 @@
9494
</section>
9595

9696
<div
97-
class="mt-4 flex animate-fade justify-between px-4"
97+
class="animate-fade mt-4 flex justify-between px-4"
9898
*ngIf="loading == false && (player$ | async) as currentPlayer"
9999
>
100-
<span class="text-lg font-semibold text-primary dark:text-primaryDark"
100+
<span class="text-primary dark:text-primaryDark text-lg font-semibold"
101101
>FIFA</span
102102
>
103103
</div>
104104

105105
<section
106106
id="player-fifa"
107-
class="mt-4 animate-fade px-4"
107+
class="animate-fade mt-4 px-4"
108108
*ngIf="loading == false && (player$ | async) as currentPlayer"
109109
>
110110
<div
111-
class="rounded-lg bg-bgLight p-4 text-sm drop-shadow-lg dark:bg-bgDark"
111+
class="bg-bgLight dark:bg-bgDark rounded-lg p-4 text-sm drop-shadow-lg"
112112
>
113113
<div
114-
class="flex cursor-pointer flex-row justify-between text-primary dark:text-primaryDark"
114+
class="text-primary dark:text-primaryDark flex cursor-pointer flex-row justify-between"
115115
[routerLink]="['/player', currentPlayer.id]"
116116
>
117117
<a
@@ -125,17 +125,17 @@
125125
</section>
126126

127127
<div
128-
class="mt-4 flex animate-fade justify-between px-4"
128+
class="animate-fade mt-4 flex justify-between px-4"
129129
*ngIf="loading == false && (player$ | async) as currentPlayer"
130130
>
131-
<span class="text-lg font-semibold text-primary dark:text-primaryDark"
131+
<span class="text-primary dark:text-primaryDark text-lg font-semibold"
132132
>League of Legends</span
133133
>
134134
</div>
135135

136136
<section
137137
id="player-lol"
138-
class="mt-4 animate-fade"
138+
class="animate-fade mt-4"
139139
*ngIf="loading == false && (player$ | async) as currentPlayer"
140140
>
141141
<app-info-message
@@ -146,10 +146,10 @@
146146
></app-info-message>
147147

148148
<div
149-
class="mx-4 rounded-lg bg-bgLight p-4 text-sm drop-shadow-lg dark:bg-bgDark"
149+
class="bg-bgLight dark:bg-bgDark mx-4 rounded-lg p-4 text-sm drop-shadow-lg"
150150
>
151151
<div
152-
class="flex cursor-pointer flex-row justify-between text-primary dark:text-primaryDark"
152+
class="text-primary dark:text-primaryDark flex cursor-pointer flex-row justify-between"
153153
[routerLink]="['/lol/summoner', currentPlayer.id]"
154154
>
155155
<div class="flex items-center space-x-2">
@@ -163,24 +163,24 @@
163163
</section>
164164

165165
<div
166-
class="mt-4 flex animate-fade justify-between px-4"
166+
class="animate-fade mt-4 flex justify-between px-4"
167167
*ngIf="loading == false && (player$ | async) as currentPlayer"
168168
>
169-
<span class="text-lg font-semibold text-primary dark:text-primaryDark"
169+
<span class="text-primary dark:text-primaryDark text-lg font-semibold"
170170
>Préférences</span
171171
>
172172
</div>
173173

174174
<section
175175
id="player-preferences"
176-
class="mt-4 animate-fade px-4"
176+
class="animate-fade mt-4 px-4"
177177
*ngIf="loading == false && (player$ | async) as currentPlayer"
178178
>
179179
<div
180-
class="rounded-lg bg-bgLight p-4 text-sm drop-shadow-lg dark:bg-bgDark"
180+
class="bg-bgLight dark:bg-bgDark rounded-lg p-4 text-sm drop-shadow-lg"
181181
>
182182
<div
183-
class="flex cursor-pointer flex-row justify-between text-primary dark:text-primaryDark"
183+
class="text-primary dark:text-primaryDark flex cursor-pointer flex-row justify-between"
184184
>
185185
<span
186186
><fa-icon [icon]="calendarIcon" class="mr-2"></fa-icon>
@@ -195,13 +195,13 @@
195195
<input
196196
type="text"
197197
id="fullname"
198-
class="peer block w-full appearance-none border-0 border-b-2 border-gray-300 bg-transparent px-0 py-2.5 text-sm text-primary focus:border-secondary focus:outline-none focus:ring-0 dark:text-primaryDark"
198+
class="peer text-primary focus:border-secondary dark:text-primaryDark block w-full appearance-none border-0 border-b-2 border-gray-300 bg-transparent px-0 py-2.5 text-sm focus:ring-0 focus:outline-none"
199199
required
200200
formControlName="fullName"
201201
/>
202202
<label
203203
for="fullname"
204-
class="absolute top-3 -z-10 origin-[0] -translate-y-6 scale-75 transform text-sm text-gray-300 duration-300 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:left-0 peer-focus:-translate-y-6 peer-focus:scale-75 peer-focus:font-medium peer-focus:text-secondary"
204+
class="peer-focus:text-secondary absolute top-3 -z-10 origin-[0] -translate-y-6 scale-75 transform text-sm text-gray-300 duration-300 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:left-0 peer-focus:-translate-y-6 peer-focus:scale-75 peer-focus:font-medium"
205205
>
206206
Nom complet
207207
<span class="text-customRed">*</span>
@@ -212,13 +212,13 @@
212212
<input
213213
type="text"
214214
id="nickname"
215-
class="peer block w-full appearance-none border-0 border-b-2 border-gray-300 bg-transparent px-0 py-2.5 text-sm text-primary focus:border-secondary focus:outline-none focus:ring-0 dark:text-primaryDark"
215+
class="peer text-primary focus:border-secondary dark:text-primaryDark block w-full appearance-none border-0 border-b-2 border-gray-300 bg-transparent px-0 py-2.5 text-sm focus:ring-0 focus:outline-none"
216216
required
217217
formControlName="nickname"
218218
/>
219219
<label
220220
for="nickname"
221-
class="absolute top-3 -z-10 origin-[0] -translate-y-6 scale-75 transform text-sm text-gray-300 duration-300 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:left-0 peer-focus:-translate-y-6 peer-focus:scale-75 peer-focus:font-medium peer-focus:text-secondary"
221+
class="peer-focus:text-secondary absolute top-3 -z-10 origin-[0] -translate-y-6 scale-75 transform text-sm text-gray-300 duration-300 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:left-0 peer-focus:-translate-y-6 peer-focus:scale-75 peer-focus:font-medium"
222222
>
223223
Pseudo
224224
<span class="text-customRed">*</span>
@@ -229,16 +229,14 @@
229229
<input
230230
type="text"
231231
id="profilePictureUrl"
232-
class="peer block w-full appearance-none border-0 border-b-2 border-gray-300 bg-transparent px-0 py-2.5 text-sm text-primary focus:border-secondary focus:outline-none focus:ring-0 dark:text-primaryDark"
233-
required
232+
class="peer text-primary focus:border-secondary dark:text-primaryDark block w-full appearance-none border-0 border-b-2 border-gray-300 bg-transparent px-0 py-2.5 text-sm focus:ring-0 focus:outline-none"
234233
formControlName="profilePictureUrl"
235234
/>
236235
<label
237236
for="profilePictureUrl"
238-
class="absolute top-3 -z-10 origin-[0] -translate-y-6 scale-75 transform text-sm text-gray-300 duration-300 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:left-0 peer-focus:-translate-y-6 peer-focus:scale-75 peer-focus:font-medium peer-focus:text-secondary"
237+
class="peer-focus:text-secondary absolute top-3 -z-10 origin-[0] -translate-y-6 scale-75 transform text-sm text-gray-300 duration-300 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:left-0 peer-focus:-translate-y-6 peer-focus:scale-75 peer-focus:font-medium"
239238
>
240239
Photo de profil (URL)
241-
<span class="text-customRed">*</span>
242240
</label>
243241
</div>
244242

@@ -248,13 +246,13 @@
248246
<input
249247
type="text"
250248
id="riotGamesNickname"
251-
class="peer block w-full appearance-none border-0 border-b-2 border-gray-300 bg-transparent px-0 py-2.5 text-sm text-primary focus:border-secondary focus:outline-none focus:ring-0 dark:text-primaryDark"
249+
class="peer text-primary focus:border-secondary dark:text-primaryDark block w-full appearance-none border-0 border-b-2 border-gray-300 bg-transparent px-0 py-2.5 text-sm focus:ring-0 focus:outline-none"
252250
required
253251
formControlName="riotGamesNickname"
254252
/>
255253
<label
256254
for="riotGamesNickname"
257-
class="absolute top-3 -z-10 origin-[0] -translate-y-6 scale-75 transform text-sm text-gray-300 duration-300 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:left-0 peer-focus:-translate-y-6 peer-focus:scale-75 peer-focus:font-medium peer-focus:text-secondary"
255+
class="peer-focus:text-secondary absolute top-3 -z-10 origin-[0] -translate-y-6 scale-75 transform text-sm text-gray-300 duration-300 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:left-0 peer-focus:-translate-y-6 peer-focus:scale-75 peer-focus:font-medium"
258256
>
259257
Nom de compte Riot Games
260258
</label>
@@ -264,21 +262,21 @@
264262
<input
265263
type="text"
266264
id="riotGamesTagLine"
267-
class="peer block w-full appearance-none border-0 border-b-2 border-gray-300 bg-transparent px-0 py-2.5 text-sm text-primary focus:border-secondary focus:outline-none focus:ring-0 dark:text-primaryDark"
265+
class="peer text-primary focus:border-secondary dark:text-primaryDark block w-full appearance-none border-0 border-b-2 border-gray-300 bg-transparent px-0 py-2.5 text-sm focus:ring-0 focus:outline-none"
268266
required
269267
formControlName="riotGamesTagLine"
270268
/>
271269
<label
272270
for="riotGamesTagLine"
273-
class="absolute top-3 -z-10 origin-[0] -translate-y-6 scale-75 transform text-sm text-gray-300 duration-300 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:left-0 peer-focus:-translate-y-6 peer-focus:scale-75 peer-focus:font-medium peer-focus:text-secondary"
271+
class="peer-focus:text-secondary absolute top-3 -z-10 origin-[0] -translate-y-6 scale-75 transform text-sm text-gray-300 duration-300 peer-placeholder-shown:translate-y-0 peer-placeholder-shown:scale-100 peer-focus:left-0 peer-focus:-translate-y-6 peer-focus:scale-75 peer-focus:font-medium"
274272
>
275273
Tag (exemple: EUW)
276274
</label>
277275
</div>
278276

279277
<button
280278
(click)="updateUser()"
281-
class="delay-50 w-full rounded-lg border border-customGreen bg-bgLight px-5 py-2.5 text-center text-sm text-customGreen transition ease-in-out hover:bg-customGreen hover:text-white focus:outline-none focus:ring-4 focus:ring-customGreen dark:bg-bgDark"
279+
class="border-customGreen bg-bgLight text-customGreen hover:bg-customGreen focus:ring-customGreen dark:bg-bgDark w-full rounded-lg border px-5 py-2.5 text-center text-sm transition delay-50 ease-in-out hover:text-white focus:ring-4 focus:outline-none"
282280
>
283281
Mettre à jour
284282
</button>
@@ -287,7 +285,7 @@
287285
<hr class="my-4" />
288286

289287
<div
290-
class="flex cursor-pointer flex-row justify-between text-customRed"
288+
class="text-customRed flex cursor-pointer flex-row justify-between"
291289
(click)="logout()"
292290
>
293291
<a><fa-icon [icon]="logoutIcon" class="mr-2"></fa-icon> Déconnexion </a>

src/app/routes/profile/profile.component.ts

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,14 @@ export class ProfilePageComponent implements OnInit, OnChanges {
6060
@Output() successMessageChange = new EventEmitter<boolean>();
6161

6262
updatePlayerForm = new FormGroup({
63-
fullName: new FormControl('', [Validators.maxLength(100)]),
64-
nickname: new FormControl('', [Validators.maxLength(100)]),
63+
fullName: new FormControl('', [
64+
Validators.maxLength(100),
65+
Validators.required,
66+
]),
67+
nickname: new FormControl('', [
68+
Validators.maxLength(100),
69+
Validators.required,
70+
]),
6571
profilePictureUrl: new FormControl('', [Validators.maxLength(500)]),
6672
riotGamesNickname: new FormControl('', [Validators.maxLength(500)]),
6773
riotGamesTagLine: new FormControl('', [Validators.maxLength(500)]),
@@ -131,6 +137,15 @@ export class ProfilePageComponent implements OnInit, OnChanges {
131137
if (this.loading == false) {
132138
let riotGamesNickname: string | undefined = undefined;
133139
let riotGamesTagLine: string | undefined = undefined;
140+
let profilePictureUrl: string | undefined = undefined;
141+
142+
if (
143+
this.updatePlayerForm.controls['profilePictureUrl'].value != null &&
144+
this.updatePlayerForm.controls['profilePictureUrl'].value != ''
145+
) {
146+
profilePictureUrl =
147+
this.updatePlayerForm.controls['profilePictureUrl'].value;
148+
}
134149

135150
if (
136151
this.updatePlayerForm.controls['riotGamesNickname'].value != null &&
@@ -153,7 +168,7 @@ export class ProfilePageComponent implements OnInit, OnChanges {
153168
.update(
154169
this.updatePlayerForm.controls['fullName'].value,
155170
this.updatePlayerForm.controls['nickname'].value,
156-
this.updatePlayerForm.controls['profilePictureUrl'].value,
171+
profilePictureUrl,
157172
riotGamesNickname,
158173
riotGamesTagLine,
159174
)

src/app/shared/services/common/gameon-player.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ export class GameOnPlayerService {
4747
update(
4848
fullName: any,
4949
nickname: any,
50-
profilePicUrl: any,
50+
profilePicUrl?: any,
5151
riotGamesNickname?: string,
5252
riotGamesTagLine?: string,
5353
): Observable<Player> {

src/environments/environment.prod.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@ export const environment = {
66
realm: 'gameon',
77
clientId: 'gameon-front',
88
},
9-
currentLoLPatch: '15.7.1',
9+
currentLoLPatch: '15.9.1',
1010
};

src/environments/environment.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@ export const environment = {
66
realm: 'gameon',
77
clientId: 'gameon-front-dev',
88
},
9-
currentLoLPatch: '15.7.1',
9+
currentLoLPatch: '15.9.1',
1010
};

0 commit comments

Comments
 (0)