chore: run clang-format on code base.

This fixes several minor indentation issues (instanceof precendence,
type declaration specificity, template string length calculation).

This should also fix some flip-flop situations with template strings.
This commit is contained in:
Martin Probst
2015-07-10 11:29:41 +02:00
parent 45994a53ce
commit 3bf8c18c56
26 changed files with 128 additions and 138 deletions

View File

@ -107,9 +107,9 @@ export class FormBuilder {
}
_createControl(controlConfig: any): modelModule.AbstractControl {
if (controlConfig instanceof modelModule.Control || controlConfig instanceof
modelModule.ControlGroup || controlConfig instanceof
modelModule.ControlArray) {
if (controlConfig instanceof modelModule.Control ||
controlConfig instanceof modelModule.ControlGroup ||
controlConfig instanceof modelModule.ControlArray) {
return controlConfig;
} else if (isArray(controlConfig)) {

View File

@ -98,8 +98,8 @@ export class AbstractControl {
}
}
updateValueAndValidity({onlySelf, emitEvent}: {onlySelf?: boolean,
emitEvent?: boolean} = {}): void {
updateValueAndValidity({onlySelf, emitEvent}: {onlySelf?: boolean, emitEvent?: boolean} = {}):
void {
onlySelf = isPresent(onlySelf) ? onlySelf : false;
emitEvent = isPresent(emitEvent) ? emitEvent : true;
@ -151,8 +151,8 @@ export class Control extends AbstractControl {
this._valueChanges = new EventEmitter();
}
updateValue(value: any,
{onlySelf, emitEvent}: {onlySelf?: boolean, emitEvent?: boolean} = {}): void {
updateValue(value: any, {onlySelf, emitEvent}: {onlySelf?: boolean, emitEvent?: boolean} = {}):
void {
this._value = value;
if (isPresent(this._onChange)) this._onChange(this._value);
this.updateValueAndValidity({onlySelf: onlySelf, emitEvent: emitEvent});