Item-radio class causing endless recalculate style


#1

Hi,
First of all, thanks for making hybrid app development something fun :smile: .

I noticed that using the class item-radio inside of a ng-repeat causes a infinite recalculate style on each element that has this class applied. Looks like this happens because of a css hack to fix a checked bug on android.
This is my code

<label bindonce bo-class="'item item-radio  menu-'+kind.name" ng-repeat="item in items">
          <input type="radio" name="group1" ng-click="toggleFilter(item)">
          <div class="item-content  card-background-pando" bo-text="kind.name"></div>
</label>

This is what i found on ionic.css

.item-radio {
  -webkit-animation: androidCheckedbugfix infinite 1s;}

@-webkit-keyframes androidCheckedbugfix {
  from {
    padding: 0; }

  to {
    padding: 0; } }

Iยดm not sure about how this affects performance, but having an endless style calculation is probably not the best option.


#2

This hack was causing a 50% load on iOS.

I noticed this is fixed in now in the current nightly :smile:

https://github.com/driftyco/ionic/blob/master/scss/_radio.scss#L50


#3

Thats nice to hear, thanks for the answer. :smile: