Author | SHA1 | Message | Date |
---|---|---|---|
Adrien | f3e7c92c7d | 🚧: init new backgrounds | 4 years ago |
Adrien | d0c4febf87 |
🚚: move files for VueJS good practices compliance
see https://vuejs.org/v2/style-guide/#Tightly-coupled-component-names-strongly-recommended for Objective and Timer see https://vuejs.org/v2/style-guide/#Single-instance-component-names-strongly-recommended for TheSelector |
4 years ago |
Adrien | 2d75ad4457 | ⬆️: update to node 14 | 4 years ago |
@@ -1 +1 @@ | |||||
12 | |||||
14 |
@@ -1,5 +1,5 @@ | |||||
FROM node:erbium-alpine | |||||
RUN apk add python2 | |||||
FROM node:fermium-alpine | |||||
RUN apk add python2 make g++ | |||||
WORKDIR /home/node | WORKDIR /home/node | ||||
COPY package.json yarn.lock ./ | COPY package.json yarn.lock ./ | ||||
RUN chown node:node -R . | RUN chown node:node -R . | ||||
@@ -9,7 +9,7 @@ | |||||
## Build Setup | ## Build Setup | ||||
This project run on the node 12 LTS version (Erbium) | |||||
This project run on the node 14 LTS version (Fermium) | |||||
``` bash | ``` bash | ||||
# install dependencies | # install dependencies | ||||
@@ -52,7 +52,7 @@ | |||||
"rimraf": "^2.6.2", | "rimraf": "^2.6.2", | ||||
"sass-loader": "7.3.1", | "sass-loader": "7.3.1", | ||||
"semver": "^5.4.1", | "semver": "^5.4.1", | ||||
"shelljs": "^0.7.8", | |||||
"shelljs": "^0.8.4", | |||||
"sw-precache-webpack-plugin": "^0.11.4", | "sw-precache-webpack-plugin": "^0.11.4", | ||||
"uglify-es": "^3.1.3", | "uglify-es": "^3.1.3", | ||||
"url-loader": "^0.6.2", | "url-loader": "^0.6.2", | ||||
@@ -41,8 +41,7 @@ | |||||
box-sizing: border-box | box-sizing: border-box | ||||
padding-top: 16px | padding-top: 16px | ||||
main | |||||
margin-top: 20px | |||||
</style> | </style> | ||||
<style lang="sass"> | <style lang="sass"> | ||||
@@ -1,26 +1,35 @@ | |||||
<template> | <template> | ||||
<div class="battleground" v-if="battleground"> | <div class="battleground" v-if="battleground"> | ||||
<div>Welcome to {{ battleground.name }}</div> | |||||
<div class="battleground-content"> | |||||
<div>Welcome to {{ battleground.name }}</div> | |||||
<div id="objectives" class="objectives"> | |||||
<div class="row" v-for="objectiveRow in battleground.objectives"> | |||||
<template v-for="objective in objectiveRow"> | |||||
<Objective :objective="objective"></Objective> | |||||
</template> | |||||
<div id="objectives" class="objectives"> | |||||
<div class="row" v-for="objectiveRow in battleground.objectives"> | |||||
<template v-for="objective in objectiveRow"> | |||||
<Objective :objective="objective"></Objective> | |||||
</template> | |||||
</div> | |||||
</div> | </div> | ||||
<router-link to="/battlegrounds">Back to selector</router-link> | |||||
</div> | </div> | ||||
<router-link to="/battlegrounds">Back to selector</router-link> | |||||
</div> | </div> | ||||
</template> | </template> | ||||
<style lang="sass" scoped> | <style lang="sass" scoped> | ||||
$border-style: 1px solid #66CCFF | $border-style: 1px solid #66CCFF | ||||
.battleground | |||||
background-image: url(/static/backgrounds/alterac-pass.jpg) | |||||
background-size: contain | |||||
&-content | |||||
backdrop-filter: blur(4px) | |||||
height: 100vh | |||||
.objectives | .objectives | ||||
display: flex | display: flex | ||||
flex-direction: column | flex-direction: column | ||||
height: 70vh | |||||
height: 100% | |||||
.row | .row | ||||
display: flex | display: flex | ||||
justify-content: space-between | justify-content: space-between | ||||
@@ -36,8 +45,8 @@ | |||||
<script> | <script> | ||||
import BATTLEGROUNDS from '@/gameInfos/battlegrounds' | import BATTLEGROUNDS from '@/gameInfos/battlegrounds' | ||||
import Timer from '@/components/Battleground/Timer' | |||||
import Objective from '@/components/Battleground/Objective' | |||||
import Timer from '@/components/Timer' | |||||
import Objective from '@/components/Objective' | |||||
export default { | export default { | ||||
name: 'Battleground', | name: 'Battleground', | ||||
@@ -46,8 +55,11 @@ | |||||
} | } | ||||
}, | }, | ||||
computed: { | computed: { | ||||
battlegroundId () { | |||||
return this.$route.params.battlegroundId | |||||
}, | |||||
battleground () { | battleground () { | ||||
return BATTLEGROUNDS[this.$route.params.battlegroundId] | |||||
return BATTLEGROUNDS[this.battlegroundId] | |||||
} | } | ||||
}, | }, | ||||
watch: { | watch: { | ||||
@@ -25,7 +25,7 @@ | |||||
</style> | </style> | ||||
<script> | <script> | ||||
import Timer from '@/components/Battleground/Timer' | |||||
import Timer from '@/components/Timer' | |||||
export default { | export default { | ||||
name: 'Objective', | name: 'Objective', | ||||
props: { | props: { |
@@ -24,7 +24,7 @@ | |||||
} | } | ||||
</script> | </script> | ||||
<style lang="sass"> | |||||
<style lang="sass" scoped> | |||||
.map-selector | .map-selector | ||||
&__map-list | &__map-list | ||||
list-style-type: none | list-style-type: none | ||||
@@ -34,9 +34,6 @@ | |||||
padding: 10px 0 10px 10px | padding: 10px 0 10px 10px | ||||
border-top: solid #5659aa 1px | border-top: solid #5659aa 1px | ||||
border-left: none | border-left: none | ||||
</style> | |||||
<style lang="sass" scoped> | |||||
a | a | ||||
text-decoration: none | text-decoration: none | ||||
color: inherit | color: inherit |
@@ -2,7 +2,7 @@ import Vue from 'vue' | |||||
import Router from 'vue-router' | import Router from 'vue-router' | ||||
import Hello from '@/components/Hello' | import Hello from '@/components/Hello' | ||||
import BattlegroundSelector from '@/components/BattlegroundSelector' | |||||
import TheBattlegroundSelector from '@/components/TheBattlegroundSelector' | |||||
import Battleground from '@/components/Battleground' | import Battleground from '@/components/Battleground' | ||||
Vue.use(Router) | Vue.use(Router) | ||||
@@ -16,7 +16,7 @@ export default new Router({ | |||||
}, | }, | ||||
{ | { | ||||
path: '/battlegrounds', | path: '/battlegrounds', | ||||
component: BattlegroundSelector | |||||
component: TheBattlegroundSelector | |||||
}, | }, | ||||
{ | { | ||||
path: '/battleground/:battlegroundId', | path: '/battleground/:battlegroundId', | ||||
@@ -7,7 +7,8 @@ | |||||
// ## Colors ## | // ## Colors ## | ||||
// ############ | // ############ | ||||
$blizzard-background-color: #0A020F | $blizzard-background-color: #0A020F | ||||
$blizzard-font-color: #66CCFF | |||||
$blizzard-background-color-transparent: #0A020FCC | |||||
$blizzard-font-color: #fff | |||||
=blizzard-header-gradient | =blizzard-header-gradient | ||||
background: #0d39a0 /* Old browsers */ | background: #0d39a0 /* Old browsers */ | ||||