From eb28c3b137c8a0d61377087c9a04b820151b0b7c Mon Sep 17 00:00:00 2001 From: Bernhard Posselt Date: Thu, 30 Apr 2015 18:30:11 +0200 Subject: update deps --- composer.lock | 29 +- js/vendor/angular-animate/.bower.json | 10 +- js/vendor/angular-animate/angular-animate.js | 369 +++++++++--- js/vendor/angular-animate/angular-animate.min.js | 88 +-- .../angular-animate/angular-animate.min.js.map | 4 +- js/vendor/angular-animate/bower.json | 4 +- js/vendor/angular-animate/package.json | 2 +- js/vendor/angular-mocks/.bower.json | 10 +- js/vendor/angular-mocks/angular-mocks.js | 2 +- js/vendor/angular-mocks/bower.json | 4 +- js/vendor/angular-mocks/package.json | 2 +- js/vendor/angular-route/.bower.json | 10 +- js/vendor/angular-route/angular-route.js | 2 +- js/vendor/angular-route/angular-route.min.js | 2 +- js/vendor/angular-route/bower.json | 4 +- js/vendor/angular-route/package.json | 2 +- js/vendor/angular-sanitize/.bower.json | 10 +- js/vendor/angular-sanitize/angular-sanitize.js | 2 +- js/vendor/angular-sanitize/angular-sanitize.min.js | 2 +- js/vendor/angular-sanitize/bower.json | 4 +- js/vendor/angular-sanitize/package.json | 2 +- js/vendor/angular/.bower.json | 8 +- js/vendor/angular/angular.js | 630 ++++++++++++++------- js/vendor/angular/angular.min.js | 537 +++++++++--------- js/vendor/angular/angular.min.js.gzip | Bin 50718 -> 50995 bytes js/vendor/angular/angular.min.js.map | 6 +- js/vendor/angular/bower.json | 2 +- js/vendor/angular/package.json | 2 +- js/vendor/es6-shim/.bower.json | 8 +- js/vendor/es6-shim/CHANGELOG.md | 17 + js/vendor/es6-shim/bower.json | 2 +- js/vendor/es6-shim/component.json | 2 +- js/vendor/es6-shim/es6-sham.js | 20 +- js/vendor/es6-shim/es6-sham.map | 2 +- js/vendor/es6-shim/es6-sham.min.js | 2 +- js/vendor/es6-shim/es6-shim.js | 500 ++++++++-------- js/vendor/es6-shim/es6-shim.map | 2 +- js/vendor/es6-shim/es6-shim.min.js | 5 +- js/vendor/es6-shim/package.json | 6 +- js/vendor/jquery/.bower.json | 9 +- js/vendor/jquery/bower.json | 3 +- js/vendor/jquery/dist/jquery.js | 13 +- js/vendor/jquery/dist/jquery.min.js | 8 +- js/vendor/jquery/dist/jquery.min.map | 2 +- js/vendor/jquery/src/core.js | 7 +- vendor/composer/autoload_classmap.php | 1 + vendor/composer/autoload_namespaces.php | 1 - vendor/composer/autoload_real.php | 4 - vendor/composer/installed.json | 31 +- vendor/fguillot/picofeed/.gitignore | 3 +- vendor/fguillot/picofeed/.travis.yml | 21 +- vendor/fguillot/picofeed/README.markdown | 1 - .../fguillot/picofeed/docs/feed-parsing.markdown | 21 + vendor/fguillot/picofeed/docs/grabber.markdown | 109 +++- .../fguillot/picofeed/lib/PicoFeed/Client/Curl.php | 7 +- .../picofeed/lib/PicoFeed/Client/Grabber.php | 592 ------------------- .../fguillot/picofeed/lib/PicoFeed/Filter/Html.php | 47 ++ .../fguillot/picofeed/lib/PicoFeed/Filter/Tag.php | 2 +- .../picofeed/lib/PicoFeed/Parser/Parser.php | 31 +- .../lib/PicoFeed/Rules/.blog.lemonde.fr.php | 18 +- .../lib/PicoFeed/Rules/.blogs.nytimes.com.php | 20 +- .../picofeed/lib/PicoFeed/Rules/.igen.fr.php | 16 +- .../picofeed/lib/PicoFeed/Rules/.nytimes.com.php | 13 +- .../picofeed/lib/PicoFeed/Rules/.phoronix.com.php | 13 +- .../picofeed/lib/PicoFeed/Rules/.slate.com.php | 28 +- .../lib/PicoFeed/Rules/.theguardian.com.php | 18 +- .../picofeed/lib/PicoFeed/Rules/.wikipedia.org.php | 48 +- .../picofeed/lib/PicoFeed/Rules/.wired.com.php | 32 +- .../picofeed/lib/PicoFeed/Rules/.wsj.com.php | 18 +- .../picofeed/lib/PicoFeed/Rules/01net.com.php | 24 +- .../lib/PicoFeed/Rules/alainonline.net.php | 18 +- .../lib/PicoFeed/Rules/allgemeine-zeitung.de.php | 35 +- .../picofeed/lib/PicoFeed/Rules/areadvd.de.php | 10 + .../lib/PicoFeed/Rules/awkwardzombie.com.php | 10 + .../picofeed/lib/PicoFeed/Rules/blog.fefe.de.php | 16 +- .../picofeed/lib/PicoFeed/Rules/bunicomic.com.php | 16 +- .../picofeed/lib/PicoFeed/Rules/cad-comic.com.php | 12 + .../lib/PicoFeed/Rules/chaoslife.findchaos.com.php | 10 + .../lib/PicoFeed/Rules/cliquerefresh.com.php | 10 + .../picofeed/lib/PicoFeed/Rules/consomac.fr.php | 16 +- .../picofeed/lib/PicoFeed/Rules/dailyjs.com.php | 26 +- .../lib/PicoFeed/Rules/degroupnews.com.php | 18 +- .../picofeed/lib/PicoFeed/Rules/derstandard.at.php | 18 +- .../lib/PicoFeed/Rules/distrowatch.com.php | 14 +- .../picofeed/lib/PicoFeed/Rules/dozodomo.com.php | 18 +- .../picofeed/lib/PicoFeed/Rules/engadget.com.php | 10 + .../lib/PicoFeed/Rules/escapistmagazine.com.php | 42 ++ .../picofeed/lib/PicoFeed/Rules/explosm.net.php | 16 +- .../lib/PicoFeed/Rules/fastcodesign.com.php | 14 +- .../lib/PicoFeed/Rules/fastcoexist.com.php | 14 +- .../lib/PicoFeed/Rules/fastcompany.com.php | 14 +- .../picofeed/lib/PicoFeed/Rules/ffworld.com.php | 14 +- .../lib/PicoFeed/Rules/fowllanguagecomics.com.php | 10 + .../picofeed/lib/PicoFeed/Rules/github.com.php | 16 +- .../picofeed/lib/PicoFeed/Rules/golem.de.php | 12 +- .../picofeed/lib/PicoFeed/Rules/heise.de.php | 10 +- .../lib/PicoFeed/Rules/huffingtonpost.com.php | 14 +- .../picofeed/lib/PicoFeed/Rules/ing.dk.php | 12 +- .../lib/PicoFeed/Rules/journaldugeek.com.php | 10 +- .../picofeed/lib/PicoFeed/Rules/kanpai.fr.php | 14 +- .../lib/PicoFeed/Rules/karriere.jobfinder.dk.php | 12 +- .../picofeed/lib/PicoFeed/Rules/lejapon.fr.php | 22 +- .../lib/PicoFeed/Rules/lesjoiesducode.fr.php | 14 +- .../picofeed/lib/PicoFeed/Rules/lfg.co.php | 13 + .../picofeed/lib/PicoFeed/Rules/lifehacker.com.php | 24 +- .../fguillot/picofeed/lib/PicoFeed/Rules/lists.php | 14 +- .../lib/PicoFeed/Rules/loadingartist.com.php | 10 + .../picofeed/lib/PicoFeed/Rules/loldwell.com.php | 10 + .../picofeed/lib/PicoFeed/Rules/macg.co.php | 16 +- .../picofeed/lib/PicoFeed/Rules/marc.info.php | 16 +- .../Rules/maximumble.thebookofbiff.com.php | 10 + .../picofeed/lib/PicoFeed/Rules/medium.com.php | 14 +- .../picofeed/lib/PicoFeed/Rules/metronieuws.nl.php | 10 + .../lib/PicoFeed/Rules/mokepon.smackjeeves.com.php | 10 + .../lib/PicoFeed/Rules/monwindowsphone.com.php | 16 +- .../lib/PicoFeed/Rules/neustadt-ticker.de.php | 12 + .../lib/PicoFeed/Rules/niceteethcomic.com.php | 10 + .../picofeed/lib/PicoFeed/Rules/nichtlustig.de.php | 8 + .../lib/PicoFeed/Rules/openrightsgroup.org.php | 30 +- .../picofeed/lib/PicoFeed/Rules/pastebin.com.php | 14 +- .../lib/PicoFeed/Rules/penny-arcade.com.php | 21 + .../lib/PicoFeed/Rules/plus.google.com.php | 12 +- .../lib/PicoFeed/Rules/putaindecode.fr.php | 20 +- .../lib/PicoFeed/Rules/rue89.nouvelobs.com.php | 14 +- .../picofeed/lib/PicoFeed/Rules/satwcomic.com.php | 12 + .../lib/PicoFeed/Rules/scrumalliance.org.php | 12 + .../picofeed/lib/PicoFeed/Rules/sitepoint.com.php | 16 +- .../picofeed/lib/PicoFeed/Rules/slashdot.org.php | 11 + .../lib/PicoFeed/Rules/smallhousebliss.com.php | 26 +- .../lib/PicoFeed/Rules/smarthomewelt.de.php | 10 + .../lib/PicoFeed/Rules/smashingmagazine.com.php | 10 + .../picofeed/lib/PicoFeed/Rules/spiegel.de.php | 10 +- .../fguillot/picofeed/lib/PicoFeed/Rules/sz.de.php | 10 + .../picofeed/lib/PicoFeed/Rules/techcrunch.com.php | 18 +- .../lib/PicoFeed/Rules/thecodinglove.com.php | 10 + .../lib/PicoFeed/Rules/thegamercat.com.php | 10 + .../lib/PicoFeed/Rules/themerepublic.net.php | 10 + .../lib/PicoFeed/Rules/travel-dealz.de.php | 15 + .../picofeed/lib/PicoFeed/Rules/treehugger.com.php | 16 +- .../picofeed/lib/PicoFeed/Rules/twogag.com.php | 9 + .../lib/PicoFeed/Rules/twokinds.keenspot.com.php | 10 + .../picofeed/lib/PicoFeed/Rules/undeadly.org.php | 18 +- .../picofeed/lib/PicoFeed/Rules/version2.dk.php | 12 +- .../picofeed/lib/PicoFeed/Rules/vgcats.com.php | 16 + .../picofeed/lib/PicoFeed/Rules/vuxml.org.php | 22 +- .../picofeed/lib/PicoFeed/Rules/www.bbc.co.uk.php | 36 +- .../picofeed/lib/PicoFeed/Rules/www.bdgest.com.php | 20 +- .../lib/PicoFeed/Rules/www.businessweek.com.php | 20 +- .../picofeed/lib/PicoFeed/Rules/www.cnn.com.php | 36 +- .../lib/PicoFeed/Rules/www.developpez.com.php | 30 +- .../lib/PicoFeed/Rules/www.egscomics.com.php | 12 +- .../picofeed/lib/PicoFeed/Rules/www.forbes.com.php | 28 +- .../lib/PicoFeed/Rules/www.futura-sciences.com.php | 28 +- .../picofeed/lib/PicoFeed/Rules/www.lemonde.fr.php | 24 +- .../picofeed/lib/PicoFeed/Rules/www.lepoint.fr.php | 24 +- .../lib/PicoFeed/Rules/www.mac4ever.com.php | 16 +- .../lib/PicoFeed/Rules/www.nextinpact.com.php | 16 +- .../picofeed/lib/PicoFeed/Rules/www.npr.org.php | 24 +- .../lib/PicoFeed/Rules/www.numerama.com.php | 18 +- .../lib/PicoFeed/Rules/www.pcinpact.com.php | 16 +- .../lib/PicoFeed/Rules/www.pseudo-sciences.org.php | 22 +- .../picofeed/lib/PicoFeed/Rules/www.slate.fr.php | 26 +- .../lib/PicoFeed/Rules/www.universfreebox.com.php | 20 +- .../picofeed/lib/PicoFeed/Rules/xkcd.com.php | 16 +- .../lib/PicoFeed/Scraper/CandidateParser.php | 286 ++++++++++ .../lib/PicoFeed/Scraper/ParserInterface.php | 13 + .../picofeed/lib/PicoFeed/Scraper/RuleLoader.php | 127 +++++ .../picofeed/lib/PicoFeed/Scraper/RuleParser.php | 93 +++ .../picofeed/lib/PicoFeed/Scraper/Scraper.php | 361 ++++++++++++ vendor/fguillot/picofeed/picofeed | 11 +- .../fguillot/picofeed/tests/Client/GrabberTest.php | 152 ----- .../picofeed/tests/Filter/HtmlFilterTest.php | 22 + .../fguillot/picofeed/tests/Reader/ReaderTest.php | 2 +- .../picofeed/tests/Scraper/RuleLoaderTest.php | 86 +++ .../picofeed/tests/Scraper/ScraperTest.php | 89 +++ vendor/pear/net_url2/.travis.yml | 7 + vendor/pear/net_url2/composer.json | 9 +- vendor/pear/net_url2/package.xml | 24 +- 178 files changed, 3976 insertions(+), 2318 deletions(-) delete mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Client/Grabber.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/areadvd.de.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/awkwardzombie.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/cad-comic.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/chaoslife.findchaos.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/cliquerefresh.com.php mode change 100755 => 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/dailyjs.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/engadget.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/escapistmagazine.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/fowllanguagecomics.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/lfg.co.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/loadingartist.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/loldwell.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/maximumble.thebookofbiff.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/metronieuws.nl.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/mokepon.smackjeeves.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/neustadt-ticker.de.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/niceteethcomic.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/nichtlustig.de.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/penny-arcade.com.php mode change 100755 => 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/putaindecode.fr.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/satwcomic.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/scrumalliance.org.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/slashdot.org.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/smarthomewelt.de.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/smashingmagazine.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/sz.de.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/thecodinglove.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/thegamercat.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/themerepublic.net.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/travel-dealz.de.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/twogag.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/twokinds.keenspot.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Rules/vgcats.com.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Scraper/CandidateParser.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Scraper/ParserInterface.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Scraper/RuleLoader.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Scraper/RuleParser.php create mode 100644 vendor/fguillot/picofeed/lib/PicoFeed/Scraper/Scraper.php delete mode 100644 vendor/fguillot/picofeed/tests/Client/GrabberTest.php create mode 100644 vendor/fguillot/picofeed/tests/Scraper/RuleLoaderTest.php create mode 100644 vendor/fguillot/picofeed/tests/Scraper/ScraperTest.php diff --git a/composer.lock b/composer.lock index b349766e2..68302587a 100644 --- a/composer.lock +++ b/composer.lock @@ -57,12 +57,12 @@ "source": { "type": "git", "url": "https://github.com/fguillot/picoFeed.git", - "reference": "6ac3334f272478257d3e4486164bc4e84046f784" + "reference": "a6087e8264550891c1b8a6da77eca0cab9328709" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/fguillot/picoFeed/zipball/6ac3334f272478257d3e4486164bc4e84046f784", - "reference": "6ac3334f272478257d3e4486164bc4e84046f784", + "url": "https://api.github.com/repos/fguillot/picoFeed/zipball/a6087e8264550891c1b8a6da77eca0cab9328709", + "reference": "a6087e8264550891c1b8a6da77eca0cab9328709", "shasum": "" }, "require": { @@ -97,20 +97,20 @@ ], "description": "Modern library to write or read feeds (RSS/Atom)", "homepage": "http://fguillot.github.io/picoFeed", - "time": "2015-04-15 00:10:14" + "time": "2015-04-27 22:22:06" }, { "name": "pear/net_url2", - "version": "v2.1.1", + "version": "v2.2.0", "source": { "type": "git", "url": "https://github.com/pear/Net_URL2.git", - "reference": "cfd234e8484400a122cec44a9d801e71186915ac" + "reference": "fa9b1ecb3c3e640d4a54d58d681a4cb7524f209e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/pear/Net_URL2/zipball/cfd234e8484400a122cec44a9d801e71186915ac", - "reference": "cfd234e8484400a122cec44a9d801e71186915ac", + "url": "https://api.github.com/repos/pear/Net_URL2/zipball/fa9b1ecb3c3e640d4a54d58d681a4cb7524f209e", + "reference": "fa9b1ecb3c3e640d4a54d58d681a4cb7524f209e", "shasum": "" }, "require": { @@ -122,18 +122,15 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "2.2.x-dev" } }, "autoload": { - "psr-0": { - "Net": "" - } + "classmap": [ + "Net/URL2.php" + ] }, "notification-url": "https://packagist.org/downloads/", - "include-path": [ - "./" - ], "license": [ "BSD-3-Clause" ], @@ -161,7 +158,7 @@ "uri", "url" ], - "time": "2014-12-27 14:00:16" + "time": "2015-04-18 17:36:57" } ], "packages-dev": [], diff --git a/js/vendor/angular-animate/.bower.json b/js/vendor/angular-animate/.bower.json index 0f44e04c4..dc1346b69 100644 --- a/js/vendor/angular-animate/.bower.json +++ b/js/vendor/angular-animate/.bower.json @@ -1,17 +1,17 @@ { "name": "angular-animate", - "version": "1.4.0-rc.0", + "version": "1.4.0-rc.1", "main": "./angular-animate.js", "ignore": [], "dependencies": { - "angular": "1.4.0-rc.0" + "angular": "1.4.0-rc.1" }, "homepage": "https://github.com/angular/bower-angular-animate", - "_release": "1.4.0-rc.0", + "_release": "1.4.0-rc.1", "_resolution": { "type": "version", - "tag": "v1.4.0-rc.0", - "commit": "a75c362178f4aac89b1daf1d8e9711f47ffa96da" + "tag": "v1.4.0-rc.1", + "commit": "872a7357132b252b0856edeea082d6e57d516ea7" }, "_source": "git://github.com/angular/bower-angular-animate.git", "_target": "~1.4.*", diff --git a/js/vendor/angular-animate/angular-animate.js b/js/vendor/angular-animate/angular-animate.js index c6e8fb592..66fc23934 100644 --- a/js/vendor/angular-animate/angular-animate.js +++ b/js/vendor/angular-animate/angular-animate.js @@ -1,5 +1,5 @@ /** - * @license AngularJS v1.4.0-rc.0 + * @license AngularJS v1.4.0-rc.1 * (c) 2010-2015 Google, Inc. http://angularjs.org * License: MIT */ @@ -27,6 +27,13 @@ var isPromiseLike = function(p) { return p && p.then ? true : false; } +function assertArg(arg, name, reason) { + if (!arg) { + throw ngMinErr('areq', "Argument '{0}' is {1}", (name || '?'), (reason || "required")); + } + return arg; +} + function mergeClasses(a,b) { if (!a && !b) return ''; if (!a) return b; @@ -115,7 +122,6 @@ function applyAnimationClassesFactory($$jqLite) { } if (options.removeClass) { $$removeClass($$jqLite, element, options.removeClass); - element.removeClass(options.removeClass); options.removeClass = null; } } @@ -417,19 +423,7 @@ var $$AnimateChildrenDirective = [function() { * start: Function, * * // ends (aborts) the animation - * end: Function, - * - * // the total number of seconds that the animation will run for - * duration: Number, - * - * // the total number of seconds that the animation will delay for before starting - * delay: Number, - * - * // whether or not transitions were detected and will therefore be used for the animation - * transitions: Boolean, - * - * // whether or not keyframe animations were detected and will therefore be used for the animation - * keyframes: Boolean + * end: Function * } * ``` * @@ -481,6 +475,7 @@ var $$AnimateChildrenDirective = [function() { * ({@link ngAnimate#css-staggering-animations Click here to learn how CSS-based staggering works in ngAnimate.}) * * `staggerIndex` - The numeric index representing the stagger item (e.g. a value of 5 is equal to the sixth item in the stagger; therefore when a * `stagger` option value of `0.1` is used then there will be a stagger delay of `600ms`) + * `applyClassesEarly` - Whether or not the classes being added or removed will be used when detecting the animation. This is set by `$animate` when enter/leave/move animations are fired to ensure that the CSS classes are resolved in time. (Note that this will prevent any transitions from occuring on the classes being added and removed.) * * @return {null|object} an object with a start method and details about the animation. If no animation is detected then a value of `null` will be returned. * @@ -753,9 +748,12 @@ var $AnimateCssProvider = ['$animateProvider', function($animateProvider) { //WILL RESULT IN AN UNPREDICTABLE BUG THAT IS VERY HARD TO TRACK DOWN AND //WILL TAKE YEARS AWAY FROM YOUR LIFE. var width = bod.offsetWidth + 1; - forEach(rafWaitQueue, function(cb) { - cb(width); - }); + + // we use a for loop to ensure that if the queue is changed + // during this looping then it will consider new requests + for (var i = 0; i < rafWaitQueue.length; i++) { + rafWaitQueue[i](width); + } rafWaitQueue.length = 0; }); } @@ -823,6 +821,17 @@ var $AnimateCssProvider = ['$animateProvider', function($animateProvider) { addRemoveClassName += pendClasses(options.removeClass, '-remove'); } + // there may be a situation where a structural animation is combined together + // with CSS classes that need to resolve before the animation is computed. + // However this means that there is no explicit CSS code to block the animation + // from happening (by setting 0s none in the class name). If this is the case + // we need to apply the classes before the first rAF so we know to continue if + // there actually is a detected transition or keyframe animation + if (options.applyClassesEarly && addRemoveClassName.length) { + applyAnimationClasses(element, options); + addRemoveClassName = ''; + } + var setupClasses = [structuralClassName, addRemoveClassName].join(' ').trim(); var fullClassName = classes + ' ' + setupClasses; var activeClasses = pendClasses(setupClasses, '-active'); @@ -904,10 +913,10 @@ var $AnimateCssProvider = ['$animateProvider', function($animateProvider) { flags.applyTransitionDuration = hasToStyles && ( (flags.hasTransitions && !flags.hasTransitionAll) || (flags.hasAnimations && !flags.hasTransitions)); - flags.applyAnimationDuration = options.duration && flags.hasAnimations; - flags.applyTransitionDelay = truthyTimingValue(options.delay) && (flags.applyTransitionDuration || flags.hasTransitions); - flags.applyAnimationDelay = truthyTimingValue(options.delay) && flags.hasAnimations; - flags.recalculateTimingStyles = addRemoveClassName.length > 0; + flags.applyAnimationDuration = options.duration && flags.hasAnimations; + flags.applyTransitionDelay = truthyTimingValue(options.delay) && (flags.applyTransitionDuration || flags.hasTransitions); + flags.applyAnimationDelay = truthyTimingValue(options.delay) && flags.hasAnimations; + flags.recalculateTimingStyles = addRemoveClassName.length > 0; if (flags.applyTransitionDuration || flags.applyAnimationDuration) { maxDuration = options.duration ? parseFloat(options.duration) : maxDuration; @@ -926,42 +935,6 @@ var $AnimateCssProvider = ['$animateProvider', function($animateProvider) { } } - flags.transitionClassBlock = timings.transitionProperty === 'none' && - timings.transitionDuration === 0; - - // there may be a situation where a structural animation is combined together - // with CSS classes that need to resolve before the animation is computed. - // However this means that there is no explicit CSS code to block the animation - // from happening (by setting 0s none in the class name). If this is the case - // we need to apply the classes before the first rAF so we know to continue if - // there actually is a detected transition or keyframe animation - var applyClassesEarly = maxDuration === 0 - && isStructural - && addRemoveClassName.length > 0 - && !flags.transitionClassBlock; - - // this is an early check to avoid having to do another call to getComputedStyle - // call which is expensive. GCS calls are cached to speed things up. - if (!applyClassesEarly && maxDuration === 0 && !flags.recalculateTimingStyles) { - close(); - return false; - } - - if (applyClassesEarly) { - applyAnimationClasses(element, options); - - // no need to calculate this anymore - flags.recalculateTimingStyles = false; - - fullClassName = node.className + ' ' + setupClasses; - cacheKey = gcsHashFn(node, fullClassName); - - timings = computeTimings(node, fullClassName, cacheKey); - relativeDelay = timings.maxDelay; - maxDelay = Math.max(relativeDelay, 0); - maxDuration = timings.maxDuration; - } - if (maxDuration === 0 && !flags.recalculateTimingStyles) { close(); return false; @@ -983,9 +956,8 @@ var $AnimateCssProvider = ['$animateProvider', function($animateProvider) { stagger.animationDuration === 0; } - if (flags.blockTransition) { - applyAnimationFromStyles(element, options); - } else { + applyAnimationFromStyles(element, options); + if (!flags.blockTransition) { blockTransitions(node, false); } @@ -1300,27 +1272,39 @@ var $$AnimateCssDriverProvider = ['$$animationProvider', function($$animationPro rootBodyElement.append(clone); - var animatorOut = prepareOutAnimation(); + var animatorIn, animatorOut = prepareOutAnimation(); + + // the user may not end up using the `out` animation and + // only making use of the `in` animation or vice-versa. + // In either case we should allow this and not assume the + // animation is over unless both animations are not used. if (!animatorOut) { - return end(); + animatorIn = prepareInAnimation(); + if (!animatorIn) { + return end(); + } } + var startingAnimator = animatorOut || animatorIn; + return { start: function() { var runner; - var currentAnimation = animatorOut.start(); + var currentAnimation = startingAnimator.start(); currentAnimation.done(function() { currentAnimation = null; - var animatorIn = prepareInAnimation(); - if (animatorIn) { - currentAnimation = animatorIn.start(); - currentAnimation.done(function() { - currentAnimation = null; - end(); - runner.complete(); - }); - return currentAnimation; + if (!animatorIn) { + animatorIn = prepareInAnimation(); + if (animatorIn) { + currentAnimation = animatorIn.start(); + currentAnimation.done(function() { + currentAnimation = null; + end(); + runner.complete(); + }); + return currentAnimation; + } } // in the event that there is no `in` animation end(); @@ -1446,8 +1430,13 @@ var $$AnimateCssDriverProvider = ['$$animationProvider', function($$animationPro function prepareRegularAnimation(animationDetails) { var element = animationDetails.element; var options = animationDetails.options || {}; + options.structural = animationDetails.structural; + // structural animations ensure that the CSS classes are always applied + // before the detection starts. + options.applyClassesEarly = options.structural; + // we special case the leave animation since we want to ensure that // the element is removed as soon as the animation is over. Otherwise // a flicker might appear or the element may not be removed at all @@ -1771,6 +1760,7 @@ var $$AnimateJsDriverProvider = ['$$animationProvider', function($$animationProv }]; var NG_ANIMATE_ATTR_NAME = 'data-ng-animate'; +var NG_ANIMATE_PIN_DATA = '$ngAnimatePin'; var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { var PRE_DIGEST_STATE = 1; var RUNNING_STATE = 2; @@ -1937,6 +1927,12 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { } }, + pin: function(element, parentElement) { + assertArg(isElement(element), 'element', 'not an element'); + assertArg(isElement(parentElement), 'parentElement', 'not an element'); + element.data(NG_ANIMATE_PIN_DATA, parentElement); + }, + push: function(element, event, options, domOperation) { options = options || {}; options.domOperation = domOperation; @@ -2020,7 +2016,7 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { var className = [node.className, options.addClass, options.removeClass].join(' '); if (!isAnimatableClassName(className)) { - runner.end(); + close(); return runner; } @@ -2151,6 +2147,7 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { // it, otherwise if it's the same then the end result will be the same too if (animationCancelled || (isStructural && animationDetails.event !== event)) { options.domOperation(); + runner.end(); } return; @@ -2245,7 +2242,7 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { // animations to properly function (otherwise any CSS selectors may not work) function examineParentAnimation(node, animationDetails) { // enter/leave/move always have priority - if (animationDetails.structural) return; + if (animationDetails.structural || !hasAnimationClasses(animationDetails.options)) return; if (animationDetails.state === RUNNING_STATE) { animationDetails.runner.end(); @@ -2260,7 +2257,18 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { var parentAnimationDetected = false; var animateChildren; + var parentHost = element.data(NG_ANIMATE_PIN_DATA); + if (parentHost) { + parent = parentHost; + } + while (parent && parent.length) { + if (!rootElementDetected) { + // angular doesn't want to attempt to animate elements outside of the application + // therefore we need to ensure that the rootElement is an ancestor of the current element + rootElementDetected = isMatchingElement(parent, $rootElement); + } + var parentNode = parent[0]; if (parentNode.nodeType !== ELEMENT_NODE) { // no point in inspecting the #document element @@ -2289,6 +2297,12 @@ var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) { // angular doesn't want to attempt to animate elements outside of the application // therefore we need to ensure that the rootElement is an ancestor of the current element rootElementDetected = isMatchingElement(parent, $rootElement); + if (!rootElementDetected) { + parentHost = parent.data(NG_ANIMATE_PIN_DATA); + if (parentHost) { + parent = parentHost; + } + } } if (!bodyElementDetected) { @@ -3149,6 +3163,207 @@ var $$AnimationProvider = ['$animateProvider', function($animateProvider) { * * To learn more about what's possible be sure to visit the {@link ngAnimate.$animateCss $animateCss service}. * + * ## Animation Anchoring (via `ng-animate-ref`) + * + * ngAnimate in AngularJS 1.4 comes packed with the ability to cross-animate elements between + * structural areas of an application (like views) by pairing up elements using an attribute + * called `ng-animate-ref`. + * + * Let's say for example we have two views that are managed by `ng-view` and we want to show + * that there is a relationship between two components situated in different views. By using the + * `ng-animate-ref` attribute we can identify that the two components are paired together and we + * can then attach an animation, which is triggered when the view changes. + * + * ```html + * + *
+ *
+ * + * + * + * + * + * + * + * + * ``` + * + * Now, when the view changes (once the link is clicked), ngAnimate will examine the + * HTML contents to see if there is a match reference between any components in the view + * that is leaving and the view that is entering. It will then attempt to trigger a CSS + * animation on the `.view-animation-anchor` CSS class (notice how `.view-animation` is + * a shared CSS class on the ng-view element? This means that view-animation will apply to + * both the enter and leave animations). + * + * The two images match since they share the same ref value. ngAnimate will now apply a + * suffixed version of each of the shared CSS classes with `-anchor`. Therefore we will + * have a shared class of `view-animation-anchor` which we can use to setup our transition animation. + * + * We can now attach a transition onto the `.view-animation-anchor` CSS class and then + * ngAnimate will handle the entire transition for us as well as the addition and removal of + * any changes of CSS classes between the elements: + * + * ```css + * .view-animation-anchor { + * /* this animation will last for 1 second since there are + * two phases to the animation (an `in` and an `out` phase) */ + * transition:0.5s linear all; + * } + * ``` + * + * There are two stages for an anchor animation: `out` and `in`. The `out` stage happens first and that + * is when the element is animated away from its origin. Once that animation is over then the `in` stage + * occurs which animates the element to its destination. The reason why there are two animations is to + * give enough time for the enter animation on the new element to be ready. + * + * The example above sets up a transition for both the in and out phases, but we can also target the out or + * in phases directly via `ng-anchor-out` and `ng-anchor-in`. + * + * ```css + * .view-animation-anchor.ng-anchor-out { + * transition: 0.5s linear all; + * + * /* the scale will be applied during the out animation, + * but will be animated away when the in animation runs */ + * transform: scale(1.2); + * } + * + * .view-animation-anchor.ng-anchor-in { + * transition: 1s linear all; + * } + * ``` + * + * + * + * + * ### Anchoring Demo + * + + + Home +
+
+
+
+
+ + angular.module('anchoringExample', ['ngAnimate', 'ngRoute']) + .config(['$routeProvider', function($routeProvider) { + $routeProvider.when('/', { + templateUrl: 'home.html', + controller: 'HomeController as home' + }); + $routeProvider.when('/profile/:id', { + templateUrl: 'profile.html', + controller: 'ProfileController as profile' + }); + }]) + .run(['$rootScope', function($rootScope) { + $rootScope.records = [ + { id:1, title: "Miss Beulah Roob" }, + { id:2, title: "Trent Morissette" }, + { id:3, title: "Miss Ava Pouros" }, + { id:4, title: "Rod Pouros" }, + { id:5, title: "Abdul Rice" }, + { id:6, title: "Laurie Rutherford Sr." }, + { id:7, title: "Nakia McLaughlin" }, + { id:8, title: "Jordon Blanda DVM" }, + { id:9, title: "Rhoda Hand" }, + { id:10, title: "Alexandrea Sauer" } + ]; + }]) + .controller('HomeController', [function() { + //empty + }]) + .controller('ProfileController', ['$rootScope', '$routeParams', function($rootScope, $routeParams) { + var index = parseInt($routeParams.id, 10); + var record = $rootScope.records[index - 1]; + + this.title = record.title; + this.id = record.id; + }]); + + +

Welcome to the home page

+

Please click on an element

+ + {{ record.title }} + +
+ +
+ {{ profile.title }} +
+
+ + .record { + display:block; + font-size:20px; + } + .profile { + background:black; + color:white; + font-size:100px; + } + .view-container { + position:relative; + } + .view-container > .view.ng-animate { + position:absolute; + top:0; + left:0; + width:100%; + min-height:500px; + } + .view.ng-enter { + transition:0.5s linear all; + transform:translateX(100%); + } + .view.ng-enter.ng-enter-active { + transform:translateX(0%); + } + .view.ng-leave { + transition:0.5s linear all; + } + .view.ng-leave.ng-leave-active { + transform:translateX(-100%); + } + .view-anchor { + transition:0.5s linear all; + } + +
+ * + * ### How is the element transported? + * + * When an anchor animation occurs, ngAnimate will clone the starting element and position it exactly where the starting + * element is located on screen via absolute positioning. The cloned element will be placed inside of the root element + * of the application (where ng-app was defined) and all of the CSS classes of the starting element will be applied. The + * element will then animate into the `out` and `in` animations and will eventually reach the coordinates and match + * the dimensions of the destination element. During the entire animation a CSS class of `.ng-animate-shim` will be applied + * to both the starting and destination elements in order to hide them from being visible (the CSS styling for the class + * is: `visibility:hidden`). Once the anchor reaches its destination then it will be removed and the destination element + * will become visible since the shim class will be removed. + * + * ### How is the morphing handled? + * + * CSS Anchoring relies on transitions and keyframes and the internal code is intelligent enough to figure out + * what CSS classes differ between the starting element and the destination element. These different CSS classes + * will be added/removed on the anchor element and a transition will be applied (the transition that is provided + * in the anchor class). Long story short, ngAnimate will figure out what classes to add and remove which will + * make the transition of the element as smooth and automatic as possible. Be sure to use simple CSS classes that + * do not rely on DOM nesting structure so that the anchor element appears the same as the starting element (since + * the cloned element is placed inside of root element which is likely close to the body element). + * + * Note that if the root element is on the `` element then the cloned node will be placed inside of body. + * * * ## Using $animate in your directive code * @@ -3224,12 +3439,12 @@ var $$AnimationProvider = ['$animateProvider', function($animateProvider) { * anymore.) * * In addition to the animation promise, we can also make use of animation-related callbacks within our directives and controller code by registering - * an event listener using the `$animate` service. Let's say for example that an animation was triggered on our `ng-view` element and we wanted our + * an event listener using the `$animate` service. Let's say for example that an animation was triggered on our view * routing controller to hook into that: * * ```js * ngModule.controller('HomePageController', ['$animate', function($animate) { - * $animate.on('enter', '[ng-view]', function(element) { + * $animate.on('enter', ngViewElement, function(element) { * // the animation for this route has completed * }]); * }]) diff --git a/js/vendor/angular-animate/angular-animate.min.js b/js/vendor/angular-animate/angular-animate.min.js index 0a615089e..878798ed0 100644 --- a/js/vendor/angular-animate/angular-animate.min.js +++ b/js/vendor/angular-animate/angular-animate.min.js @@ -1,49 +1,49 @@ /* - AngularJS v1.4.0-rc.0 + AngularJS v1.4.0-rc.1 (c) 2010-2015 Google, Inc. http://angularjs.org License: MIT */ -(function(H,s,$){'use strict';function sa(a,b){if(!a&&!b)return"";if(!a)return b;if(!b)return a;aa(a)&&(a=a.join(" "));aa(b)&&(b=b.join(" "));return a+" "+b}function Aa(a){var b={};a&&(a.to||a.from)&&(b.to=a.to,b.from=a.from);return b}function ca(a,b,c){var d="";a=aa(a)?a:a&&T(a)&&a.length?a.split(/\s+/):[];p(a,function(a,t){a&&0=L&&b>=A&&(x=!0,l())}if(!K){var k,q=[],h=function(a){if(x)C&&a&&(C=!1,l());else if(C=!a,w.animationDuration)if(a=ma(r,C),C)u.push(a);else{var b=u,c=b.indexOf(a);0<=a&&b.splice(c,1)}},n=0