vue写车牌号 自定义键盘

vue写车牌号自定义键盘

在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

<template>
  <div>
    <div class="content-wrapper">
      <div class="content-top-wrapper">
        <van-radio-group v-model="radioCarType">
          <van-radio name="1">
            蓝牌
            <img
              slot="icon"
              slot-scope="props"
              :src="props.checked ? radioImg[1] : radioImg[0]"
            />
          </van-radio>
          <van-radio name="2">
            绿牌
            <img
              slot="icon"
              slot-scope="props"
              :src="props.checked ? radioImg[1] : radioImg[0]"
            />
          </van-radio>
          <van-radio name="3">
            黄牌
            <img
              slot="icon"
              slot-scope="props"
              :src="props.checked ? radioImg[1] : radioImg[0]"
            />
          </van-radio>
        </van-radio-group>
      </div>
      <div class="content-middle-wrapper">
        <div class="content-car-number">
          <div class="content-section">
            <div class="content-section-flex flex-card">
              <div class="content-section-flex flex-card-border">
                <button
                  id="font"
                  class="flex-btn"
                  @click="btnClickYue"
                  v-bind:class="{ isClick: isYue }"
                >
                  {{ areaName }}
                </button>
                <span class="blank-border blank-border-first"></span>
                <button
                  id="letter"
                  class="flex-btn"
                  @click="btnClickA"
                  v-bind:class="{ isClick: isA }"
                >
                  {{ areaLetter }}
                </button>
                <div class="flex-mid"><span></span></div>
                <div class="flex-btns">
                  <button
                    id="numOne"
                    @click="btnClickNum('one')"
                    v-bind:class="{ isNumClick: isNumOne }"
                  >
                    {{ numOne }}
                  </button>
                  <span class="blank-border"></span>
                  <button
                    id="numTwo"
                    @click="btnClickNum('two')"
                    v-bind:class="{ isNumClick: isNumTwo }"
                  >
                    {{ numTwo }}
                  </button>
                  <span class="blank-border"></span>
                  <button
                    id="numThree"
                    @click="btnClickNum('three')"
                    v-bind:class="{ isNumClick: isNumThree }"
                  >
                    {{ numThree }}
                  </button>
                  <span class="blank-border"></span>
                  <button
                    id="numFour"
                    @click="btnClickNum('four')"
                    v-bind:class="{ isNumClick: isNumFour }"
                  >
                    {{ numFour }}
                  </button>
                  <span class="blank-border"></span>
                  <button
                    id="numFive"
                    @click="btnClickNum('five')"
                    v-bind:class="{ isNumClick: isNumFive }"
                  >
                    {{ numFive }}
                  </button>
                  <span class="blank-border" v-if="radioCarType == '2'"></span>
                  <button
                    v-if="radioCarType == '2'"
                    id="numSix"
                    @click="btnClickNum('six')"
                    v-bind:class="{ isNumClick: isNumSix }"
                  >
                    {{ numSix }}
                  </button>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
    </div>
    <button class="band-btn" :disabled="!checked" @click="bindCar">
      立即绑定
    </button>
    <div class="shadow" v-if="keyboardShow" @click="completeClick"></div>
    <div
      class="keyboard"
      v-if="keyboardShow"
      :class="{ animationDown: isDown, animationUp: isUp }"
    >
      <button class="btn-complete" @click="completeClick">
        <span>完成</span>
      </button>
      <div v-if="keyboard == 'txt'">
        <div class="keyboard-row" v-for="(item, rows) in carTxt" :key="rows">
          <button
            class="keyboard-row-item"
            v-for="(i, index) in item.name"
            :key="index"
            @click="btnWordClick(rows, index, i)"
          >
            {{ i }}
          </button>
        </div>
        <div class="keyboard-row">
          <button
            class="keyboard-row-item bottom"
            @click="btnBottomClick('新')"
          >
            新
          </button>
          <button
            class="keyboard-row-item bottom"
            @click="btnBottomClick('使')"
          >
            使
          </button>
          <button v-for="j in noneBottomtxt" :key="j" class="none-botton">
            {{ j }}
          </button>
          <div class="keyboard-row-item clear" @click="clearClick">
            <img src="./images/icon_input_delete.png" alt="删除" />
          </div>
        </div>
      </div>
      <div v-if="keyboard == 'num'">
        <div class="keyboard-row" v-for="(item, rows) in carNum" :key="rows">
          <button
            :disabled="
              !isSelectl ? isDisable && i < 10 : isDisable && rows != 0
            "
            class="keyboard-row-item"
            v-for="(i, index) in item.name"
            :key="index"
            @click="btnWordClick(rows, index, i)"
          >
            {{ i }}
          </button>
        </div>
        <div class="keyboard-row">
          <button
            :disabled="isSelectl"
            v-for="(item, index) in carNumBottom"
            :key="index"
            class="keyboard-row-item bottom"
            @click="btnBottomNumClick(item)"
          >
            {{ item }}
          </button>
          <button v-for="j in noneBottom" :key="j" class="none-botton">
            {{ j }}
          </button>
          <div class="keyboard-row-item clear" @click="clearClick">
            <img src="./images/icon_input_delete.png" alt="删除" />
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      num: "",
      radioCarType: "1", // 单选
      radioImg: [
        require("./images/radio0.png"),
        require("./images/radio1.png"),
        require("./images/checked1.png"),
        require("./images/checked0.png"),
      ], //单选图标
      checked: true, //协议复选框
      isAble: false, //发送控制,
      province: "浙", //省份简称
      plateNumber: "", //默认显示E
      checkbox: false,
      isDown: false,
      isUp: false,
      selected: null,
      isSelectx: false,
      isSelectl: false,
      key: "1",
      areaName: "",
      areaLetter: "",
      numOne: "",
      numTwo: "",
      numThree: "",
      numFour: "",
      numFive: "",
      numSix: "",
      isYue: false,
      keyboardShow: false,
      keyboard: false,
      isA: false,
      isNumOne: false,
      isNumTwo: false,
      isNumThree: false,
      isNumFour: false,
      isNumFive: false,
      isNumSix: false,
      isDisable: false,
      carTxt: [
        {
          name: ["粤", "京", "冀", "沪", "津", "晋", "蒙", "辽", "吉", "黑"],
        },
        {
          name: ["苏", "浙", "皖", "闽", "赣", "鲁", "豫", "鄂", "湘", "桂"],
        },
        {
          name: ["琼", "渝", "川", "贵", "云", "藏", "陕", "甘", "青", "宁"],
        },
      ],
      carNumBottom: ["W", "X", "Y", "Z"],
      noneBottom: ["", "", "", ""],
      noneBottomtxt: ["", "", "", "", "", ""],
      carNum: [
        {
          name: ["1", "2", "3", "4", "5", "6", "7", "8", "9", "0"],
        },
        {
          name: ["A", "B", "C", "D", "E", "F", "G", "H", "J", "K"],
        },
        {
          name: ["L", "M", "N", "P", "Q", "R", "S", "T", "U", "V"],
        },
      ],
    };
  },
  beforeCreate() {
    document
      .querySelector("body")
      .setAttribute("style", "background: #f5f5f5 !important");
  },
  destroyed() {
    document.querySelector("body").setAttribute("style", "background: #fff");
  },
  mounted() {
    this.isYue = true;
    this.isA = false;
    this.isUp = true;
    this.isNumOne = false;
    this.isNumTwo = false;
    this.isNumThree = false;
    this.isNumFour = false;
    this.isNumFive = false;
    this.isNumSix = false;
    this.keyboardShow = true;
    this.keyboard = "txt";
    this.key = 1;
  },
  watch: {
    radioCarType(news) {
      if (news) {
        this.isYue = false;
        this.keyboardShow = false;
        this.keyboard = false;
        this.key = "1";
        this.areaName = "";
        this.areaLetter = "";
        this.numOne = "";
        this.numTwo = "";
        this.numThree = "";
        this.numFour = "";
        this.numFive = "";
        this.numSix = "";
        this.isNumOne = false;
        this.isNumTwo = false;
        this.isNumThree = false;
        this.isNumFour = false;
        this.isNumFive = false;
        this.isNumSix = false;
      }
    },
  },
  methods: {
    // 车牌号第一位输入框选择
    btnClickYue() {
      this.isYue = true;
      this.isA = false;
      this.isUp = true;
      this.isNumOne = false;
      this.isNumTwo = false;
      this.isNumThree = false;
      this.isNumFour = false;
      this.isNumFive = false;
      this.isNumSix = false;
      this.keyboardShow = true;
      this.keyboard = "txt";
      this.key = 1;
    },
    // 键盘选择显示
    btnWordClick(rows, index, i) {
      this.selected = i;
      if (this.key === 1) {
        this.areaName = i;
        this.isSelectl = false;
        document.getElementById("letter").click();
      } else if (this.key === 2) {
        this.areaLetter = i;
        document.getElementById("numOne").click();
      } else if (this.key === 3) {
        this.numOne = i;
        document.getElementById("numTwo").click();
      } else if (this.key === 4) {
        this.numTwo = i;
        document.getElementById("numThree").click();
      } else if (this.key === 5) {
        this.numThree = i;
        document.getElementById("numFour").click();
      } else if (this.key === 6) {
        this.numFour = i;
        document.getElementById("numFive").click();
      } else if (this.key === 7) {
        this.numFive = i;
        if (this.radioCarType == "2") {
          document.getElementById("numSix").click();
        }
      } else if (this.key === 8) {
        this.numSix = i;
      }
      if ((this.key === 7 || this.key === 8) && this.radioCarType != "2") {
        this.carNumBottom = ["W", "X", "Y", "Z", "港", "澳", "学", "警", "领"];
        this.noneBottom = [];
      } else if (
        this.key === 3 ||
        this.key === 4 ||
        this.key === 5 ||
        this.key === 6
      ) {
        this.carNumBottom = ["W", "X", "Y", "Z"];
        this.noneBottom = ["", "", "", ""];
      } else if (this.radioCarType == "2" && this.key === 2) {
        this.carNumBottom = ["W", "X", "Y", "Z"];
        this.noneBottom = ["", "", "", ""];
      }
    },
    // 车牌第一位选择‘临’,’新‘后的键盘显示
    btnBottomClick(val) {
      this.areaName = val;
      this.isSelectx = true;
      this.isSelectl = false;
      document.getElementById("letter").click();
    },
    // 键盘最后一行字母点击事件
    btnBottomNumClick(i) {
      this.selected = i;
      if (this.key === 2) {
        this.areaLetter = i;
        document.getElementById("numOne").click();
      } else if (this.key === 3) {
        this.numOne = i;
        document.getElementById("numTwo").click();
      } else if (this.key === 4) {
        this.numTwo = i;
        document.getElementById("numThree").click();
      } else if (this.key === 5) {
        this.numThree = i;
        document.getElementById("numFour").click();
      } else if (this.key === 6) {
        this.numFour = i;
        document.getElementById("numFive").click();
      } else if (this.key === 7) {
        this.numFive = i;
        if (this.radioCarType == "2") {
          document.getElementById("numSix").click();
        }
      } else if (this.key === 8) {
        this.numSix = i;
      }
    },
    // 车牌号第二位输入框选择
    btnClickA() {
      this.isDisable = true;
      this.isA = true;
      this.isYue = false;
      this.isUp = true;
      this.isNumOne = false;
      this.isNumTwo = false;
      this.isNumThree = false;
      this.isNumFour = false;
      this.isNumFive = false;
      this.isNumSix = false;
      this.keyboardShow = true;
      this.keyboard = "num";
      this.key = 2;
    },
    // 车牌号后五位或六位输入框选择
    btnClickNum(name) {
      if (this.isSelectl) {
        this.isDisable = true;
      } else {
        this.isDisable = false;
      }
      this.keyboard = "num";
      this.keyboardShow = true;
      this.isYue = false;
      this.isA = false;
      this.isNumOne = false;
      this.isNumTwo = false;
      this.isNumThree = false;
      this.isNumFour = false;
      this.isNumFive = false;
      this.isNumSix = false;
      this.isUp = true;
      if (name === "one") {
        this.isNumOne = true;
        this.key = 3;
      } else if (name === "two") {
        this.isNumTwo = true;
        this.key = 4;
      } else if (name === "three") {
        this.isNumThree = true;
        this.key = 5;
      } else if (name === "four") {
        this.isNumFour = true;
        this.key = 6;
      } else if (name === "five") {
        this.isNumFive = true;
        this.key = 7;
      } else if (name === "six") {
        this.isNumSix = true;
        this.key = 8;
      }
      if ((name === "five" || name === "six") && this.radioCarType != "2") {
        this.carNumBottom = ["W", "X", "Y", "Z", "港", "澳", "学", "警", "领"];
        this.noneBottom = [];
      } else {
        this.carNumBottom = ["W", "X", "Y", "Z"];
        this.noneBottom = ["", "", "", ""];
      }
    },
    // 键盘点击‘完成’
    completeClick() {
      this.isYue = false;
      this.isA = false;
      this.isNumOne = false;
      this.isNumTwo = false;
      this.isNumThree = false;
      this.isNumFour = false;
      this.isNumFive = false;
      this.isNumSix = false;
      this.isUp = false;
      this.isDown = true;
      this.keyboardShow = false;
    },
    // 键盘点击‘删除图标’
    clearClick() {
      if (this.key === 1) {
        this.areaName = "";
      } else if (this.key === 2) {
        document.getElementById("font").click();
        this.areaLetter = "";
      } else if (this.key === 3) {
        document.getElementById("letter").click();
        this.numOne = "";
      } else if (this.key === 4) {
        document.getElementById("numOne").click();
        this.numTwo = "";
      } else if (this.key === 5) {
        document.getElementById("numTwo").click();
        this.numThree = "";
      } else if (this.key === 6) {
        document.getElementById("numThree").click();
        this.numFour = "";
      } else if (this.key === 7) {
        document.getElementById("numFour").click();
        this.numFive = "";
      } else if (this.key === 8) {
        document.getElementById("numFive").click();
        this.numSix = "";
      }
    },
    // 绑定车牌
    bindCar() {
      if (this.radioCarType != "2") {
        if (
          this.areaName === "" ||
          this.areaLetter === "" ||
          this.numOne === "" ||
          this.numTwo === "" ||
          this.numThree === "" ||
          this.numFour === "" ||
          this.numFive === ""
        ) {
          this.$toast("请输入完整车牌");
          return false;
        }
        this.num =
          this.areaName +
          this.areaLetter +
          this.numOne +
          this.numTwo +
          this.numThree +
          this.numFour +
          this.numFive;
      } else {
        if (
          this.areaName === "" ||
          this.areaLetter === "" ||
          this.numOne === "" ||
          this.numTwo === "" ||
          this.numThree === "" ||
          this.numFour === "" ||
          this.numFive === "" ||
          this.numSix === ""
        ) {
          this.$toast("请输入完整车牌");
          return false;
        }
        this.num =
          this.areaName +
          this.areaLetter +
          this.numOne +
          this.numTwo +
          this.numThree +
          this.numFour +
          this.numFive +
          this.numSix;
      }
    },
  },
};
</script>

