Skip to content

Instantly share code, notes, and snippets.

@victorwoo
Created April 14, 2015 08:43
Show Gist options
  • Save victorwoo/24d493da9ec26fd58dbd to your computer and use it in GitHub Desktop.
Save victorwoo/24d493da9ec26fd58dbd to your computer and use it in GitHub Desktop.
input in ion-list
<html ng-app="ionicApp">
<head>
<meta charset="utf-8">
<meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width">
<title>Ionic Pull to Refresh</title>
<link href="//code.ionicframework.com/nightly/css/ionic.css" rel="stylesheet">
<script src="//code.ionicframework.com/nightly/js/ionic.bundle.js"></script>
</head>
<body ng-controller="MyCtrl">
<ion-header-bar class="bar-assertive">
<h1 class="title">How to place &lt;input&gt; in &lt;ion-list&gt; correctly?</h1>
</ion-header-bar>
<ion-content>
<div class="list">
<label class="item item-input">
<input type="text" placeholder="input in div.list is OK">
</label>
<label class="item item-input">
<input type="text" placeholder="input in div.list is OK">
</label>
</div>
<ion-list>
<ion-item ng-repeat="checkpoint in ['foo', 'bar']">
<label class="item item-input">
<input type="text" placeholder="ion-item>label>input is FAT with outer border">
</label>
<ion-option-button class="button-assertive">Remove</ion-option-button>
</ion-item>
</ion-list>
<ion-list>
<ion-item ng-repeat="checkpoint in ['foo', 'bar']">
<input type="text" placeholder="ion-item>input can't fit width">
<ion-option-button class="button-assertive">Remove</ion-option-button>
</ion-item>
</ion-list>
</ion-content>
</body>
</html>
angular.module('ionicApp', ['ionic'])
.controller('MyCtrl', function($scope) {
});
body {
cursor: url('http://ionicframework.com/img/finger.png'), auto;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment