Compare commits
	
		
			2 commits
		
	
	
		
			10b5ce30a3
			...
			aa9153e50d
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| aa9153e50d | |||
| dba1380966 | 
					 2 changed files with 10 additions and 14 deletions
				
			
		|  | @ -9,18 +9,18 @@ html { | ||||||
| 	--font-family: comic-mono Consolas sans-serif; | 	--font-family: comic-mono Consolas sans-serif; | ||||||
| 	--syntax-tab-size: 2; | 	--syntax-tab-size: 2; | ||||||
| 
 | 
 | ||||||
| 	--background-color: var(--xkcd-very-dark-brown); | 	--background-color: var(--xkcd-eggshell); | ||||||
| 	--text-color: var(--xkcd-light-grey); | 	--text-color: var(--xkcd-dark-grey); | ||||||
| 	--text-color-link: var(--xkcd-steel-blue); | 	--text-color-link: var(--xkcd-teal); | ||||||
| 	--accent-color: var(--xkcd-bronze); | 	--accent-color: var(--xkcd-red-orange); | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| @media(prefers-color-scheme: light) { | @media(prefers-color-scheme: dark) { | ||||||
| 	html { | 	html { | ||||||
| 		--background-color: var(--xkcd-eggshell); | 		--background-color: var(--xkcd-very-dark-brown); | ||||||
| 		--text-color: var(--xkcd-dark-grey); | 		--text-color: var(--xkcd-light-grey); | ||||||
| 		--text-color-link: var(--xkcd-teal); | 		--text-color-link: var(--xkcd-steel-blue); | ||||||
| 		--accent-color: var(--xkcd-red-orange); | 		--accent-color: var(--xkcd-bronze); | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -22,11 +22,7 @@ function themeClear() { | ||||||
|   themeRefresh(); |   themeRefresh(); | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| function themeRefresh(newValue) { | function themeRefresh() { | ||||||
|   if (newValue !== undefined) { |  | ||||||
|     localStorage.setItem('theme', newValue); |  | ||||||
|   } |  | ||||||
| 
 |  | ||||||
|   const theme = localStorage.getItem('theme') |   const theme = localStorage.getItem('theme') | ||||||
|   const el = document.getElementsByTagName('html')[0]; |   const el = document.getElementsByTagName('html')[0]; | ||||||
|   if (theme == 'light') { |   if (theme == 'light') { | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		
		Reference in a new issue