2019-01-11 20:20:21 +00:00
|
|
|
<template lang="html">
|
2019-01-17 06:21:41 +00:00
|
|
|
<div :class="['gameboard-placeholder', { dark: darkModeEnabled }]">
|
2019-01-11 20:20:21 +00:00
|
|
|
<div class="list" v-for="list in lists" :key="list.name">
|
|
|
|
<div class="list-header" />
|
|
|
|
|
|
|
|
<div class="games">
|
|
|
|
<div class="game">
|
|
|
|
<placeholder
|
|
|
|
image
|
|
|
|
v-for="n in list.games.length"
|
|
|
|
:lines="2"
|
|
|
|
:key="n"
|
|
|
|
/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
2019-01-17 06:21:41 +00:00
|
|
|
import { mapState, mapGetters } from 'vuex';
|
2019-01-11 20:20:21 +00:00
|
|
|
import Placeholder from '@/components/Placeholder/Placeholder';
|
|
|
|
|
|
|
|
export default {
|
|
|
|
components: {
|
|
|
|
Placeholder,
|
|
|
|
},
|
|
|
|
|
|
|
|
computed: {
|
|
|
|
...mapState(['gameLists', 'platform']),
|
2019-01-17 06:21:41 +00:00
|
|
|
...mapGetters(['darkModeEnabled']),
|
2019-01-11 20:20:21 +00:00
|
|
|
|
|
|
|
lists() {
|
|
|
|
return this.gameLists && this.gameLists[this.platform.code]
|
|
|
|
? this.gameLists[this.platform.code]
|
|
|
|
: null;
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
methods: {
|
|
|
|
randomColumn() {
|
|
|
|
return Math.floor(Math.random() * 4) + 1;
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<style lang="scss" rel="stylesheet/scss" scoped>
|
|
|
|
@import "~styles/styles.scss";
|
|
|
|
|
|
|
|
.gameboard-placeholder {
|
|
|
|
user-select: none;
|
|
|
|
display: flex;
|
|
|
|
align-items: flex-start;
|
|
|
|
}
|
|
|
|
|
|
|
|
.list {
|
|
|
|
flex-shrink: 0;
|
|
|
|
cursor: default;
|
|
|
|
border-radius: $border-radius;
|
|
|
|
background: $color-white;
|
|
|
|
overflow: hidden;
|
|
|
|
position: relative;
|
|
|
|
width: $list-width;
|
|
|
|
margin-right: $gp;
|
|
|
|
max-height: calc(100vh - 81px);
|
2019-01-17 06:21:41 +00:00
|
|
|
}
|
2019-01-11 20:20:21 +00:00
|
|
|
|
2019-01-17 06:21:41 +00:00
|
|
|
.dark .list {
|
|
|
|
background: $color-dark-gray;
|
|
|
|
}
|
2019-01-11 20:20:21 +00:00
|
|
|
|
2019-01-17 06:21:41 +00:00
|
|
|
.list-header {
|
|
|
|
background: $color-dark-gray;
|
|
|
|
height: $list-header-height;
|
|
|
|
position: absolute;
|
|
|
|
width: 100%;
|
|
|
|
}
|
|
|
|
|
|
|
|
.games {
|
|
|
|
margin-top: $list-header-height;
|
|
|
|
width: 100%;
|
|
|
|
padding: $gp / 2;
|
|
|
|
}
|
2019-01-11 20:20:21 +00:00
|
|
|
|
2019-01-17 06:21:41 +00:00
|
|
|
.placeholder {
|
|
|
|
padding-right: $gp;
|
|
|
|
margin-bottom: $gp / 2;
|
2019-01-11 20:20:21 +00:00
|
|
|
}
|
|
|
|
</style>
|