zoukankan      html  css  js  c++  java
  • 手机端ios cube-ui input键盘弹起输入完成后点完成 不回弹的问题

    今天发现最近做的手机端页面 ui 用的cube-ui textarea 输入内容后点击键盘 完成 不回弹的问题  

    记录下来 备忘

    <template>
      <div>
    
        <section class="cube-content">
          <h2 class="cube-index-list-anchor">财务处理</h2>
    
          <div class="scroll-list-wrap">
          <cube-scroll ref="scroll">
          <section class="anchor">
            <p>张小黑:100001ASA1L1</p>
            <p>参照费用:16800</p>
          </section>
          <section class="anchor">
            <cube-upload
            :max="3"
            action="http://devtbsapp.origimed.com:18081/app/qa/Questions/uploadFiles.json?TOKEN=cdWsYYqJQce9FVmhwNTpcV"
            :simultaneous-uploads="1"
            @files-added="filesAdded"
            @file-success="fileSuccess"/>
          </section>
          <section class="anchor">
              <cube-input v-model="value" :placeholder="placeholder" @focus="getFocus"></cube-input>
          </section>
          <section class="anchor">
              <cube-input v-model="pay" :placeholder="pay2" @focus="getFocus"></cube-input>
          </section>
          <section class="anchor">
              <cube-input v-model="time" :placeholder="time2" :readonly="readonly" @focus="showDateTimePicker"></cube-input>
          </section>
          <section class="anchor">
              <cube-textarea v-model="text"  :maxlength="maxlength" :placeholder="text2" @focus="getFocus"></cube-textarea>
          </section>
          <section class="anchor">
              <cube-textarea v-model="explain"  :maxlength="maxlength" :placeholder="text3" @focus="getFocus"></cube-textarea>
          </section>
          <section class="anchor">
            <cube-button :primary="true" :disabled="disabledBtn">确定</cube-button>
            <cube-button class="rback">返回</cube-button>
          </section>
          </cube-scroll>
          </div>
    
        </section>
    
      </div>
    </template>
    getFocus() {
          window.addEventListener('focusout', function () {
           document.body.scrollTop = document.body.scrollHeight;
          })
        },

    就是在每个input上绑定个getFocus事件

    亲试好用  感谢

    https://www.cnblogs.com/yangwenbo/p/11028005.html

  • 相关阅读:
    2007年8月小记
    2007年7月小记
    CS2007.1 在多应用程序中的单点登录
    C#类型转换2
    checkbox与说明文字无法对齐的问题
    css中的内容溢出
    javascript获取的层(div)高度
    C#类型转换3
    js修改css样式表解析(转)
    (转)javascript选择id class
  • 原文地址:https://www.cnblogs.com/junwu/p/11340790.html
Copyright © 2011-2022 走看看