Skip to content

Commit

Permalink
feat: add geist font
Browse files Browse the repository at this point in the history
  • Loading branch information
adrian-ub committed Aug 1, 2024
1 parent c6804a2 commit 7ff4014
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 1 deletion.
6 changes: 5 additions & 1 deletion apps/www/astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ export default defineConfig({
label: "CLI",
slug: "docs/cli",
},
{
label: "Typography",
slug: "docs/components/typography",
},
],
},
{
Expand All @@ -61,7 +65,7 @@ export default defineConfig({
},
},
],
customCss: ["./src/tailwind.css"],
customCss: ["./src/fonts/font-face.css", "./src/tailwind.css"],
components: {
Header: "./src/components/starlight/header/Header.astro",
SiteTitle: "./src/components/starlight/SiteTitle.astro",
Expand Down
Binary file added apps/www/src/fonts/GeistVariableVF.woff2
Binary file not shown.
5 changes: 5 additions & 0 deletions apps/www/src/fonts/font-face.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
@font-face {
font-family: "Geist Sans Variable";
src: url("./GeistVariableVF.woff2") format("woff2");
font-display: swap;
}
4 changes: 4 additions & 0 deletions apps/www/tailwind.config.mjs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import colors from "tailwindcss/colors";
import starlightPlugin from "@astrojs/starlight-tailwind";
import { fontFamily } from "tailwindcss/defaultTheme";

/** @type {import('tailwindcss').Config} */
export default {
Expand Down Expand Up @@ -72,6 +73,9 @@ export default {
"accordion-down": "accordion-down 0.2s ease-out",
"accordion-up": "accordion-up 0.2s ease-out",
},
fontFamily: {
sans: ["Geist Sans Variable", ...fontFamily.sans],
},
},
},
corePlugins: {
Expand Down

0 comments on commit 7ff4014

Please sign in to comment.