Themes: add Monkeytype themes

This commit is contained in:
He4eT 2023-05-25 02:47:04 +03:00
commit 07c0ce0625
5 changed files with 1353 additions and 24 deletions

27
src/themes/_generator.js Normal file
View file

@ -0,0 +1,27 @@
/* @see https://github.com/monkeytypegame/monkeytype/blob/master/frontend/static/themes/_list.json */
const monkeyTypesThemes = [
/* Paste json here! */
].map((theme) => theme)
.filter((theme) => ![
'dark', 'solarized_dark', 'solarized_light',
].includes(theme.name))
.sort((a, b) => a.name.localeCompare(b.name))
const names = monkeyTypesThemes
.map(({name}) => `'${name}',`).join('\n')
const css = monkeyTypesThemes
.map((theme) => [
`.${theme.name} {`,
` --bg-color: ${theme.bgColor};`,
` --main-color: ${theme.textColor};`,
` --accent-color: ${theme.mainColor};`,
` --input-color: ${theme.subColor};`,
'}\n'].join('\n'))
.join('\n')
console.log('/* List*/')
console.log(names)
console.log('/* CSS */')
console.log(css)