|
10 | 10 | } |
11 | 11 | .stats-container { |
12 | 12 | display: grid; |
13 | | - grid-template-columns: repeat(3, 1fr); |
| 13 | + grid-template-columns: repeat(4, 1fr); |
14 | 14 | gap: 40px; |
15 | 15 | } |
16 | 16 | .reviews-container { |
|
22 | 22 | border: 1px black solid; |
23 | 23 | padding: 5px; |
24 | 24 | } |
| 25 | + .module { |
| 26 | + background-color: lightgrey; |
| 27 | + border: 1px black solid; |
| 28 | + margin-bottom: 10px; |
| 29 | + padding: 5px; |
| 30 | + } |
25 | 31 | </style> |
26 | 32 | </head> |
27 | 33 | <body> |
@@ -51,46 +57,67 @@ <h3>Needs review to complete</h3> |
51 | 57 | <li>p100: {{format_duration(aggregate_metrics.p100_needs_review_to_complete)}}</li> |
52 | 58 | </ul> |
53 | 59 | </div> |
| 60 | + <div class="stats-card"> |
| 61 | + <h3>Iterations</h3> |
| 62 | + <ul> |
| 63 | + {% for (iteration, count) in aggregate_metrics.iteration_counts %} |
| 64 | + <li>{{iteration}}: {{count}} PRs</li> |
| 65 | + {% endfor %} |
| 66 | + </ul> |
| 67 | + </div> |
54 | 68 | </div> |
55 | 69 |
|
56 | 70 | {% for module in modules %} |
57 | | - <h2>{{module.name}}</h2> |
58 | | - <div class="stats-container"> |
59 | | - <div class="stats-card"> |
60 | | - <h3>Needs review to first review</h3> |
61 | | - <ul> |
62 | | - <li>p50: {{format_duration(module.aggregate_metrics.p50_needs_review_to_first_review)}}</li> |
63 | | - <li>p90: {{format_duration(module.aggregate_metrics.p90_needs_review_to_first_review)}}</li> |
64 | | - <li>p100: {{format_duration(module.aggregate_metrics.p100_needs_review_to_first_review)}}</li> |
65 | | - </ul> |
66 | | - </div> |
67 | | - <div class="stats-card"> |
68 | | - <h3>Created to complete</h3> |
69 | | - <ul> |
70 | | - <li>p50: {{format_duration(module.aggregate_metrics.p50_created_to_complete)}}</li> |
71 | | - <li>p90: {{format_duration(module.aggregate_metrics.p90_created_to_complete)}}</li> |
72 | | - <li>p100: {{format_duration(module.aggregate_metrics.p100_created_to_complete)}}</li> |
73 | | - </ul> |
74 | | - </div> |
75 | | - <div class="stats-card"> |
76 | | - <h3>Needs review to complete</h3> |
77 | | - <ul> |
78 | | - <li>p50: {{format_duration(module.aggregate_metrics.p50_needs_review_to_complete)}}</li> |
79 | | - <li>p90: {{format_duration(module.aggregate_metrics.p90_needs_review_to_complete)}}</li> |
80 | | - <li>p100: {{format_duration(module.aggregate_metrics.p100_needs_review_to_complete)}}</li> |
81 | | - </ul> |
82 | | - </div> |
83 | | - </div> |
84 | | - <div class="reviews-container"> |
85 | | - {% for pr in module.metrics %} |
86 | | - <div class="review-card"> |
87 | | - <div><a href="{{pr.pr.url}}">{{pr.pr.repo_name}} #{{pr.pr.number}}</a></div> |
88 | | - <div>Created to Complete: {{format_duration(&pr.created_to_complete())}}</div> |
89 | | - <div>Needs Review to Complete: {{format_duration(&pr.needs_review_to_complete())}}</div> |
90 | | - <div>{{pr.iterations}} iterations</div> |
91 | | - <div>Time since created: {{format_duration(&Some(pr.time_since_created()))}}</div> |
| 71 | + <div class="module"> |
| 72 | + <h2>{{module.name}}</h2> |
| 73 | + <details> |
| 74 | + <summary>Expand for details</summary> |
| 75 | + <div class="stats-container"> |
| 76 | + <div class="stats-card"> |
| 77 | + <h3>Needs review to first review</h3> |
| 78 | + <ul> |
| 79 | + <li>p50: {{format_duration(module.aggregate_metrics.p50_needs_review_to_first_review)}}</li> |
| 80 | + <li>p90: {{format_duration(module.aggregate_metrics.p90_needs_review_to_first_review)}}</li> |
| 81 | + <li>p100: {{format_duration(module.aggregate_metrics.p100_needs_review_to_first_review)}}</li> |
| 82 | + </ul> |
| 83 | + </div> |
| 84 | + <div class="stats-card"> |
| 85 | + <h3>Created to complete</h3> |
| 86 | + <ul> |
| 87 | + <li>p50: {{format_duration(module.aggregate_metrics.p50_created_to_complete)}}</li> |
| 88 | + <li>p90: {{format_duration(module.aggregate_metrics.p90_created_to_complete)}}</li> |
| 89 | + <li>p100: {{format_duration(module.aggregate_metrics.p100_created_to_complete)}}</li> |
| 90 | + </ul> |
| 91 | + </div> |
| 92 | + <div class="stats-card"> |
| 93 | + <h3>Needs review to complete</h3> |
| 94 | + <ul> |
| 95 | + <li>p50: {{format_duration(module.aggregate_metrics.p50_needs_review_to_complete)}}</li> |
| 96 | + <li>p90: {{format_duration(module.aggregate_metrics.p90_needs_review_to_complete)}}</li> |
| 97 | + <li>p100: {{format_duration(module.aggregate_metrics.p100_needs_review_to_complete)}}</li> |
| 98 | + </ul> |
| 99 | + </div> |
| 100 | + <div class="stats-card"> |
| 101 | + <h3>Iterations</h3> |
| 102 | + <ul> |
| 103 | + {% for (iteration, count) in module.aggregate_metrics.iteration_counts %} |
| 104 | + <li>{{iteration}}: {{count}} PRs</li> |
| 105 | + {% endfor %} |
| 106 | + </ul> |
| 107 | + </div> |
| 108 | + </div> |
| 109 | + <div class="reviews-container"> |
| 110 | + {% for pr in module.metrics %} |
| 111 | + <div class="review-card"> |
| 112 | + <div><a href="{{pr.pr.url}}">{{pr.pr.repo_name}} #{{pr.pr.number}}</a></div> |
| 113 | + <div>Created to Complete: {{format_duration(&pr.created_to_complete())}}</div> |
| 114 | + <div>Needs Review to Complete: {{format_duration(&pr.needs_review_to_complete())}}</div> |
| 115 | + <div>{{pr.iterations}} iterations</div> |
| 116 | + <div>Time since created: {{format_duration(&Some(pr.time_since_created()))}}</div> |
| 117 | + </div> |
| 118 | + {% endfor %} |
92 | 119 | </div> |
93 | | - {% endfor %} |
| 120 | + </details> |
94 | 121 | </div> |
95 | 122 | {% endfor %} |
96 | 123 | </body> |
|
0 commit comments