configurable font family (google fonts)
This commit is contained in:
parent
12c551468f
commit
e76c38db9d
|
@ -1,6 +1,11 @@
|
|||
{
|
||||
"icon": "/icons/128.png",
|
||||
"title": "Spencer's OneDrive Index",
|
||||
"googleFont": "Rubik",
|
||||
"googleFontWeights": [
|
||||
"400",
|
||||
"600"
|
||||
],
|
||||
"footer": "Powered by <a class=\"hover:underline\" href=\"https://github.com/spencerwooo/onedrive-vercel-index\" target=\"_blank\" rel=\"noopener noreferrer\">onedrive-vercel-index</a>. Made with ❤ by SpencerWoo.",
|
||||
"protectedRoutes": [
|
||||
"/🌞 Private folder/u-need-a-password",
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
import Document, { Head, Html, Main, NextScript } from 'next/document'
|
||||
import siteConfig from '../config/site.json'
|
||||
|
||||
class MyDocument extends Document {
|
||||
render() {
|
||||
|
@ -7,6 +8,14 @@ class MyDocument extends Document {
|
|||
<Head>
|
||||
<meta name="description" content="OneDrive Vercel Index" />
|
||||
<link rel="icon" href="/favicon.ico" />
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossOrigin="true" />
|
||||
<link
|
||||
href={`https://fonts.googleapis.com/css2?family=${
|
||||
siteConfig.googleFont
|
||||
}:wght@${siteConfig.googleFontWeights.join(';')}&display=swap`}
|
||||
rel="stylesheet"
|
||||
/>
|
||||
</Head>
|
||||
<body>
|
||||
<Main />
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;700&display=swap');
|
||||
|
||||
@tailwind base;
|
||||
@tailwind components;
|
||||
@tailwind utilities;
|
||||
|
|
|
@ -62,8 +62,6 @@
|
|||
line-height: 1.5;
|
||||
color: #24292e;
|
||||
background-color: #ffffff;
|
||||
font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial, sans-serif, Apple Color Emoji,
|
||||
Segoe UI Emoji;
|
||||
font-size: 16px;
|
||||
line-height: 1.5;
|
||||
word-wrap: break-word;
|
||||
|
@ -992,8 +990,8 @@
|
|||
.markdown-body {
|
||||
/* color: #c9d1d9; */
|
||||
/* background-color: #0d1117; */
|
||||
color: #F3F4F6;
|
||||
background-color: #18181B;
|
||||
color: #f3f4f6;
|
||||
background-color: #18181b;
|
||||
}
|
||||
.markdown-body a {
|
||||
color: #58a6ff;
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
const defaultTheme = require('tailwindcss/defaultTheme')
|
||||
const colors = require('tailwindcss/colors')
|
||||
const siteConfig = require('./config/site.json')
|
||||
|
||||
module.exports = {
|
||||
mode: 'jit',
|
||||
|
@ -22,7 +23,7 @@ module.exports = {
|
|||
},
|
||||
extend: {
|
||||
fontFamily: {
|
||||
sans: ['Inter', '"Noto Sans SC"', ...defaultTheme.fontFamily.sans]
|
||||
sans: [`"${siteConfig.googleFont}"`, '"Noto Sans SC"', ...defaultTheme.fontFamily.sans]
|
||||
},
|
||||
colors: {
|
||||
gray: {
|
||||
|
|
Loading…
Reference in a new issue