diff --git a/frontend_v2/src/app/components/about/about.component.ts b/frontend_v2/src/app/components/about/about.component.ts index 3235a9908b..ea75489bd3 100644 --- a/frontend_v2/src/app/components/about/about.component.ts +++ b/frontend_v2/src/app/components/about/about.component.ts @@ -1,4 +1,4 @@ -import { Component, OnInit, Inject } from '@angular/core'; +import { Component, OnInit } from '@angular/core'; import { GlobalService } from '../../services/global.service'; /** diff --git a/frontend_v2/src/app/components/auth/auth.component.ts b/frontend_v2/src/app/components/auth/auth.component.ts index 8a5b57d8ee..dd5d0a8160 100644 --- a/frontend_v2/src/app/components/auth/auth.component.ts +++ b/frontend_v2/src/app/components/auth/auth.component.ts @@ -1,5 +1,5 @@ -import { AfterViewInit, Component, ElementRef, OnInit, ViewChild } from '@angular/core'; -import { Router, ActivatedRoute } from '@angular/router'; +import { Component, ElementRef, OnInit, ViewChild } from '@angular/core'; +import { Router } from '@angular/router'; import { GlobalService } from '../../services/global.service'; import { AuthService } from '../../services/auth.service'; @@ -22,13 +22,11 @@ export class AuthComponent implements OnInit { /** * Constructor. * @param router Router Injection. - * @param route ActivatedRoute Injection. * @param globalService GlobalService Injection. * @param authService AuthServiceInjection */ constructor( private router: Router, - private route: ActivatedRoute, private globalService: GlobalService, public authService: AuthService ) {} diff --git a/frontend_v2/src/app/components/auth/login/login.component.html b/frontend_v2/src/app/components/auth/login/login.component.html index c6cd7c8055..37dd4390a7 100644 --- a/frontend_v2/src/app/components/auth/login/login.component.html +++ b/frontend_v2/src/app/components/auth/login/login.component.html @@ -27,16 +27,16 @@ id="name" class="dark-autofill" name="name" - (focusin)="isnameFocused = true" - (focusout)="isnameFocused = authService.getUser['name'] !== ''" + (focusin)="isNameFocused = true" + (focusout)="isNameFocused = authService.getUser['name'] !== ''" [(ngModel)]="authService.getUser['name']" - (change)="isnameFocused = authService.getUser['name'] !== ''" + (change)="isNameFocused = authService.getUser['name'] !== ''" #name="ngModel" minLength="3" required /> - +

Username is too short.

Username is required.

