Fix tailwind theme to not override previous font families.

This commit is contained in:
jahooma 2021-12-12 16:37:59 -06:00
parent b216236503
commit 7ef00d085f
2 changed files with 12 additions and 7 deletions

View File

@ -96,11 +96,11 @@ export function BetPanel(props: { contract: Contract; className?: string }) {
<div className="p-2 font-medium">Implied probability</div>
<Row>
<div className="px-2" style={{ fontFamily: 'sans-serif' }}>
<div className="px-2 font-sans">
{Math.floor(initialProb * 1000) / 10 + '%'}
</div>
<div></div>
<div className="px-2" style={{ fontFamily: 'sans-serif' }}>
<div className="px-2 font-sans">
{Math.floor(resultProb * 1000) / 10 + '%'}
</div>
</Row>
@ -108,7 +108,7 @@ export function BetPanel(props: { contract: Contract; className?: string }) {
<Spacer h={2} />
<div className="p-2 font-medium">Estimated winnings</div>
<div className="px-2" style={{ fontFamily: 'sans-serif' }}>
<div className="px-2 font-sans">
{formatMoney(estimatedWinnings)} (+{estimatedReturnPercent})
</div>

View File

@ -1,12 +1,17 @@
const defaultTheme = require('tailwindcss/defaultTheme')
module.exports = {
mode: 'jit',
purge: ['./pages/**/*.{js,ts,jsx,tsx}', './components/**/*.{js,ts,jsx,tsx}'],
darkMode: false, // or 'media' or 'class'
theme: {
fontFamily: {
'major-mono': ['Major Mono Display', 'monospace'],
'readex-pro': ['Readex Pro', 'sans-serif'],
},
fontFamily: Object.assign(
{ ...defaultTheme.fontFamily },
{
'major-mono': ['Major Mono Display', 'monospace'],
'readex-pro': ['Readex Pro', 'sans-serif'],
}
),
extend: {
backgroundImage: {
'world-trading': "url('/world-trading-background.jpg')",