Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(546)

Unified Diff: milo/appengine/frontend/templates/pages/build.html

Issue 2886353002: Milo: Add an option to hide green steps (Closed)
Patch Set: Retrain Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « milo/appengine/frontend/static/buildbot/css/default.css ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: milo/appengine/frontend/templates/pages/build.html
diff --git a/milo/appengine/frontend/templates/pages/build.html b/milo/appengine/frontend/templates/pages/build.html
index 93b22a0163042f8ccccc2826f8e4a2f034d0a3e8..615adc146c8fb679e60521f3979a3b4f004efdfc 100644
--- a/milo/appengine/frontend/templates/pages/build.html
+++ b/milo/appengine/frontend/templates/pages/build.html
@@ -148,9 +148,14 @@
{{ if or .Build.Components .Build.Summary.SubLink }}
<h2>Steps and Logfiles:</h2>
- <input type="checkbox" id="showHidden">
- <label for="showHidden">Show hidden <span id="numHidden"></span></label>
- <ol id="steps" class="hide">
+ Show:
+ <input type="radio" name="hider" id="showAll">
+ <label for="showAll">All</label>
+ <input type="radio" name="hider" id="showStandard" checked>
+ <label for="showStandard">Standard</label>
+ <input type="radio" name="hider" id="showInteresting">
+ <label for="showInteresting">Interesting Only</label>
+ <ol id="steps" class="standard">
{{ with .Build.Summary }}
{{ if .SubLink }}
@@ -325,24 +330,25 @@
</div>
<script language="javascript">
$(document).ready(function() {
- var check = function(checked) {
- var things = $("#steps");
- if (checked) {
- $("#steps").removeClass("hide");
- } else {
- $("#steps").addClass("hide");
- }
- var numHidden = $(".verbosity-Hidden").length;
- if (numHidden > 0) {
- $("#numHidden").text("(" + numHidden + " hidden)");
- } else {
- $("#numHidden").text("");
- }
- };
- check($("#showHidden").is(":checked"));
- $("#showHidden").click(function(e) {
- check($(this).is(":checked"));
+ var check = function(className) {
+ $("#steps").removeClass("all standard interesting").addClass(className)
+ }
+
+ $("#showInteresting").click(function(e) {
+ check("interesting");
+ });
+ $("#showStandard").click(function(e) {
+ check("standard");
+ });
+ $("#showAll").click(function(e) {
+ check("all");
+ });
+
+ $("input[name='hider']").each(function(){
+ if ($(this).prop("checked")) {
+ $(this).click();
+ }
});
});
</script>
« no previous file with comments | « milo/appengine/frontend/static/buildbot/css/default.css ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698