add server tests, improve readme and types

This commit is contained in:
Rene Haas
2022-10-17 11:32:09 +02:00
parent f3bcdfba85
commit 9c3b00a9a9
22 changed files with 5170 additions and 321 deletions
+1514
View File
File diff suppressed because it is too large Load Diff
+4 -1
View File
@@ -1,4 +1,7 @@
{
"private": true,
"main": "tailwind.config.js"
"main": "tailwind.config.js",
"devDependencies": {
"@tailwindcss/typography": "^0.5.7"
}
}
+95 -5
View File
@@ -3,13 +3,100 @@ const defaultTheme = require('tailwindcss/defaultTheme');
/** @type {import('tailwindcss').Config} */
module.exports = {
theme: {
extend: {},
extend: {
colors: {
transparent: 'transparent',
current: 'currentColor',
'primary-cyan1': '#33FFFF',
'primary-cyan2': '#87FED1',
'primary-green': '#C0FEB1',
'primary-blue1': '#338EFF',
'primary-blue2': '#4276FF',
'primary-violet': '#5D55FF',
'primary-dark': '#0A376B',
'primary-gray1': '#475774',
'primary-gray2': '#697996',
},
transitionProperty: {
transformColor: 'transform, color',
},
fontFamily: {
sans: ['Noto Sans', ...defaultTheme.fontFamily.sans],
},
typography: ({ theme }) => ({
DEFAULT: {
css: {
b: {
fontWeight: theme('fontWeight.medium'),
},
strong: {
fontWeight: theme('fontWeight.medium'),
},
h5: {
color: theme('colors.primary-dark'),
fontWeight: theme('fontWeight.medium'),
fontSize: theme('fontSize.sm'),
},
h6: {
color: theme('colors.primary-dark'),
fontWeight: theme('fontWeight.medium'),
fontSize: theme('fontSize.sm'),
},
'blockquote > p > strong:first-child': {
color: theme('colors.primary-blue2'),
},
'blockquote p:first-of-type::before': {
content: '',
},
'blockquote p:last-of-type::after': {
content: '',
},
code: {
background: 'var(--tw-prose-pre-bg)',
fontWeight: theme('fontWeight.medium'),
padding: theme('padding[1]'),
borderRadius: theme('borderRadius.md'),
},
'code::before': {
content: '',
},
'code::after': {
content: '',
},
'summary > *:only-child,': {
display: 'inline-block',
},
summary: {
display: 'inline list-item',
cursor: 'pointer',
},
},
},
primary: {
css: {
'--tw-prose-body': theme('colors.primary-gray1'),
'--tw-prose-headings': theme('colors.primary-dark'),
'--tw-prose-lead': theme('colors.primary-gray1'),
'--tw-prose-links': theme('colors.primary-blue2'),
'--tw-prose-bold': theme('colors.primary-dark'),
'--tw-prose-counters': theme('colors.primary-gray1'),
'--tw-prose-bullets': theme('colors.primary-blue2'),
'--tw-prose-hr': theme('colors.slate[200]'),
'--tw-prose-quotes': theme('colors.primary-dark'),
'--tw-prose-quote-borders': theme('colors.slate[200]'),
'--tw-prose-captions': theme('colors.primary-gray1'),
'--tw-prose-code': theme('colors.primary-dark'),
'--tw-prose-pre-code': theme('colors.pink[100]'),
'--tw-prose-pre-bg': theme('colors.slate[100]'),
'--tw-prose-th-borders': theme('colors.slate[200]'),
'--tw-prose-td-borders': theme('colors.slate[200]'),
},
},
}),
},
container: {
center: true,
},
fontFamily: {
sans: ['Noto Sans', ...defaultTheme.fontFamily.sans],
},
fontWeight: {
normal: 400,
medium: 600,
@@ -25,5 +112,8 @@ module.exports = {
xxl: '1536px',
},
},
plugins: [],
plugins: [
// eslint-disable-next-line global-require
require('@tailwindcss/typography'),
],
};