| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <title>Skia Fuzzer</title> | 4 <title>Skia Fuzzer</title> |
| 5 {{template "header.html" .}} | 5 {{template "header.html" .}} |
| 6 </head> | 6 </head> |
| 7 <body> | 7 <body> |
| 8 <scaffold-sk responsiveWidth="700px"> |
| 9 {{template "titlebar.html" .}} |
| 10 <div id="fuzzes"></div> |
| 11 </scaffold-sk> |
| 12 |
| 13 <script type="text/javascript" charset="utf-8"> |
| 14 (function() { |
| 15 sk.WebComponentsReady.then(function() { |
| 16 var page = {}; |
| 17 var fuzzes = []; |
| 18 |
| 19 page.state = { |
| 20 failed: true, |
| 21 passed: false |
| 22 }; |
| 23 |
| 24 function displayFuzzes() { |
| 25 var container = $$$("#fuzzes"); |
| 26 sk.clearChildren(container); |
| 27 |
| 28 fuzzes.forEach(function(c, i) { |
| 29 var s = document.createElement('fuzz-summary-sk'
); |
| 30 s.hash = c; |
| 31 |
| 32 container.appendChild(s); |
| 33 }) |
| 34 } |
| 35 |
| 36 function loadFuzzes() { |
| 37 sk.get("{{.LoadFuzzListURL}}?"+sk.query.fromObject(page.
state)).then(JSON.parse).then(function(data) { |
| 38 fuzzes = data; |
| 39 displayFuzzes(); |
| 40 }); |
| 41 } |
| 42 |
| 43 path = document.location.pathname; |
| 44 if (path.startsWith("/passed")) { |
| 45 page.state.failed = false; |
| 46 page.state.passed = true; |
| 47 } |
| 48 |
| 49 sk.stateReflector(page, loadFuzzes); |
| 50 }); |
| 51 })(); |
| 52 </script> |
| 53 |
| 8 {{template "footer.html" .}} | 54 {{template "footer.html" .}} |
| 9 </body> | 55 </body> |
| 10 </html> | 56 </html> |
| OLD | NEW |