mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-19 03:32:21 +08:00
@ -9,7 +9,7 @@ import {
|
||||
import {Ion} from '../ion';
|
||||
import {IonInput} from '../form/input';
|
||||
import {IonicConfig} from '../../config/config';
|
||||
import {IonicComponent, IonicView} from '../../config/decorators';
|
||||
import {IonicComponent} from '../../config/decorators';
|
||||
|
||||
/**
|
||||
* The checkbox is no different than the HTML checkbox input, except it's styled differently
|
||||
@ -42,7 +42,7 @@ import {IonicComponent, IonicView} from '../../config/decorators';
|
||||
'(click)': 'click($event)'
|
||||
}
|
||||
})
|
||||
@IonicView({
|
||||
@View({
|
||||
template:
|
||||
'<media-checkbox disable-activated>' +
|
||||
'<checkbox-icon></checkbox-icon>' +
|
||||
|
@ -1,6 +1,7 @@
|
||||
import {Component, Directive, View, Optional, ElementRef, TemplateRef, forwardRef, Inject} from 'angular2/angular2';
|
||||
|
||||
import {Ion} from '../ion';
|
||||
import {Icon} from '../icon/icon';
|
||||
import {ToolbarBase} from '../toolbar/toolbar';
|
||||
import {IonicConfig} from '../../config/config';
|
||||
import {IonicView} from '../../config/decorators';
|
||||
@ -54,7 +55,7 @@ class BackButtonText extends Ion {
|
||||
'class': 'toolbar'
|
||||
}
|
||||
})
|
||||
@IonicView({
|
||||
@View({
|
||||
template:
|
||||
'<div class="toolbar-inner">' +
|
||||
'<button class="back-button">' +
|
||||
@ -69,7 +70,7 @@ class BackButtonText extends Ion {
|
||||
'<ng-content select="ion-nav-items[secondary]"></ng-content>' +
|
||||
'</div>' +
|
||||
'<div class="toolbar-background"></div>',
|
||||
directives: [BackButton, BackButtonText]
|
||||
directives: [BackButton, BackButtonText, Icon]
|
||||
})
|
||||
export class Navbar extends ToolbarBase {
|
||||
constructor(
|
||||
|
@ -1,6 +1,6 @@
|
||||
import {ElementRef, Host, Optional, NgControl, Query, QueryList} from 'angular2/angular2';
|
||||
import {ElementRef, Host, Optional, NgControl, Query, QueryList, View} from 'angular2/angular2';
|
||||
|
||||
import {IonicDirective, IonicComponent, IonicView} from '../../config/decorators';
|
||||
import {IonicDirective, IonicComponent} from '../../config/decorators';
|
||||
import {IonicConfig} from '../../config/config';
|
||||
import {Ion} from '../ion';
|
||||
import {ListHeader} from '../list/list';
|
||||
@ -182,7 +182,7 @@ export class RadioGroup extends Ion {
|
||||
'(click)': 'click($event)'
|
||||
}
|
||||
})
|
||||
@IonicView({
|
||||
@View({
|
||||
template:
|
||||
'<ion-item-content id="{{labelId}}">' +
|
||||
'<ng-content></ng-content>' +
|
||||
|
@ -1,9 +1,9 @@
|
||||
import {ElementRef, Pipe, NgControl, Renderer} from 'angular2/angular2';
|
||||
import {ElementRef, Pipe, NgControl, Renderer, View} from 'angular2/angular2';
|
||||
//import {ControlGroup} from 'angular2/forms'
|
||||
|
||||
import {Ion} from '../ion';
|
||||
import {IonicConfig} from '../../config/config';
|
||||
import {IonicComponent, IonicView} from '../../config/decorators';
|
||||
import {IonicComponent} from '../../config/decorators';
|
||||
|
||||
/**
|
||||
* TODO
|
||||
@ -20,7 +20,7 @@ import {IonicComponent, IonicView} from '../../config/decorators';
|
||||
'placeholder': 'Search'
|
||||
}
|
||||
})
|
||||
@IonicView({
|
||||
@View({
|
||||
template: `
|
||||
<div class="search-bar-input-container" [class.left-align]="shouldLeftAlign">
|
||||
<div class="search-bar-search-icon"></div>
|
||||
|
@ -13,7 +13,7 @@ import {
|
||||
import {Ion} from '../ion';
|
||||
import {IonInput} from '../form/input';
|
||||
import {IonicConfig} from '../../config/config';
|
||||
import {IonicComponent, IonicView} from '../../config/decorators';
|
||||
import {IonicComponent} from '../../config/decorators';
|
||||
import {pointerCoord} from '../../util/dom';
|
||||
|
||||
/**
|
||||
@ -99,7 +99,7 @@ class MediaSwitch {
|
||||
'(mouseup)': 'pointerUp($event)'
|
||||
}
|
||||
})
|
||||
@IonicView({
|
||||
@View({
|
||||
template:
|
||||
'<ng-content select="[item-left]"></ng-content>' +
|
||||
'<ion-item-content id="{{labelId}}">' +
|
||||
|
@ -66,7 +66,7 @@ import * as dom from 'ionic/util/dom';
|
||||
'tabBarIcons': 'top'
|
||||
}
|
||||
})
|
||||
@IonicView({
|
||||
@View({
|
||||
template: '' +
|
||||
'<section class="navbar-container">' +
|
||||
'<template navbar-anchor></template>' +
|
||||
|
@ -2,7 +2,6 @@ import {Component, Directive, View, Host, ElementRef, Optional, forwardRef, Inje
|
||||
|
||||
import {Ion} from '../ion';
|
||||
import {IonicConfig} from '../../config/config';
|
||||
import {IonicView} from '../../config/decorators';
|
||||
import {MenuToggle} from '../menu/menu-toggle';
|
||||
import {Navbar} from '../nav-bar/nav-bar';
|
||||
|
||||
@ -62,7 +61,7 @@ export class ToolbarBase extends Ion {
|
||||
'class': 'toolbar'
|
||||
}
|
||||
})
|
||||
@IonicView({
|
||||
@View({
|
||||
template:
|
||||
'<div class="toolbar-inner">' +
|
||||
'<ng-content select="[menu-toggle]"></ng-content>' +
|
||||
|
@ -1,24 +1,35 @@
|
||||
import {CORE_DIRECTIVES, FORM_DIRECTIVES, forwardRef} from 'angular2/angular2'
|
||||
|
||||
import {
|
||||
OverlayAnchor,
|
||||
Menu, MenuToggle, MenuClose,
|
||||
Button, Content, Scroll, Refresher,
|
||||
Slides, Slide, SlideLazy,
|
||||
Tabs, Tab,
|
||||
Card, List, ListHeader, Item, ItemGroup, ItemGroupTitle,
|
||||
Toolbar, ToolbarTitle, ToolbarItem,
|
||||
Icon,
|
||||
Checkbox, Switch,
|
||||
TextInput, TextInputElement, Label,
|
||||
Segment, SegmentButton, SegmentControlValueAccessor,
|
||||
RadioGroup, RadioButton, SearchBar,
|
||||
Nav, NavbarTemplate, Navbar,
|
||||
NavPush, NavPop, NavRouter,
|
||||
IdRef,
|
||||
ShowWhen, HideWhen
|
||||
} from '../ionic';
|
||||
|
||||
import {OverlayAnchor} from '../components/overlay/overlay';
|
||||
import {Menu} from '../components/menu/menu';
|
||||
import {MenuToggle} from '../components/menu/menu-toggle';
|
||||
import {MenuClose} from '../components/menu/menu-close';
|
||||
import {Button} from '../components/button/button';
|
||||
import {Content} from '../components/content/content';
|
||||
import {Scroll} from '../components/scroll/scroll';
|
||||
import {Refresher} from '../components/scroll/pull-to-refresh';
|
||||
import {Slides, Slide, SlideLazy} from '../components/slides/slides';
|
||||
import {Tabs} from '../components/tabs/tabs';
|
||||
import {Tab} from '../components/tabs/tab';
|
||||
import {Card} from '../components/card/card';
|
||||
import {List, ListHeader} from '../components/list/list';
|
||||
import {Item} from '../components/item/item';
|
||||
import {ItemGroup, ItemGroupTitle} from '../components/item/item-group';
|
||||
import {Toolbar, ToolbarTitle, ToolbarItem} from '../components/toolbar/toolbar';
|
||||
import {Icon} from '../components/icon/icon';
|
||||
import {Checkbox} from '../components/checkbox/checkbox';
|
||||
import {Switch} from '../components/switch/switch';
|
||||
import {TextInput, TextInputElement} from '../components/text-input/text-input';
|
||||
import {Label} from '../components/text-input/label';
|
||||
import {Segment, SegmentButton, SegmentControlValueAccessor} from '../components/segment/segment';
|
||||
import {RadioGroup, RadioButton} from '../components/radio/radio';
|
||||
import {SearchBar} from '../components/search-bar/search-bar';
|
||||
import {Nav} from '../components/nav/nav';
|
||||
import {NavPush, NavPop} from '../components/nav/nav-push';
|
||||
import {NavRouter} from '../components/nav/nav-router';
|
||||
import {NavbarTemplate, Navbar} from '../components/nav-bar/nav-bar';
|
||||
import {IdRef} from '../components/app/id';
|
||||
import {ShowWhen, HideWhen} from '../components/show-hide-when/show-hide-when';
|
||||
|
||||
/**
|
||||
* The core Ionic directives. Automatically available in every
|
||||
@ -30,63 +41,63 @@ export const IONIC_DIRECTIVES = [
|
||||
FORM_DIRECTIVES,
|
||||
|
||||
// Content
|
||||
forwardRef(() => OverlayAnchor),
|
||||
forwardRef(() => Menu),
|
||||
forwardRef(() => MenuToggle),
|
||||
forwardRef(() => MenuClose),
|
||||
OverlayAnchor,
|
||||
Menu,
|
||||
MenuToggle,
|
||||
MenuClose,
|
||||
|
||||
forwardRef(() => Button),
|
||||
forwardRef(() => Content),
|
||||
forwardRef(() => Scroll),
|
||||
forwardRef(() => Refresher),
|
||||
Button,
|
||||
Content,
|
||||
Scroll,
|
||||
Refresher,
|
||||
|
||||
// Lists
|
||||
forwardRef(() => Card),
|
||||
forwardRef(() => List),
|
||||
forwardRef(() => ListHeader),
|
||||
forwardRef(() => Item),
|
||||
forwardRef(() => ItemGroup),
|
||||
forwardRef(() => ItemGroupTitle),
|
||||
Card,
|
||||
List,
|
||||
ListHeader,
|
||||
Item,
|
||||
ItemGroup,
|
||||
ItemGroupTitle,
|
||||
|
||||
// Slides
|
||||
forwardRef(() => Slides),
|
||||
forwardRef(() => Slide),
|
||||
forwardRef(() => SlideLazy),
|
||||
Slides,
|
||||
Slide,
|
||||
SlideLazy,
|
||||
|
||||
// Tabs
|
||||
forwardRef(() => Tabs),
|
||||
forwardRef(() => Tab),
|
||||
Tabs,
|
||||
Tab,
|
||||
|
||||
// Toolbar
|
||||
forwardRef(() => Toolbar),
|
||||
forwardRef(() => ToolbarTitle),
|
||||
forwardRef(() => ToolbarItem),
|
||||
Toolbar,
|
||||
ToolbarTitle,
|
||||
ToolbarItem,
|
||||
|
||||
// Media
|
||||
forwardRef(() => Icon),
|
||||
Icon,
|
||||
|
||||
// Forms
|
||||
forwardRef(() => Segment),
|
||||
forwardRef(() => SegmentButton),
|
||||
forwardRef(() => SegmentControlValueAccessor),
|
||||
forwardRef(() => Checkbox),
|
||||
forwardRef(() => RadioGroup),
|
||||
forwardRef(() => RadioButton),
|
||||
forwardRef(() => Switch),
|
||||
forwardRef(() => TextInput),
|
||||
forwardRef(() => TextInputElement),
|
||||
forwardRef(() => Label),
|
||||
Segment,
|
||||
SegmentButton,
|
||||
SegmentControlValueAccessor,
|
||||
Checkbox,
|
||||
RadioGroup,
|
||||
RadioButton,
|
||||
Switch,
|
||||
TextInput,
|
||||
TextInputElement,
|
||||
Label,
|
||||
|
||||
// Nav
|
||||
forwardRef(() => Nav),
|
||||
forwardRef(() => NavbarTemplate),
|
||||
forwardRef(() => Navbar),
|
||||
Nav,
|
||||
NavbarTemplate,
|
||||
Navbar,
|
||||
|
||||
forwardRef(() => NavPush),
|
||||
forwardRef(() => NavPop),
|
||||
forwardRef(() => NavRouter),
|
||||
forwardRef(() => IdRef),
|
||||
NavPush,
|
||||
NavPop,
|
||||
NavRouter,
|
||||
IdRef,
|
||||
|
||||
forwardRef(() => ShowWhen),
|
||||
forwardRef(() => HideWhen)
|
||||
ShowWhen,
|
||||
HideWhen
|
||||
];
|
||||
|
Reference in New Issue
Block a user