JSDM

HTML

31
 
1
<html ng-app="ionicApp">
2
  <head>
3
    <meta charset="utf-8">
4
    <meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width">
5
6
    <title>Ionic Pull to Refresh</title>
7
8
    <link href="http://code.ionicframework.com/1.0.0-beta.11/css/ionic.css" rel="stylesheet">
9
    <script src="http://code.ionicframework.com/1.0.0-beta.11/js/ionic.bundle.js"></script>
10
  </head>
11
  <body ng-controller="MyCtrl">
12
13
    <ion-header-bar class="bar-positive">
14
      <h1 class="title">下拉刷新</h1>
15
    </ion-header-bar>
16
17
    <ion-content>
18
      <ion-refresher on-refresh="doRefresh()"
19
                     pulling-text="Pull to refresh..."
20
                     refreshing-text="Refreshing!"
21
                     refreshing-icon="ion-loading-c">
22
                     
23
      </ion-refresher>
24
      <ion-list>
25
        <ion-item ng-repeat="item in items">{{item}}</ion-item>
26
      </ion-list>
27
    </ion-content>
28
29
  </body>
30
</html>
31

CSS

xxxxxxxxxx
3
 
1
body {
2
  cursor: url('http://ionicframework.com/img/finger.png'), auto;
3
}
? ?
? ?
必须是有效的URL
+ 添加另一个资源

JS

20
 
1
angular.module('ionicApp', ['ionic'])
2
3
.controller('MyCtrl', function($scope, $timeout) {
4
  $scope.items = ['Item 1', 'Item 2', 'Item 3'];
5
  
6
  $scope.doRefresh = function() {
7
    
8
    console.log('Refreshing!');
9
    $timeout( function() {
10
      //simulate async response
11
      $scope.items.push('New Item ' + Math.floor(Math.random() * 1000) + 4);
12
13
      //Stop the ion-refresher from spinning
14
      $scope.$broadcast('scroll.refreshComplete');
15
    
16
    }, 1000);
17
      
18
  };
19
  
20
});
必须是有效的URL
+ 添加另一个资源
Close

文件管理 点击文件查看URL

图片

  1. 暂无文件

CSS

  1. 暂无文件

JavaScript

  1. 暂无文件

其他

  1. 暂无文件
拖动文件到上面的区域或者:
加载中 ..................