mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-11-07 06:57:02 +08:00
Reduced drag banding resistance
This commit is contained in:
2
dist/js/ionic-angular.js
vendored
2
dist/js/ionic-angular.js
vendored
@ -797,7 +797,7 @@ angular.module('ionic.ui.nav', ['ionic.service.templateLoad', 'ionic.service.ges
|
||||
|
||||
// Compile the template with the new scrope, and append it to the navigation's content area
|
||||
var el = $compile(templateString)(childScope, function(cloned, scope) {
|
||||
var content = angular.element($element[0].querySelector('.content'));
|
||||
var content = angular.element($element[0].querySelector('.content, .scroll'));
|
||||
|
||||
//content.append(cloned);
|
||||
//angular.element(content).append(cloned);
|
||||
|
||||
2
dist/js/ionic.js
vendored
2
dist/js/ionic.js
vendored
@ -1990,7 +1990,7 @@ window.ionic = {
|
||||
dragThreshold: 10,
|
||||
|
||||
// Resistance when scrolling too far up or down
|
||||
rubberBandResistance: 3,
|
||||
rubberBandResistance: 2,
|
||||
|
||||
// Scroll event names. These are custom so can be configured
|
||||
scrollEventName: 'momentumScrolled',
|
||||
|
||||
2
js/ext/angular/src/directive/ionicNav.js
vendored
2
js/ext/angular/src/directive/ionicNav.js
vendored
@ -57,7 +57,7 @@ angular.module('ionic.ui.nav', ['ionic.service.templateLoad', 'ionic.service.ges
|
||||
|
||||
// Compile the template with the new scrope, and append it to the navigation's content area
|
||||
var el = $compile(templateString)(childScope, function(cloned, scope) {
|
||||
var content = angular.element($element[0].querySelector('.content'));
|
||||
var content = angular.element($element[0].querySelector('.content, .scroll'));
|
||||
|
||||
//content.append(cloned);
|
||||
//angular.element(content).append(cloned);
|
||||
|
||||
@ -7,9 +7,9 @@
|
||||
<meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no">
|
||||
<link href="/vendor/font-awesome/css/font-awesome.css" rel="stylesheet">
|
||||
<link rel="stylesheet" href="../../../../dist/css/ionic.css">
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.0-rc.3/angular.min.js"></script>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.0-rc.3/angular-touch.js"></script>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.0-rc.3/angular-animate.js"></script>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.0/angular.min.js"></script>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.0/angular-touch.js"></script>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.0/angular-animate.js"></script>
|
||||
<style>
|
||||
.view {
|
||||
position: fixed;
|
||||
@ -34,8 +34,10 @@
|
||||
<navs>
|
||||
<nav-bar></nav-bar>
|
||||
|
||||
<content has-header="true" ng-controller="AppCtrl">
|
||||
<div ng-controller="AppCtrl">
|
||||
<content has-header="true">
|
||||
</content>
|
||||
</div>
|
||||
</navs>
|
||||
|
||||
<script id="page.html" type="text/ng-template">
|
||||
@ -65,7 +67,7 @@
|
||||
|
||||
}
|
||||
|
||||
angular.module('navTest', ['ionic.ui.nav', 'ionic.ui.content', 'ionic.ui.list', 'ngAnimate'])
|
||||
angular.module('navTest', ['ionic', 'ngAnimate'])
|
||||
|
||||
.controller('AppCtrl', function($scope, $compile, $element) {
|
||||
$scope.navController.pushFromTemplate('page.html');
|
||||
|
||||
@ -40,7 +40,7 @@
|
||||
dragThreshold: 10,
|
||||
|
||||
// Resistance when scrolling too far up or down
|
||||
rubberBandResistance: 3,
|
||||
rubberBandResistance: 2,
|
||||
|
||||
// Scroll event names. These are custom so can be configured
|
||||
scrollEventName: 'momentumScrolled',
|
||||
|
||||
Reference in New Issue
Block a user