refactor(material): remove imports from 'angular2/angular2'

Closes #5800
This commit is contained in:
Pawel Kozlowski 2015-12-10 17:03:30 +01:00
parent edcb34dc9f
commit d26c338aa0
9 changed files with 15 additions and 24 deletions

View File

@ -1,4 +1,4 @@
import {Component, View, ViewEncapsulation, OnChanges} from 'angular2/angular2'; import {Component, View, ViewEncapsulation, OnChanges} from 'angular2/core';
import {TimerWrapper} from 'angular2/src/facade/async'; import {TimerWrapper} from 'angular2/src/facade/async';
import {isPresent} from 'angular2/src/facade/lang'; import {isPresent} from 'angular2/src/facade/lang';

View File

@ -1,4 +1,4 @@
import {Component, View, Attribute, ViewEncapsulation} from 'angular2/angular2'; import {Component, View, Attribute, ViewEncapsulation} from 'angular2/core';
import {isPresent} from 'angular2/src/facade/lang'; import {isPresent} from 'angular2/src/facade/lang';
import {KeyCodes} from 'angular2_material/src/core/key_codes'; import {KeyCodes} from 'angular2_material/src/core/key_codes';
import {KeyboardEvent} from 'angular2/src/facade/browser'; import {KeyboardEvent} from 'angular2/src/facade/browser';

View File

@ -7,7 +7,7 @@ import {
OnChanges, OnChanges,
OnDestroy, OnDestroy,
AfterContentChecked AfterContentChecked
} from 'angular2/angular2'; } from 'angular2/core';
import {ListWrapper} from 'angular2/src/facade/collection'; import {ListWrapper} from 'angular2/src/facade/collection';
import {StringWrapper, isPresent, isString, NumberWrapper} from 'angular2/src/facade/lang'; import {StringWrapper, isPresent, isString, NumberWrapper} from 'angular2/src/facade/lang';

View File

@ -1,4 +1,4 @@
import {Directive, Attribute, Host, SkipSelf, AfterContentChecked} from 'angular2/angular2'; import {Directive, Attribute, Host, SkipSelf, AfterContentChecked} from 'angular2/core';
import {ObservableWrapper, EventEmitter} from 'angular2/src/facade/async'; import {ObservableWrapper, EventEmitter} from 'angular2/src/facade/async';

View File

@ -1,7 +1,7 @@
import {Component, View, ViewEncapsulation} from 'angular2/angular2'; import {Component, ViewEncapsulation} from 'angular2/core';
@Component({selector: 'md-progress-circular'}) @Component({
@View({ selector: 'md-progress-circular',
templateUrl: 'package:angular2_material/src/components/progress-circular/progress_circular.html', templateUrl: 'package:angular2_material/src/components/progress-circular/progress_circular.html',
encapsulation: ViewEncapsulation.None encapsulation: ViewEncapsulation.None
}) })

View File

@ -1,4 +1,4 @@
import {Component, View, ViewEncapsulation, Attribute, OnChanges} from 'angular2/angular2'; import {Component, ViewEncapsulation, Attribute, OnChanges} from 'angular2/core';
import {CONST} from 'angular2/src/facade/lang'; import {CONST} from 'angular2/src/facade/lang';
import {isPresent, isBlank} from 'angular2/src/facade/lang'; import {isPresent, isBlank} from 'angular2/src/facade/lang';
import {Math} from 'angular2/src/facade/math'; import {Math} from 'angular2/src/facade/math';
@ -20,9 +20,7 @@ class ProgressMode {
'aria-valuemin': '0', 'aria-valuemin': '0',
'aria-valuemax': '100', 'aria-valuemax': '100',
'[attr.aria-valuenow]': 'value' '[attr.aria-valuenow]': 'value'
} },
})
@View({
templateUrl: 'package:angular2_material/src/components/progress-linear/progress_linear.html', templateUrl: 'package:angular2_material/src/components/progress-linear/progress_linear.html',
directives: [], directives: [],
encapsulation: ViewEncapsulation.None encapsulation: ViewEncapsulation.None

View File

@ -1,6 +1,5 @@
import { import {
Component, Component,
View,
ViewEncapsulation, ViewEncapsulation,
Host, Host,
SkipSelf, SkipSelf,
@ -8,7 +7,7 @@ import {
Optional, Optional,
OnChanges, OnChanges,
OnInit OnInit
} from 'angular2/angular2'; } from 'angular2/core';
import {isPresent, StringWrapper, NumberWrapper} from 'angular2/src/facade/lang'; import {isPresent, StringWrapper, NumberWrapper} from 'angular2/src/facade/lang';
import {ObservableWrapper, EventEmitter} from 'angular2/src/facade/async'; import {ObservableWrapper, EventEmitter} from 'angular2/src/facade/async';
@ -42,9 +41,7 @@ var _uniqueIdCounter: number = 0;
// TODO(jelbourn): Remove ^ when event retargeting is fixed. // TODO(jelbourn): Remove ^ when event retargeting is fixed.
'(keydown)': 'onKeydown($event)', '(keydown)': 'onKeydown($event)',
'[tabindex]': 'tabindex', '[tabindex]': 'tabindex',
} },
})
@View({
templateUrl: 'package:angular2_material/src/components/radio/radio_group.html', templateUrl: 'package:angular2_material/src/components/radio/radio_group.html',
encapsulation: ViewEncapsulation.None encapsulation: ViewEncapsulation.None
}) })
@ -198,9 +195,7 @@ export class MdRadioGroup implements OnChanges {
'[attr.aria-checked]': 'checked', '[attr.aria-checked]': 'checked',
'[attr.aria-disabled]': 'disabled', '[attr.aria-disabled]': 'disabled',
'(keydown)': 'onKeydown($event)', '(keydown)': 'onKeydown($event)',
} },
})
@View({
templateUrl: 'package:angular2_material/src/components/radio/radio_button.html', templateUrl: 'package:angular2_material/src/components/radio/radio_button.html',
directives: [], directives: [],
encapsulation: ViewEncapsulation.None encapsulation: ViewEncapsulation.None

View File

@ -1,4 +1,4 @@
import {Injectable} from 'angular2/angular2'; import {Injectable} from 'angular2/core';
/** /**
* Class for radio buttons to coordinate unique selection based on name. * Class for radio buttons to coordinate unique selection based on name.

View File

@ -1,4 +1,4 @@
import {Component, View, ViewEncapsulation, Attribute} from 'angular2/angular2'; import {Component, ViewEncapsulation, Attribute} from 'angular2/core';
import {MdCheckbox} from "../checkbox/checkbox"; import {MdCheckbox} from "../checkbox/checkbox";
// TODO(jelbourn): add gesture support // TODO(jelbourn): add gesture support
@ -12,9 +12,7 @@ import {MdCheckbox} from "../checkbox/checkbox";
'[attr.aria-checked]': 'checked', '[attr.aria-checked]': 'checked',
'[attr.aria-disabled]': 'disabled_', '[attr.aria-disabled]': 'disabled_',
'(keydown)': 'onKeydown($event)', '(keydown)': 'onKeydown($event)',
} },
})
@View({
templateUrl: 'package:angular2_material/src/components/switcher/switch.html', templateUrl: 'package:angular2_material/src/components/switcher/switch.html',
directives: [], directives: [],
encapsulation: ViewEncapsulation.None encapsulation: ViewEncapsulation.None