mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-18 19:21:34 +08:00
docs()
This commit is contained in:
@ -5,23 +5,27 @@ import {extend} from '../util/util';
|
||||
/**
|
||||
Animation Steps/Process
|
||||
-----------------------
|
||||
1) Construct animation (doesn't start)
|
||||
2) Client play()'s animation, returns promise
|
||||
3) Add before classes to elements
|
||||
4) Remove before classes from elements
|
||||
5) Elements staged in "from" effect w/ inline styles
|
||||
6) Call onReady()
|
||||
7) Wait for RENDER_DELAY milliseconds (give browser time to render)
|
||||
8) Call onPlay()
|
||||
8) Run from/to animation on elements
|
||||
9) Animations finish async
|
||||
10) Set inline styles w/ the "to" effects on elements
|
||||
11) Add after classes to elements
|
||||
12) Remove after classes from elements
|
||||
13) Call onFinish()
|
||||
14) Resolve play()'s promise
|
||||
|
||||
- Construct animation (doesn't start)
|
||||
- Client play()'s animation, returns promise
|
||||
- Add before classes to elements
|
||||
- Remove before classes from elements
|
||||
- Elements staged in "from" effect w/ inline styles
|
||||
- Call onReady()
|
||||
- Wait for RENDER_DELAY milliseconds (give browser time to render)
|
||||
- Call onPlay()
|
||||
- Run from/to animation on elements
|
||||
- Animations finish async
|
||||
- Set inline styles w/ the "to" effects on elements
|
||||
- Add after classes to elements
|
||||
- Remove after classes from elements
|
||||
- Call onFinish()
|
||||
- Resolve play()'s promise
|
||||
**/
|
||||
|
||||
/**
|
||||
* @private
|
||||
**/
|
||||
export class Animation {
|
||||
|
||||
constructor(ele, opts={}) {
|
||||
@ -554,6 +558,9 @@ export class Animation {
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* @private
|
||||
**/
|
||||
class Animate {
|
||||
|
||||
constructor(ele, fromEffect, toEffect, duration, easingConfig, playbackRate) {
|
||||
|
@ -1,10 +1,3 @@
|
||||
/**
|
||||
* @ngdoc service
|
||||
* @name ActionSheet
|
||||
* @module ionic
|
||||
* @description
|
||||
* The ActionSheet is a modal menu with options to select based on an action.
|
||||
*/
|
||||
import {Component, Injectable, Renderer} from 'angular2/core';
|
||||
import {NgFor, NgIf} from 'angular2/common';
|
||||
|
||||
|
@ -5,14 +5,28 @@ import {ionicProviders} from '../bootstrap';
|
||||
import {IONIC_DIRECTIVES} from '../directives';
|
||||
|
||||
/**
|
||||
* @ngdoc service
|
||||
* @name App
|
||||
* @module ionic
|
||||
* @param {object} [config] - the app's [../Config](Config) object
|
||||
* @param {string} [template] - the template to use for the app root
|
||||
* @param {string} [templateUrl] - a relative URL pointing to the template to use for the app root
|
||||
* @description
|
||||
* App is an Ionic decorator that bootstraps an application. It can be passed a number of arguments, that act as global config variables for the app.
|
||||
* App can accept a `template` property that has an inline template or a `templateUrl` property that points to an external html template.
|
||||
*
|
||||
* @usage
|
||||
* ```ts
|
||||
* import {App} from 'ionic/ionic';
|
||||
*
|
||||
* @App({
|
||||
* templateUrl: 'app/app.html'
|
||||
* })
|
||||
*
|
||||
* export class MyApp{
|
||||
*
|
||||
* }
|
||||
* ```
|
||||
*
|
||||
* @param {Object} [config] - the app's [../Config](Config) object
|
||||
* @param {String} [template] - the template to use for the app root
|
||||
* @param {String} [templateUrl] - a relative URL pointing to the template to use for the app root
|
||||
*
|
||||
*/
|
||||
export function App(args={}) {
|
||||
|
||||
|
23
scripts/docs/templates/common.template.html
vendored
23
scripts/docs/templates/common.template.html
vendored
@ -27,7 +27,7 @@ angular_controller: APIDemoCtrl <@ endif @>
|
||||
<a href="https://github.com/<$ versionInfo.gitRepoInfo.owner $>/<$ versionInfo.gitRepoInfo.repo $>/tree/master/<$ doc.fileInfo.relativePath $>#L<$ doc.location.start.line+1 $>-L<$ doc.location.end.line+1 $>"><$ doc.fileInfo.relativePath $> (line <$ doc.location.start.line+1 $>)</a>
|
||||
<@- endmacro -@>
|
||||
|
||||
<@ macro paramTable(params, isDirective) @>
|
||||
<@ macro paramTable(params, isDirective) -@>
|
||||
<table class="table" style="margin:0;">
|
||||
<thead>
|
||||
<tr>
|
||||
@ -55,16 +55,17 @@ angular_controller: APIDemoCtrl <@ endif @>
|
||||
<@ endfor @>
|
||||
</tbody>
|
||||
</table>
|
||||
<@ endmacro @>
|
||||
<@- endmacro -@>
|
||||
|
||||
|
||||
<@- macro functionSyntax(fn) @>
|
||||
<@- set sep = joiner(', ') -@>
|
||||
<@- set sep = joiner(', ') -@>
|
||||
<code><$ fn.name $>(<@- for param in fn.params @><$ sep() $>
|
||||
<@- if param.type.optional @>[<@ endif -@>
|
||||
<$ param.name $>
|
||||
<@- if param.type.optional @>]<@ endif -@>
|
||||
<@ endfor @>)</code><@ if fn.alias @><small>(alias: <$ fn.alias $>)</small><@ endif @>
|
||||
<@ endfor @>)</code>
|
||||
<@ if fn.alias @><small>(alias: <$ fn.alias $>)</small><@ endif @>
|
||||
<@ endmacro -@>
|
||||
|
||||
<@ macro typeList(types) -@>
|
||||
@ -86,17 +87,16 @@ angular_controller: APIDemoCtrl <@ endif @>
|
||||
<a href='http://github.com/driftyco/ionic2/edit/master/<$ doc.fileInfo.relativePath $>#L<$ doc.location.start.line $>'>
|
||||
Improve this doc
|
||||
</a>
|
||||
|
||||
</div>
|
||||
|
||||
<@ block content @>
|
||||
|
||||
<@ block header @>
|
||||
|
||||
<h1 class="api-title">
|
||||
|
||||
<@ if doc.docType == "directive" @>
|
||||
<$ doc.name | dashCase $>
|
||||
|
||||
<@ else @>
|
||||
<$ doc.name $>
|
||||
<@ endif @>
|
||||
@ -124,6 +124,7 @@ Delegate: <$ doc.delegate $>
|
||||
<@ endblock @>
|
||||
|
||||
|
||||
<!-- description -->
|
||||
<h2>Description</h2>
|
||||
<@ block description @>
|
||||
<$ doc.description | marked $>
|
||||
@ -135,7 +136,7 @@ Delegate: <$ doc.delegate $>
|
||||
<h3><$ doc.directiveInfo.properties[0].name $>: <code><$ doc.directiveInfo.properties[0].values $></code></h3>
|
||||
<@ endif -@>
|
||||
|
||||
|
||||
<!-- @usage tag -->
|
||||
<@ if doc.usage @>
|
||||
<h2>Usage</h2>
|
||||
<@ block usage @>
|
||||
@ -143,7 +144,7 @@ Delegate: <$ doc.delegate $>
|
||||
<@ endblock @>
|
||||
<@ endif @>
|
||||
|
||||
|
||||
<!-- @property tags -->
|
||||
<@ if doc.properties @>
|
||||
<h2>Attributes:</h2>
|
||||
<table class="table" style="margin:0;">
|
||||
@ -186,6 +187,7 @@ Delegate: <$ doc.delegate $>
|
||||
</table>
|
||||
<@ endif @>
|
||||
|
||||
<!-- methods on the class -->
|
||||
<@- if doc.members and doc.members.length @>
|
||||
|
||||
<h2>Methods</h2>
|
||||
@ -217,10 +219,7 @@ Delegate: <$ doc.delegate $>
|
||||
|
||||
<@- endif -@>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- related link -->
|
||||
<@- if doc.see @>
|
||||
|
||||
<h2>Related</h2>
|
||||
|
Reference in New Issue
Block a user