Skip to content

Commit 82d8b00

Browse files
committed
Add dark mode
1 parent c19b714 commit 82d8b00

5 files changed

Lines changed: 59 additions & 13 deletions

File tree

Readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
* alaugks/spring-messagesource-xliff ([GitHub](https://github.com/alaugks/spring-messagesource-xliff))
44
* Docker Image: alaugks/spring-boot-xliff-example:
5-
2.0.0.2 ([Docker Hub](https://hub.docker.com/r/alaugks/spring-messagesource-xliff-example/tags))
5+
2.0.0.3 ([Docker Hub](https://hub.docker.com/r/alaugks/spring-messagesource-xliff-example/tags))
66
* [Example Website](https://spring-boot-xliff-example.alaugks.dev)
77

88
## Build and Run Docker Image

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<groupId>io.github.alaugks</groupId>
77
<artifactId>spring-messagesource-xliff-example</artifactId>
88

9-
<version>2.0.0.2</version>
9+
<version>2.0.0.3</version>
1010

1111
<packaging>jar</packaging>
1212

src/main/resources/static/main.css

Lines changed: 54 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,36 @@
1-
* {
1+
:root {
2+
color-scheme: light dark;
3+
}
4+
5+
body {
6+
background-color: #fff;
27
font-family: sans-serif;
8+
color: #000;
9+
}
10+
11+
a {
12+
color: #4493F8;
13+
font-weight: bold;
14+
}
15+
16+
a:visited {
17+
color: #b6268d;
318
}
419

520
table {
6-
background-color: #FFFFFF;
721
border-collapse: collapse;
822
border-width: 1px;
923
border-color: #000;
1024
border-style: solid;
11-
color: #000;
1225
}
1326

14-
1527
table td, table th {
1628
border-width: 1px;
1729
border-color: #000;
1830
border-style: solid;
1931
padding: 5px;
2032
}
2133

22-
table thead {
23-
background-color: #D1D1D1;
24-
}
25-
2634
ul {
2735
padding: 0;
2836
margin: 0;
@@ -62,3 +70,41 @@ div.menu-pages {
6270
table {
6371
margin-top: 2em;
6472
}
73+
74+
input {
75+
color: #000;
76+
background: none;
77+
font-size: 1em;
78+
}
79+
80+
.github {
81+
padding: 0 0 2em 0;
82+
}
83+
84+
.version {
85+
padding: 0 0 2em 0;
86+
color:#cacccf;
87+
font-size: 0.8em;
88+
text-align: right;
89+
}
90+
91+
@media (prefers-color-scheme: dark) {
92+
body {
93+
background-color: #2b2b2b;
94+
color: #fff;
95+
}
96+
97+
table {
98+
border-color: #fff;
99+
}
100+
101+
table td, table th {
102+
border-color: #fff;
103+
color: #fff;
104+
}
105+
106+
input {
107+
background-color: #ccc;
108+
color: #000;
109+
}
110+
}

src/main/resources/templates/home/translations.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
<table>
1414
<thead>
1515
<tr>
16-
<th>id</th>
16+
<th>id/code</th>
1717
<th>value</th>
1818
</tr>
1919
</thead>

src/main/resources/templates/layouts/base.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@
1919
</main>
2020

2121
<footer>
22-
<p style="padding: 0 0 2em 0;">
22+
<p class="github">
2323
SourceCode of this example on <a href="https://github.com/alaugks/spring-messagesource-xliff-example-spring-boot">GitHub</a>.
2424
</p>
2525

26-
<p style="padding: 0 0 2em 0;color:#cacccf; font-size: 0.8em;text-align: right;">
26+
<p class="version">
2727
[[${@environment.getProperty('docker.image.version')}]]
2828
</p>
2929
</footer>

0 commit comments

Comments
 (0)