[英]jQuery UI 1.10.3 Dialog Box, dragging moves away dialog box
我使用jQuery 1.10.1與migrate,jQueryUI 1.10.3,jQueryValidate 1.11.1。
只是使用一個簡單的表單,它有兩個字段。 在提交時,如果未提供值,則會顯示一個帶有消息的對話框。
問題:在IE 10中當用戶嘗試移動(拖動)錯誤消息對話框時,它只是向下移動。 僅當瀏覽器窗口中出現垂直滾動條時才會發生這種情況。 在Chrome 27中驗證它有效。 有時在Firefox 21和Opera 12.15中會出現同樣的問題。
注意:它適用於jQuery UI 1.10.2只有問題在1.10.3中。
樣本來源
<html>
<head>
<style type="text/css">
.label {width:100px;text-align:right;float:left;padding-right:10px;font-weight:bold;}
.label1 {width:350px; text-align:right; padding-top:300px;padding-bottom:30px; font-weight:bold; }
</style>
<link rel="stylesheet" type="text/css" href="http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css" />
<script src="http://code.jquery.com/jquery-1.10.1.min.js"></script>
<script src="http://code.jquery.com/jquery-migrate-1.2.1.min.js"></script>
<!-- <script src="http://ajax.aspnetcdn.com/ajax/jquery.ui/1.10.2/jquery-ui.min.js"></script> -->
<script src="http://ajax.aspnetcdn.com/ajax/jquery.ui/1.10.3/jquery-ui.min.js"></script>
<script src="http://ajax.aspnetcdn.com/ajax/jquery.validate/1.11.1/jquery.validate.min.js"></script>
<script>
$(function() {
$("#register-form").validate({
rules: { firstname: "required", lastname: "required" },
messages: { firstname: "Need First Name", lastname: "Need Last Name" },
showErrors: function(errorMap, errorList) {
$("#diverror").dialog({ modal: true });
},
submitHandler: function(form) {
form.submit();
}
});
});
</script>
</head>
<body>
<form method="post" id="register-form">
<div class="label">First Name</div><input type="text" id="firstname" name="firstname" /><br />
<div class="label">Last Name</div><input type="text" id="lastname" name="lastname" /><br />
<div class="label1">Making page to scroll. Scroll down to submit</div>
<div class="label1">Making page to scroll. Scroll down to submit</div>
<div class="label1">Making page to scroll. Scroll down to submit</div>
<div style="margin-left:140px;"><input type="submit" name="submit" value="Submit" /></div>
</form>
<div id="diverror" title="Basic dialog"><p>This is the default DIVERROR which is useful for displaying information.</p></div>
</body>
</html>
已驗證的jQuery UI網站,它是jQuery UI中的一個錯誤。
機票#9354: http : //bugs.jqueryui.com/ticket/9354
門票#9315: http : //bugs.jqueryui.com/ticket/9315
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.