✅ 부트스트랩 활용 - 반응형 웹페이지(인스타그램) 만들기
🔥 html 기본 틀 (부트스트랩 활용하기 전 <head>부분에 링크 세팅 하고 활용하기)
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-1BmE4kWBq78iYhFldvKuhfTAU6auU8tT94WrHftjDbrCEXSU1oBoqyl2QvZ6jIW3" crossorigin="anonymous">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.8.0/font/bootstrap-icons.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/js/bootstrap.bundle.min.js" integrity="sha384-ka7Sk0Gln4gmtz2MlQnikT1wXgYsOg+OMhuP+IlRH9sENBO0LRn5q+8nbTov4+1p" crossorigin="anonymous"></script>
<title> 띵동코딩-부트스트랩_인스타그램</title>
<style>
</style>
</head>
<body>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link
href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css"
rel="stylesheet"
integrity="sha384-1BmE4kWBq78iYhFldvKuhfTAU6auU8tT94WrHftjDbrCEXSU1oBoqyl2QvZ6jIW3"
crossorigin="anonymous"
/>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.8.0/font/bootstrap-icons.css" />
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script
src="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/js/bootstrap.bundle.min.js"
integrity="sha384-ka7Sk0Gln4gmtz2MlQnikT1wXgYsOg+OMhuP+IlRH9sENBO0LRn5q+8nbTov4+1p"
crossorigin="anonymous"
></script>
<title>띵동코딩-부트스트랩_인스타그램</title>
<style>
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+KR:wght@100;300;400;500;700;900&display=swap');
* {
font-family: 'Noto Sans KR', sans-serif;
}
body,
h1,
h2,
h3,
p,
a {
font-weight: normal;
margin: 0;
padding: 0;
text-decoration: none;
}
.name {
color: gray;
font-size: 12px;
margin-bottom: 5px;
}
.title {
font-size: 14px;
}
.wrap {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
width: 300px;
margin: 20px auto 0px auto;
}
.card-text {
font-size: 14px;
}
.user {
font-size: 14px;
font-weight: 500;
}
.card-body > input {
border: none;
margin-top: 10px;
font-weight: 400;
}
.icons {
display: flex;
flex-direction: row;
justify-content: space-between;
align-items: center;
margin-bottom: 10px;
}
.icons > .bi-send {
margin-right: auto;
}
.icons > .bi-suit-heart {
margin-right: 10px;
}
.icons > .bi-chat {
margin-right: 10px;
}
.me {
width: 280px;
display: flex;
flex-direction: row;
justify-content: space-between;
align-items: center;
margin-bottom: 5px;
font-size: 14px;
font-weight: 500;
}
.me > img {
width: 25px;
height: 25px;
border-radius: 100%;
margin-right: 10px;
}
.me > span {
margin-right: auto;
}
</style>
</head>
<body>
<div class="wrap">
<h1 class="name">SKUUKZKY</h1>
<p class="title">게시물</p>
<div class="me">
<img src="http://www.naewoeilbo.com/news/photo/202110/414285_189601_940.png" />
<span>SKUUKZKY</span>
<i class="bi bi-three-dots"></i>
</div>
<div class="card" style="width: 18rem">
<img
src="http://talkimg.imbc.com/TVianUpload/tvian/TViews/image/2021/10/18/a706569b-e8db-4c05-bbd1-2c48a53a0f2f.jpg"
class="card-img-top"
alt="..."
/>
<div class="card-body">
<div class="icons">
<i class="bi bi-suit-heart"></i>
<i class="bi bi-chat"></i>
<i class="bi bi-send"></i>
<i class="bi bi-bookmark"></i>
</div>
<p class="card-text">1500명이 좋아합니다</p>
<p class="user">SKUUKZKY</p>
<input
class="form-control form-control-sm"
type="text"
placeholder="...댓글달기"
aria-label=".form-control-sm example"
/>
</div>
</div>
</div>
</body>
</html>
'Web_Project' 카테고리의 다른 글
[jQuery + 자바스크립트] 이메일 로그인 하기 (1) | 2023.12.02 |
---|---|
[CSS] 부트스트랩 활용 - 쇼핑몰 만들기 (0) | 2023.12.01 |
[CSS] 틀린 그림 찾기 (2) | 2023.12.01 |
[CSS]로그인 접속 페이지 만들기 (1) | 2023.11.30 |
[CSS] 간단한 로그인 페이지 만들기 (1) | 2023.11.30 |