gamebrary/src/components/GameCards/GameCardGrid.vue

40 lines
655 B
Vue
Raw Normal View History

2019-06-06 13:44:06 +00:00
<template lang="html">
2019-11-08 20:34:06 +00:00
<div
v-if="gameId && games[gameId]"
:class="gameCardClass">
<img
:src="coverUrl"
:alt="game.name"
@click="openDetails"
>
</div>
2019-06-06 13:44:06 +00:00
</template>
<script>
import GameCardUtils from '@/components/GameCards/GameCard';
export default {
2019-11-08 19:56:03 +00:00
mixins: [GameCardUtils],
2019-06-06 13:44:06 +00:00
};
</script>
<style lang="scss" rel="stylesheet/scss" scoped>
2019-11-08 20:34:06 +00:00
@import "~styles/styles";
2019-06-06 13:44:06 +00:00
2019-11-08 20:34:06 +00:00
.game-card {
display: flex;
flex-direction: column;
position: relative;
width: 94.5px;
margin-bottom: 4px;
border-radius: $border-radius;
overflow: hidden;
cursor: pointer;
2019-06-06 13:44:06 +00:00
2019-11-08 20:34:06 +00:00
img {
width: 100%;
height: auto;
}
}
2019-06-06 13:44:06 +00:00
</style>