From 8649369cf0cf5d5b45d2fe7e17a26aaad7bc4563 Mon Sep 17 00:00:00 2001 From: Alexandre-io Date: Fri, 11 Sep 2015 15:10:22 +0200 Subject: [PATCH 1/5] fix(Gruntfile): fix src path and add test task --- Gruntfile.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Gruntfile.js b/Gruntfile.js index 6c317df..9e171db 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -32,12 +32,12 @@ module.exports = function(grunt) { jshint: { lib: { options: {}, - src: ['lib/*.js'] + src: ['src/*.js'] }, }, watch: { scripts: { - files: 'lib/*.js', + files: 'src/*.js', tasks: ['jshint', 'uglify'], options: { interrupt: true @@ -54,4 +54,7 @@ module.exports = function(grunt) { // Default task(s). grunt.registerTask('default', ['jshint', 'uglify']); + + // Test + grunt.registerTask('test', ['jshint']); }; From 971db12c20696aef1064c05cc8fa2f782486d9a7 Mon Sep 17 00:00:00 2001 From: Alexandre-io Date: Fri, 11 Sep 2015 15:11:07 +0200 Subject: [PATCH 2/5] feat(deps): bump dependencies versions --- bower.json | 6 +++--- package.json | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/bower.json b/bower.json index e32ab68..b92177b 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "angular-intro.js", - "version": "1.2.7", + "version": "1.3.0", "main": "src/angular-intro.js", "description": "Angular directive to wrap intro.js", "license": "MIT", @@ -12,8 +12,8 @@ "assets" ], "dependencies": { - "angular": "~1.2.x", - "intro.js": "1.1.0" + "angular": "~1.4.0", + "intro.js": "~1.1.1" }, "devDependencies": {} } diff --git a/package.json b/package.json index 04695b8..1b3938c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "angular-intro.js", - "version": "0.1.0", + "version": "1.3.0", "description": "Angular directive to wrap intro.js", "main": "src/angular-intro.js", "directories": { @@ -26,13 +26,13 @@ }, "homepage": "https://github.com/mendhak/angular-intro.js", "devDependencies": { - "bower": "~1.3.1", - "grunt": "~0.4.4", + "bower": "~1.5.2", + "grunt": "~0.4.5", "grunt-cli": "~0.1.13", "grunt-contrib-connect": "^0.11.2", - "grunt-contrib-jshint": "~0.9.2", - "grunt-contrib-uglify": "~0.4.0", + "grunt-contrib-jshint": "~0.11.3", + "grunt-contrib-uglify": "~0.9.2", "grunt-contrib-watch": "~0.6.1", - "load-grunt-tasks": "~0.4.0" + "load-grunt-tasks": "~3.2.0" } } From c857e9905ffee426715af072f334e66c20cab748 Mon Sep 17 00:00:00 2001 From: Alexandre-io Date: Fri, 11 Sep 2015 15:11:44 +0200 Subject: [PATCH 3/5] feat(example): add support for angular 1.3 & 1.4 --- example/index.html | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/example/index.html b/example/index.html index acab730..deacde4 100644 --- a/example/index.html +++ b/example/index.html @@ -16,8 +16,8 @@ - From b9e52dec97660565e9735df0194f1311858954ac Mon Sep 17 00:00:00 2001 From: Alexandre-io Date: Fri, 11 Sep 2015 15:12:42 +0200 Subject: [PATCH 4/5] fix(jshint): typo fix to pass jshint tests --- src/angular-intro.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/angular-intro.js b/src/angular-intro.js index ba559b1..a34862e 100644 --- a/src/angular-intro.js +++ b/src/angular-intro.js @@ -60,7 +60,7 @@ if (scope.ngIntroOncomplete) { intro.oncomplete(function() { scope.ngIntroOncomplete.call(this, scope); - $timeout(function() {scope.$digest()}); + $timeout(function() {scope.$digest();}); navigationWatch(); }); } @@ -68,7 +68,7 @@ if (scope.ngIntroOnexit) { intro.onexit(function() { scope.ngIntroOnexit.call(this, scope); - $timeout(function() {scope.$digest()}); + $timeout(function() {scope.$digest();}); navigationWatch(); }); } @@ -76,21 +76,21 @@ if (scope.ngIntroOnchange) { intro.onchange(function(targetElement){ scope.ngIntroOnchange.call(this, targetElement, scope); - $timeout(function() {scope.$digest()}); + $timeout(function() {scope.$digest();}); }); } if (scope.ngIntroOnbeforechange) { intro.onbeforechange(function(targetElement) { scope.ngIntroOnbeforechange.call(this, targetElement, scope); - $timeout(function() {scope.$digest()}); + $timeout(function() {scope.$digest();}); }); } if (scope.ngIntroOnafterchange) { intro.onafterchange(function(targetElement){ scope.ngIntroOnafterchange.call(this, targetElement, scope); - $timeout(function() {scope.$digest()}); + $timeout(function() {scope.$digest();}); }); } @@ -103,11 +103,11 @@ scope.ngIntroNextMethod = function () { intro.nextStep(); - } + }; scope.ngIntroPreviousMethod = function () { intro.previousStep(); - } + }; scope.ngIntroExitMethod = function (callback) { intro.exit(); From 9fc801d245e7e3e19e092f8f52fea209922ffa40 Mon Sep 17 00:00:00 2001 From: Alexandre-io Date: Fri, 11 Sep 2015 15:14:33 +0200 Subject: [PATCH 5/5] feat(build): new version 1.3.0 --- build/angular-intro.min.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/angular-intro.min.js b/build/angular-intro.min.js index b00eb63..540bf9b 100644 --- a/build/angular-intro.min.js +++ b/build/angular-intro.min.js @@ -1,2 +1,2 @@ -/*! angular-intro.js 2015-09-05 */ +/*! angular-intro.js 2015-09-11 */ !function(a,b){"function"==typeof define&&define.amd?define(["angular","intro"],b):"object"==typeof exports?module.exports=b(require("angular"),require("intro")):a.angularIntroJs=b(a.angular,a.introJs)}(this,function(a,b){"object"==typeof b&&(b=b.introJs);var c=a.module("angular-intro",[]);return c.directive("ngIntroOptions",["$timeout",function(a){return{restrict:"A",scope:{ngIntroMethod:"=",ngIntroExitMethod:"=?",ngIntroNextMethod:"=?",ngIntroPreviousMethod:"=?",ngIntroOptions:"=",ngIntroOncomplete:"=",ngIntroOnexit:"=",ngIntroOnchange:"=",ngIntroOnbeforechange:"=",ngIntroOnafterchange:"=",ngIntroAutostart:"=",ngIntroAutorefresh:"="},link:function(c,d,e){var f;c.ngIntroMethod=function(d){var e=c.$on("$locationChangeStart",function(){f.exit()});f="string"==typeof d?b(d):b(),f.setOptions(c.ngIntroOptions),c.ngIntroAutorefresh&&c.$watch(function(){f.refresh()}),c.ngIntroOncomplete&&f.oncomplete(function(){c.ngIntroOncomplete.call(this,c),a(function(){c.$digest()}),e()}),c.ngIntroOnexit&&f.onexit(function(){c.ngIntroOnexit.call(this,c),a(function(){c.$digest()}),e()}),c.ngIntroOnchange&&f.onchange(function(b){c.ngIntroOnchange.call(this,b,c),a(function(){c.$digest()})}),c.ngIntroOnbeforechange&&f.onbeforechange(function(b){c.ngIntroOnbeforechange.call(this,b,c),a(function(){c.$digest()})}),c.ngIntroOnafterchange&&f.onafterchange(function(b){c.ngIntroOnafterchange.call(this,b,c),a(function(){c.$digest()})}),"number"==typeof d?f.goToStep(d).start():f.start()},c.ngIntroNextMethod=function(){f.nextStep()},c.ngIntroPreviousMethod=function(){f.previousStep()},c.ngIntroExitMethod=function(a){f.exit(),a()};var g=c.$watch("ngIntroAutostart",function(){c.ngIntroAutostart&&a(function(){c.ngIntroMethod()}),g()});c.$on("$locationChangeSuccess",function(){"undefined"!=typeof f&&f.exit()})}}}]),c}); \ No newline at end of file