📅2024. 01. 19 30일차
- 5차시도 2차메뉴 배경의 높이 조절 (3차 + 4차)
- 6차시도 모바일 탑바 레이아웃
- 7차시도 토글 버튼 완성
실행 중지
톰캣 서버 삭제
create new server
아파치에서 아파치 10.1 선택
add all 하고 finish
tomcat server 8080을 8081로 바꾸기
다시 실행 톰캣 선택 후 next -> finish
.mail {
border: 2px solid red;
width: 100px; /*44px*/
height: 44px;
background-image: url(https://pm.pstatic.net/resources/asset/sp_main.2b26eb67.png);
background-position: -250px -90px;
background-size: 434px 416px;
}
음소거 바로 재생 가능
HTML
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.7.1/jquery.min.js"></script>
<div class="pop_up">POP UP!</div>
<div class="layer">
<div class="title">title</div>
<div class="body">Lorem ipsum dolor sit amet consectetur adipisicing elit. Amet ut pariatur commodi eligendi, nostrum numquam. Architecto, repellat molestias at ducimus expedita quisquam. Quos expedita possimus nam odio ab sint cupiditate? </div>
<button class="close_btn">close</button>
</div>
<div class="layer_bg"></div>
CSS
body,
ul,
li {
margin: 0;
padding: 0;
list-style: none;
}
a {
color: inherit;
text-decoration: none;
}
.pop_up {
display: inline-block;
font-size: 4rem;
background-color: #afafaf;
}
.layer {
display: none;
width: 500px;
height: 500px;
background-color: pink;
border: 5px solid red;
position: absolute;
left: 50%;
top: 50%;
transform: translatex(-50%) translatey(-50%);
z-index: 100;
}
.title {
padding: 20px;
font-size: 2rem;
}
.body {
padding: 20px;
font-size: 1.4rem;
}
.close_btn {
position: absolute;
bottom: 30px;
right: 30px;
font-size: 2rem;
}
.layer_bg {
display: none;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, 0.3);
position: absolute;
left: 0;
top: 0;
z-index: 50;
}
JS
console.clear();
$(".pop_up").click(function () {
$(".layer").show();
$(".layer_bg").show();
// $('.layer').css('display','block');
});
$(".close_btn").click(function () {
// $(".layer").hide();
$(".layer").css("display", "none");
$(".layer_bg").hide();
});