<ion-view view-title="My Favorite">
    <ion-nav-title>
        <img src="img/logo.png" height="100%">
    </ion-nav-title> 
    <ion-content>
        <ion-list>
            <ion-item ng-repeat="item in results"  class="item-thumbnail-left" href="#/app/view/{{ item._id.$oid }}">
                <img ng-src="{{ item.feature_url | get_url  }}" ng-if="item.feature_url">
                <h2>{{item.title ? item.title : "No Title" }}</h2>
                {{ item._id.$oid }}
                <div ng-if="item.categories"> from {{ item.categoires[item.categories.length-1]}}</div><br>
                {{ toDate(item.updated_at) | relativeDate }}
                <ion-option-button class="button-positive icon-left ion-share"
                                   ng-click="share(item)">
                    Share
                </ion-option-button>
                <ion-option-button class="button-energized icon-left ion-star">Favorite</ion-option-button>
            </ion-item>
        </ion-list>
        <ion-infinite-scroll
            ng-if="moreDataCanBeLoaded()"
            icon="ion-loading-c"
            on-infinite="loadMoreData()"
            immediate-check=true
             >
        </ion-infinite-scroll>
            <div ng-if="is_empty">No Result</div>
    </ion-content>
</ion-view>
