Skip to content

Commit b37a429

Browse files
committed
fix tests
1 parent 36f4fb7 commit b37a429

File tree

3 files changed

+28
-30
lines changed

3 files changed

+28
-30
lines changed

scaladoc-testcases/docs/_layouts/static-site-main.html

Lines changed: 25 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,34 @@
11
---
2-
layout: main
2+
extraJS:
3+
- js/contributors.js
4+
extraCSS:
5+
- css/bootstrap.min.css
6+
- css/content-contributors.css
37
---
48

5-
<div class="site-container">
6-
<div id="site-header"></div>
9+
<div class="container">
710
{{ content }}
8-
<div class="divider" />
9-
<nav class="arrow-navigation" aria-label="Page navigation">
11+
<nav class="arrows-wrapper" aria-label="Page navigation">
1012
{% if page.previous %}
11-
<div>
12-
<span class="body-small">Previous</span>
13-
<a
14-
rel="prev"
15-
href="{{ page.previous.url }}"
16-
aria-keyshortcuts="Left"
17-
class="body-medium"
18-
>
19-
<span class="body-medium">{{ page.previous.title }}</span>
20-
</a>
21-
</div>
13+
<a
14+
rel="prev"
15+
href="{{ page.previous.url }}"
16+
class="arrows previous"
17+
aria-keyshortcuts="Left"
18+
>
19+
<span>{{ page.previous.title }}</span>
20+
<i class="fa fa-angle-left"></i>
21+
</a>
2222
{% endif %} {% if page.next %}
23-
<div>
24-
<span class="body-small">Next</span>
25-
<a
26-
rel="next"
27-
href="{{ page.next.url }}"
28-
aria-keyshortcuts="Right"
29-
class="body-medium"
30-
>
31-
<span class="body-medium">{{ page.next.title }}</span>
32-
</a>
33-
</div>
23+
<a
24+
rel="next"
25+
href="{{ page.next.url }}"
26+
class="arrows next"
27+
aria-keyshortcuts="Right"
28+
>
29+
<span>{{ page.next.title }}</span>
30+
<i class="fa fa-angle-right"></i>
31+
</a>
3432
{% endif %}
3533
</nav>
3634
<div class="content-contributors hidden">

scaladoc/src/dotty/tools/scaladoc/renderers/MemberRenderer.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ class MemberRenderer(signatureRenderer: SignatureRenderer)(using DocContext) ext
125125
Option.when(bodyContents.nonEmpty || attributes.nonEmpty)(
126126
div(cls := "cover")(
127127
div(cls := "doc")(bodyContents),
128-
h1(cls := "h500")("Attributes"),
128+
h2(cls := "h500")("Attributes"),
129129
dl(cls := "attributes")(attributes*)
130130
)
131131
)
@@ -327,7 +327,7 @@ class MemberRenderer(signatureRenderer: SignatureRenderer)(using DocContext) ext
327327
}.toSeq
328328

329329
div(cls := "membersList expand")(
330-
h1(cls := "h500")("Members list"),
330+
h2(cls := "h500")("Members list"),
331331
renderTabs(
332332
singleSelection = false,
333333
buildGroup("Packages", Seq(

scaladoc/test/dotty/tools/scaladoc/site/SiteGeneratationTest.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ class SiteGeneratationTest extends BaseHtmlTest:
2323
parents: Seq[String] = Nil,
2424
checks: DocumentContext => Unit = _ => ())(using ProjectContext) =
2525
withHtmlFile(path){ content =>
26-
content.assertTextsIn(".project-name", projectName)
26+
content.assertTextsIn(".project-name", projectName, projectName) // There are two elements with project name: one for desktop, one for mobile
2727
content.assertTextsIn(".projectVersion", projectVersion)
2828
content.assertTextsIn("h1", header)
2929
content.assertTextsIn("title", title)

0 commit comments

Comments
 (0)