uni-app 软键盘顶起底部fixed定位的输入框

当点击input框时,软键盘弹出,把fixed定位的输入框向上推起,给input框设置: :adjust-position="true" 即可 

<view class="cu-bar search bg-white" style="position: fixed;left: 0;bottom: 0;width: 100%;z-index: 9999;" >
	<view class="search-form">
		<input :adjust-position="true" type="text" placeholder=" 请输入信息"  v-model="my_say_text"></input>
		<button @click="to_send" type="primary" style="height: 64upx;line-height: 64upx;margin-left: 16upx;background: #FF5959;">发送</button>
	</view>
</view>

猜你喜欢

转载自blog.csdn.net/weixin_44285250/article/details/108789923