parent
76f8ae31ad
commit
7d1990e4d1
|
@ -50,7 +50,7 @@ const templateC = `
|
||||||
})
|
})
|
||||||
// #docregion carol-class
|
// #docregion carol-class
|
||||||
export class CarolComponent {
|
export class CarolComponent {
|
||||||
name= 'Carol';
|
name = 'Carol';
|
||||||
// #docregion carol-ctor
|
// #docregion carol-ctor
|
||||||
constructor( @Optional() public parent: Parent ) { }
|
constructor( @Optional() public parent: Parent ) { }
|
||||||
// #enddocregion carol-ctor
|
// #enddocregion carol-ctor
|
||||||
|
@ -63,7 +63,7 @@ export class CarolComponent {
|
||||||
template: templateC
|
template: templateC
|
||||||
})
|
})
|
||||||
export class ChrisComponent {
|
export class ChrisComponent {
|
||||||
name= 'Chris';
|
name = 'Chris';
|
||||||
constructor( @Optional() public parent: Parent ) { }
|
constructor( @Optional() public parent: Parent ) { }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -116,7 +116,7 @@ export class BarryComponent implements Parent {
|
||||||
providers: [ provideParent(BobComponent) ]
|
providers: [ provideParent(BobComponent) ]
|
||||||
})
|
})
|
||||||
export class BobComponent implements Parent {
|
export class BobComponent implements Parent {
|
||||||
name= 'Bob';
|
name = 'Bob';
|
||||||
constructor( @SkipSelf() @Optional() public parent: Parent ) { }
|
constructor( @SkipSelf() @Optional() public parent: Parent ) { }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -128,7 +128,7 @@ export class BobComponent implements Parent {
|
||||||
// #enddocregion beth-providers
|
// #enddocregion beth-providers
|
||||||
})
|
})
|
||||||
export class BethComponent implements Parent {
|
export class BethComponent implements Parent {
|
||||||
name= 'Beth';
|
name = 'Beth';
|
||||||
constructor( @SkipSelf() @Optional() public parent: Parent ) { }
|
constructor( @SkipSelf() @Optional() public parent: Parent ) { }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -157,7 +157,7 @@ export class BethComponent implements Parent {
|
||||||
export class AlexComponent extends Base
|
export class AlexComponent extends Base
|
||||||
// #enddocregion alex-class-signature
|
// #enddocregion alex-class-signature
|
||||||
{
|
{
|
||||||
name= 'Alex';
|
name = 'Alex';
|
||||||
}
|
}
|
||||||
// #enddocregion alex, alex-1
|
// #enddocregion alex, alex-1
|
||||||
|
|
||||||
|
@ -182,7 +182,7 @@ export class AlexComponent extends Base
|
||||||
export class AliceComponent implements Parent
|
export class AliceComponent implements Parent
|
||||||
// #enddocregion alice-class-signature
|
// #enddocregion alice-class-signature
|
||||||
{
|
{
|
||||||
name= 'Alice';
|
name = 'Alice';
|
||||||
}
|
}
|
||||||
// #enddocregion alice
|
// #enddocregion alice
|
||||||
|
|
||||||
|
|
|
@ -187,7 +187,7 @@ describe('Dependency Injection Tests', function () {
|
||||||
let heroes = element.all(by.css('#authorized app-hero-list div'));
|
let heroes = element.all(by.css('#authorized app-hero-list div'));
|
||||||
expect(heroes.count()).toBeGreaterThan(0);
|
expect(heroes.count()).toBeGreaterThan(0);
|
||||||
|
|
||||||
let filteredHeroes = heroes.filter(function(elem: ElementFinder, index: number){
|
let filteredHeroes = heroes.filter(function(elem: ElementFinder, index: number) {
|
||||||
return elem.getText().then(function(text: string) {
|
return elem.getText().then(function(text: string) {
|
||||||
return /secret/.test(text);
|
return /secret/.test(text);
|
||||||
});
|
});
|
||||||
|
|
|
@ -19,7 +19,7 @@ import { AdComponent } from './ad.component';
|
||||||
// #docregion class
|
// #docregion class
|
||||||
export class AdBannerComponent implements OnInit, OnDestroy {
|
export class AdBannerComponent implements OnInit, OnDestroy {
|
||||||
@Input() ads: AdItem[];
|
@Input() ads: AdItem[];
|
||||||
currentAdIndex: number = -1;
|
currentAdIndex = -1;
|
||||||
@ViewChild(AdDirective) adHost: AdDirective;
|
@ViewChild(AdDirective) adHost: AdDirective;
|
||||||
interval: any;
|
interval: any;
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,7 @@ describe('Dynamic Form', function () {
|
||||||
element(by.css('select option[value="solid"]')).click();
|
element(by.css('select option[value="solid"]')).click();
|
||||||
|
|
||||||
let saveButton = element.all(by.css('button')).get(0);
|
let saveButton = element.all(by.css('button')).get(0);
|
||||||
saveButton.click().then(function(){
|
saveButton.click().then(function() {
|
||||||
expect(element(by.xpath("//strong[contains(text(),'Saved the following values')]")).isPresent()).toBe(true);
|
expect(element(by.xpath("//strong[contains(text(),'Saved the following values')]")).isPresent()).toBe(true);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
// #docregion
|
// #docregion
|
||||||
export class QuestionBase<T>{
|
export class QuestionBase<T> {
|
||||||
value: T;
|
value: T;
|
||||||
key: string;
|
key: string;
|
||||||
label: string;
|
label: string;
|
||||||
|
|
Loading…
Reference in New Issue