Skip to content

Commit 42daa87

Browse files
committed
Update MathJax URL
MathJax is now hosted on Apache servers to comply with the Content Security Policy (CSP) for project websites.
1 parent 105413d commit 42daa87

File tree

2 files changed

+21
-7
lines changed

2 files changed

+21
-7
lines changed

pom.xml

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,8 @@
118118
<commons.release.isDistModule>true</commons.release.isDistModule>
119119
<!-- project.build.outputTimestamp is managed by Maven plugins, see https://maven.apache.org/guides/mini/guide-reproducible-builds.html -->
120120
<project.build.outputTimestamp>2024-12-18T21:13:07Z</project.build.outputTimestamp>
121+
<!-- MathJax configuration. See the maven-javadoc-plugin plugin. -->
122+
<mathjax.url>https://commons.apache.org/js/mathjax/tex-mml-chtml.js</mathjax.url>
121123
<!-- JaCoCo: Don't make code coverage worse than: -->
122124
<commons.jacoco.haltOnFailure>true</commons.jacoco.haltOnFailure>
123125
<commons.jacoco.classRatio>0.96</commons.jacoco.classRatio>
@@ -127,7 +129,6 @@
127129
<commons.jacoco.lineRatio>0.85</commons.jacoco.lineRatio>
128130
<commons.jacoco.complexityRatio>0.78</commons.jacoco.complexityRatio>
129131
<doxia.module.markdown.version>2.0.0</doxia.module.markdown.version>
130-
<math.mathjax.version>2.7.9</math.mathjax.version>
131132
<commons.easymock.version>5.5.0</commons.easymock.version>
132133
<!-- PMD 7.9.0 throws java.io.IOException: Stream closed probably because PMD is shadding ASM. -->
133134
<commons.pmd-impl.version>7.8.0</commons.pmd-impl.version>
@@ -223,14 +224,15 @@
223224
</configuration>
224225
</plugin>
225226
<plugin>
227+
<!-- NOTE: javadoc config must also be set under <reporting> -->
226228
<groupId>org.apache.maven.plugins</groupId>
227229
<artifactId>maven-javadoc-plugin</artifactId>
228230
<configuration>
229-
<source>8</source>
230-
<!-- TODO -->
231-
<failOnWarnings>false</failOnWarnings>
232-
<!-- Enable MathJax -->
233-
<additionalOptions>-Xdoclint:all --allow-script-in-comments -header '&lt;script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/${math.mathjax.version}/MathJax.js?config=TeX-AMS-MML_HTMLorMML"&gt;&lt;/script&gt;'</additionalOptions>
231+
<source>8</source>
232+
<!-- TODO -->
233+
<failOnWarnings>false</failOnWarnings>
234+
<!-- Enable MathJax -->
235+
<additionalOptions>-Xdoclint:all --allow-script-in-comments -header '&lt;script type="text/javascript" async src="${mathjax.url}"&gt;&lt;/script&gt;'</additionalOptions>
234236
</configuration>
235237
</plugin>
236238
<plugin>
@@ -315,6 +317,18 @@
315317
<groupId>org.apache.maven.plugins</groupId>
316318
<artifactId>maven-pmd-plugin</artifactId>
317319
</plugin>
320+
<plugin>
321+
<!-- NOTE: javadoc config must also be set under <build> -->
322+
<groupId>org.apache.maven.plugins</groupId>
323+
<artifactId>maven-javadoc-plugin</artifactId>
324+
<configuration>
325+
<source>8</source>
326+
<!-- TODO -->
327+
<failOnWarnings>false</failOnWarnings>
328+
<!-- Enable MathJax -->
329+
<additionalOptions>-Xdoclint:all --allow-script-in-comments -header '&lt;script type="text/javascript" async src="${mathjax.url}"&gt;&lt;/script&gt;'</additionalOptions>
330+
</configuration>
331+
</plugin>
318332
</plugins>
319333
</reporting>
320334
<profiles>

src/site/site.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
<image src="/images/logo.png"/>
2424
</bannerRight>
2525
<body>
26-
<head>&lt;script type="text/javascript" id="MathJax-script" async="async" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.2/MathJax.js?config=TeX-AMS-MML_HTMLorMML"&gt;&lt;/script&gt;
26+
<head>&lt;script type="text/javascript" id="MathJax-script" async="async" src="https://commons.apache.org/js/mathjax/tex-mml-chtml.js"&gt;&lt;/script&gt;
2727
&lt;style&gt;
2828
.footnotes ol li p {
2929
display: inline;

0 commit comments

Comments
 (0)