Skip to content

Commit

Permalink
revert to one css file
Browse files Browse the repository at this point in the history
  • Loading branch information
grcoleman committed Jul 24, 2020
1 parent 60105b6 commit d7806ed
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 37 deletions.
12 changes: 0 additions & 12 deletions WebView/app/src/main/assets/dark.css

This file was deleted.

17 changes: 0 additions & 17 deletions WebView/app/src/main/assets/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,6 @@
<head>
<script async src="main.js"></script>
<meta name="color-scheme" content="dark light">
<script>
// If dark mode is not supported then load light.css
if (window.matchMedia('(prefers-color-scheme: dark)').media === 'not all') {
document.head.insertAdjacentHTML(
'beforeend',
'<link rel="stylesheet" href="light.css" onload="document.documentElement.style.display = \'\'">'
);
}
</script>
<!--
If dark mode is supported, conditionally either load the light or the dark stylesheet. If
`prefers-color-scheme` is not supported the media query is unknown and the files are loaded
with `lowest` priority.
-->
<link rel="stylesheet" href="dark.css" media="(prefers-color-scheme: dark)">
<link rel="stylesheet" href="light.css" media="(prefers-color-scheme: light)">
<!-- The main stylesheet with generic rules used universally -->
<link rel="stylesheet" href="style.css">
</head>
<body onload="getData()">
Expand Down
8 changes: 0 additions & 8 deletions WebView/app/src/main/assets/light.css

This file was deleted.

21 changes: 21 additions & 0 deletions WebView/app/src/main/assets/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,13 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
body {
background-color: white;
}
h1, h2 {
text-align: center;
color: black;
text-align: center;
}
p {
font-family: verdana;
Expand Down Expand Up @@ -80,4 +85,20 @@ img {
padding-top: 20%;
padding-left: 5%;
padding-right: 5%;
}
@media (prefers-color-scheme: dark) {
body {
background: #383838;
}
h1 {
color: white;
}
h2 {
color: white;
}
select {
color: white;
background-color: #1f1f1f;
border-color: #121212;
}
}

0 comments on commit d7806ed

Please sign in to comment.