From 37be253f60ad07185871975888e55e657c9ef2ac Mon Sep 17 00:00:00 2001 From: Max Lynch Date: Thu, 14 Nov 2013 21:29:02 -0600 Subject: [PATCH] Poly stuff working better --- dist/css/ionic.css | 10 +++--- dist/css/themes/ionic-ios7.css | 5 +-- dist/js/ionic-angular.js | 32 +++++++------------ dist/js/ionic.js | 14 ++++---- js/ext/angular/src/directive/ionicCheckbox.js | 24 +++++--------- js/ext/angular/src/directive/ionicRadio.js | 8 ++--- js/utils/poly.js | 14 ++++---- 7 files changed, 48 insertions(+), 59 deletions(-) diff --git a/dist/css/ionic.css b/dist/css/ionic.css index ad7a4b8d2e..67113112a4 100644 --- a/dist/css/ionic.css +++ b/dist/css/ionic.css @@ -1,5 +1,5 @@ @charset "UTF-8"; -/*! +/* Ionicons, v1.3.4 Created by Ben Sperry for the Ionic Framework, http://ionicons.com/ https://twitter.com/helloimben https://twitter.com/ionicframework @@ -2045,7 +2045,7 @@ sub { fieldset { margin: 0 2px; padding: 0.35em 0.625em 0.75em; - border: 1px solid #c0c0c0; } + border: 1px solid silver; } /** * 1. Correct `color` not being inherited in IE 8/9. @@ -4152,7 +4152,7 @@ input[type="checkbox"][readonly] { border-radius: 50%; background: white; content: ' '; - transition: background-color .1s ease-in-out; } + transition: background-color 0.1s ease-in-out; } /* the checkmark within the box */ .checkbox input:after { @@ -4167,7 +4167,7 @@ input[type="checkbox"][readonly] { border-right: 0; content: ' '; opacity: 0; - transition: opacity .05s ease-in-out; + transition: opacity 0.05s ease-in-out; -webkit-transform: rotate(-45deg); transform: rotate(-45deg); } @@ -4652,7 +4652,7 @@ input[type="range"] { .button-icon:active, .button-icon.active { background: none; box-shadow: none; - text-shadow: 0px 0px 10px #fff; } + text-shadow: 0px 0px 10px white; } .padding > .button.block:first-child { margin-top: 0; } diff --git a/dist/css/themes/ionic-ios7.css b/dist/css/themes/ionic-ios7.css index 680f21850c..53b57eba7c 100644 --- a/dist/css/themes/ionic-ios7.css +++ b/dist/css/themes/ionic-ios7.css @@ -1,3 +1,4 @@ +@charset "UTF-8"; /** * Nav controllers and header bar animations */ @@ -118,7 +119,7 @@ right: 20px; transition: 0.2s ease; transition-property: left, right; - transition-delay: 0s, .05s; } + transition-delay: 0s, 0.05s; } .toggle :checked + .track { /* When the toggle is "on" */ @@ -133,4 +134,4 @@ right: 0; left: 20px; -webkit-transform: none; - transition-delay: .05s, 0s; } + transition-delay: 0.05s, 0s; } diff --git a/dist/js/ionic-angular.js b/dist/js/ionic-angular.js index f07eaed42a..4750324ee7 100644 --- a/dist/js/ionic-angular.js +++ b/dist/js/ionic-angular.js @@ -23545,7 +23545,8 @@ angular.module('ionic.ui.checkbox', []) replace: true, require: '?ngModel', scope: {}, - template: '', + transclude: true, + template: '', link: function($scope, $element, $attr, ngModel) { @@ -23557,12 +23558,12 @@ angular.module('ionic.ui.checkbox', []) if(!checkbox.length) { return; } - var tapHandler = function(e) { - checkbox[0].checked = !checkbox[0].checked; - $scope.$apply(function() { - ngModel.$setViewValue(checkbox[0].checked); - }); - e.preventDefault(); + $scope.tapHandler = function(e) { + if(e.type != 'click') { + checkbox[0].checked = !checkbox[0].checked; + } + ngModel.$setViewValue(checkbox[0].checked); + e.alreadyHandled = true; }; var clickHandler = function(e) { @@ -23572,17 +23573,8 @@ angular.module('ionic.ui.checkbox', []) }); }; - $scope.$on('$destroy', function() { - $element.unbind('tap', tapHandler); - $element.unbind('click', clickHandler); - }); - if(ngModel) { - $element.bind('tap', tapHandler); - $element.bind('click', clickHandler); - ngModel.$render = function() { - console.log('checkbox redern', ngModel.$viewValue); checkbox[0].checked = ngModel.$viewValue; }; } @@ -24185,7 +24177,7 @@ angular.module('ionic.ui.radio', []) value: '@' }, transclude: true, - template: '