Skip to content

Commit

Permalink
style : a 태그 밑줄 없애기, 테스트 처음으로 돌아가기
Browse files Browse the repository at this point in the history
  • Loading branch information
hwan129 committed Jun 8, 2024
1 parent 92ce3bf commit 623c554
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 4 deletions.
14 changes: 11 additions & 3 deletions src/components/header/header.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,13 @@ const Title = styled.div`
font-family: Dream5;
`;

const ReturnBtn = styled.button`
const ReturnBtn = styled.a`
border: 1px solid #410a0a;
border-radius: 30px;
margin-top: 4px;
text-decoration: none;
background-color: white;
width: 79px;
height: 32px;
Expand Down Expand Up @@ -93,11 +95,17 @@ export default function Header({ isHeader }) {
function getButton(isHeader) {
switch (isHeader) {
case "test":
return <ReturnBtn>처음으로</ReturnBtn>;
return (
<ReturnBtn href="/test" onClick={() => window.location.reload()}>
처음으로
</ReturnBtn>
);
case "ramentest":
return (
// <Link to="/test">
<ReturnBtn>처음으로</ReturnBtn>
<ReturnBtn href="/test" onClick={() => window.location.reload()}>
처음으로
</ReturnBtn>
// </Link>
);
case "main":
Expand Down
12 changes: 11 additions & 1 deletion src/components/review/mapLogo.jsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import styled from "styled-components";
import CharacterLogo from "../../imgs/characterLogo.svg";
import { useNavigate } from "react-router-dom";

const Sidebar = styled.div`
position: absolute;
Expand All @@ -13,12 +14,21 @@ const Character = styled.img`
height: 48px;
margin-top: 10px;
margin-right: 14px;
&:hover {
cursor: pointer;
}
`;

export default function MapLogo() {
const navigate = useNavigate();

function toMain() {
navigate("/");
}
return (
<Sidebar>
<Character src={CharacterLogo} alt="캐릭터 로고" />
<Character onClick={toMain} src={CharacterLogo} alt="캐릭터 로고" />
</Sidebar>
);
}

0 comments on commit 623c554

Please sign in to comment.