mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 565074 - Write reftests for the placeholder without readonly input element. r=ehsan
--HG-- rename : layout/reftests/forms/placeholder/placeholder-7.html => layout/reftests/forms/placeholder/placeholder-15.html rename : layout/reftests/forms/placeholder/placeholder-8.html => layout/reftests/forms/placeholder/placeholder-16.html rename : layout/reftests/forms/placeholder/placeholder-9.html => layout/reftests/forms/placeholder/placeholder-17.html rename : layout/reftests/forms/placeholder/placeholder-focus-ref.html => layout/reftests/forms/placeholder/placeholder-readonly-focus-ref.html
This commit is contained in:
parent
c42409c3af
commit
d42236f376
18
layout/reftests/forms/placeholder/placeholder-15.html
Normal file
18
layout/reftests/forms/placeholder/placeholder-15.html
Normal file
@ -0,0 +1,18 @@
|
||||
<!DOCTYPE html>
|
||||
<html class="reftest-wait">
|
||||
<!-- Test: when focused, element should show placeholder. -->
|
||||
<script type="text/javascript">
|
||||
function focusPlaceholder()
|
||||
{
|
||||
document.getElementById('p1').focus();
|
||||
}
|
||||
function disableReftestWait()
|
||||
{
|
||||
document.documentElement.className = '';
|
||||
}
|
||||
</script>
|
||||
|
||||
<body onload="focusPlaceholder();">
|
||||
<input type="text" id="p1" value="" placeholder="my placeholder" onfocus="disableReftestWait();">
|
||||
</body>
|
||||
</html>
|
22
layout/reftests/forms/placeholder/placeholder-16.html
Normal file
22
layout/reftests/forms/placeholder/placeholder-16.html
Normal file
@ -0,0 +1,22 @@
|
||||
<!DOCTYPE html>
|
||||
<html class="reftest-wait">
|
||||
<!-- Test: when focused, placeholder update shouldn't show placeholder. -->
|
||||
<script type="text/javascript">
|
||||
function focusPlaceholder()
|
||||
{
|
||||
document.getElementById('p1').focus();
|
||||
}
|
||||
function setPlaceholder()
|
||||
{
|
||||
document.getElementById('p1').placeholder = 'new placeholder';
|
||||
}
|
||||
function disableReftestWait()
|
||||
{
|
||||
document.documentElement.className = '';
|
||||
}
|
||||
</script>
|
||||
|
||||
<body onload="focusPlaceholder();">
|
||||
<input type="text" id="p1" value="" placeholder="my placeholder" onfocus="setPlaceholder(); disableReftestWait();">
|
||||
</body>
|
||||
</html>
|
22
layout/reftests/forms/placeholder/placeholder-17.html
Normal file
22
layout/reftests/forms/placeholder/placeholder-17.html
Normal file
@ -0,0 +1,22 @@
|
||||
<!DOCTYPE html>
|
||||
<html class="reftest-wait">
|
||||
<!-- Test: when focused, value reset shouldn't show placeholder. -->
|
||||
<script type="text/javascript">
|
||||
function focusPlaceholder()
|
||||
{
|
||||
document.getElementById('p1').focus();
|
||||
}
|
||||
function resetValue()
|
||||
{
|
||||
document.getElementById('p1').value = '';
|
||||
}
|
||||
function disableReftestWait()
|
||||
{
|
||||
document.documentElement.className = '';
|
||||
}
|
||||
</script>
|
||||
|
||||
<body onload="focusPlaceholder();">
|
||||
<input type="text" id="p1" value="my value" placeholder="my placeholder" onfocus="resetValue(); disableReftestWait();">
|
||||
</body>
|
||||
</html>
|
@ -1,7 +1,6 @@
|
||||
<!DOCTYPE html>
|
||||
<html class="reftest-wait">
|
||||
<!-- Test: when focused, element should show placeholder
|
||||
Using a readonly input text to disable caret -->
|
||||
<!-- Test: when focused, element should show placeholder. -->
|
||||
<script type="text/javascript">
|
||||
function focusPlaceholder()
|
||||
{
|
||||
|
@ -1,7 +1,6 @@
|
||||
<!DOCTYPE html>
|
||||
<html class="reftest-wait">
|
||||
<!-- Test: when focused, placeholder update shouldn't show placeholder
|
||||
Using a readonly input text to disable caret -->
|
||||
<!-- Test: when focused, placeholder update shouldn't show placeholder. -->
|
||||
<script type="text/javascript">
|
||||
function focusPlaceholder()
|
||||
{
|
||||
|
@ -1,7 +1,6 @@
|
||||
<!DOCTYPE html>
|
||||
<html class="reftest-wait">
|
||||
<!-- Test: when focused, value reset shouldn't show placeholder
|
||||
Using a readonly input text to disable caret -->
|
||||
<!-- Test: when focused, value reset shouldn't show placeholder. -->
|
||||
<script type="text/javascript">
|
||||
function focusPlaceholder()
|
||||
{
|
||||
|
@ -1,6 +1,5 @@
|
||||
<!DOCTYPE html>
|
||||
<html class="reftest-wait">
|
||||
<!-- Using a readonly input text to disable caret -->
|
||||
<script type="text/javascript">
|
||||
function focusInput()
|
||||
{
|
||||
@ -12,6 +11,6 @@
|
||||
}
|
||||
</script>
|
||||
<body onload="focusInput();">
|
||||
<input id='t1' type="text" readonly onfocus="disableReftestWait();">
|
||||
<input id='t1' type="text" onfocus="disableReftestWait();">
|
||||
</body>
|
||||
</html>
|
||||
|
@ -0,0 +1,16 @@
|
||||
<!DOCTYPE html>
|
||||
<html class="reftest-wait">
|
||||
<script type="text/javascript">
|
||||
function focusInput()
|
||||
{
|
||||
document.getElementById('t1').focus();
|
||||
}
|
||||
function disableReftestWait()
|
||||
{
|
||||
document.documentElement.className = '';
|
||||
}
|
||||
</script>
|
||||
<body onload="focusInput();">
|
||||
<input id='t1' type="text" readonly onfocus="disableReftestWait();">
|
||||
</body>
|
||||
</html>
|
@ -7,11 +7,14 @@
|
||||
== placeholder-5.html placeholder-visible-ref.html
|
||||
== placeholder-6.html placeholder-overflow-ref.html
|
||||
== placeholder-6-textarea.html placeholder-overflow-textarea-ref.html
|
||||
== placeholder-7.html placeholder-focus-ref.html
|
||||
== placeholder-8.html placeholder-focus-ref.html
|
||||
== placeholder-9.html placeholder-focus-ref.html
|
||||
== placeholder-7.html placeholder-readonly-focus-ref.html
|
||||
== placeholder-8.html placeholder-readonly-focus-ref.html
|
||||
== placeholder-9.html placeholder-readonly-focus-ref.html
|
||||
== placeholder-10.html placeholder-visible-ref.html
|
||||
== placeholder-11.html placeholder-visible-ref.html
|
||||
== placeholder-12.html placeholder-visible-ref.html
|
||||
== placeholder-13.html placeholder-visible-ref.html
|
||||
== placeholder-14.html placeholder-visible-ref.html
|
||||
== placeholder-15.html placeholder-focus-ref.html
|
||||
== placeholder-16.html placeholder-focus-ref.html
|
||||
== placeholder-17.html placeholder-focus-ref.html
|
||||
|
Loading…
Reference in New Issue
Block a user