This commit is contained in:
insanity 2018-05-29 15:16:18 +09:00
commit 997218e1a8
3 changed files with 22 additions and 12 deletions

View File

@ -5,7 +5,7 @@ import {
Output,
EventEmitter,
} from '@angular/core';
import { FormGroup, FormBuilder, Validators, AbstractControl, FormControl } from '@angular/forms';
import { FormGroup, FormBuilder, Validators, AbstractControl, FormControl, ValidationErrors } from '@angular/forms';
import { Member } from '@overflow/commons-typescript/model/member';
@Component({
@ -92,7 +92,7 @@ export class MemberSignupComponent implements OnInit, OnDestroy {
this.company = this.signupForm.controls['company'];
}
pwMatchValidator(control: FormControl): { [s: string]: boolean } {
pwMatchValidator(control: FormControl): ValidationErrors {
let pw;
if (control.parent) {
pw = control.parent.controls['password'].value;
@ -100,6 +100,7 @@ export class MemberSignupComponent implements OnInit, OnDestroy {
if (control.value !== pw) {
return { notMatched: true };
}
return null;
}
signupFormSubmit() {

View File

@ -44,7 +44,7 @@ export class AppSubMenuComponent {
constructor(public app: PagesComponent) { }
itemClick(event: Event, item: MenuItem, index: number)  {
itemClick(event: Event, item: MenuItem, index: number): boolean  {
if (this.root) {
this.app.menuHoverActive = !this.app.menuHoverActive;
}
@ -83,6 +83,7 @@ export class AppSubMenuComponent {
this.app.staticMenuMobileActive = false;
this.app.menuHoverActive = !this.app.menuHoverActive;
}
return false;
}
onMouseEnter(index: number) {

View File

@ -24,17 +24,25 @@
"@app/*": [
"src/app/*"
]
}
// /* Additional Checks */
},
/* Strict Type-Checking Options */
// "noImplicitAny": true /* Raise error on expressions and declarations with an implied 'any' type. */,
// "strictNullChecks": true /* Enable strict null checks. */,
// "strictFunctionTypes": true /* Enable strict checking of function types. */,
"strictPropertyInitialization": true /* Enable strict checking of property initialization in classes. */,
// "noImplicitThis": true /* Raise error on 'this' expressions with an implied 'any' type. */,
// "alwaysStrict": true /* Parse in strict mode and emit "use strict" for each source file. */,
/* Additional Checks */
// "noUnusedLocals": true /* Report errors on unused locals. */,
// "noUnusedParameters": true /* Report errors on unused parameters. */,
// "noImplicitReturns": true /* Report error when not all code paths in function return a value. */,
// "noFallthroughCasesInSwitch": true /* Report errors for fallthrough cases in switch statement. */,
"noImplicitReturns": true /* Report error when not all code paths in function return a value. */,
"noFallthroughCasesInSwitch": true /* Report errors for fallthrough cases in switch statement. */,
// /* Debugging Options */
// "traceResolution": false /* Report module resolution log messages. */,
// "listEmittedFiles": false /* Print names of generated files part of the compilation. */,
// "listFiles": false /* Print names of files part of the compilation. */,
// "pretty": true /* Stylize errors and messages using color and context. */,
/* Debugging Options */
"traceResolution": false /* Report module resolution log messages. */,
"listEmittedFiles": false /* Print names of generated files part of the compilation. */,
"listFiles": false /* Print names of files part of the compilation. */,
"pretty": true /* Stylize errors and messages using color and context. */,
}
}