OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <style> | 4 <style> |
5 .test-row { | 5 .test-row { |
6 display: flex; | 6 display: flex; |
7 margin-bottom: 5px; | 7 margin-bottom: 5px; |
8 } | 8 } |
9 .test-row > div { | 9 .test-row > div { |
10 flex: none; | 10 flex: none; |
(...skipping 20 matching lines...) Expand all Loading... |
31 </style> | 31 </style> |
32 </head> | 32 </head> |
33 <body> | 33 <body> |
34 <p>Scrollbars should work in all the flexboxes.</p> | 34 <p>Scrollbars should work in all the flexboxes.</p> |
35 </body> | 35 </body> |
36 <script> | 36 <script> |
37 // The -almost values are cases where we don't scroll all the way because of | 37 // The -almost values are cases where we don't scroll all the way because of |
38 // https://bugs.webkit.org/show_bug.cgi?id=76129 . | 38 // https://bugs.webkit.org/show_bug.cgi?id=76129 . |
39 var results = [ | 39 var results = [ |
40 'left top', 'left top', 'right top', 'left bottom', | 40 'left top', 'left top', 'right top', 'left bottom', |
41 'left bottom-almost', 'left bottom-almost', 'right bottom-almost', 'left top
', | |
42 'right-almost top', 'right-almost top', 'right-almost bottom', 'left top', | 41 'right-almost top', 'right-almost top', 'right-almost bottom', 'left top', |
43 'left top', 'left top', 'left bottom', 'right top']; | 42 'left top', 'left top', 'left bottom', 'right top']; |
44 | 43 |
45 var testContents = ''; | 44 var testContents = ''; |
46 for (var i = 0; i < results.length; ++i) { | 45 for (var i = 0; i < results.length; ++i) { |
47 if (!(i % 4)) | 46 if (!(i % 4)) |
48 testContents += "<div class='test-row'>"; | 47 testContents += "<div class='test-row'>"; |
49 | 48 |
50 var containerClass = 'container ' + results[i]; | 49 var containerClass = 'container ' + results[i]; |
51 testContents += | 50 testContents += |
(...skipping 20 matching lines...) Expand all Loading... |
72 element.firstChild.scrollLeft = element.firstChild.scrollWidth - element.fir
stChild.offsetWidth; | 71 element.firstChild.scrollLeft = element.firstChild.scrollWidth - element.fir
stChild.offsetWidth; |
73 }); | 72 }); |
74 | 73 |
75 Array.prototype.forEach.call(document.querySelectorAll(".bottom-almost"), functi
on(element) { | 74 Array.prototype.forEach.call(document.querySelectorAll(".bottom-almost"), functi
on(element) { |
76 element.firstChild.scrollTop = element.firstChild.scrollHeight - element.fir
stChild.offsetHeight; | 75 element.firstChild.scrollTop = element.firstChild.scrollHeight - element.fir
stChild.offsetHeight; |
77 }); | 76 }); |
78 | 77 |
79 </script> | 78 </script> |
80 </body> | 79 </body> |
81 </html> | 80 </html> |
OLD | NEW |