Skip to content

Commit

Permalink
폰트적용
Browse files Browse the repository at this point in the history
  • Loading branch information
dbstjs95 committed May 14, 2022
1 parent 80eb5a8 commit 96522aa
Show file tree
Hide file tree
Showing 7 changed files with 46 additions and 14 deletions.
6 changes: 4 additions & 2 deletions client/src/component/Footer.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import React from 'react';
import logo from '../images/logo.png';
import styled from 'styled-components';

const FooterContainer = styled.div`
Expand All @@ -8,6 +7,10 @@ const FooterContainer = styled.div`
color: white;
align-items: center;
padding: 20px 30px;
> ul {
list-style: none;
}
`;

const Footer = () => {
Expand All @@ -22,7 +25,6 @@ const Footer = () => {
Copyright &copy; <span>{thisYear()}</span>
</p>
<ul className="footer-info">
<li>TeamLeader&nbsp;:&nbsp;오상민</li>
<li>Back-End&nbsp;:&nbsp;오상민</li>
<li>Back-End&nbsp;:&nbsp;유지훈</li>
<li>Front-End&nbsp;:&nbsp;최윤선</li>
Expand Down
2 changes: 1 addition & 1 deletion client/src/component/Header.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import { NavLink } from 'react-router-dom';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import { faBars } from '@fortawesome/free-solid-svg-icons';
import { useState } from 'react';
import { useSelector } from 'react-redux';
import UserMenu from './UserMenu';
import styled from 'styled-components';

function Header() {
// const test = useSelector((state) => state);
Expand Down
5 changes: 4 additions & 1 deletion client/src/component/MypageCompo/UserInfo.js
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,10 @@ function UserInfo() {
//처음 렌더링때 작동: 유저정보 불러오기
useEffect(() => {
axios
.get(`${process.env.REACT_APP_SERVER_DEV_URL}/users/${id}`, getConfig)
.get(
`${process.env.REACT_APP_SERVER_DEV_URL}/users/userinfo/${id}`,
getConfig,
)
.then((res) => {
const { user } = res.data;
if (user) {
Expand Down
Binary file added client/src/fonts/EliceDigitalCoding_Bold.woff
Binary file not shown.
Binary file added client/src/fonts/EliceDigitalCoding_Regular.woff
Binary file not shown.
23 changes: 23 additions & 0 deletions client/src/fonts/fonts.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import { createGlobalStyle } from 'styled-components';
import EliceDigitalCodingRegular from './EliceDigitalCoding_Regular.woff';
import EliceDigitalCodingBold from './EliceDigitalCoding_Bold.woff';

export default createGlobalStyle`
@font-face {
font-family: 'Elice Regular';
src: local('Elice Regular'),
url(${EliceDigitalCodingRegular}) format('woff');
font-weight: 300;
font-style: normal;
}
@font-face {
font-family: 'Elice Bold';
src: local('Elice Bold'),
url(${EliceDigitalCodingBold}) format('woff');
font-weight: 300;
font-style: normal;
}
`;
24 changes: 14 additions & 10 deletions client/src/pages/Outline.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,36 @@ import { Outlet } from 'react-router-dom';
import Header from '../component/Header';
import Footer from '../component/Footer';
import styled from 'styled-components';
import GlobalFonts from '../fonts/fonts';

const EntireContainer = styled.div`
* {
box-sizing: border-box;
word-break: keep-all;
font-family: 'Helvetica', 'Arial', sans-serif;
color: red;
/* font-family: 'Helvetica', 'Arial', sans-serif; */
font-family: 'Elice Bold';
}
`;

const BodyContainer = styled.div`
* {
margin: 0;
background-color: wheat;
font-family: 'Elice Regular';
}
`;

function Outline() {
return (
<EntireContainer>
<Header />
<BodyContainer id="content-wrap">
<Outlet />
</BodyContainer>
<Footer />
</EntireContainer>
<>
<GlobalFonts />
<EntireContainer>
<Header />
<BodyContainer id="content-wrap">
<Outlet />
</BodyContainer>
<Footer />
</EntireContainer>
</>
);
}

Expand Down

0 comments on commit 96522aa

Please sign in to comment.