Skip to content

Commit

Permalink
chore(build): updated accordingly to ng2 style guide
Browse files Browse the repository at this point in the history
  • Loading branch information
valorkin committed Apr 27, 2016
1 parent 7f091ba commit f5157df
Show file tree
Hide file tree
Showing 8 changed files with 21 additions and 21 deletions.
4 changes: 2 additions & 2 deletions components/select.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
import {Select} from './select/select';
export const SELECT_DIRECTIVES:Array<any> = [Select];
import {SelectComponent} from './select/select';
export const SELECT_DIRECTIVES:Array<any> = [SelectComponent];
10 changes: 5 additions & 5 deletions components/select/select.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ let optionsTemplate = `
</div>
`
})
export class Select implements OnInit {
export class SelectComponent implements OnInit {
@Input() public allowClear:boolean = false;
@Input() public placeholder:string = '';
@Input() public initData:Array<any> = [];
Expand Down Expand Up @@ -381,8 +381,8 @@ export class Select implements OnInit {
export class Behavior {
public optionsMap:Map<string, number> = new Map<string, number>();

public actor: Select;
public constructor(actor:Select) {
public actor: SelectComponent;
public constructor(actor:SelectComponent) {
this.actor = actor;
}

Expand Down Expand Up @@ -431,7 +431,7 @@ export class Behavior {
}

export class GenericBehavior extends Behavior implements OptionsBehavior {
public constructor(actor:Select) {
public constructor(actor:SelectComponent) {
super(actor);
}

Expand Down Expand Up @@ -475,7 +475,7 @@ export class GenericBehavior extends Behavior implements OptionsBehavior {
}

export class ChildrenBehavior extends Behavior implements OptionsBehavior {
public constructor(actor:Select) {
public constructor(actor:SelectComponent) {
super(actor);
}

Expand Down
12 changes: 6 additions & 6 deletions demo/components/select-section.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ import {CORE_DIRECTIVES} from 'angular2/common';

import {TAB_DIRECTIVES} from 'ng2-bootstrap/ng2-bootstrap';

import {SingleDemo} from './select/single-demo';
import {MultipleDemo} from './select/multiple-demo';
import {ChildrenDemo} from './select/children-demo';
import {RichDemo} from './select/rich-demo';
import {SingleDemoComponent} from './select/single-demo';
import {MultipleDemoComponent} from './select/multiple-demo';
import {ChildrenDemoComponent} from './select/children-demo';
import {RichDemoComponent} from './select/rich-demo';

let name = 'Select';
// webpack html imports
Expand Down Expand Up @@ -86,9 +86,9 @@ tabDesc.forEach((desc:any) => {
</div>
</section>
`,
directives: [SingleDemo, MultipleDemo, ChildrenDemo, RichDemo, TAB_DIRECTIVES, CORE_DIRECTIVES]
directives: [SingleDemoComponent, MultipleDemoComponent, ChildrenDemoComponent, RichDemoComponent, TAB_DIRECTIVES, CORE_DIRECTIVES]
})
export class SelectSection {
export class SelectSectionComponent {
public currentHeading:string = 'Single';

public select_zzz(e:any):void {
Expand Down
2 changes: 1 addition & 1 deletion demo/components/select/children-demo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ let template = require('./children-demo.html');
template: template,
directives: [SELECT_DIRECTIVES, NgClass, CORE_DIRECTIVES, FORM_DIRECTIVES, ButtonCheckbox]
})
export class ChildrenDemo {
export class ChildrenDemoComponent {
public items:Array<any> = [
{
text: 'Austria',
Expand Down
2 changes: 1 addition & 1 deletion demo/components/select/multiple-demo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ let template = require('./multiple-demo.html');
template: template,
directives: [SELECT_DIRECTIVES, NgClass, CORE_DIRECTIVES, FORM_DIRECTIVES, ButtonCheckbox]
})
export class MultipleDemo {
export class MultipleDemoComponent {
public items:Array<string> = ['Amsterdam', 'Antwerp', 'Athens', 'Barcelona',
'Berlin', 'Birmingham', 'Bradford', 'Bremen', 'Brussels', 'Bucharest',
'Budapest', 'Cologne', 'Copenhagen', 'Dortmund', 'Dresden', 'Dublin', 'Düsseldorf',
Expand Down
2 changes: 1 addition & 1 deletion demo/components/select/rich-demo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ let template = require('./rich-demo.html');
directives: [SELECT_DIRECTIVES, NgClass, CORE_DIRECTIVES, FORM_DIRECTIVES, ButtonCheckbox],
encapsulation: ViewEncapsulation.None // Enable dynamic HTML styles
})
export class RichDemo implements OnInit {
export class RichDemoComponent implements OnInit {
private value:any = {};
private _disabledV:string = '0';
private disabled:boolean = false;
Expand Down
2 changes: 1 addition & 1 deletion demo/components/select/single-demo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ let template = require('./single-demo.html');
template: template,
directives: [SELECT_DIRECTIVES, NgClass, CORE_DIRECTIVES, FORM_DIRECTIVES, ButtonCheckbox]
})
export class SingleDemo {
export class SingleDemoComponent {
public items:Array<string> = ['Amsterdam', 'Antwerp', 'Athens', 'Barcelona',
'Berlin', 'Birmingham', 'Bradford', 'Bremen', 'Brussels', 'Bucharest',
'Budapest', 'Cologne', 'Copenhagen', 'Dortmund', 'Dresden', 'Dublin',
Expand Down
8 changes: 4 additions & 4 deletions demo/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import {bootstrap} from 'angular2/platform/browser';
import {Component} from 'angular2/core';
import {NgClass} from 'angular2/common';

import {SelectSection} from './components/select-section';
import {SelectSectionComponent} from './components/select-section';

let gettingStarted = require('./getting-started.md');

Expand Down Expand Up @@ -35,10 +35,10 @@ let gettingStarted = require('./getting-started.md');
`,
directives: [
NgClass,
SelectSection
SelectSectionComponent
]
})
export class Demo {
export class DemoComponent {
}

bootstrap(Demo);
bootstrap(DemoComponent);

0 comments on commit f5157df

Please sign in to comment.