<style lang="scss" scoped>
.content-wrapper {
  width: 100%;
  height: auto;
  background-color: #fff;
  margin-top: 0.2rem;
}

.content-top-wrapper {
  height: 0.96rem;
  padding: 0 0.3rem;
  font-size: 0.32rem;
  color: #212121;
  border-bottom: 1px solid #f5f5f5;
}

.content-top-wrapper img {
  width: 0.34rem;
  height: 0.34rem;
  vertical-align: initial;
}

.van-radio-group {
  width: 80%;
  height: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.shadow {
  width: 100vw;
  height: 100vh;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 9;
  background: rgba(000,000,000,0);
}
.content-middle-wrapper {
  width: 100%;
  height: 1.4rem;
  border-bottom: 10px solid #f5f5f5;
  padding: 0 0.15rem;
}

.plate-number-box {
  width: 100%;
  height: 1rem;
  padding-top: 0.4rem;
}

.province-box {
  width: 0.6rem;
  height: 0.6rem;
  position: relative;
}

.province-box .province-show {
  width: 100%;
  height: 100%;
  position: absolute;
  border-bottom: 1px solid #c7c7c7;
  top: 0;
  left: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 0.36rem;
}

.province-box input {
  width: 100%;
  height: 100%;
  opacity: 0;
}

.plateNumber-box {
  width: calc(100% - 0.7rem);
  height: 0.6rem;
  position: relative;
  overflow: hidden;
}

.plateNumber-box input {
  width: 200%;
  height: 100%;
  opacity: 0;
  color: transparent;
  text-indent: -999em;
  margin-left: -100%;
}

.plateNumber-box .plateNumber-show {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  display: flex;
  justify-content: space-around;
  align-items: center;
}

.plateNumber-show div {
  width: 10%;
  height: 0.6rem;
  border-bottom: 1px solid #c7c7c7;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 0.3rem;
}

.plateNumber-show div.new-powwer {
  width: 0.85rem;
  font-size: 0.24rem;
  color: #999;
}

.van-checkbox__label {
  margin-left: 2px !important;
}

.band-btn {
  width: 7rem;
  height: 0.88rem;
  background-color: #12b7f5;
  color: #fff;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0.5rem auto;
  font-size: 0.32rem;
  border: none;
  border-radius: 0.04rem;
}

.band-btn:disabled {
  background-color: #bbb;
}

.auth-code {
  width: 4rem;
  height: 100%;
  font-size: 0.28rem;
}

.send-btn {
  width: 1.52rem;
  height: 0.6rem;
  border-radius: 0.04rem;
  border: 0.02rem solid #12b7f5;
  position: absolute;
  right: 0.3rem;
  top: 0;
  bottom: 0;
  margin: auto;
  font-size: 0.24rem;
  color: #12b7f5;
  display: flex;
  justify-content: center;
  align-items: center;
}

.send-btn:disabled {
  border-color: #999;
  color: #999999;
}

.provinceData-wrapper {
  width: 7rem;
  height: 4rem;
}

.provinceData {
  width: 100%;
  height: 100%;
  padding: 0.33rem 0.1rem 0.2rem 0.14rem;
}

.province-btn {
  width: 0.6rem;
  height: 0.7rem;
  display: flex;
  justify-content: center;
  align-items: center;
  border: 1px solid #b5b5b5;
  border-radius: 0.04rem;
  font-size: 0.28rem;
  margin-left: 0.11rem;
  margin-bottom: 0.15rem;
  border-radius: 0.1rem;
}

.area-wrapper {
  width: 100%;
  height: auto;
  padding: 0.3rem;
  background-color: #fff;
  margin-top: 0.2rem;
}

.area-wrapper .title {
  font-size: 0.26rem;
  margin-bottom: 0.3rem;
}

.menu-wrapper {
  width: 76%;
  height: 0.68rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.menu-wrapper .menu {
  width: 2.16rem;
  height: 0.68rem;
  color: #333333;
  border: 1px solid #cecccc;
  border-radius: 0.08rem;
  font-size: 0.24rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.menu-wrapper .menu.active {
  border-color: #12b7f5;
  background-color: #ebf9fe;
  color: #12b7f5;
}
.content-car-number {
  padding-top: 0.1rem;
}

.content-car-number .car-content-title {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-pack: justify;
  -ms-flex-pack: justify;
  justify-content: space-between;
  padding: 0 0.32rem;
  margin-bottom: 0.16rem;
}

.content-car-number .car-content-title span {
  font-size: 0.34rem;
}

.content-car-number .car-content-title .ze-checkbox {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
}

.content-car-number .car-content-title .ze-radio-text {
  font-size: 0.28rem;
}

.content-car-number .car-content-title .ze-checkbox-icon {
  color: #ffedb1 !important;
  margin-right: 0.08rem;
}

.content-car-number .content-section .content-section-flex {
  width: 100%;
  height: 100%;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  font-size: 0.32rem;
}

.content-car-number .content-section .content-section-flex .blank-border {
  height: 0.44rem;
  width: 1px;
  /*no*/
  border-right: 1px solid #ddd;
  /*no*/
  margin-top: 0.22rem;
  /* margin-left: -0.15rem; */
  z-index: 1;
}

.content-car-number
  .content-section
  .content-section-flex
  .blank-border.blank-border-first {
  margin-top: 0;
}

.content-car-number .content-section .content-section-flex.flex-card {
  color: #000;
}

.content-car-number .content-section .content-section-flex.flex-card .flex-btn {
  width: 0.88rem;
  height: 0.88rem;
  border: none;
  text-align: center;
  background: #fff;
  font-size: 0.32rem;
  color: #000;
}

.content-car-number
  .content-section
  .content-section-flex.flex-card
  .flex-btns {
  display: flex;
  background: #fff;
  position: relative;
  height: 0.88rem;
}

.content-car-number
  .content-section
  .content-section-flex.flex-card
  .flex-btns
  button {
  width: 0.78rem;
  height: 0.88rem;
  border: none;
  font-size: 0.32rem;
  color: #000;
  border-radius: 50%;
  background: transparent;
  z-index: 2;
  position: relative;
}

.content-car-number
  .content-section
  .content-section-flex.flex-card
  .flex-btns
  button:first-child {
  margin-left: 0;
}

.content-car-number .content-section .content-section-flex.flex-card .flex-mid {
  margin: 0 0.05rem;
}

.content-car-number
  .content-section
  .content-section-flex.flex-card
  .flex-mid
  span {
  display: block;
  width: 0.1rem;
  height: 0.1rem;
  border-radius: 20rem;
  background: #ddd;
}

.content-car-number .content-section .content-section-flex.flex-card .isClick {
  border: 1px solid #12b7f5;
  /*no*/
  z-index: 50;
  border-radius: 0.08rem;
}

.content-car-number
  .content-section
  .content-section-flex.flex-card
  .isNumClick {
  border-radius: 0.08rem !important;
  border: 1px solid #12b7f5 !important;
  /*no*/
  z-index: 10;
  background-color: #fff !important;
}

.content-car-number .content-section .content-section-flex .flex-card-border {
  border: 1px solid #ddd;
  /*no*/
  border-radius: 0.08rem;
}

.keyboard {
  width: 100%;
  height: 5.3rem;
  position: fixed;
  bottom: -5rem;
  background: #eeeeee;
  z-index: 10;
}

.keyboard.animationDown {
  -webkit-animation: slide_dowms 0.3s ease-out;
  animation: slide_dowms 0.3s ease-out;
  -webkit-animation-fill-mode: forwards;
  animation-fill-mode: forwards;
}

.keyboard.animationUp {
  -webkit-animation: slide_ups 0.3s ease-out;
  animation: slide_ups 0.3s ease-out;
  -webkit-animation-fill-mode: forwards;
  animation-fill-mode: forwards;
  box-shadow: 1px 0 5px #cccccc;
}

.keyboard .btn-complete {
  height: 0.9rem;
  text-align: center;
  color: #12b7f5;
  font-size: 0.3rem;
  width: 100%;
  background: #fff;
  border: none;
  border-top: 1px solid #eee;
  margin-bottom: 0.3rem;
}

.keyboard .keyboard-row {
  margin-top: 0.2rem;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-pack: justify;
  -ms-flex-pack: justify;
  justify-content: space-between;
  padding: 0 0.08rem;
  color: #333;
}

.keyboard .keyboard-row:first-child {
  margin-top: 0;
}

.keyboard .keyboard-row .keyboard-row-items {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-pack: left;
  -ms-flex-pack: left;
  justify-content: left;
}

.keyboard .keyboard-row .keyboard-row-bottom {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-pack: justify;
  -ms-flex-pack: justify;
  justify-content: space-between;
}

.keyboard .keyboard-row .keyboard-row-item {
  width: 0.66rem;
  height: 0.8rem;
  background: #fff;
  font-size: 0.34rem;
  border: 1px solid #ccc;
  line-height: 0.8rem;
  border-radius: 0.1rem;
  color: #333;
}

.keyboard-row-item:disabled {
  opacity: 0.7;
}

.keyboard .keyboard-row .keyboard-row-item.bottom {
  height: 0.8rem;
  width: 0.66rem;
  line-height: 0.8rem;
  background: #fff;
  color: #333;
  /*margin-right: 0.08rem;*/
}

.keyboard .keyboard-row .keyboard-row-item.clear {
  width: 1rem;
  height: 0.8rem;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  -webkit-box-pack: center;
  -ms-flex-pack: center;
  justify-content: center;
}

.keyboard .keyboard-row .keyboard-row-item.clear img {
  width: 0.62rem;
}

.keyboard .keyboard-row .none-botton {
  border: none;
  height: 0.8rem;
  width: 0.66rem;
  visibility: hidden;
}

.keyboard button:active {
  background: #f4f4f4 !important;
  color: #999 !important;
}

@-webkit-keyframes slide_ups {
  from {
    bottom: -5rem;
  }

  to {
    bottom: 0;
  }
}

@keyframes slide_ups {
  from {
    bottom: -5rem;
  }

  to {
    bottom: 0;
  }
}

@-webkit-keyframes slide_dowms {
  from {
    bottom: 0;
  }

  to {
    bottom: -5rem;
  }
}

@keyframes slide_dowms {
  from {
    bottom: 0;
  }

  to {
    bottom: -5rem;
  }
}
</style>

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:/a/41217.html

如若内容造成侵权/违法违规/事实不符,请联系我们进行投诉反馈qq邮箱809451989@qq.com,一经查实,立即删除!

相关文章

前端学习笔记:JavaScript基础语法(ECMAScript)

此博客参考b站&#xff1a;【黑马程序员前端JavaScript入门到精通全套视频教程&#xff0c;javascript核心进阶ES6语法、API、js高级等基础知识和实战教程】https://www.bilibili.com/video/BV1Y84y1L7Nn?p76&vd_source06e5549bf018e111f4275c259292d0da 这份笔记适用于已…

ETHERNET/IP转TCP/IP网关tcp/ip协议包含哪几层

大家好&#xff0c;今天我们将带大家了解一款自主研发的通讯网关&#xff0c;远创智控YC-EIP-TCP/IP。这是一个强大的工具&#xff0c;能帮助我们将ETHERNET/IP网络和TCP/IP网络连接在一起&#xff0c;让我们更好地管理和监控网络。 1, 首先&#xff0c;让我们来看看这款网关…

Html基础知识学习——圣杯布局、margin负值、等高布局(十七)

文章目录 圣杯布局margin负值等高布局 圣杯布局 两边页面固定中间页面宽度随着浏览器大小自适应 <!DOCTYPE html> <html lang"en"><head><meta charset"UTF-8"><meta name"viewport" content"widthdevice-widt…

Django中使用反向关系名称(related_name)解决由“多对多”关系引起的字段名字冲突问题引起的迁移命令报错。

当在模型中为关系字段添加了related_name参数后&#xff0c;您可以使用该参数指定的名称来引用反向关系。下面是一个简单的例子来说明如何引用反向关系。 假设您有以下两个模型&#xff1a; from django.db import modelsclass Author(models.Model):name models.CharField(…

十八、Unity游戏引擎入门

1、下载 首先需要下载Unity Hub,下载网址:https://unity.com/cn。 然后在其中下载Unity编辑器并安装,可选择最新版本。 接着需要选择适合的开发环境,例如Android Studio或Xcode,以便进行手机游戏开发。在安装完Unity后,需要根据项目需求下载对应的模块和插件…

php 开发微信 h5 支付 APIv3 接入超详细流程

✨ 目录 &#x1f388; 申请商户号&#x1f388; 申请商户证书&#x1f388; 设置V3密钥&#x1f388; 开通H5支付&#x1f388; 设置支付域名&#x1f388; SDK 下载&#x1f388; 第一次下载平台证书&#x1f388;非第一次下载平台证书&#x1f388; H5下单 &#x1f388; 申…

CentOS7中安装docker并配置阿里云加速器

文章目录 一、docker的安装二、docker的卸载三、配置加速器四、docker-compose安装五、docker-compose卸载六、docker-compose相关命令七、常用shell组合 一、docker的安装 参考&#xff1a;https://docs.docker.com/engine/install/centos 本文内容是基于&#xff1a;CentOS L…

管理软件开发平台:用科技提升数据治理能力,实现流程化办公!

如果实现流程化办公&#xff0c;想必是很多企业心心念念的发展愿望。但是&#xff0c;如何实现&#xff1f;利用什么样的平台可以完成这一目标&#xff1f;这是很多人值得深思的问题之一。管理软件开发平台实行100%全源码开放&#xff0c;是轻量级、可视化低代码开发平台&#…

Python Web框架 Flask 安装、使用

Python Web框架 Flask 安装 安装 Flask 框架 首先需要安装 Flask 框架, 可以通过以下命令安装: [rootlocalhost web]# pip3 install Flask Collecting FlaskDownloading Flask-2.0.3-py3-none-any.whl (95 kB)|██████████████████████████████…

【Visual Studio Code】---自定义键盘快捷键设置

概述 一个好的文章能够帮助开发者完成更便捷、更快速的开发。书山有路勤为径&#xff0c;学海无涯苦作舟。我是秋知叶i、期望每一个阅读了我的文章的开发者都能够有所成长。 一、进入键盘快捷键设置 1、进入键盘快捷键设置方法1 使用快捷键进入键盘快捷键设置先按 Ctrl K再…

基于springboot的企业员工工资管理系统(财务系统)

项目描述 临近学期结束&#xff0c;还是毕业设计&#xff0c;你还在做java程序网络编程&#xff0c;期末作业&#xff0c;老师的作业要求觉得大了吗?不知道毕业设计该怎么办?网页功能的数量是否太多?没有合适的类型或系统?等等。这里根据疫情当下&#xff0c;你想解决的问…

php实现站群软件权限管理功能示例

1.管理员页面RBAC.php <!DOCTYPE html> <html> <head> <meta charset"UTF-8"> <title>权限管理</title> <script src"bootstrap/js/jquery-1.11.2.min.js"></script> </head>…

计算机网络 day11 tcpdump - 传输层 - netstat - socket - nc - TCP/UDP头部

目录 故障排查 tcpdump抓包工具 传输层&#xff08;TCP和UDP协议&#xff09; 传输层的作用 应用程序和端口号有什么关系&#xff1f; 传输层端对端连接实现拓扑图 如何查看自己的linux机器开放了哪些端口&#xff1f; 1、netstat(network status 网络的状态) netsta…

安卓APK反编译+修改+重打包+签名

目录 1.下载反编译工具包。2.将APK包&#xff0c;重命名为ZIP&#xff0c;解压。放到反编译根目录下。3.使用apktool反编译修改smail文件&#xff0c;进行重打包4.重新打包5.重签名 1.下载反编译工具包。 反编译工具包地址&#xff1a;百度网盘 提取码&#xff1a;dsu3 解压后…

传智教育成功入选教育部2023年产学合作协同育人项目

传智教育成功入选教育部2023年产学合作协同育人项目 近日&#xff0c;教育部产学合作协同育人项目专家组发布《关于公布教育部产学合作协同育人项目指南通过企业名单&#xff08;2023年5月&#xff09;的通知》&#xff0c;传智教育申报的“教学内容和课程体系改革项目 、师资…

标注工具Labelimg,正常运行显示,但是对图片点击Create RectBox画矩形框开始闪退

问题描述*&#xff1a;标注工具Labelimg&#xff0c;正常运行显示&#xff0c;但是对图片点击Create RectBox画矩形框开始闪退&#xff0c;闪退出现以下代码 File “C:\ProgramData\anaconda3\Lib\site-packages\libs\canvas.py”, line 530, in paintEvent p.drawLine(self.p…

一探究竟:人工智能、机器学习、深度学习

一、人工智能 1.1 人工智能是什么&#xff1f; 1956年在美国Dartmounth 大学举办的一场研讨会中提出了人工智能这一概念。人工智能&#xff08;Artificial Intelligence&#xff09;&#xff0c;简称AI&#xff0c;是计算机科学的一个分支&#xff0c;它企图了解智能的实质&am…

4. 设计(黑盒)测试用例 (一) 等价类 边界值 判定表

本篇文章我们将详细介绍如何来测试用例。 1. 设计测试用例的基本要素 1.1 测试用例概念 测试用例&#xff08;Test Case&#xff09;是为了实施测试而向被测试的系统提供的一组集合。 1.2 测试用例要素 测试环境、测试步骤、测试数据、预期结果。 1.3 测试用例的重要性 提…

异步fifo(1)

什么时异步fifo FIFO&#xff0c;即First In First Out &#xff0c;是一种先进先出的数据缓存器&#xff0c;异步FIFO 是指读写时钟不一致&#xff0c;读写时钟是互相独立的。数据从一个时钟域写入FIFO缓冲区&#xff0c;并从另一个时钟域的同一FIFO缓冲区中读取数据&#xf…