Try get a smaller version of the wine image.
This commit is contained in:
		| @@ -27,7 +27,7 @@ | |||||||
|           </router-link> |           </router-link> | ||||||
|            |            | ||||||
|           <div class="won-wine"> |           <div class="won-wine"> | ||||||
|             <img :src="win.wine.image"> |             <img :src="smallerWineImage(win.wine.image)"> | ||||||
|  |  | ||||||
|             <div class="wine-details"> |             <div class="wine-details"> | ||||||
|               <h3>{{ win.wine.name }}</h3> |               <h3>{{ win.wine.name }}</h3> | ||||||
| @@ -71,6 +71,11 @@ export default { | |||||||
|       this.winner = winner |       this.winner = winner | ||||||
|       this.winningColors = this.findWinningColors() |       this.winningColors = this.findWinningColors() | ||||||
|     }, |     }, | ||||||
|  |     smallerWineImage(image) { | ||||||
|  |       if (image && image.includes(`515x515`)) | ||||||
|  |         return image.replace(`515x515`, `175x175`) | ||||||
|  |       return image | ||||||
|  |     }, | ||||||
|     findWinningColors() { |     findWinningColors() { | ||||||
|       const colors = this.winner.highscore.map(win => win.color) |       const colors = this.winner.highscore.map(win => win.color) | ||||||
|       const colorOccurences = {} |       const colorOccurences = {} | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user