Skip to content

Commit

Permalink
Fix FakeTMP on light mode
Browse files Browse the repository at this point in the history
  • Loading branch information
NotNite committed Nov 28, 2023
1 parent f49c80e commit 5ea696b
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/FakeTMP.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ function parse(temp: string): React.ReactNode[] {
function add(str: string) {
if (currentColor == null) {
spans.push(
<span style={{ color: "#ffffff" }} key={spans.length}>
<span className="tmp" key={spans.length}>
{str}
</span>
);
Expand Down
12 changes: 12 additions & 0 deletions src/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,18 @@
--danger-inverse: #fff;
}

@media (prefers-color-scheme: dark) {
.tmp {
color: #ffffff;
}
}

@media (prefers-color-scheme: light) {
.tmp {
color: #000000;
}
}

.currentAccount {
align-items: center;
gap: 0.5rem;
Expand Down

0 comments on commit 5ea696b

Please sign in to comment.