36 | {latex && (
37 |
38 | LaTeX experimental support
39 |
40 | )}
41 | {/* biome-ignore lint/security/noDangerouslySetInnerHtml: Internal function */}
42 |
45 | {syntaxHighlight(expression)}
46 |
47 | {answer ? (
48 |
{
51 | if (event.detail !== 2) return;
52 | event.preventDefault();
53 | copyAnswer();
54 | }}
55 | onKeyPress={() => copyAnswer()}
56 | >
57 | {"="}
58 | {answer.toSignificantDigits(accuracy).toString().replace(".", ",")}
59 |
60 | ) : (
61 |
62 | ⠀
63 |
64 | )}{" "}
65 | {/* Space taker */}
66 |
67 | );
68 | }
69 |
--------------------------------------------------------------------------------
/src/styles/themes/dracula.scss:
--------------------------------------------------------------------------------
1 | /**
2 | * Based on Dracula Speedcrunch theme https://github.com/dracula/speedcrunch
3 | * Licensed under MIT
4 | */
5 |
6 | /*
7 | MIT License
8 |
9 | Copyright (c) 2022 Dracula Theme
10 |
11 | Permission is hereby granted, free of charge, to any person obtaining a copy
12 | of this software and associated documentation files (the "Software"), to deal
13 | in the Software without restriction, including without limitation the rights
14 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
15 | copies of the Software, and to permit persons to whom the Software is
16 | furnished to do so, subject to the following conditions:
17 |
18 | The above copyright notice and this permission notice shall be included in all
19 | copies or substantial portions of the Software.
20 |
21 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
26 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
27 | SOFTWARE.
28 | */
29 |
30 | body.theme-dracula {
31 | --theme-background: #282a36;
32 | --theme-text-color: #f8f8f2;
33 | --theme-answer: #50fa7b;
34 | --theme-warning: #ff79c6;
35 | --theme-input-background: #44475a;
36 | --theme-cursor: #f8f8f2;
37 | --theme-symbol-litr: #ffb86c;
38 | --theme-symbol-oper: #8be9fd;
39 | --theme-symbol-func: #50fa7b;
40 | --theme-symbol-var: #f8f8f2;
41 | --theme-symbol-separator: #ff79c6;
42 | --theme-symbol-rbrk: #f8f8f2;
43 | --theme-symbol-lbrk: #f8f8f2;
44 | --theme-link-color: #8be9fd; /* Operator color */
45 | --theme-link-color-secondary: #a4f2ff; /* Even Lighter Operator color */
46 | }
47 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 |