fix(popup): 弹窗居中显示 archor:cc + 修 height:auto 导致的 NaN 位置
Popup 位置计算(height→h)只支持 px/百分比/cheight,不支持 auto:
height:'auto' → parseFloat('auto')=NaN → t=(rect.height-NaN)/2=NaN → top='NaNpx'
浏览器忽略无效值 → 弹窗跑到顶部,表现像 archor:'tc'。
改为 height:'60%' + 显式 archor:'cc'(默认本就是 cc,显式写清居中意图)。
This commit is contained in:
parent
f2afaa82e8
commit
c7a82dc570
@ -66,8 +66,9 @@
|
||||
"auto_dismiss": false,
|
||||
"dismiss_events": ["cancel", "submited"],
|
||||
"movable": true,
|
||||
"archor": "cc",
|
||||
"width": "34%",
|
||||
"height": "auto"
|
||||
"height": "60%"
|
||||
},
|
||||
"options": {
|
||||
"url": "{{entire_url('./new_kb_form.ui')}}"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user