aboutsummaryrefslogtreecommitdiffstats
path: root/src/Angular.js
AgeCommit message (Collapse)Author
2014-02-27docs(core): update fromJson return valueslinclark
Dates are not returned, so remove Date from list of return values. Closes #3070
2014-02-26docs(*): fix jsdoc type expressionsPeter Bacon Darwin
These errors in the docs were preventing some parts of the docs from being parsed.
2014-02-21fix(isElement): reduce false-positives in isElement testsCaitlin Potter
Complimentary change to match changed $parse behaviour.
2014-02-20docs(core): add note that isObject returns true for arrayscnlevy
Closes #6353
2014-02-18style: remove ws and enfore no-trailing-ws jscs ruleIgor Minar
2014-02-16docs(bike-shed-migration): fix url-based links refs to AUTO modulePeter Bacon Darwin
2014-02-16docs(bike-shed-migration): convert <doc:...> examples to <example>...Peter Bacon Darwin
2014-02-16docs(all): convert <pre>/</pre> snippets to GFM snippetsCaitlin Potter
2014-02-16docs(bike-shed-migration): convert doctype and namesPeter Bacon Darwin
2014-02-16docs(bike-shed-migration): move ng module doc into Angular.jsPeter Bacon Darwin
2014-02-16docs(bike-shed-migration): Add missing module tagPeter Bacon Darwin
The generator is able to imply the module from the containing folder for most files but these are in the ng module but are stored at the root folder.
2014-02-11docs(core): add closing tag to ngApp directive exampleJesse Palmer
added missing closing tag to ngApp example. Closes #6066
2014-02-11feat(filterFilter): support deeply nested predicate objectsCaitlin Potter
Due to 339a165, it became impossible to filter nested properties of an object using the filterFilter. A proposed solution to this was to enable the use of nested predicate objects. This change enables the use of these nested predicate objects. Example: ```html <div ng-repeat="it in items | filter:{ address: { country: 'Canuckistan'}}"></div> ``` Or ```js $filter('filter')(items, { address: { country: 'Canuckistan' } }); ``` Closes #6215 Related to #6009
2014-02-05docs(angular.forEach): add missing space in testFranziskus Domig
Closes #6130
2014-02-05docs(forEach): correct spelling errorHopiu
Closes #6124
2014-02-04fix(ngResource): don't filter "$"-prefixed properties from ngResource ↵Thomas Belin
requests/responses ngResource no longer filters properties prefixed with a single "$" character from requests or responses, correcting a regression introduced in 1.2.6 (cb29632a) which caused shallowCopy and shallowClearAndCopy to ignore properties prefixed with a single "$". Closes #5666 Closes #6080 Closes #6033
2014-01-13docs(forEach): remove obsolte noteIgor Minar
2014-01-13docs(angular.forEach): specifies that .forEach filters using .hasOwnPropertyMehul Patel
Closes #5180 Closes #5776
2014-01-02fix(ngShow/ngHide, ngIf): functions with zero args should be truthyBrian Ford
Previously, expressions that were a function with one or more arguments evaluated to true, but functions with zero arguments evaluated to false. This behavior seems both unintentional and undesirable. This patch makes a function truthy regardless of its number of arguments. Closes #5414
2013-12-18fix(forEach): allow looping over result of querySelectorAll in IE8Tobias Bosch
In IE8 the result object of calling `node.querySelectorAll` does not have a `hasOwnPropery` function. However, it should be usable with `forEach`. Related to #5400.
2013-12-17perf: use faster check for $$ prefixKarl Seamon
Use two calls to charAt instead of substr to detect a $$prefix in the shallowCopy functions. This makes shallowCopy 25-50% faster (depending on which browser is used). http://jsperf.com/angular-shallow-copy Closes #5457
2013-12-13perf(jqLite): implement and use the `empty` method in place of `html(‘’)`Michał Gołębiowski
jQuery's elem.html('') is way slower than elem.empty(). As clearing element contents happens quite often in certain scenarios, switching to using .empty() provides a significant performance boost when using Angular with jQuery. Closes #4457
2013-12-13perf: use call and === instead of apply and == in type check functionsKarl Seamon
Updates isDate et al to use call instead of apply and === instead of ==. The change to call brings minor performance improvement and === is just better practice than ==. http://jsperf.com/call-vs-apply-tostring Closes #5295
2013-12-06revert: chore(Angular.js): Use call and === instead of apply and == in type ↵Matias Niemelä
check functions
2013-12-05fix($compile): update cloned elements if the template arrives after the cloningTobias Bosch
If an element has a directive whose content is loaded using `templateUrl`, and the element is cloned using a linking function before the template arrives, the clone needs to be updated as well. This also updates `ngIf` and `ngRepeat` to keep the connection to the clone of a tranclude function, so that they know about the changes a directive with `templateUrl` does to the element in the future. Fixes to #4930.
2013-12-05fix(isElement): return boolean value rather than `truthy` value.Caitlin Potter
angular.isElement currently returns a truthy object/function, or false. This patch aims to correct this behaviour by casting the result of the isElement expression to a boolean value via double-negation. Closes #4519 Closes #4534
2013-12-05chore(Angular.js): Use call and === instead of apply and == in type check ↵Karl Seamon
functions Updates isDate et al to use call instead of apply and === instead of ==. The change to call brings minor performance improvement and === is just better practice than ==. http://jsperf.com/call-vs-apply-tostring Closes #5295
2013-12-03style(Angular.js): fix typo in commentIgor Minar
2013-11-26refactor(angular.js): improve trim performancesunnylost
According to Flagrant Badassery's blog http://blog.stevenlevithan.com/archives/faster-trim-javascript and this comparison http://jsperf.com/trim-function, this trim method is faster. Closes #4406
2013-11-21fix($compile): ensure CSS classes are added and removed only when necessaryMatias Niemelä
When $compile interpolates a CSS class attribute expression it will do so by comparing the CSS class value already present on the element. This may lead to unexpected results when dealing with ngClass values being added and removed therefore it is best that both compile and ngClass delegate addClass/removeClass operations to the same block of code.
2013-11-20fix(ngClass): ensure that ngClass only adds/removes the changed classesMatias Niemelä
ngClass works by removing all the former classes and then adding all the new classes to the element during each watch change operation. This may cause transition animations to never render. The ngClass directive will now only add and remove the classes that change during each watch operation. Closes #4960 Closes #4944
2013-11-18docs(ngApp): improve description and examplePete Bacon Darwin
2013-11-08fix($animate): don't force animations to be enabledIgor Minar
The way that enabling of animations was set up, made it impossible to inject a module into the bootstrap to disable animations for things like end 2 end tests. Now animations are temporarily blocked by setting the animation state to RUNNING during bootstrap, which allows the developer to permanently disable at any point by calling $animate.enabled(false).
2013-11-07feat(jqLite): expose isolateScope() getter similar to scope()Igor Minar
See doc update in the diff for more info. BREAKING CHANGE: jqLite#scope() does not return the isolate scope on the element that triggered directive with isolate scope. Use jqLite#isolateScope() instead.
2013-11-07docs(guide/filter): Refactor filter guide docsTobias Bosch
This refactors the filter guide docs into a single file. Also removes out of date references to the fact that Angular used to enhance Arrays while evaluating expressions.
2013-10-30chore: move getBlockElements to Angular.jsBrian Ford
2013-10-26docs(Angular.js): angular.equals calls itself recursively on objectsthorn0
Closes #4622
2013-10-22style: make jshint happyVojta Jina
2013-10-18fix(csp): fix csp auto-detection and stylesheet injectionIgor Minar
When we refactored , we broke the csp mode because the previous implementation relied on the fact that it was ok to lazy initialize the .csp property, this is not the case any more. Besides, we need to know about csp mode during bootstrap and avoid injecting the stylesheet when csp is active, so I refactored the code to fix both issues. PR #4411 will follow up on this commit and add more improvements. Closes #917 Closes #2963 Closes #4394 Closes #4444 BREAKING CHANGE: triggering ngCsp directive via `ng:csp` attribute is not supported any more. Please use data-ng-csp instead.
2013-10-08docs(angular.equals): fix simple typoMarc Tamlyn
- JavasScript -> Javascript Closes #4323
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-10-03docs(angular.bind): clarify that bind is partial applicationJoe Hanink
The `angular.bind` function reflects the definition of "partial application", which reduces a function's arity rather than transforming a function with n args into a chain of n functions, each having a single arg. curry : f(x,y,z) -> f(x)(y)(z) partial application : f(x,y,z) -> f(x)(y,z) Closes #4239
2013-10-02fix(isArrayLike): correctly handle string primitivesDaniel Luz
Closes #3356
2013-09-30docs(angular.copy): add an example with the two possible argumentsUri Goldshtein
Closes #4179
2013-09-23refactor(angular.toJson): use charAt instead of regexpBoris Serdyuk
Provides a performance improvement when serializing to JSON strings. Closes #4093
2013-09-19doc(ngApp): fix grammarDave Peticolas
2013-09-10docs(angular.copy): clarify corner casesjakub-bochenski
The behaviour when null or undefined was passed was not clear. The exception thrown when source == destination was not documented. Closes #3946
2013-09-05docs(angular.bootstrap): clarify modules parameterPete Bacon Darwin
It was not clear what you could pass to specify modules to load in the `module` parameter of this function. The `modules` parameter takes an array. The main case is to provide a String, which is the name of a "predefined" angular module. The side cases are to provide a Function (or an annotated function in the form of an Array), which will be invoked by the injector as a run block. It is not possible to "define" new modules via this parameter. Closes #3692
2013-08-29fix(core): parse IE11 UA string correctlyChirayu Krishnappa
It's great that IE11 wants to be compatible enough that it doesn't want to be special cased and treated differently. However, as long as one has to have a different code path for IE than for the other supported browsers, we still need to detect and special case it. For instance, our URL parsing code still needs the same workaround the we used for IE10. We still see the same Access denied / TypeError exceptions when setting certain values. FYI, Angular doesn't generally blindly test for IE – we also check the version number. Thanks to modern.ie for the free IE11 test VM. Closes #3682
2013-08-09fix(re-bootstrap): Throw an error when bootstrapping a bootstrapped element.Jeff Cross
Nothing would prevent a user from accidentally calling angular.bootstrap on an element that had already been bootstrapped. If this was done, odd behavior could manifest in an application, causing different scopes to update the same DOM, and causing debugger confusion. This fix adds a check inside of angular.bootstrap to check if the passed-in element already has an injector, and if so, will throw an error.