Vue Exercise Seven: 02_01_ Baidu input method

Demo online address:
https://sx00xs.github.io/test/7/index.html
----------------------------- ----------------------------------
IDE: VSCode
file formats: .vue
resolve to be completed :()

<template>
  <div id="app">
    <div class="outer">
      <button @click="handleShow">输入法</button>
      <ul class="ime" v-show="show">
        <li><a href="#">手写</a></li>
        <li><a href="#">拼音</a></li>
        <li class="close"
        @click="handleShow"
        ><a href="#">关闭</a></li>
      </ul>
    </div>
  </div>
</template>
<script>
export default {
  data:function(){
    return{
      show:false
    }
  },
  methods:{
    handleShow(){
      this.show=!this.show;
    }
  }
}
</script>

 

Guess you like

Origin www.cnblogs.com/sx00xs/p/11265609.html