aboutsummaryrefslogtreecommitdiff
path: root/src/App.vue
blob: 04563889dbf05741a82431124b32889201bf0368 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<script>
import tol from './tol.json';
export default {
	data() {
		return {
			tol: tol,
			tiles: tol.map(e => ({name: e.name}))
		}
	}
}
</script>

<template>
	<div id="grid">
		<img v-for="tile in tiles" :src="'/src/assets/' + tile.name + '.jpg'" :alt="tile.name" :id="tile.name"
			@click="$event.target.style.transform = 'translate(20%,30%)'"/>
	</div>
</template>

<style>
#app {
	background-color: black;
}
#grid {
	display: flex;
	flex-flow: row wrap;
	justify-content: center;
}
img {
	margin: 5px;
	flex: auto;
	transition: transform 1s;
	max-width: 100%;
}
</style>