Skip to content

Commit

Permalink
Merge pull request #35 from softeerbootcamp4th/dev-darkdulgi
Browse files Browse the repository at this point in the history
[design] 폰트 적용 #4
  • Loading branch information
lybell-art authored Jul 25, 2024
2 parents 578fa27 + be7ec85 commit 39a40d2
Show file tree
Hide file tree
Showing 7 changed files with 36 additions and 11 deletions.
Binary file added public/font/DS-DIGI.TTF
Binary file not shown.
Binary file added public/font/HyundaiSansTextOffice-Medium.ttf
Binary file not shown.
Binary file added public/font/HyundaiSansTextOffice-Medium.woff
Binary file not shown.
8 changes: 6 additions & 2 deletions src/App.jsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
function App() {
return (
<div>
<span>Hello Orange</span>
<div className="text-5xl">
<div className="flex flex-col">
<span>다람쥐 헌 쳇바퀴에 타고파</span>
<span>Hyundai Sans Text Office</span>
<span className="font-ds-digital">0123456789</span>
</div>
</div>
);
}
Expand Down
16 changes: 16 additions & 0 deletions src/index.css
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
@tailwind base;
@tailwind components;
@tailwind utilities;

@font-face {
font-family: "ds-digital";
src: url("/font/DS-DIGI.TTF") format("truetype");
}

@font-face {
font-family: "hdsans";
src: url("/font/HyundaiSansTextOffice-Medium.woff") format("woff"), url("/font/HyundaiSansTextOffice-Medium.ttf") format("truetype")
}

@layer base {
body {
font-family: "hdsans";
}
}
12 changes: 6 additions & 6 deletions tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
/** @type {import('tailwindcss').Config} */
export default {
content: [
"./index.html",
"./src/**/*.{js,ts,jsx,tsx}",
],
content: ["./index.html", "./src/**/*.{js,ts,jsx,tsx}"],
theme: {
extend: {},
fontFamily: {
"ds-digital": ["ds-digital"],
"hdsans": ["hdsans"],
},
},
plugins: [],
}

};
11 changes: 8 additions & 3 deletions vite.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
import { defineConfig } from "vite";
import react from "@vitejs/plugin-react";
import { resolve } from "path";

// https://vitejs.dev/config/
export default defineConfig({
base: "./",
plugins: [react()],
})
resolve: {
alias: [{ find: "@", replacement: resolve(__dirname, "src") }],
},
});

0 comments on commit 39a40d2

Please sign in to comment.