Update everything
This commit is contained in:
parent
bf368181a4
commit
72a485d6e8
319 changed files with 67958 additions and 13948 deletions
64
lib/angular/docs/partials/api/ng.directive:ngList.html
Normal file
64
lib/angular/docs/partials/api/ng.directive:ngList.html
Normal file
|
@ -0,0 +1,64 @@
|
|||
<h1><code ng:non-bindable="">ngList</code>
|
||||
<span class="hint">(directive in module <code ng:non-bindable="">ng</code>
|
||||
)</span>
|
||||
</h1>
|
||||
<div><h2 id="Description">Description</h2>
|
||||
<div class="description"><p>Text input that converts between comma-separated string into an array of strings.</p></div>
|
||||
<h2 id="Usage">Usage</h2>
|
||||
<div class="usage">as attribute<pre class="prettyprint linenums"><input ng-list="{string}">
|
||||
...
|
||||
</input></pre>
|
||||
as class<pre class="prettyprint linenums"><input class="ng-list: {string};">
|
||||
...
|
||||
</input></pre>
|
||||
<h3 id="Parameters">Parameters</h3>
|
||||
<ul class="parameters"><li><code ng:non-bindable="">ngList<i>(optional)</i> – {string=} – </code>
|
||||
<p>optional delimiter that should be used to split the value. If
|
||||
specified in form <code>/something/</code> then the value will be converted into a regular expression.</p></li>
|
||||
</ul>
|
||||
</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-138" source-edit-css="" source-edit-js="script.js-137" source-edit-unit="" source-edit-scenario="scenario.js-139"></div>
|
||||
<div class="tabbable"><div class="tab-pane" title="index.html">
|
||||
<pre class="prettyprint linenums" ng-set-text="index.html-138" ng-html-wrap=" angular.js script.js"></pre>
|
||||
<script type="text/ng-template" id="index.html-138">
|
||||
|
||||
<form name="myForm" ng-controller="Ctrl">
|
||||
List: <input name="namesInput" ng-model="names" ng-list required>
|
||||
<span class="error" ng-show="myForm.list.$error.required">
|
||||
Required!</span>
|
||||
<tt>names = {{names}}</tt><br/>
|
||||
<tt>myForm.namesInput.$valid = {{myForm.namesInput.$valid}}</tt><br/>
|
||||
<tt>myForm.namesInput.$error = {{myForm.namesInput.$error}}</tt><br/>
|
||||
<tt>myForm.$valid = {{myForm.$valid}}</tt><br/>
|
||||
<tt>myForm.$error.required = {{!!myForm.$error.required}}</tt><br/>
|
||||
</form>
|
||||
</script>
|
||||
</div>
|
||||
<div class="tab-pane" title="script.js">
|
||||
<pre class="prettyprint linenums" ng-set-text="script.js-137"></pre>
|
||||
<script type="text/ng-template" id="script.js-137">
|
||||
function Ctrl($scope) {
|
||||
$scope.names = ['igor', 'misko', 'vojta'];
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
<div class="tab-pane" title="End to end test">
|
||||
<pre class="prettyprint linenums" ng-set-text="scenario.js-139"></pre>
|
||||
<script type="text/ng-template" id="scenario.js-139">
|
||||
it('should initialize to model', function() {
|
||||
expect(binding('names')).toEqual('["igor","misko","vojta"]');
|
||||
expect(binding('myForm.namesInput.$valid')).toEqual('true');
|
||||
});
|
||||
|
||||
it('should be invalid if empty', function() {
|
||||
input('names').enter('');
|
||||
expect(binding('names')).toEqual('[]');
|
||||
expect(binding('myForm.namesInput.$valid')).toEqual('false');
|
||||
});
|
||||
</script>
|
||||
</div>
|
||||
</div><h4>Demo</h4>
|
||||
<div class="well doc-example-live" ng-embed-app="" ng-set-html="index.html-138" ng-eval-javascript="script.js-137"></div></div>
|
||||
</div>
|
Loading…
Add table
Add a link
Reference in a new issue