Skip to content

Commit 8d2bb12

Browse files
committed
Fix #24685: use webjars instead of CDN
1 parent cb55cc8 commit 8d2bb12

3 files changed

Lines changed: 14 additions & 2 deletions

File tree

pom.xml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -271,6 +271,16 @@
271271
<artifactId>jquery</artifactId>
272272
<version>3.5.0</version>
273273
</dependency>
274+
<dependency>
275+
<groupId>org.webjars.bower</groupId>
276+
<artifactId>bootstrap-social</artifactId>
277+
<version>5.1.1</version>
278+
</dependency>
279+
<dependency>
280+
<groupId>org.webjars.bower</groupId>
281+
<artifactId>fontawesome</artifactId>
282+
<version>4.7.0</version>
283+
</dependency>
274284

275285
<!-- Amazon S3 -->
276286
<dependency>

src/main/java/eu/openanalytics/containerproxy/api/BaseController.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ protected void prepareMap(ModelMap map) {
4444
map.put("bootstrapCss", "/webjars/bootstrap/3.4.1/css/bootstrap.min.css");
4545
map.put("bootstrapJs", "/webjars/bootstrap/3.4.1/js/bootstrap.min.js");
4646
map.put("jqueryJs", "/webjars/jquery/3.5.0/jquery.min.js");
47+
map.put("fontAwesomeCss", "/webjars/fontawesome/4.7.0/css/font-awesome.min.css");
48+
map.put("bootstrapSocialCss", "/webjars/bootstrap-social/5.1.1/bootstrap-social.css");
4749
}
4850

4951
public static class NotFoundException extends RuntimeException {

src/main/resources/templates/login.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@
3030
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
3131
<link rel="stylesheet" media="screen" th:href="@{${bootstrapCss}}" />
3232
<link rel="stylesheet" media="screen" th:href="@{/css/login.css}"/>
33-
<link rel="stylesheet" media="screen" type="text/css" href="https://cdn.jsdelivr.net/bootstrap-social/5.1.1/bootstrap-social.css"/>
34-
<link rel="stylesheet" media="screen" type="text/css" href="https://cdn.jsdelivr.net/fontawesome/4.7.0/css/font-awesome.min.css"/>
33+
<link rel="stylesheet" media="screen" th:href="@{${bootstrapSocialCss}}"/>
34+
<link rel="stylesheet" media="screen" th:href="@{${fontAwesomeCss}}"/>
3535
<script th:src="@{${jqueryJs}}"></script>
3636
<script th:src="@{${bootstrapJs}}"></script>
3737
</head>

0 commit comments

Comments
 (0)