Skip to content

Commit 73e3cbe

Browse files
committed
add darkmode for textarea
1 parent bb6e706 commit 73e3cbe

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

src/App.tsx

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from "react";
2-
import styled from "styled-components";
2+
import styled, { createGlobalStyle } from "styled-components";
33
import "latex.css/style.css";
44
import LZString from "lz-string";
55
import "katex/dist/katex.css";
@@ -8,9 +8,19 @@ import Katex from "./katex";
88
import Settings from "./settings";
99
const DEFAULT_VALUE = "\\zeta(s) = \\sum_{n=1}^\\infty \\frac{1}{n^s}";
1010

11+
const GlobalStyle = createGlobalStyle`
12+
.latex-dark {
13+
textarea {
14+
color: #f8f9fa;
15+
background-color: #212529;
16+
}
17+
}
18+
`;
19+
1120
function App() {
1221
return (
1322
<div>
23+
<GlobalStyle />
1424
<h1>MathJojo</h1>
1525
<Sandbox />
1626
</div>

0 commit comments

Comments
 (0)