Skip to content

Commit 0441d9f

Browse files
committed
Add custom theme for Maven site and JaCoCo report
- Add site.css with light theme matching docs index design - Add GitHub Copilot logo to poweredBy section - Add custom JaCoCo report.css with matching theme - Add Maven copy-resources overlay for JaCoCo CSS
1 parent 8c92c73 commit 0441d9f

2 files changed

Lines changed: 316 additions & 0 deletions

File tree

pom.xml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -368,6 +368,23 @@
368368
</resources>
369369
</configuration>
370370
</execution>
371+
<execution>
372+
<id>overlay-jacoco-css</id>
373+
<phase>site</phase>
374+
<goals>
375+
<goal>copy-resources</goal>
376+
</goals>
377+
<configuration>
378+
<outputDirectory>${project.reporting.outputDirectory}/jacoco-coverage/jacoco-resources</outputDirectory>
379+
<resources>
380+
<resource>
381+
<directory>src/site/jacoco-resources</directory>
382+
<filtering>false</filtering>
383+
</resource>
384+
</resources>
385+
<overwrite>true</overwrite>
386+
</configuration>
387+
</execution>
371388
</executions>
372389
</plugin>
373390
<!-- Maven Site Plugin -->
Lines changed: 299 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,299 @@
1+
/* ===== Custom JaCoCo Report Theme ===== */
2+
/* Matches the Copilot SDK site design */
3+
4+
body, td {
5+
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
6+
font-size: 10pt;
7+
color: #24292f;
8+
-webkit-font-smoothing: antialiased;
9+
}
10+
11+
body {
12+
background: #f6f8fa;
13+
margin: 0;
14+
padding: 20px;
15+
}
16+
17+
h1 {
18+
font-weight: 800;
19+
font-size: 18pt;
20+
color: #24292f;
21+
margin-bottom: 16px;
22+
}
23+
24+
a {
25+
color: #0969da;
26+
text-decoration: none;
27+
}
28+
29+
a:hover {
30+
color: #0550ae;
31+
text-decoration: underline;
32+
}
33+
34+
/* ===== Breadcrumb ===== */
35+
.breadcrumb {
36+
background: #fff;
37+
border: 1px solid #d0d7de;
38+
border-radius: 10px;
39+
padding: 10px 16px;
40+
margin-bottom: 20px;
41+
}
42+
43+
.breadcrumb .info {
44+
float: right;
45+
}
46+
47+
.breadcrumb .info a {
48+
margin-left: 8px;
49+
color: #57606a;
50+
font-size: 0.9em;
51+
}
52+
53+
.breadcrumb .info a:hover {
54+
color: #0969da;
55+
}
56+
57+
/* ===== Element Icons ===== */
58+
.el_report {
59+
padding-left: 18px;
60+
background-image: url(report.gif);
61+
background-position: left center;
62+
background-repeat: no-repeat;
63+
}
64+
65+
.el_group {
66+
padding-left: 18px;
67+
background-image: url(group.gif);
68+
background-position: left center;
69+
background-repeat: no-repeat;
70+
}
71+
72+
.el_bundle {
73+
padding-left: 18px;
74+
background-image: url(bundle.gif);
75+
background-position: left center;
76+
background-repeat: no-repeat;
77+
}
78+
79+
.el_package {
80+
padding-left: 18px;
81+
background-image: url(package.gif);
82+
background-position: left center;
83+
background-repeat: no-repeat;
84+
}
85+
86+
.el_class {
87+
padding-left: 18px;
88+
background-image: url(class.gif);
89+
background-position: left center;
90+
background-repeat: no-repeat;
91+
}
92+
93+
.el_source {
94+
padding-left: 18px;
95+
background-image: url(source.gif);
96+
background-position: left center;
97+
background-repeat: no-repeat;
98+
}
99+
100+
.el_method {
101+
padding-left: 18px;
102+
background-image: url(method.gif);
103+
background-position: left center;
104+
background-repeat: no-repeat;
105+
}
106+
107+
.el_session {
108+
padding-left: 18px;
109+
background-image: url(session.gif);
110+
background-position: left center;
111+
background-repeat: no-repeat;
112+
}
113+
114+
/* ===== Source Code ===== */
115+
pre.source {
116+
background: #fff;
117+
border: 1px solid #d0d7de;
118+
border-radius: 10px;
119+
font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
120+
overflow-x: auto;
121+
}
122+
123+
pre.source ol {
124+
margin-bottom: 0;
125+
margin-top: 0;
126+
}
127+
128+
pre.source li {
129+
border-left: 1px solid #d0d7de;
130+
color: #8b949e;
131+
padding-left: 0;
132+
}
133+
134+
pre.source span.fc {
135+
background-color: #dafbe1;
136+
}
137+
138+
pre.source span.nc {
139+
background-color: #ffeef0;
140+
}
141+
142+
pre.source span.pc {
143+
background-color: #fff8c5;
144+
}
145+
146+
pre.source span.bfc {
147+
background-image: url(branchfc.gif);
148+
background-repeat: no-repeat;
149+
background-position: 2px center;
150+
}
151+
152+
pre.source span.bfc:hover {
153+
background-color: #aff5b4;
154+
}
155+
156+
pre.source span.bnc {
157+
background-image: url(branchnc.gif);
158+
background-repeat: no-repeat;
159+
background-position: 2px center;
160+
}
161+
162+
pre.source span.bnc:hover {
163+
background-color: #ffcecb;
164+
}
165+
166+
pre.source span.bpc {
167+
background-image: url(branchpc.gif);
168+
background-repeat: no-repeat;
169+
background-position: 2px center;
170+
}
171+
172+
pre.source span.bpc:hover {
173+
background-color: #fff2b2;
174+
}
175+
176+
/* ===== Coverage Table ===== */
177+
table.coverage {
178+
empty-cells: show;
179+
border-collapse: separate;
180+
border-spacing: 0;
181+
border: 1px solid #d0d7de;
182+
border-radius: 10px;
183+
overflow: hidden;
184+
width: 100%;
185+
background: #fff;
186+
}
187+
188+
table.coverage thead {
189+
background: #f6f8fa;
190+
}
191+
192+
table.coverage thead td {
193+
white-space: nowrap;
194+
padding: 10px 14px 10px 10px;
195+
border-bottom: 2px solid #d0d7de;
196+
font-weight: 700;
197+
color: #24292f;
198+
font-size: 0.92em;
199+
}
200+
201+
table.coverage thead td.bar {
202+
border-left: 1px solid #eaeef2;
203+
}
204+
205+
table.coverage thead td.ctr1 {
206+
text-align: right;
207+
border-left: 1px solid #eaeef2;
208+
}
209+
210+
table.coverage thead td.ctr2 {
211+
text-align: right;
212+
padding-left: 2px;
213+
}
214+
215+
table.coverage thead td.sortable {
216+
cursor: pointer;
217+
background-image: url(sort.gif);
218+
background-position: right center;
219+
background-repeat: no-repeat;
220+
}
221+
222+
table.coverage thead td.up {
223+
background-image: url(up.gif);
224+
}
225+
226+
table.coverage thead td.down {
227+
background-image: url(down.gif);
228+
}
229+
230+
table.coverage tbody td {
231+
white-space: nowrap;
232+
padding: 8px 10px;
233+
border-bottom: 1px solid #eaeef2;
234+
}
235+
236+
table.coverage tbody tr:hover {
237+
background: rgba(102, 126, 234, 0.04) !important;
238+
}
239+
240+
table.coverage tbody td.bar {
241+
border-left: 1px solid #eaeef2;
242+
}
243+
244+
table.coverage tbody td.ctr1 {
245+
text-align: right;
246+
padding-right: 14px;
247+
border-left: 1px solid #eaeef2;
248+
}
249+
250+
table.coverage tbody td.ctr2 {
251+
text-align: right;
252+
padding-right: 14px;
253+
padding-left: 2px;
254+
}
255+
256+
table.coverage tfoot td {
257+
white-space: nowrap;
258+
padding: 8px 10px;
259+
font-weight: 700;
260+
background: #f6f8fa;
261+
border-top: 2px solid #d0d7de;
262+
}
263+
264+
table.coverage tfoot td.bar {
265+
border-left: 1px solid #eaeef2;
266+
}
267+
268+
table.coverage tfoot td.ctr1 {
269+
text-align: right;
270+
padding-right: 14px;
271+
border-left: 1px solid #eaeef2;
272+
}
273+
274+
table.coverage tfoot td.ctr2 {
275+
text-align: right;
276+
padding-right: 14px;
277+
padding-left: 2px;
278+
}
279+
280+
/* ===== Footer ===== */
281+
.footer {
282+
margin-top: 24px;
283+
border-top: 1px solid #d0d7de;
284+
padding-top: 8px;
285+
font-size: 8pt;
286+
color: #8b949e;
287+
}
288+
289+
.footer a {
290+
color: #8b949e;
291+
}
292+
293+
.footer a:hover {
294+
color: #0969da;
295+
}
296+
297+
.right {
298+
float: right;
299+
}

0 commit comments

Comments
 (0)