安卓textarea的父容器已隐藏此控件内容提示漂移到屏幕顶部bug
<view class= "dialog-root" hidden = "{{!currentItemId}}" > <view class= "dialog-layout" id= "dialog-layout" > <form bindsubmit= "formSubmit" bindreset= "formReset" > <textarea name= "input" class= "dialog-input" id= "commentinput" placeholder= "请输入评论" style= "height:auto" value= "{{input}}" placeholder-style= "color:#EBEBEB;" /> <view class= "dialog-action" > <button class= "dialog-cancnel" bindtap= "onDialogCancelPress" formType= "reset" >取消</button> <button class= "dialog-confirm" bindtap= "onDialogOkPress" formType= "submit" >确定</button> </view> </form> </view> </view> .dialog-root { background : black ; width : 100% ; height : 100% ; position : fixed ; bottom : 0 ; left : 0 ; right : 0 ; top : 0 ; z-index : 998 ; display : flex; align-items: center ; justify- content : center ; background-color : rgba( 0 , 0 , 0 , 0.2 ); box-sizing: border-box; } .dialog-root .dialog-layout { border-radius: 15 rpx; width : 70% ; height : 70 vw; z-index : 999 ; background-color : white ; color : black ; } #dialog-layout { padding : 15 rpx; } |
默认是隐藏的,
对吧,但是出现了啥情况呢, 请输入评论几个字在屏幕上边了没有被隐藏了, 当我把这个对话框弹出来后
就正常了,隐藏 后 请输入评论寄给字屏幕左边。
area
rea