@@ -50,9 +50,9 @@ (paste)="authService.getUser['password'] = ''" class="dark-autofill" name="password" - (focusin)="ispasswordFocused = true" - (focusout)="ispasswordFocused = authService.getUser['password'] !== ''" - (change)="ispasswordFocused = authService.getUser['password'] !== ''" + (focusin)="isPasswordFocused = true" + (focusout)="isPasswordFocused = authService.getUser['password'] !== ''" + (change)="isPasswordFocused = authService.getUser['password'] !== ''" [(ngModel)]="authService.getUser['password']" #password="ngModel" autocomplete="new-password" @@ -63,7 +63,7 @@ - +
{}; + /** + * Constructor. + * @param globalService GlobalService Injection. + */ constructor(private globalService: GlobalService) {} ngOnInit() { diff --git a/frontend_v2/src/app/components/challenge/challengephases/challengephases.component.ts b/frontend_v2/src/app/components/challenge/challengephases/challengephases.component.ts index f8d07ecb5d..3eae3e6fae 100644 --- a/frontend_v2/src/app/components/challenge/challengephases/challengephases.component.ts +++ b/frontend_v2/src/app/components/challenge/challengephases/challengephases.component.ts @@ -1,5 +1,4 @@ -import { Component, OnInit, Inject } from '@angular/core'; -import { DOCUMENT } from '@angular/common'; +import { Component, OnInit } from '@angular/core'; import { ChallengeService } from '../../../services/challenge.service'; /** @@ -23,14 +22,9 @@ export class ChallengephasesComponent implements OnInit { /** * Constructor. - * @param route ActivatedRoute Injection. - * @param router GlobalService Injection. - * @param authService AuthService Injection. - * @param globalService GlobalService Injection. - * @param apiService Router Injection. * @param challengeService ChallengeService Injection. */ - constructor(private challengeService: ChallengeService, @Inject(DOCUMENT) private document: Document) {} + constructor(private challengeService: ChallengeService) {} /** * Component on intialized diff --git a/frontend_v2/src/app/components/challenge/challengephases/phasecard/phasecard.component.ts b/frontend_v2/src/app/components/challenge/challengephases/phasecard/phasecard.component.ts index 3f9b16b635..46a18b065a 100644 --- a/frontend_v2/src/app/components/challenge/challengephases/phasecard/phasecard.component.ts +++ b/frontend_v2/src/app/components/challenge/challengephases/phasecard/phasecard.component.ts @@ -1,8 +1,6 @@ -import { Component, OnInit, Input, Inject } from '@angular/core'; +import { Component, OnInit, Input } from '@angular/core'; import { GlobalService } from '../../../../services/global.service'; import { ChallengeService } from '../../../../services/challenge.service'; -import { ApiService } from '../../../../services/api.service'; -import { EndpointsService } from '../../../../services/endpoints.service'; /** * Component Class @@ -46,12 +44,11 @@ export class PhasecardComponent implements OnInit { /** * Constructor. * @param globalService GlobalService Injection. + * @param challengeService ChallengeService Injection. */ constructor( private globalService: GlobalService, - private challengeService: ChallengeService, - private apiService: ApiService, - private endpointsService: EndpointsService + private challengeService: ChallengeService ) {} /** diff --git a/frontend_v2/src/app/components/challenge/challengesubmissions/challengesubmissions.component.ts b/frontend_v2/src/app/components/challenge/challengesubmissions/challengesubmissions.component.ts index f1c00fd0f2..bef9851841 100644 --- a/frontend_v2/src/app/components/challenge/challengesubmissions/challengesubmissions.component.ts +++ b/frontend_v2/src/app/components/challenge/challengesubmissions/challengesubmissions.component.ts @@ -166,13 +166,14 @@ export class ChallengesubmissionsComponent implements OnInit, AfterViewInit { /** * Constructor. - * @param route ActivatedRoute Injection. - * @param router GlobalService Injection. * @param authService AuthService Injection. + * @param router Router Injection. + * @param route ActivatedRoute Injection. + * @param challengeService ChallengeService Injection. * @param globalService GlobalService Injection. * @param apiService Router Injection. + * @param windowService WindowService Injection. * @param endpointsService EndpointsService Injection. - * @param challengeService ChallengeService Injection. */ constructor( private authService: AuthService, diff --git a/frontend_v2/src/app/components/challenge/challengesubmit/challengesubmit.component.ts b/frontend_v2/src/app/components/challenge/challengesubmit/challengesubmit.component.ts index 7d27a7c228..f18cfb5697 100644 --- a/frontend_v2/src/app/components/challenge/challengesubmit/challengesubmit.component.ts +++ b/frontend_v2/src/app/components/challenge/challengesubmit/challengesubmit.component.ts @@ -213,12 +213,13 @@ export class ChallengesubmitComponent implements OnInit { /** * Constructor. - * @param route ActivatedRoute Injection. - * @param router Router Injection. * @param authService AuthService Injection. - * @param globalService GlobalService Injection. - * @param apiService ApiService Injection. + * @param router Router Injection. + * @param route ActivatedRoute Injection. * @param challengeService ChallengeService Injection. + * @param globalService GlobalService Injection. + * @param apiService Router Injection. + * @param endpointsService EndpointsService Injection. */ constructor( private authService: AuthService, diff --git a/frontend_v2/src/app/components/challenge/challengeviewallsubmissions/challengeviewallsubmissions.component.ts b/frontend_v2/src/app/components/challenge/challengeviewallsubmissions/challengeviewallsubmissions.component.ts index d1c42d3e76..30c072aa3f 100644 --- a/frontend_v2/src/app/components/challenge/challengeviewallsubmissions/challengeviewallsubmissions.component.ts +++ b/frontend_v2/src/app/components/challenge/challengeviewallsubmissions/challengeviewallsubmissions.component.ts @@ -165,13 +165,14 @@ export class ChallengeviewallsubmissionsComponent implements OnInit, AfterViewIn /** * Constructor. - * @param route ActivatedRoute Injection. - * @param router GlobalService Injection. * @param authService AuthService Injection. + * @param router Router Injection. + * @param route ActivatedRoute Injection. + * @param challengeService ChallengeService Injection. * @param globalService GlobalService Injection. * @param apiService Router Injection. + * @param windowService WindowService Injection. * @param endpointsService EndpointsService Injection. - * @param challengeService ChallengeService Injection. */ constructor( private authService: AuthService, diff --git a/frontend_v2/src/app/components/contact/contact.component.ts b/frontend_v2/src/app/components/contact/contact.component.ts index 5f9375005e..3b92dd4c71 100644 --- a/frontend_v2/src/app/components/contact/contact.component.ts +++ b/frontend_v2/src/app/components/contact/contact.component.ts @@ -1,11 +1,9 @@ -import { Component, OnInit, Inject } from '@angular/core'; +import { Component, OnInit } from '@angular/core'; import { ViewChildren, QueryList, AfterViewInit } from '@angular/core'; -import { DOCUMENT } from '@angular/common'; -import { Router, ActivatedRoute } from '@angular/router'; +import { Router } from '@angular/router'; import { NGXLogger } from 'ngx-logger'; import { InputComponent } from '../../components/utility/input/input.component'; -import { WindowService } from '../../services/window.service'; import { ApiService } from '../../services/api.service'; import { EndpointsService } from '../../services/endpoints.service'; import { GlobalService } from '../../services/global.service'; @@ -41,20 +39,15 @@ export class ContactComponent implements OnInit, AfterViewInit { componentlist: any; /** - * Constructor. - * @param document Window document Injection. - * @param route ActivatedRoute Injection. - * @param router Router Injection. + * Constructor.. * @param globalService GlobalService Injection. * @param apiService ApiService Injection. + * @param router Router Injection. * @param endpointsService EndpointsService Injection. */ constructor( - @Inject(DOCUMENT) private document: Document, - private windowService: WindowService, private globalService: GlobalService, private apiService: ApiService, - private route: ActivatedRoute, private router: Router, private endpointsService: EndpointsService, private logger: NGXLogger diff --git a/frontend_v2/src/app/components/home/featured-challenges/featured-challenges.component.ts b/frontend_v2/src/app/components/home/featured-challenges/featured-challenges.component.ts index 148d67c875..6e63bc100e 100644 --- a/frontend_v2/src/app/components/home/featured-challenges/featured-challenges.component.ts +++ b/frontend_v2/src/app/components/home/featured-challenges/featured-challenges.component.ts @@ -1,11 +1,9 @@ import { Component, OnInit } from '@angular/core'; -import { HttpClientModule } from '@angular/common/http'; -import { Router, ActivatedRoute } from '@angular/router'; +import { Router } from '@angular/router'; import { NGXLogger } from 'ngx-logger'; // import service import { GlobalService } from '../../../services/global.service'; -import { AuthService } from '../../../services/auth.service'; import { EndpointsService } from '../../../services/endpoints.service'; import { ApiService } from '../../../services/api.service'; @@ -31,19 +29,15 @@ export class FeaturedChallengesComponent implements OnInit { /** * Constructor. * @param endpointsService EndpointService Injection. - * @param route ActivatedRoute Injection. * @param router Router Injection. * @param globalService GlobalService Injection. * @param apiService ApiService Injection. - * @param authService AuthService Injection. */ constructor( - private apiService: ApiService, - private authService: AuthService, - private globalService: GlobalService, - private router: Router, - private route: ActivatedRoute, private endpointsService: EndpointsService, + private router: Router, + private globalService: GlobalService, + private apiService: ApiService, private logger: NGXLogger ) {} diff --git a/frontend_v2/src/app/components/home/home.component.ts b/frontend_v2/src/app/components/home/home.component.ts index 42dde6c28c..9efd12a4cd 100644 --- a/frontend_v2/src/app/components/home/home.component.ts +++ b/frontend_v2/src/app/components/home/home.component.ts @@ -3,7 +3,6 @@ import { ApiService } from '../../services/api.service'; import { EndpointsService } from '../../services/endpoints.service'; import { AuthService } from '../../services/auth.service'; import { GlobalService } from '../../services/global.service'; -import { BehaviorSubject } from 'rxjs'; import { Router } from '@angular/router'; import { InputComponent } from '../../components/utility/input/input.component'; @@ -32,6 +31,16 @@ export class HomeComponent implements OnInit, AfterViewInit, OnDestroy { components: QueryList; authServiceSubscription: any; + + /** + * Constructor. + * @param apiService ApiServiceInjection + * @param endpointService EndPointServiceInjection. + * @param authService AuthServiceInjection. + * @param globalService GlobalService Injection. + * @param router Router Injection. + */ + constructor( private apiService: ApiService, private endpointService: EndpointsService, diff --git a/frontend_v2/src/app/components/home/homemain/homemain.component.ts b/frontend_v2/src/app/components/home/homemain/homemain.component.ts index 3fcd4e2271..7f6e3782e5 100644 --- a/frontend_v2/src/app/components/home/homemain/homemain.component.ts +++ b/frontend_v2/src/app/components/home/homemain/homemain.component.ts @@ -1,8 +1,5 @@ import { Component, OnInit } from '@angular/core'; -import { Router, ActivatedRoute } from '@angular/router'; import { AuthService } from '../../../services/auth.service'; -import { ApiService } from '../../../services/api.service'; -import { GlobalService } from '../../../services/global.service'; /** * Component Class @@ -20,17 +17,9 @@ export class HomemainComponent implements OnInit { /** * Constructor. - * @param route ActivatedRoute Injection. - * @param router Router Injection. - * @param globalService GlobalService Injection. - * @param apiService ApiService Injection. * @param authService AuthService Injection. */ constructor( - private router: Router, - private route: ActivatedRoute, - private apiService: ApiService, - private globalService: GlobalService, private authService: AuthService ) {} diff --git a/frontend_v2/src/app/components/nav/footer/footer.component.ts b/frontend_v2/src/app/components/nav/footer/footer.component.ts index 70d2c0818a..29f2db0097 100644 --- a/frontend_v2/src/app/components/nav/footer/footer.component.ts +++ b/frontend_v2/src/app/components/nav/footer/footer.component.ts @@ -2,7 +2,7 @@ import { Component, OnInit, Inject, Input } from '@angular/core'; import { ApiService } from '../../../services/api.service'; import { GlobalService } from '../../../services/global.service'; import { DOCUMENT } from '@angular/common'; -import { Router, ActivatedRoute } from '@angular/router'; +import { Router } from '@angular/router'; /** * Component Class @@ -34,18 +34,16 @@ export class FooterComponent implements OnInit { /** * Constructor. + * @param apiService ApiService Injection. * @param document Window document Injection. - * @param route ActivatedRoute Injection. - * @param router Router Injection. * @param globalService GlobalService Injection. - * @param apiService ApiService Injection. + * @param router Router Injection. */ constructor( private apiService: ApiService, @Inject(DOCUMENT) private document: Document, private globalService: GlobalService, - private router: Router, - private route: ActivatedRoute + private router: Router ) {} /** diff --git a/frontend_v2/src/app/components/nav/header-static/header-static.component.ts b/frontend_v2/src/app/components/nav/header-static/header-static.component.ts index 5d53f335b0..a35411f778 100644 --- a/frontend_v2/src/app/components/nav/header-static/header-static.component.ts +++ b/frontend_v2/src/app/components/nav/header-static/header-static.component.ts @@ -7,15 +7,12 @@ import { HostListener, ViewChild, ElementRef, - AfterViewInit, } from '@angular/core'; import { GlobalService } from '../../../services/global.service'; import { AuthService } from '../../../services/auth.service'; import { filter } from "rxjs/internal/operators"; -import { RouterModule, Router, ActivatedRoute, NavigationEnd } from '@angular/router'; +import { Router, NavigationEnd } from '@angular/router'; import { DOCUMENT } from '@angular/common'; -import { ApiService } from '../../../services/api.service'; -import { el } from '@angular/platform-browser/testing/src/browser_util'; /** * Component Class @@ -82,21 +79,17 @@ export class HeaderStaticComponent implements OnInit, OnDestroy { /** * Constructor. - * @param document Window document Injection. - * @param route ActivatedRoute Injection. - * @param router Router Injection. * @param globalService GlobalService Injection. - * @param authService AuthService Injection. - * @param apiService ApiService Injection. + * @param router Router Injection. * @param ref Angular Change Detector Injection. + * @param authService AuthService Injection. + * @param document Window document Injection. */ constructor( private globalService: GlobalService, - private route: ActivatedRoute, private router: Router, private ref: ChangeDetectorRef, public authService: AuthService, - private apiService: ApiService, @Inject(DOCUMENT) private document: Document ) { this.authState = authService.authState; diff --git a/frontend_v2/src/app/components/our-team/our-team.component.ts b/frontend_v2/src/app/components/our-team/our-team.component.ts index 0df1050411..bcac673717 100644 --- a/frontend_v2/src/app/components/our-team/our-team.component.ts +++ b/frontend_v2/src/app/components/our-team/our-team.component.ts @@ -1,12 +1,10 @@ import { Component, OnInit } from '@angular/core'; -import { Router, ActivatedRoute } from '@angular/router'; import { NGXLogger } from 'ngx-logger'; // import service import { ApiService } from '../../services/api.service'; import { GlobalService } from '../../services/global.service'; import { EndpointsService } from '../../services/endpoints.service'; -import { AuthService } from '../../services/auth.service'; /** * Component Class @@ -19,19 +17,13 @@ import { AuthService } from '../../services/auth.service'; export class OurTeamComponent implements OnInit { /** * Constructor. - * @param endpointsService EndpointService Injection. - * @param route ActivatedRoute Injection. - * @param router Router Injection. - * @param globalService GlobalService Injection. * @param apiService ApiService Injection. - * @param authService AuthService Injection. + * @param globalService GlobalService Injection. + * @param endpointsService EndpointService Injection. */ constructor( private apiService: ApiService, - private authService: AuthService, private globalService: GlobalService, - private router: Router, - private route: ActivatedRoute, private endpointsService: EndpointsService, private logger: NGXLogger ) {} diff --git a/frontend_v2/src/app/components/publiclists/challengelist/challengelist.component.ts b/frontend_v2/src/app/components/publiclists/challengelist/challengelist.component.ts index 329c033ae8..d6efda8c64 100644 --- a/frontend_v2/src/app/components/publiclists/challengelist/challengelist.component.ts +++ b/frontend_v2/src/app/components/publiclists/challengelist/challengelist.component.ts @@ -3,7 +3,7 @@ import { ApiService } from '../../../services/api.service'; import { GlobalService } from '../../../services/global.service'; import { AuthService } from '../../../services/auth.service'; import { EndpointsService } from '../../../services/endpoints.service'; -import { Router, ActivatedRoute } from '@angular/router'; +import { Router } from '@angular/router'; import { DOCUMENT } from '@angular/common'; /** @@ -179,12 +179,11 @@ export class ChallengelistComponent implements OnInit { /** * Constructor. - * @param route ActivatedRoute Injection. - * @param router Router Injection. - * @param globalService GlobalService Injection. - * @param authService AuthService Injection. * @param apiService ApiService Injection. + * @param authService AuthService Injection. + * @param globalService GlobalService Injection. * @param endpointsService EndpointsService Injection. + * @param router Router Injection. * @param document */ constructor( @@ -193,8 +192,7 @@ export class ChallengelistComponent implements OnInit { private globalService: GlobalService, private endpointsService: EndpointsService, private router: Router, - @Inject(DOCUMENT) private document, - private route: ActivatedRoute + @Inject(DOCUMENT) private document ) {} /** diff --git a/frontend_v2/src/app/components/publiclists/publiclists.component.ts b/frontend_v2/src/app/components/publiclists/publiclists.component.ts index 5bf8ba6653..2add1a954c 100644 --- a/frontend_v2/src/app/components/publiclists/publiclists.component.ts +++ b/frontend_v2/src/app/components/publiclists/publiclists.component.ts @@ -1,7 +1,4 @@ -import { Component, OnInit, Inject, OnDestroy } from '@angular/core'; -import { Router, ActivatedRoute } from '@angular/router'; -import { DOCUMENT } from '@angular/common'; -import { GlobalService } from '../../services/global.service'; +import { Component } from '@angular/core'; import { AuthService } from '../../services/auth.service'; /** @@ -15,17 +12,9 @@ import { AuthService } from '../../services/auth.service'; export class PubliclistsComponent { /** * Constructor. - * @param document Window document Injection. - * @param route ActivatedRoute Injection. - * @param router Router Injection. * @param authService - * @param globalService GlobalService Injection. */ constructor( - private router: Router, - private route: ActivatedRoute, - @Inject(DOCUMENT) private document: Document, - public authService: AuthService, - private globalService: GlobalService + public authService: AuthService ) {} } diff --git a/frontend_v2/src/app/components/publiclists/teamlist/teamcard/teamcard.component.ts b/frontend_v2/src/app/components/publiclists/teamlist/teamcard/teamcard.component.ts index 9a1ea3f73b..6451dd108c 100644 --- a/frontend_v2/src/app/components/publiclists/teamlist/teamcard/teamcard.component.ts +++ b/frontend_v2/src/app/components/publiclists/teamlist/teamcard/teamcard.component.ts @@ -1,7 +1,4 @@ import { Component, OnInit, OnChanges, Input, Output, EventEmitter, SimpleChanges } from '@angular/core'; -import { GlobalService } from '../../../../services/global.service'; -import { ApiService } from '../../../../services/api.service'; -import { Router, ActivatedRoute } from '@angular/router'; import { AuthService } from '../../../../services/auth.service'; /** @@ -100,17 +97,10 @@ export class TeamcardComponent implements OnInit, OnChanges { /** * Constructor. - * @param route ActivatedRoute Injection. - * @param router Router Injection. - * @param globalService GlobalService Injection. - * @param apiService ApiService Injection. + * @param authService AuthService Injection. */ constructor( - private globalService: GlobalService, - private apiService: ApiService, - public authService: AuthService, - private router: Router, - private route: ActivatedRoute + public authService: AuthService ) {} /** diff --git a/frontend_v2/src/app/components/publiclists/teamlist/teamlist.component.ts b/frontend_v2/src/app/components/publiclists/teamlist/teamlist.component.ts index 45ccf1811e..cf197bacec 100644 --- a/frontend_v2/src/app/components/publiclists/teamlist/teamlist.component.ts +++ b/frontend_v2/src/app/components/publiclists/teamlist/teamlist.component.ts @@ -226,7 +226,6 @@ export class TeamlistComponent implements OnInit, OnDestroy { templatePhases = null; /** - * Constructor. * @param route ActivatedRoute Injection. * @param router Router Injection. diff --git a/frontend_v2/src/app/components/publiclists/templatechallengelist/templatechallengelist.component.ts b/frontend_v2/src/app/components/publiclists/templatechallengelist/templatechallengelist.component.ts index a1fe325542..7daa9fd72d 100644 --- a/frontend_v2/src/app/components/publiclists/templatechallengelist/templatechallengelist.component.ts +++ b/frontend_v2/src/app/components/publiclists/templatechallengelist/templatechallengelist.component.ts @@ -1,9 +1,7 @@ -import { Component, HostListener, Inject, OnInit } from '@angular/core'; +import { Component, OnInit } from '@angular/core'; import { ApiService } from '../../../services/api.service'; import { GlobalService } from '../../../services/global.service'; import { AuthService } from '../../../services/auth.service'; -import { Router, ActivatedRoute } from '@angular/router'; -import { DOCUMENT } from '@angular/common'; /** @@ -36,12 +34,14 @@ export class TemplateChallengeListComponent implements OnInit { */ templateChallengesFetchPath = 'challenges/get_all_challenge_templates/' - + /** + * Constructor. + * @param authService AuthService Injection. + * @param globalService GlobalService Injection. + * @param apiService ApiService Injection. + */ constructor( public authService: AuthService, - private router: Router, - private route: ActivatedRoute, - @Inject(DOCUMENT) private document, private globalService: GlobalService, private apiService: ApiService ) {} diff --git a/frontend_v2/src/app/components/template-challenge-create/template-challenge-create.component.ts b/frontend_v2/src/app/components/template-challenge-create/template-challenge-create.component.ts index a8ed8f92ea..fce08e9f17 100644 --- a/frontend_v2/src/app/components/template-challenge-create/template-challenge-create.component.ts +++ b/frontend_v2/src/app/components/template-challenge-create/template-challenge-create.component.ts @@ -1,11 +1,9 @@ -import { Component, OnInit, ViewChildren, QueryList, Inject } from '@angular/core'; +import { Component, OnInit } from '@angular/core'; import { AuthService } from '../../services/auth.service'; -import { ApiService } from '../../services/api.service'; import { GlobalService } from '../../services/global.service'; import { ChallengeService } from '../../services/challenge.service'; import { Router, ActivatedRoute } from '@angular/router'; -import { DOCUMENT } from '@angular/common'; /** * Component Class @@ -78,9 +76,7 @@ export class TemplateChallengeCreateComponent implements OnInit { private router: Router, private route: ActivatedRoute, private challengeService: ChallengeService, - @Inject(DOCUMENT) private document, - private globalService: GlobalService, - private apiService: ApiService + private globalService: GlobalService ) {} ngOnInit() { diff --git a/frontend_v2/src/app/components/utility/input/input.component.ts b/frontend_v2/src/app/components/utility/input/input.component.ts index 4647c9e0cc..71b3b1bc4c 100644 --- a/frontend_v2/src/app/components/utility/input/input.component.ts +++ b/frontend_v2/src/app/components/utility/input/input.component.ts @@ -1,4 +1,4 @@ -import { Injectable, Component, OnInit, Input, Inject } from '@angular/core'; +import { Component, OnInit, Input, Inject } from '@angular/core'; import { DOCUMENT } from '@angular/common'; import { GlobalService } from '../../../services/global.service'; diff --git a/frontend_v2/src/app/components/utility/modal/modal.component.ts b/frontend_v2/src/app/components/utility/modal/modal.component.ts index fc0e5fbb5f..89639303c0 100644 --- a/frontend_v2/src/app/components/utility/modal/modal.component.ts +++ b/frontend_v2/src/app/components/utility/modal/modal.component.ts @@ -1,5 +1,5 @@ import { Component, OnInit, Input } from '@angular/core'; -import { ViewChildren, QueryList, AfterViewInit } from '@angular/core'; +import { ViewChildren, QueryList } from '@angular/core'; import { GlobalService } from '../../../services/global.service'; import { InputComponent } from '../input/input.component'; import { ChallengeService } from '../../../services/challenge.service'; diff --git a/frontend_v2/tslint.json b/frontend_v2/tslint.json index 2c7cc88920..b66f76a483 100644 --- a/frontend_v2/tslint.json +++ b/frontend_v2/tslint.json @@ -36,6 +36,8 @@ "no-switch-case-fall-through": true, "no-unnecessary-initializer": true, "no-unused-expression": true, + "no-unused-variable": true, + "noUnusedLocals": true, "no-use-before-declare": true, "no-var-keyword": true, "object-literal-sort-keys": false,