File tree Expand file tree Collapse file tree 5 files changed +895
-1898
lines changed Expand file tree Collapse file tree 5 files changed +895
-1898
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ const Icon: FC<Props> = ({
16
16
className = "" ,
17
17
viewBox = DEFAULT_VIEW_BOX ,
18
18
width = "45" ,
19
- height = "45"
19
+ height = "45" ,
20
20
} ) => (
21
21
< span className = { `icon ${ className } ` } >
22
22
< svg
@@ -73,7 +73,12 @@ export function DiscordIcon({ className = "" }) {
73
73
74
74
export function LightThemeIcon ( { className = "" } ) {
75
75
return (
76
- < Icon className = { className } width = { "24" } height = { "24" } viewBox = { "0 0 16 16" } >
76
+ < Icon
77
+ className = { className }
78
+ width = { "24" }
79
+ height = { "24" }
80
+ viewBox = { "0 0 16 16" }
81
+ >
77
82
< path
78
83
fill = "#ffffff"
79
84
d = "M8 11a3 3 0 1 1 0-6 3 3 0 0 1 0 6zm0 1a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM8 0a.5.5 0 0 1 .5.5v2a.5.5 0 0 1-1 0v-2A.5.5 0 0 1 8 0zm0 13a.5.5 0 0 1 .5.5v2a.5.5 0 0 1-1 0v-2A.5.5 0 0 1 8 13zm8-5a.5.5 0 0 1-.5.5h-2a.5.5 0 0 1 0-1h2a.5.5 0 0 1 .5.5zM3 8a.5.5 0 0 1-.5.5h-2a.5.5 0 0 1 0-1h2A.5.5 0 0 1 3 8zm10.657-5.657a.5.5 0 0 1 0 .707l-1.414 1.415a.5.5 0 1 1-.707-.708l1.414-1.414a.5.5 0 0 1 .707 0zm-9.193 9.193a.5.5 0 0 1 0 .707L3.05 13.657a.5.5 0 0 1-.707-.707l1.414-1.414a.5.5 0 0 1 .707 0zm9.193 2.121a.5.5 0 0 1-.707 0l-1.414-1.414a.5.5 0 0 1 .707-.707l1.414 1.414a.5.5 0 0 1 0 .707zM4.464 4.465a.5.5 0 0 1-.707 0L2.343 3.05a.5.5 0 1 1 .707-.707l1.414 1.414a.5.5 0 0 1 0 .708z"
@@ -84,7 +89,12 @@ export function LightThemeIcon({ className = "" }) {
84
89
85
90
export function DarkThemeIcon ( { className = "" } ) {
86
91
return (
87
- < Icon className = { className } width = { "24" } height = { "24" } viewBox = { "0 0 24 24" } >
92
+ < Icon
93
+ className = { className }
94
+ width = { "24" }
95
+ height = { "24" }
96
+ viewBox = { "0 0 24 24" }
97
+ >
88
98
< path
89
99
fill = "#ffffff"
90
100
d = "M12.0972 2.53039C12.2913 2.8649 12.2752 3.28136 12.0557 3.5998C11.3898 4.56594 11 5.73595 11 7.00002C11 10.3137 13.6863 13 17 13C18.2641 13 19.4341 12.6102 20.4002 11.9443C20.7187 11.7249 21.1351 11.7087 21.4696 11.9028C21.8041 12.0969 21.9967 12.4665 21.9642 12.8519C21.5313 17.9765 17.236 22 12 22C6.47715 22 2 17.5229 2 12C2 6.76398 6.02351 2.46874 11.1481 2.03585C11.5335 2.0033 11.9031 2.19588 12.0972 2.53039ZM9.42424 4.42352C6.26994 5.49553 4 8.48306 4 12C4 16.4183 7.58172 20 12 20C15.517 20 18.5045 17.7301 19.5765 14.5758C18.7676 14.8508 17.9008 15 17 15C12.5817 15 9 11.4183 9 7.00002C9 6.09922 9.1492 5.2324 9.42424 4.42352Z"
Original file line number Diff line number Diff line change @@ -6,13 +6,13 @@ const ToggleTheme: React.FC = () => {
6
6
* Handles theme change
7
7
*/
8
8
const toggleTheme = ( ) => {
9
- const THEME_KEY = ' data-theme' ;
9
+ const THEME_KEY = " data-theme" ;
10
10
11
11
// getting current theme from body element
12
12
const currentTheme = document . body . getAttribute ( THEME_KEY ) ;
13
13
14
14
// new theme, opposite to current theme
15
- const newTheme = currentTheme === ' light' ? ' dark' : ' light' ;
15
+ const newTheme = currentTheme === " light" ? " dark" : " light" ;
16
16
17
17
// set new theme on body element
18
18
document . body . setAttribute ( THEME_KEY , newTheme ) ;
You can’t perform that action at this time.
0 commit comments