generated from VLADIMIR/template_frontend
add block game
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
import { Footsteps } from '@vicons/ionicons5'
|
||||
import { ContactMailRound } from '@vicons/material'
|
||||
import { Icon } from '@vicons/utils'
|
||||
import { type PropType,ref } from 'vue';
|
||||
import { type PropType, ref } from 'vue';
|
||||
|
||||
import BeltBlock from './BeltBlock.vue';
|
||||
import HeaderText from './HeaderText.vue';
|
||||
@@ -22,6 +22,10 @@ const props = defineProps({
|
||||
newPlacesCount: {
|
||||
type: Number,
|
||||
required: true
|
||||
},
|
||||
gameStatus: {
|
||||
type: String,
|
||||
required: true
|
||||
}
|
||||
})
|
||||
|
||||
@@ -56,8 +60,6 @@ function getTextForCounter(count: number): string[] {
|
||||
<MetalPlate class="controller-metal controller-metal-left"></MetalPlate>
|
||||
<MetalPlate class="controller-metal controller-metal-right"></MetalPlate>
|
||||
|
||||
|
||||
|
||||
<div class="center-block-700">
|
||||
<div class="controller">
|
||||
|
||||
@@ -81,11 +83,15 @@ function getTextForCounter(count: number): string[] {
|
||||
</div>
|
||||
|
||||
<div class="game-input">
|
||||
<input id="run" class="game-input-run" v-model="code" type="text" placeholder="Место назначения">
|
||||
<input id="run" class="game-input-run" v-model="code" type="text"
|
||||
:placeholder="props.gameStatus == 'run' ? 'Место назначения' : 'Ходы запрещены'"
|
||||
:disabled="props.gameStatus != 'run'">
|
||||
</div>
|
||||
<div class="game-button-run-shadow"></div>
|
||||
<button class="game-button-run" type="submit" :disabled="code.length == 0" v-on:click="addClickButton">
|
||||
<HeaderText>Поехали</HeaderText>
|
||||
<HeaderText v-if="props.gameStatus == 'run'">Поехали</HeaderText>
|
||||
<HeaderText v-if="props.gameStatus == 'pause' || props.gameStatus == 'draft'">Ждём</HeaderText>
|
||||
<HeaderText v-if="props.gameStatus == 'finish'">Всё</HeaderText>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -243,7 +249,7 @@ function getTextForCounter(count: number): string[] {
|
||||
margin: 0 4px;
|
||||
}
|
||||
|
||||
@media (width >= 1025px) {
|
||||
@media (width >=1025px) {
|
||||
.center-block-700 {
|
||||
width: 700px;
|
||||
margin: 0 auto;
|
||||
|
||||
Reference in New Issue
Block a user