aboutsummaryrefslogtreecommitdiffstats
path: root/test/ng/directive/ngRepeatSpec.js
AgeCommit message (Collapse)Author
2013-10-11fix($compile): abort compilation when duplicate element transclusionIgor Minar
Issue an error and abort compilation when two directives that ask for transclusion are found on a single element. This configuration is not supported and we previously failed to issue the error because in the case of element transclusion the compilation is re-started and this caused the compilation context to be lost. The ngRepeat directive has been special-cased to bypass this warning because it knows how to handle this scenario internally. This is not an ideal solution to the problem of multiple transclusions per element, we are hoping to have this configuration supported by the compiler in the future. See #4357. Closes #3893 Closes #4217 Closes #3307
2013-10-09feat(ngRepeat): use block separator commentsjankuca
Issue: multi-elements ng-repeat (ng-repeat-start, ng-repeat-end) can contain elements with a trancluding directive. This directive changes content of the row (template) and ng-repeat does not work correctly (when removing/moving rows), because ng-repeat works with the original template (elements). This changes ng-repeat behavior to traverse the DOM to find current elements everytime we are moving/removing rows (if the template has multiple elements). Closes #3104
2013-10-07fix(*): protect calls to hasOwnProperty in public APIPeter Bacon Darwin
Objects received from outside AngularJS may have had their `hasOwnProperty` method overridden with something else. In cases where we can do this without incurring a performance penalty we call directly on Object.prototype.hasOwnProperty to ensure that we use the correct method. Also, we have some internal hash objects, where the keys for the map are provided from outside AngularJS. In such cases we either prevent `hasOwnProperty` from being used as a key or provide some other way of preventing our objects from having their `hasOwnProperty` overridden. BREAKING CHANGE: Inputs with name equal to "hasOwnProperty" are not allowed inside form or ngForm directives. Before, inputs whose name was "hasOwnProperty" were quietly ignored and not added to the scope. Now a badname exception is thrown. Using "hasOwnProperty" for an input name would be very unusual and bad practice. Either do not include such an input in a `form` or `ngForm` directive or change the name of the input. Closes #3331
2013-09-25fix(ngRepeat): correctly track elements even when the collection is ↵jankuca
initially undefined Previously if the collection model was set to undefined on the first digest, the repeater would get confused and not use the correct tracking function for associating model with dom elements in the repeater. Closes #4145 Closes #3964
2013-08-15feat(minerr): log minerr doc url in developmentKen Sheedlo
Closes #3566
2013-08-02chore(ngMock): rename $animate.process to $animate.flushNext()Matias Niemelä
2013-07-31fix(isArrayLike) Correctly detect arrayLike itemsDaniel Herman
Change the implementation of isArrayLike to use one heavily based on the implementation in jQuery in order to correctly detect array-like objects, that way functionality like ngRepeat works as expected.
2013-07-26feat(ngAnimate): complete rewrite of animationsMatias Niemelä
- ngAnimate directive is gone and was replaced with class based animations/transitions - support for triggering animations on css class additions and removals - done callback was added to all animation apis - $animation and $animator where merged into a single $animate service with api: - $animate.enter(element, parent, after, done); - $animate.leave(element, done); - $animate.move(element, parent, after, done); - $animate.addClass(element, className, done); - $animate.removeClass(element, className, done); BREAKING CHANGE: too many things changed, we'll write up a separate doc with migration instructions
2013-07-24feat(ngRepeat): add $even and $odd props to iteratorP. Envall
2013-07-24fix(ngRepeat): handle iteration over identical obj valuesRory Douglas
Modifies default trackByIdFn to factor both key and value into hashKey for non-array primitive (i.e. index not provided) values Closes #2787 Closes #2806
2013-07-18test(ngRepeat): add a test for ngRepeat when using 'track by' and a filterBrian Ford
2013-07-15fix($animator): ensure animations are always disabled for an element that is ↵Matias Niemelä
not attached to the DOM
2013-07-02fix($compile): prevent infinite loop w/ replace+transclude directivesIgor Minar
Previously if a template contained a directive that had a template (sync or async) and the directive template was to replace the original element and the directive template contained another directive on the root element of this template and this new directive was an element transclude directive then an infinite recursion would follow because the compiler kept on re-adding and reapplying the original directive to the replaced node. This change fixes that. Closes #2155
2013-07-02test(ngRepeat): disable an element directive test on IE8Igor Minar
2013-07-02revert: test(ngRepeat): fix IE8 test compatibility issueIgor Minar
This reverts commit 0c6fb665a4e2e1e7ceb11372153963658d4b53b1. The change invalidated the test because the point of the the test was to test that an element directive works. Changing it to attribute directive was wrong.
2013-07-01test(ngRepeat): fix IE8 test compatibility issueIgor Minar
2013-06-28style(ngRepeatSpec): fix up colons and iitPete Bacon Darwin
2013-06-27fix(compiler): corrects component transclusion on compilation root.Igor Minar
Closes# 2155
2013-06-17chore(minErr): replace ngError with minErrKen Sheedlo
2013-06-11fix(ngRepeat): support growing over multi-element groupsMisko Hevery
2013-05-24feat(ngError): add error message compression and better error messagesIgor Minar
- add toThrowNg matcher
2013-05-08chore(ngAnimate): CSS classes X-setup/X-start -> X/X-activeMatias Niemelä
BREAKING CHANGE: css classes foo-setup/foo-start become foo/foo-active The CSS transition classes have changed suffixes. To migrate rename .foo-setup {...} to .foo {...} .foo-start {...} to .foo-active {...} or for type: enter, leave, move, show, hide .foo-type-setup {...} to .foo-type {...} .foo-type-start {...} to .foo-type-active {...}
2013-05-08feat($sniffer): Add support for supportsAnimations flag for detecting CSS ↵Matias Niemelä
Animations browser support
2013-05-02fix(ngRepeat): correctly iterate over array-like objectsGonzalo Ruiz de Villa
Check if the object is array-like to iterate over it like it's done with arrays. Closes #2546
2013-05-01test(ngAnimate): also provide W3C transition property to work on IE10Pete Bacon Darwin
Closes: #2492
2013-04-11fix(ngAnimate): prevent animation on initial page loadMisko Hevery
2013-04-11fix(ngRepeat): prevent initial duplicatesMisko Hevery
2013-04-11fix(ngAnimate): skip animation on first renderMatias Niemelä
2013-04-02feat(ngAnimate): add support for animationMisko Hevery
2013-03-29feat(ngRepeat): add support for custom tracking of itemsMisko Hevery
BREAKING CHANGE: It is considered an error to have two items produce the same track by key. (This was tolerated before.)
2013-01-17fix(ngRepeat): correctly apply $last if repeating over objectPete Bacon Darwin
If the $last property is calculated from the original collectionLength on an object and properties starting with $ were filtered out, then $last is never applied and $middle is applied erroniously. Closes #1789
2012-11-26fix(ngRepeat): support mostly-stable repeating for primitivesIgor Minar
I'm reverting changes that were originally done to ngRepeat to fix #933, because these are now not necessary after the previous changes to keep ngModel always synced with the DOM.
2012-11-26test(ngRepeat): clean up and improve testsIgor Minar
2012-11-26test(ngRepeat): add test for issue #1076Igor Minar
2012-09-06fix(ngRepeat): now works with primitive typesZhenbo Zhang
closes #933
2012-08-31revert: fix(ng-repeat) to work with primitive typesIgor Minar
this was accidentaly merged in. the commit is not ready yet and we don't have CLA signature. This reverts commit 98d489712eff7559bce87ae53bd242112a875c1a.
2012-08-30fix(ng-repeat) to work with primitive typesZhenbo Zhang
2012-05-22fix(ngRepeat): expose $first, $middle and $last instead of $positionMax
$position marker doesn't work well in cases when we have just one item in the list because then the item is both the first and last. To solve this properly we need to expose individual $first and $middle and $last flags. BREAKING CHANGE: $position is not exposed in repeater scopes any more To update, search for $position and replace it with one of $first, $middle or $last. Closes #912
2012-04-09chore(tests): rename all directive names to the normalized formIgor Minar
2012-04-09fix(docs): change all directive references to use the normalized namesIgor Minar
2012-03-28chore(module): move files around in preparation for more modulesMisko Hevery