import ngModule from '../module'; class ItemProduct { onClick(event) { if (event.defaultPrevented) event.stopImmediatePropagation(); } clone(event) { event.preventDefault(); this.ItemList.cloneItem(this.item); } preview(event) { event.preventDefault(); this.ItemList.showItemPreview(this.item); } } ngModule.component('vnItemProduct', { template: require('./item-product.html'), bindings: { item: '<' }, controller: ItemProduct, require: { ItemList: '^vnItemList' } });