Skip to content

Commit

Permalink
Accessibility corrections
Browse files Browse the repository at this point in the history
  • Loading branch information
Bernardo-MG authored Jan 31, 2023
1 parent 58ba156 commit 851f11b
Show file tree
Hide file tree
Showing 26 changed files with 78 additions and 116 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ Any kind of help with the project will be well received, and there are two main

### Issues Management

Issues are managed at the GitHub [project issues tracker][issues], where any Github user may report bugs or ask for new features.
Issues are managed at the GitHub [project issues tracker][issues], where any GitHub user may report bugs or ask for new features.

### Getting the Code

Expand Down
8 changes: 4 additions & 4 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
</issueManagement>

<ciManagement>
<system>Github workflow</system>
<system>GitHub workflow</system>
<url>https://github.com/Bernardo-MG/docs-maven-skin/actions</url>
<notifiers />
</ciManagement>
Expand Down Expand Up @@ -83,11 +83,11 @@
</distributionManagement>
</profile>
<profile>
<!-- Github deployment profile. -->
<!-- GitHub deployment profile. -->
<id>deployment-github</id>
<distributionManagement>
<repository>
<!-- Github repository -->
<!-- GitHub repository -->
<id>github</id>
<name>GitHub Packages</name>
<url>https://maven.pkg.github.com/Bernardo-MG/docs-maven-skin</url>
Expand Down Expand Up @@ -223,7 +223,7 @@
<!-- ============================================== -->
<!-- ================= MAVEN SITE ================= -->
<!-- ============================================== -->
<site.skin.version>2.2.7</site.skin.version>
<site.skin.version>2.3.0</site.skin.version>
<mavenURL>https://mvnrepository.com/artifact/${project.groupId}/${project.artifactId}</mavenURL>
<githubArtifactURL><![CDATA[https://github.com/Bernardo-MG?tab=packages&amp;repo_name=docs-maven-skin]]></githubArtifactURL>
</properties>
Expand Down
8 changes: 4 additions & 4 deletions src/main/resources/META-INF/maven/macros/menu-macros.vm
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
<a href="#" class="nav-link dropdown-toggle" id="$element.name.replace(" ", "_")_menu" data-bs-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">$element.name</a>
<ul class="dropdown-menu dropdown-menu-end" role="menu" aria-labelledby="$element.name.replace(" ", "_")_menu">
#* *##foreach( $item in $element.items )
<li><a class="dropdown-item" href="$item.href" title="$item.name">$item.name</a></li>
<li><a class="dropdown-item" href="$item.href" title="$item.name" aria-label="$item.name">$item.name</a></li>
#* *##end
</ul>
</li>
Expand Down Expand Up @@ -82,7 +82,7 @@
<a href="#" class="nav-link dropdown-toggle" id="links_menu" data-bs-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">Links</a>
<ul class="dropdown-menu dropdown-menu-end" role="menu" aria-labelledby="links_menu">
#* *##foreach( $item in $elements )
<li><a class="dropdown-item" href="$item.href" title="$item.name">$item.name</a></li>
<li><a class="dropdown-item" href="$item.href" title="$item.name" aria-label="$item.name">$item.name</a></li>
#* *##end
</ul>
</li>
Expand Down Expand Up @@ -134,9 +134,9 @@
#**##end
#**##foreach( $item in $element.items )
#* *##if( $item.description )
<dd><a href="$item.href" title="$item.name" class="link-noted">$item.name <span class="note">$item.description</span></a></dd>
<dd><a href="$item.href" title="$item.name" aria-label="$item.name" class="link-noted">$item.name <span class="note">$item.description</span></a></dd>
#* *##else
<dd><a href="$item.href" title="$item.name">$item.name</a></dd>
<dd><a href="$item.href" title="$item.name" aria-label="$item.name">$item.name</a></dd>
#* *##end
#**##end
</dl>
Expand Down
6 changes: 4 additions & 2 deletions src/main/resources/META-INF/maven/site.vm
Original file line number Diff line number Diff line change
Expand Up @@ -156,9 +156,11 @@
</div>
</nav>
</header>
<section id="main-section" class="container flex-grow-1">
<main>
<section id="main-section" class="container flex-grow-1">
$bodyContent
</section>
</section>
</main>
<footer class="footer w-100 pt-2 border-top bg-$bgshine">
<div id="footer-nav" class="bg-$bgshine container">
#set( $menuElements = [] )
Expand Down
2 changes: 1 addition & 1 deletion src/site/markdown/acquire.md.vm
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#set( $symbol_pound = '#' )
${symbol_pound} Setting up the dependencies

The project files are hosted in the the [Maven Central Repository][maven-repo], and the [Github Packages Repository][github-repo]. This means that most Maven setups will be able to acquire the dependency without any additional configuration.
The project files are hosted in the the [Maven Central Repository][maven-repo], and the [GitHub Packages Repository][github-repo]. This means that most Maven setups will be able to acquire the dependency without any additional configuration.

For any additional information about how to set up the dependency check the [dependency information section](./dependency-info.html).

Expand Down
2 changes: 1 addition & 1 deletion src/site/markdown/custom_site_descriptor.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ For this to work you just need to add an image attribute to the menu item:
<body>
...
<menu name="Icons" inherit="bottom">
<item name="Github" img="fab fa-github" href="${project.scm.url}" />
<item name="GitHub" img="fab fa-github" href="${project.scm.url}" />
</menu>
...
</body>
Expand Down
2 changes: 1 addition & 1 deletion src/site/markdown/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ The following example for a site.xml file will be useful for most sites:
<item name="Maven Central" href="${mavenURL}" />
</menu>
<menu name="Icons" inherit="bottom">
<item name="Github" img="fab fa-github" href="${project.scm.url}" />
<item name="GitHub" img="fab fa-github" href="${project.scm.url}" />
</menu>
</body>
</project>
Expand Down
4 changes: 2 additions & 2 deletions src/site/site.xml
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,10 @@
</menu>
<menu name="Releases" inherit="bottom">
<item name="Maven Central" href="${mavenURL}" />
<item name="Github" href="${githubArtifactURL}" />
<item name="GitHub" href="${githubArtifactURL}" />
</menu>
<menu name="Icons" inherit="bottom">
<item name="Github" img="fab fa-github" href="${project.scm.url}" />
<item name="GitHub" img="fab fa-github" href="${project.scm.url}" />
</menu>
</body>

Expand Down
4 changes: 2 additions & 2 deletions src/test/resources/it/bottom_nav/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
</issueManagement>

<ciManagement>
<system>Github workflow</system>
<system>GitHub workflow</system>
<url>https://github.com/Bernardo-MG/docs-maven-skin/actions</url>
<notifiers />
</ciManagement>
Expand All @@ -44,8 +44,8 @@
<plugin.site.version>@plugin.site.version@</plugin.site.version>
<!-- Maven Site -->
<site.skin.version>@project.version@</site.skin.version>
<bintrayURL>https://bintray.com/bernardo-mg/maven/docs-maven-skin/view</bintrayURL>
<mavenURL>http://mvnrepository.com/artifact/com.bernardomg.maven.skins/docs-maven-skin</mavenURL>
<githubArtifactURL><![CDATA[https://github.com/Bernardo-MG?tab=packages&amp;repo_name=docs-maven-skin]]></githubArtifactURL>
</properties>

<!-- ********************************************** -->
Expand Down
4 changes: 2 additions & 2 deletions src/test/resources/it/bottom_nav/src/site/site.xml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@
</item>
</menu>
<menu name="Releases" inherit="bottom">
<item name="Bintray" href="https://bintray.com/bernardo-mg/maven/docs-maven-skin/view" />
<item name="Maven Central" href="http://mvnrepository.com/artifact/com.bernardomg.maven.skins/docs-maven-skin" />
<item name="Maven Central" href="${mavenURL}" />
<item name="GitHub" href="${githubArtifactURL}" />
</menu>
</body>

Expand Down
21 changes: 14 additions & 7 deletions src/test/resources/it/bottom_nav/verify.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ link = link.children().first()
assert link.tag().normalName().equals('a')
assert link.attr( 'href' ).equals('./acquire.html')
assert link.attr( 'title' ).equals('Acquire')
assert link.attr( 'aria-label' ).equals('Acquire')
assert link.html().equals('Acquire')

link = row.get(1)
Expand All @@ -48,6 +49,7 @@ link = link.children().first()
assert link.tag().normalName().equals('a')
assert link.attr( 'href' ).equals('./usage.html')
assert link.attr( 'title' ).equals('Usage')
assert link.attr( 'aria-label' ).equals('Usage')
assert link.html().equals('Usage')

// Second column
Expand All @@ -60,6 +62,7 @@ link = link.children().first()
assert link.tag().normalName().equals('a')
assert link.attr( 'href' ).equals('https://github.com/Bernardo-MG/docs-maven-skin')
assert link.attr( 'title' ).equals('SCM')
assert link.attr( 'aria-label' ).equals('SCM')
assert link.html().equals('SCM <span class="note">GitHub</span>')
assert link.hasClass( 'link-noted' )

Expand All @@ -69,7 +72,8 @@ link = link.children().first()
assert link.tag().normalName().equals('a')
assert link.attr( 'href' ).equals('https://github.com/Bernardo-MG/docs-maven-skin/actions')
assert link.attr( 'title' ).equals('CI')
assert link.html().equals('CI <span class="note">Github workflow</span>')
assert link.attr( 'aria-label' ).equals('CI')
assert link.html().equals('CI <span class="note">GitHub workflow</span>')
assert link.hasClass( 'link-noted' )

link = row.get(2)
Expand All @@ -78,6 +82,7 @@ link = link.children().first()
assert link.tag().normalName().equals('a')
assert link.attr( 'href' ).equals('https://www.github.com/bernardo-mg/docs-maven-skin/issues')
assert link.attr( 'title' ).equals('Issues')
assert link.attr( 'aria-label' ).equals('Issues')
assert link.html().equals('Issues <span class="note">GitHub</span>')
assert link.hasClass( 'link-noted' )

Expand All @@ -89,14 +94,16 @@ link = row.get(0)
assert link.tag().normalName().equals('dd')
link = link.children().first()
assert link.tag().normalName().equals('a')
assert link.attr( 'href' ).equals('https://bintray.com/bernardo-mg/maven/docs-maven-skin/view')
assert link.attr( 'title' ).equals('Bintray')
assert link.html().equals('Bintray')
assert link.attr( 'href' ).equals('http://mvnrepository.com/artifact/com.bernardomg.maven.skins/docs-maven-skin')
assert link.attr( 'title' ).equals('Maven Central')
assert link.attr( 'aria-label' ).equals('Maven Central')
assert link.html().equals('Maven Central')

link = row.get(1)
assert link.tag().normalName().equals('dd')
link = link.children().first()
assert link.tag().normalName().equals('a')
assert link.attr( 'href' ).equals('http://mvnrepository.com/artifact/com.bernardomg.maven.skins/docs-maven-skin')
assert link.attr( 'title' ).equals('Maven Central')
assert link.html().equals('Maven Central')
assert link.attr( 'href' ).equals('https://github.com/Bernardo-MG?tab=packages&repo_name=docs-maven-skin')
assert link.attr( 'title' ).equals('GitHub')
assert link.attr( 'aria-label' ).equals('GitHub')
assert link.html().equals('GitHub')
4 changes: 2 additions & 2 deletions src/test/resources/it/bottom_nav_max/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
</issueManagement>

<ciManagement>
<system>Github workflow</system>
<system>GitHub workflow</system>
<url>https://github.com/Bernardo-MG/docs-maven-skin/actions</url>
<notifiers />
</ciManagement>
Expand All @@ -44,8 +44,8 @@
<plugin.site.version>@plugin.site.version@</plugin.site.version>
<!-- Maven Site -->
<site.skin.version>@project.version@</site.skin.version>
<bintrayURL>https://bintray.com/bernardo-mg/maven/docs-maven-skin/view</bintrayURL>
<mavenURL>http://mvnrepository.com/artifact/com.bernardomg.maven.skins/docs-maven-skin</mavenURL>
<githubArtifactURL><![CDATA[https://github.com/Bernardo-MG?tab=packages&amp;repo_name=docs-maven-skin]]></githubArtifactURL>
</properties>

<!-- ********************************************** -->
Expand Down
Original file line number Diff line number Diff line change
@@ -1,29 +1,9 @@
#set( $symbol_pound = '#' )
${symbol_pound} Setting up the dependencies

The project files are hosted on a [Bintray repository][bintray-repo], and have been replicated on JCenter and OSS Sonatype, which also replicates into the [Maven Central Repository][maven-repo].

This means that most Maven setups will be able to acquire the dependency without any additional configuration. Still, if the repository should be registered it is recommended using the Bintray one.
The project files are hosted in the the [Maven Central Repository][maven-repo], and the [GitHub Packages Repository][github-repo]. This means that most Maven setups will be able to acquire the dependency without any additional configuration.

For any additional information about how to set up the dependency check the [dependency information section](./dependency-info.html).

${symbol_pound}${symbol_pound} Snapshots

Snapshot artifacts are stored on OSS Sonatype. They can be accessed by adding the following lines to the configuration files:

${symbol_pound}${symbol_pound}${symbol_pound} Maven

```xml
<repositories>
...
<repository>
<id>oss-sonatype-snapshots</id>
<name>OSS Sonatype snapshots repository</name>
<url>https://oss.sonatype.org/content/groups/staging</url>
</repository>
...
</repositories>
```

[bintray-repo]: ${bintrayURL}
[maven-repo]: ${mavenURL}
[maven-repo]: ${mavenURL}
[github-repo]: ${githubArtifactURL}
4 changes: 2 additions & 2 deletions src/test/resources/it/custom_shine_dark_default/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
</issueManagement>

<ciManagement>
<system>Github workflow</system>
<system>GitHub workflow</system>
<url>https://github.com/Bernardo-MG/docs-maven-skin/actions</url>
<notifiers />
</ciManagement>
Expand All @@ -44,8 +44,8 @@
<plugin.site.version>@plugin.site.version@</plugin.site.version>
<!-- Maven Site -->
<site.skin.version>@project.version@</site.skin.version>
<bintrayURL>https://bintray.com/bernardo-mg/maven/docs-maven-skin/view</bintrayURL>
<mavenURL>http://mvnrepository.com/artifact/com.bernardomg.maven.skins/docs-maven-skin</mavenURL>
<githubArtifactURL><![CDATA[https://github.com/Bernardo-MG?tab=packages&amp;repo_name=docs-maven-skin]]></githubArtifactURL>
</properties>

<!-- ********************************************** -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@
</item>
</menu>
<menu name="Releases" inherit="bottom">
<item name="Bintray" href="https://bintray.com/bernardo-mg/maven/docs-maven-skin/view" />
<item name="Maven Central" href="http://mvnrepository.com/artifact/com.bernardomg.maven.skins/docs-maven-skin" />
<item name="Maven Central" href="${mavenURL}" />
<item name="GitHub" href="${githubArtifactURL}" />
</menu>
</body>

Expand Down
4 changes: 2 additions & 2 deletions src/test/resources/it/custom_shine_dark_overriden/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
</issueManagement>

<ciManagement>
<system>Github workflow</system>
<system>GitHub workflow</system>
<url>https://github.com/Bernardo-MG/docs-maven-skin/actions</url>
<notifiers />
</ciManagement>
Expand All @@ -44,8 +44,8 @@
<plugin.site.version>@plugin.site.version@</plugin.site.version>
<!-- Maven Site -->
<site.skin.version>@project.version@</site.skin.version>
<bintrayURL>https://bintray.com/bernardo-mg/maven/docs-maven-skin/view</bintrayURL>
<mavenURL>http://mvnrepository.com/artifact/com.bernardomg.maven.skins/docs-maven-skin</mavenURL>
<githubArtifactURL><![CDATA[https://github.com/Bernardo-MG?tab=packages&amp;repo_name=docs-maven-skin]]></githubArtifactURL>
</properties>

<!-- ********************************************** -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@
</item>
</menu>
<menu name="Releases" inherit="bottom">
<item name="Bintray" href="https://bintray.com/bernardo-mg/maven/docs-maven-skin/view" />
<item name="Maven Central" href="http://mvnrepository.com/artifact/com.bernardomg.maven.skins/docs-maven-skin" />
<item name="Maven Central" href="${mavenURL}" />
<item name="GitHub" href="${githubArtifactURL}" />
</menu>
</body>

Expand Down
4 changes: 2 additions & 2 deletions src/test/resources/it/custom_shine_default/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
</issueManagement>

<ciManagement>
<system>Github workflow</system>
<system>GitHub workflow</system>
<url>https://github.com/Bernardo-MG/docs-maven-skin/actions</url>
<notifiers />
</ciManagement>
Expand All @@ -44,8 +44,8 @@
<plugin.site.version>@plugin.site.version@</plugin.site.version>
<!-- Maven Site -->
<site.skin.version>@project.version@</site.skin.version>
<bintrayURL>https://bintray.com/bernardo-mg/maven/docs-maven-skin/view</bintrayURL>
<mavenURL>http://mvnrepository.com/artifact/com.bernardomg.maven.skins/docs-maven-skin</mavenURL>
<githubArtifactURL><![CDATA[https://github.com/Bernardo-MG?tab=packages&amp;repo_name=docs-maven-skin]]></githubArtifactURL>
</properties>

<!-- ********************************************** -->
Expand Down
4 changes: 2 additions & 2 deletions src/test/resources/it/custom_shine_default/src/site/site.xml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@
</item>
</menu>
<menu name="Releases" inherit="bottom">
<item name="Bintray" href="https://bintray.com/bernardo-mg/maven/docs-maven-skin/view" />
<item name="Maven Central" href="http://mvnrepository.com/artifact/com.bernardomg.maven.skins/docs-maven-skin" />
<item name="Maven Central" href="${mavenURL}" />
<item name="GitHub" href="${githubArtifactURL}" />
</menu>
</body>

Expand Down
2 changes: 1 addition & 1 deletion src/test/resources/it/icons_list/src/site/site.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

<body>
<menu name="Icons" inherit="bottom">
<item name="Github" img="fab fa-github" href="${project.scm.url}" />
<item name="GitHub" img="fab fa-github" href="${project.scm.url}" />
</menu>
</body>

Expand Down
6 changes: 3 additions & 3 deletions src/test/resources/it/icons_list/verify.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ assert icons.size() == 1
def link = icons.first().parent()
assert link.tag().normalName().equals('a')
assert link.attr( 'href' ).equals('https://github.com/Bernardo-MG/docs-maven-skin')
assert link.attr( 'title' ).equals('Github')
assert link.attr( 'aria-label' ).equals('Github')
assert link.html().equals('<span class="navbar-icon fab fa-github ps-1" aria-hidden="true"></span> <span class="d-none d-sm-block d-md-none"> Github</span>')
assert link.attr( 'title' ).equals('GitHub')
assert link.attr( 'aria-label' ).equals('GitHub')
assert link.html().equals('<span class="navbar-icon fab fa-github ps-1" aria-hidden="true"></span> <span class="d-none d-sm-block d-md-none"> GitHub</span>')
Loading

0 comments on commit 851f11b

Please sign in to comment.