Update to Angular 1.1.4
This commit is contained in:
parent
72a485d6e8
commit
f5fc1369ad
585 changed files with 48055 additions and 3041 deletions
69
lib/angular/docs/partials/api/ng.directive:ngInclude.html
Normal file → Executable file
69
lib/angular/docs/partials/api/ng.directive:ngInclude.html
Normal file → Executable file
|
@ -2,14 +2,17 @@
|
|||
<span class="hint">(directive in module <code ng:non-bindable="">ng</code>
|
||||
)</span>
|
||||
</h1>
|
||||
<div><h2 id="Description">Description</h2>
|
||||
<div><a href="http://github.com/angular/angular.js/edit/master/src/ng/directive/ngInclude.js" class="improve-docs btn btn-primary">Improve this doc</a><h2 id="Description">Description</h2>
|
||||
<div class="description"><p>Fetches, compiles and includes an external HTML fragment.</p>
|
||||
|
||||
<p>Keep in mind that Same Origin Policy applies to included resources
|
||||
(e.g. ngInclude won't work for cross-domain requests on all browsers and for
|
||||
file:// access on some browsers).</p></div>
|
||||
file:// access on some browsers).</p>
|
||||
|
||||
<p>Additionally, you can also provide animations via the ngAnimate attribute to animate the <strong>enter</strong>
|
||||
and <strong>leave</strong> effects.</p></div>
|
||||
<h2 id="Usage">Usage</h2>
|
||||
<div class="usage">as element (see <a href="guide/ie">IE restrictions</a>)<pre class="prettyprint linenums"><ng-include
|
||||
<div class="usage"><p>This directive can be used as custom element, but we aware of <a href="guide/ie">IE restrictions</a>.</p>as element:<pre class="prettyprint linenums"><ng-include
|
||||
src="{string}"
|
||||
[onload="{string}"]
|
||||
[autoscroll="{string}"]>
|
||||
|
@ -22,7 +25,13 @@ as attribute<pre class="prettyprint linenums"><ANY ng-include="{string}"
|
|||
as class<pre class="prettyprint linenums"><ANY class="ng-include: {string}; [onload: {string};] [autoscroll: {string};]">
|
||||
...
|
||||
</ANY></pre>
|
||||
<h3 id="Directive.info">Directive info</h3>
|
||||
with <span id="animations">animations</span><pre class="prettyprint linenums">//The enter and leave animations are supported
|
||||
<ANY ng-include="{string}"
|
||||
[onload="{string}"]
|
||||
[autoscroll="{string}"] ng-animate="{enter: 'enter-animation', leave: 'leave-animation'}">
|
||||
...
|
||||
</ANY></pre>
|
||||
<a href="api/ng.$animator#Methods">Click here</a> to learn more about the steps involved in the animation.<h3 id="Directive.info">Directive info</h3>
|
||||
<div class="directive-info"><ul><li>This directive creates new scope.</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
@ -41,6 +50,8 @@ make sure you wrap it in quotes, e.g. <code>src="'myPartialTemplate.html'"</code
|
|||
<li>Otherwise enable scrolling only if the expression evaluates to truthy value.</li>
|
||||
</ul></li>
|
||||
</ul>
|
||||
<h3 id="Animations">Animations</h3>
|
||||
<div class="animations"><ul><li>enter - happens just after the ngInclude contents change and a new DOM element is created and injected into the ngInclude container</li><li>leave - happens just after the ngInclude contents change and just before the former contents are removed from the DOM</li></ul></div>
|
||||
</div>
|
||||
<div class="member event"><h2 id="Events">Events</h2>
|
||||
<ul class="events"><li><h3 id="$includeContentLoaded">$includeContentLoaded</h3>
|
||||
|
@ -56,7 +67,7 @@ make sure you wrap it in quotes, e.g. <code>src="'myPartialTemplate.html'"</code
|
|||
</div>
|
||||
<h2 id="Example">Example</h2>
|
||||
<div class="example"><h4>Source</h4>
|
||||
<div source-edit="" source-edit-deps="angular.js script.js" source-edit-html="index.html-159 template1.html template2.html" source-edit-css="" source-edit-js="script.js-160" source-edit-unit="" source-edit-scenario="scenario.js-161"></div>
|
||||
<div source-edit="" source-edit-deps="angular.js script.js" source-edit-html="index.html-159 template1.html template2.html" source-edit-css="animations.css" source-edit-js="script.js-160" source-edit-unit="" source-edit-scenario="scenario.js-161"></div>
|
||||
<div class="tabbable"><div class="tab-pane" title="index.html">
|
||||
<pre class="prettyprint linenums" ng-set-text="index.html-159" ng-html-wrap=" angular.js script.js"></pre>
|
||||
<script type="text/ng-template" id="index.html-159">
|
||||
|
@ -66,22 +77,62 @@ make sure you wrap it in quotes, e.g. <code>src="'myPartialTemplate.html'"</code
|
|||
</select>
|
||||
url of the template: <tt>{{template.url}}</tt>
|
||||
<hr/>
|
||||
<div ng-include src="template.url"></div>
|
||||
<div class="example-animate-container"
|
||||
ng-include="template.url"
|
||||
ng-animate="{enter: 'example-enter', leave: 'example-leave'}"></div>
|
||||
</div>
|
||||
</script>
|
||||
</div>
|
||||
<div class="tab-pane" title="template1.html">
|
||||
<pre class="prettyprint linenums" ng-set-text="template1.html"></pre>
|
||||
<script type="text/ng-template" id="template1.html">
|
||||
Content of template1.html
|
||||
<div>Content of template1.html</div>
|
||||
</script>
|
||||
</div>
|
||||
<div class="tab-pane" title="template2.html">
|
||||
<pre class="prettyprint linenums" ng-set-text="template2.html"></pre>
|
||||
<script type="text/ng-template" id="template2.html">
|
||||
Content of template2.html
|
||||
<div>Content of template2.html</div>
|
||||
</script>
|
||||
</div>
|
||||
<div class="tab-pane" title="animations.css">
|
||||
<pre class="prettyprint linenums" ng-set-text="animations.css"></pre>
|
||||
<style type="text/css" id="animations.css">
|
||||
.example-leave-setup,
|
||||
.example-enter-setup {
|
||||
-webkit-transition:all cubic-bezier(0.250, 0.460, 0.450, 0.940) 0.5s;
|
||||
-moz-transition:all cubic-bezier(0.250, 0.460, 0.450, 0.940) 0.5s;
|
||||
-ms-transition:all cubic-bezier(0.250, 0.460, 0.450, 0.940) 0.5s;
|
||||
-o-transition:all cubic-bezier(0.250, 0.460, 0.450, 0.940) 0.5s;
|
||||
transition:all cubic-bezier(0.250, 0.460, 0.450, 0.940) 0.5s;
|
||||
|
||||
position:absolute;
|
||||
top:0;
|
||||
left:0;
|
||||
right:0;
|
||||
bottom:0;
|
||||
}
|
||||
|
||||
.example-animate-container > * {
|
||||
display:block;
|
||||
padding:10px;
|
||||
}
|
||||
|
||||
.example-enter-setup {
|
||||
top:-50px;
|
||||
}
|
||||
.example-enter-setup.example-enter-start {
|
||||
top:0;
|
||||
}
|
||||
|
||||
.example-leave-setup {
|
||||
top:0;
|
||||
}
|
||||
.example-leave-setup.example-leave-start {
|
||||
top:50px;
|
||||
}
|
||||
</style>
|
||||
</div>
|
||||
<div class="tab-pane" title="script.js">
|
||||
<pre class="prettyprint linenums" ng-set-text="script.js-160"></pre>
|
||||
<script type="text/ng-template" id="script.js-160">
|
||||
|
@ -112,5 +163,5 @@ make sure you wrap it in quotes, e.g. <code>src="'myPartialTemplate.html'"</code
|
|||
</script>
|
||||
</div>
|
||||
</div><h4>Demo</h4>
|
||||
<div class="well doc-example-live" ng-embed-app="" ng-set-html="index.html-159" ng-eval-javascript="script.js-160"></div></div>
|
||||
<div class="well doc-example-live animator-container" ng-embed-app="" ng-set-html="index.html-159" ng-eval-javascript="script.js-160"></div></div>
|
||||
</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue