import Component from 'ember-component';
import computed from 'ember-computed';

export default Component.extend({
  tagName: 'li',

  /* passed in */
  game: null,
  onGameSelect() {},

  /* internal properties */
  gameBox: computed('game.box.template', function() {
    return this.get('game.box.template').replace('{width}', 26).replace('{height}', 36);
  }),

  actions: {
    onSelect(game) {
      this.get('onGameSelect')(game);
    }
  }
});
