| Аутор | SHA1 | Порука | Датум |
|---|---|---|---|
|
|
8182ce97dd | 💄:: make timers bigger | пре 5 година |
|
|
c32061f81f | 🍱: add maps backgrounds | пре 5 година |
|
|
f3e7c92c7d | 🚧: init new backgrounds | пре 5 година |
|
|
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 |
пре 5 година |
| @@ -28,7 +28,7 @@ | |||||
| margin: 0 | margin: 0 | ||||
| height: 56px | height: 56px | ||||
| padding: 0 16px 0 24px | padding: 0 16px 0 24px | ||||
| +blizzard-header-gradient | |||||
| @include blizzard-header-gradient | |||||
| text-shadow: 0 0 1rem #009cff | text-shadow: 0 0 1rem #009cff | ||||
| color: #fff | color: #fff | ||||
| span | span | ||||
| @@ -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,27 +1,40 @@ | |||||
| <template> | <template> | ||||
| <div class="battleground" v-if="battleground"> | <div class="battleground" v-if="battleground"> | ||||
| <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 class="battleground-background" :style="backgroundCss"/> | |||||
| <div class="battleground-content"> | |||||
| <div id="objectives" class="objectives"> | |||||
| <div class="objectives-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 $blizzard-font-color | |||||
| .battleground | |||||
| &-background, &-content | |||||
| height: 100vh | |||||
| width: 100vw | |||||
| &-background | |||||
| position: absolute | |||||
| background-size: cover | |||||
| background-position: center | |||||
| filter: blur(2px) brightness(70%) | |||||
| z-index: -10 | |||||
| .objectives | .objectives | ||||
| display: flex | display: flex | ||||
| flex-direction: column | flex-direction: column | ||||
| height: 70vh | |||||
| .row | |||||
| height: 100% | |||||
| &-row | |||||
| display: flex | display: flex | ||||
| justify-content: space-between | justify-content: space-between | ||||
| flex-grow: 1 | flex-grow: 1 | ||||
| @@ -36,8 +49,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 +59,16 @@ | |||||
| } | } | ||||
| }, | }, | ||||
| computed: { | computed: { | ||||
| battlegroundId () { | |||||
| return this.$route.params.battlegroundId | |||||
| }, | |||||
| battleground () { | battleground () { | ||||
| return BATTLEGROUNDS[this.$route.params.battlegroundId] | |||||
| return BATTLEGROUNDS[this.battlegroundId] | |||||
| }, | |||||
| backgroundCss () { | |||||
| return { | |||||
| backgroundImage: `url(${this.battleground.backgroundUrl})` | |||||
| } | |||||
| } | } | ||||
| }, | }, | ||||
| watch: { | watch: { | ||||
| @@ -61,4 +82,3 @@ | |||||
| } | } | ||||
| } | } | ||||
| </script> | </script> | ||||
| @@ -12,6 +12,7 @@ | |||||
| <div> | <div> | ||||
| <Timer | <Timer | ||||
| ref="timer" | ref="timer" | ||||
| class="objective-timer" | |||||
| :initialTime="objective.initialSpawnTime" | :initialTime="objective.initialSpawnTime" | ||||
| /> | /> | ||||
| </div> | </div> | ||||
| @@ -22,10 +23,13 @@ | |||||
| .objective | .objective | ||||
| width: 100% | width: 100% | ||||
| text-align: center | text-align: center | ||||
| &-timer | |||||
| font-size: 2rem | |||||
| </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 | ||||
| @@ -16,6 +16,7 @@ const BOT = 'bottom' | |||||
| export default { | export default { | ||||
| alteracPass: { | alteracPass: { | ||||
| name: 'Alterac Pass', | name: 'Alterac Pass', | ||||
| backgroundUrl: '/static/backgrounds/alterac-pass.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| MAP.cavalryPrison | MAP.cavalryPrison | ||||
| @@ -34,6 +35,7 @@ export default { | |||||
| }, | }, | ||||
| battlefieldOfEternity: { | battlefieldOfEternity: { | ||||
| name: 'Battlefield of Eternity', | name: 'Battlefield of Eternity', | ||||
| backgroundUrl: '/static/backgrounds/battlefield-of-eternity.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| MAP.immortals | MAP.immortals | ||||
| @@ -52,6 +54,7 @@ export default { | |||||
| }, | }, | ||||
| blackheartSBay: { | blackheartSBay: { | ||||
| name: "Blackheart's Bay", | name: "Blackheart's Bay", | ||||
| backgroundUrl: '/static/backgrounds/blackhearts-bay.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| CAMPS.graveGolem | CAMPS.graveGolem | ||||
| @@ -75,6 +78,7 @@ export default { | |||||
| }, | }, | ||||
| gardenOfTerror: { | gardenOfTerror: { | ||||
| name: 'Garden of Terror', | name: 'Garden of Terror', | ||||
| backgroundUrl: '/static/backgrounds/garden-of-terror.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| {...CAMPS.giants, position: 'blue top'}, | {...CAMPS.giants, position: 'blue top'}, | ||||
| @@ -94,6 +98,7 @@ export default { | |||||
| }, | }, | ||||
| hanamuraTemple: { | hanamuraTemple: { | ||||
| name: 'Hanamura Temple', | name: 'Hanamura Temple', | ||||
| backgroundUrl: '/static/backgrounds/hanamura.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| {...CAMPS.fortifiaction, position: TOP} | {...CAMPS.fortifiaction, position: TOP} | ||||
| @@ -113,6 +118,7 @@ export default { | |||||
| }, | }, | ||||
| volskayaFoundry: { | volskayaFoundry: { | ||||
| name: 'Volskaya Foundry', | name: 'Volskaya Foundry', | ||||
| backgroundUrl: '/static/backgrounds/volskaya.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| MAP.capturePoints | MAP.capturePoints | ||||
| @@ -141,6 +147,7 @@ export default { | |||||
| }, | }, | ||||
| towersOfDoom: { | towersOfDoom: { | ||||
| name: 'Towers of Doom', | name: 'Towers of Doom', | ||||
| backgroundUrl: '/static/backgrounds/towers-of-doom.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| MAP.altars | MAP.altars | ||||
| @@ -159,6 +166,7 @@ export default { | |||||
| }, | }, | ||||
| infernalShrines: { | infernalShrines: { | ||||
| name: 'Infernal Shrines', | name: 'Infernal Shrines', | ||||
| backgroundUrl: '/static/backgrounds/infernal-shrines.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| MAP.shrine | MAP.shrine | ||||
| @@ -178,6 +186,7 @@ export default { | |||||
| }, | }, | ||||
| tombOfTheSpiderQueen: { | tombOfTheSpiderQueen: { | ||||
| name: 'Tomb of the Spider Queen', | name: 'Tomb of the Spider Queen', | ||||
| backgroundUrl: '/static/backgrounds/tomb-of-spider-queen.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| CAMPS.sandGolem | CAMPS.sandGolem | ||||
| @@ -193,6 +202,7 @@ export default { | |||||
| }, | }, | ||||
| skyTemple: { | skyTemple: { | ||||
| name: 'Sky Temple', | name: 'Sky Temple', | ||||
| backgroundUrl: '/static/backgrounds/sky-temple.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| MAP.temples | MAP.temples | ||||
| @@ -212,6 +222,7 @@ export default { | |||||
| }, | }, | ||||
| dragonShire: { | dragonShire: { | ||||
| name: 'Dragon Shire', | name: 'Dragon Shire', | ||||
| backgroundUrl: '/static/backgrounds/dragon-shire.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| MAP.dragon | MAP.dragon | ||||
| @@ -228,6 +239,7 @@ export default { | |||||
| }, | }, | ||||
| cursedHollow: { | cursedHollow: { | ||||
| name: 'Cursed Hollow', | name: 'Cursed Hollow', | ||||
| backgroundUrl: '/static/backgrounds/cursed-hollow.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| {...CAMPS.graveGolem, position: RED} | {...CAMPS.graveGolem, position: RED} | ||||
| @@ -247,6 +259,7 @@ export default { | |||||
| }, | }, | ||||
| braxisHoldout: { | braxisHoldout: { | ||||
| name: 'Braxis Holdout', | name: 'Braxis Holdout', | ||||
| backgroundUrl: '/static/backgrounds/braxis-holdout.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| {...CAMPS.goliaths, position: BLUE}, | {...CAMPS.goliaths, position: BLUE}, | ||||
| @@ -263,6 +276,7 @@ export default { | |||||
| }, | }, | ||||
| warheadJunction: { | warheadJunction: { | ||||
| name: 'Warhead Junction', | name: 'Warhead Junction', | ||||
| backgroundUrl: '/static/backgrounds/warhead-junction.jpg', | |||||
| objectives: [ | objectives: [ | ||||
| [ | [ | ||||
| {...CAMPS.slime, position: TOP} | {...CAMPS.slime, position: TOP} | ||||
| @@ -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', | ||||
| @@ -6,10 +6,12 @@ | |||||
| // ############ | // ############ | ||||
| // ## Colors ## | // ## Colors ## | ||||
| // ############ | // ############ | ||||
| $blizzard-background-color: #0A020F | $blizzard-background-color: #0A020F | ||||
| $blizzard-font-color: #66CCFF | |||||
| $blizzard-background-color-transparent: #0A020FCC | |||||
| $blizzard-font-color: #6CF | |||||
| =blizzard-header-gradient | |||||
| @mixin blizzard-header-gradient | |||||
| background: #0d39a0 /* Old browsers */ | background: #0d39a0 /* Old browsers */ | ||||
| background: -moz-linear-gradient(left, #0d39a0 0%, #2f099b 100%) /* FF3.6-15 */ | background: -moz-linear-gradient(left, #0d39a0 0%, #2f099b 100%) /* FF3.6-15 */ | ||||
| background: -webkit-linear-gradient(left, #0d39a0 0%,#2f099b 100%) /* Chrome10-25,Safari5.1-6 */ | background: -webkit-linear-gradient(left, #0d39a0 0%,#2f099b 100%) /* Chrome10-25,Safari5.1-6 */ | ||||