mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2026-03-13 10:22:08 +08:00
tim checkbox
This commit is contained in:
@@ -6,13 +6,14 @@ import {View} from 'angular2/src/core/annotations_impl/view';
|
||||
|
||||
//import {ControlGroup, ControlDirective} from 'angular2/forms';
|
||||
import {IonicComponent} from '../../config/component';
|
||||
import {Icon} from '../icon/icon';
|
||||
|
||||
|
||||
@IonicComponent(Checkbox)
|
||||
@View({
|
||||
template: `
|
||||
<div class="item-media media-checkbox">
|
||||
<icon class="checkbox-off"></icon>
|
||||
<icon [name]="timsIcon" class="checkbox-off"></icon>
|
||||
<icon class="checkbox-on"></icon>
|
||||
</div>
|
||||
|
||||
@@ -20,7 +21,8 @@ import {IonicComponent} from '../../config/component';
|
||||
<div class="item-label">
|
||||
<content></content>
|
||||
</div>
|
||||
</div>`
|
||||
</div>`,
|
||||
directives: [Icon]
|
||||
})
|
||||
export class Checkbox {
|
||||
|
||||
@@ -49,6 +51,9 @@ export class Checkbox {
|
||||
) {
|
||||
this.domElement = elementRef.domElement
|
||||
this.domElement.classList.add('item')
|
||||
|
||||
this.timsIcon = 'hi-tim'
|
||||
|
||||
// this.controlDirective = cd;
|
||||
// cd.valueAccessor = this;
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ import {IonicComponent} from '../../config/component';
|
||||
template: `
|
||||
<nav class="navbar-container tab-bar-container">
|
||||
<div class="tab-bar" role="tablist">
|
||||
<button *ng-for="#t of tabs" [tab]="t" class="tab-button" role="tab">
|
||||
<button *ng-for="#t of tabs" class="tab-button" role="tab">
|
||||
<icon [name]="t.tabIcon" class="tab-button-icon"></icon>
|
||||
<span class="tab-button-text">{{t.tabTitle}}</span>
|
||||
</button>
|
||||
|
||||
5
ionic/config/config.js
Normal file
5
ionic/config/config.js
Normal file
@@ -0,0 +1,5 @@
|
||||
|
||||
|
||||
export class IonicConfig {
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user