Extending the ionRefresher and ionInfiniteScroll directives

Hello,

What I want to do is to specify either spinner or refreshing-icon attribute for the ionRefresher and ionInfiniteScroll directives, depending on the Android platform version. All this, because the new spinner icons do not seem to work in a <=4.3 WebView.

I first tried extending the ionRefresher directive. The attributes were successfully updated, but it would still show the original spinner icon instead of refreshing-icon.

<ion-refresher
  pulling-icon="ion-android-arrow-down"
  spinner="lines"
  on-refresh="onRefresh()">
</ion-refresher>

.directive('ionRefresher', [function() {
  return {
    priority: 1,
    link: function($scope, $element, $attrs) {
      $element.removeAttr('spinner');
      $element.attr('refreshing-icon', 'ion-loading-c');
    },
  };
}])

I realize this is probably more an Angularjs question, but it’d be great if someone shares some info.