refactor(playground): update gestures playground to use latest hammer.js

This commit is contained in:
Joao Dias 2016-10-30 22:25:42 +01:00 committed by vsavkin
parent 5494169fb4
commit bad58824a0
6 changed files with 20 additions and 21 deletions

View File

@ -67,6 +67,7 @@ if [[ ${BUILD_ALL} == true ]]; then
ln -s ../../../../node_modules/reflect-metadata/Reflect.js .
ln -s ../../../../node_modules/rxjs .
ln -s ../../../../node_modules/angular/angular.js .
ln -s ../../../../node_modules/hammerjs/hammer.js .
cd -
echo "====== Copying files needed for benchmarks ====="

File diff suppressed because one or more lines are too long

View File

@ -16,13 +16,11 @@ class GesturesCmp {
pinchScale: number = 1;
rotateAngle: number = 0;
onSwipe(event: any /** TODO #9100 */): void {
this.swipeDirection = event.deltaX > 0 ? 'right' : 'left';
}
onSwipe(event: HammerInput): void { this.swipeDirection = event.deltaX > 0 ? 'right' : 'left'; }
onPinch(event: any /** TODO #9100 */): void { this.pinchScale = event.scale; }
onPinch(event: HammerInput): void { this.pinchScale = event.scale; }
onRotate(event: any /** TODO #9100 */): void { this.rotateAngle = event.rotation; }
onRotate(event: HammerInput): void { this.rotateAngle = event.rotation; }
}
@NgModule({declarations: [GesturesCmp], bootstrap: [GesturesCmp], imports: [BrowserModule]})

View File

@ -11,7 +11,7 @@
"dev": true
},
"@types/hammerjs": {
"version": "2.0.22-alpha",
"version": "2.0.33",
"dev": true
},
"@types/jasmine": {
@ -3490,6 +3490,10 @@
"version": "1.0.0",
"dev": true
},
"hammerjs": {
"version": "2.0.8",
"dev": true
},
"handlebars": {
"version": "4.0.5",
"dev": true,

10
npm-shrinkwrap.json generated
View File

@ -15,9 +15,9 @@
"dev": true
},
"@types/hammerjs": {
"version": "2.0.22-alpha",
"version": "2.0.33",
"from": "@types/hammerjs@latest",
"resolved": "https://registry.npmjs.org/@types/hammerjs/-/hammerjs-2.0.22-alpha.tgz",
"resolved": "https://registry.npmjs.org/@types/hammerjs/-/hammerjs-2.0.33.tgz",
"dev": true
},
"@types/jasmine": {
@ -5066,6 +5066,12 @@
"resolved": "https://registry.npmjs.org/gulplog/-/gulplog-1.0.0.tgz",
"dev": true
},
"hammerjs": {
"version": "2.0.8",
"from": "hammerjs@latest",
"resolved": "https://registry.npmjs.org/hammerjs/-/hammerjs-2.0.8.tgz",
"dev": true
},
"handlebars": {
"version": "4.0.5",
"from": "handlebars@>=4.0.2 <5.0.0",

View File

@ -26,7 +26,7 @@
"devDependencies": {
"@types/angularjs": "^1.5.13-alpha",
"@types/fs-extra": "0.0.22-alpha",
"@types/hammerjs": "^2.0.22-alpha",
"@types/hammerjs": "^2.0.33",
"@types/jasmine": "^2.2.22-alpha",
"@types/node": "^4.0.22-alpha",
"@types/protractor": "^1.5.11-alpha",
@ -51,6 +51,7 @@
"gulp-connect": "^2.3.1",
"gulp-conventional-changelog": "^1.1.0",
"gulp-tslint": "^6.1.1",
"hammerjs": "^2.0.8",
"incremental-dom": "^0.4.1",
"jasmine": "^2.4.1",
"jasmine-core": "^2.3.4",