https://github.com/ssi02014/webstandardsite
๐ป W3C ์น ํ์ค ์ค์ ์น์ฌ์ดํธ
https://github.com/ssi02014/webstandardsite
Last synced: 8 days ago
JSON representation
๐ป W3C ์น ํ์ค ์ค์ ์น์ฌ์ดํธ
- Host: GitHub
- URL: https://github.com/ssi02014/webstandardsite
- Owner: ssi02014
- Created: 2020-08-20T17:44:34.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2021-02-26T20:10:25.000Z (over 4 years ago)
- Last Synced: 2025-07-19T07:57:57.420Z (3 months ago)
- Language: HTML
- Homepage:
- Size: 2.22 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ๐ป WebStandardSite
### HTML, CSS, JS(Jquery)๋ฅผ ์ด์ฉํด์ ๋ง๋ W3C ์น ํ์ค ์ค์ ์ฌ์ดํธ (๋ฐ์ํX)
### โญ Github Page : https://ssi02014.github.io/WebStandardSite/
## ๐ฅ index.html


## ๐ฅ W3C Check


## ๐ Main Development Stack
### ๐จ๐ปโ๐ป FrontEnd
1. HTML
2. CSS
3. JavaScript(Jquery)
## ๐ CSS ๊ด๋ จ ํ์ต ๋ด์ฉ ๋๋ ์ด์
### ๐ 1. IR ๊ธฐ๋ฒ: ์ด๋ฏธ์ง ๋์ฒด ํ ์คํธ ์ ๊ณต์ ์ํ CSS ๊ธฐ๋ฒ
```css
/* 1. ์๋ฏธ์๋ ์ด๋ฏธ์ง์ ๋์ฒด ํ ์คํธ ์ ๊ณต */
.ir_pm{
display: block;
overflow: hidden;
font-size: 0;
line-height: 0;
text-indent: -9999px;
}/* 2. ์๋ฏธ์๋ ์ด๋ฏธ์ง์ ๋์ฒด ํ ์คํธ๋ก ์ด๋ฏธ์ง๊ฐ ์์ด๋ ๋์ฒด ํ ์คํธ๋ฅผ ๋ณด์ฌ์ฃผ๊ณ ์ ํ ๋ ์ฌ์ฉ */
.ir_wa{
display: block;
overflow: hidden;
position: relative;
z-index: -1;
width: 100%;
height: 100%;
}/* 3. ๋์ฒด ํ ์คํธ๊ฐ ์๋ ์ ๊ทผ์ฑ์ ์ํ ์จ๊น ํ ์คํธ๋ฅผ ์ ๊ณตํ ๋ ์ฌ์ฉ */
.ir_su{
overflow: hidden;
position: absolute;
width: 0;
height: 0;
line-height: 0;
text-indent: -9999px;
}
```
### ๐ 2. float
```
โ float: left๋ก ์ธํ ์์ญ๊นจ์ง(height:0) ๋ฐฉ์ง๋ฒ
1. ๊นจ์ง๋ ์์ญ์ ๋๊ฐ์ด float:left๋ฅผ ์ฌ์ฉ
2. float์ ์ฑ์ง์ ์ฐจ๋จํ๋ clear:both; ๋ฅผ ์ฌ์ฉ
3. float์ ์ฌ์ฉํ ์์ ๋ฐ์คํํ overflow:hidden์ ์ฌ์ฉ
4. clearfix๋ฅผ ์ฌ์ฉ (O) ๊ฐ์ฅ ์ข์ ๋ฐฉ๋ฒbutโโ display:flex๊ฐ ๊ฐ์ฅ ์ข์!
```
### ๐ 3. ์ฝํ ์ธ ์์๋ฅผ ๋ณด์ด์ง ์๊ฒ ํ๋ ๋ฐฉ๋ฒ
```
1. display: none โ๏ธ display: block (์์ญ์ด ์ฌ๋ผ์ง)
2. visibility : hidden โ๏ธ visibility : visible; (์์ญ ์ ์ง)
3. opacity: 0 โ๏ธ opacity: 1; (์์ญ ์ ์ง)
4. width: 0, height: 0, overflow:hidden;
```
### ๐ 4. ํ ์ค ํจ๊ณผ, ๋ ์ค ํจ๊ณผ
```css
/* ํ ์คํจ๊ณผ */
li {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
/* ๋ ์คํจ๊ณผ */
li {
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
}
```
### ๐ 5. Image Sprite
```
โ ์ด๋ฏธ์ง ์คํ๋ผ์ดํธ(image sprite): ์ฌ๋ฌ ๊ฐ์ ์ด๋ฏธ์ง๋ฅผ ํ๋์ ์ด๋ฏธ์ง๋ก ํฉ์ณ์ ๊ด๋ฆฌํ๋ ์ด๋ฏธ์ง๋ฅผ ์๋ฏธํ๋ค.- ์ฅ์
1. ์ด๋ฏธ์ง๋ฅผ ๋ค์ด๋ฐ๊ธฐ ์ํ ์๋ฒ ์์ฒญ์ ์ค์ผ ์ ์๋ค.
2. ๋ชจ๋ฐ์ผ ํ๊ฒฝ๊ณผ ๊ฐ์ ํ์ ๋ ์์์ ์ฌ์ฉํ๋ ํ๋ซํผ์์๋ ์น ํ์ด์ง ๋ก๋ฉ ์๊ฐ์ ๋จ์ถํด์ฃผ๋ ํจ๊ณผ๊ฐ ์๋ค.
3. ๋ง์ ์ด๋ฏธ์ง ํ์ผ์ ๊ด๋ฆฌํ๋ ๋์ ๋ช ๊ฐ์ ์คํ๋ผ์ดํธ ์ด๋ฏธ์ง ํ์ผ๋ง์ ๊ด๋ฆฌํ๋ฏ๋ก ๊ฐํธํ๋ค.
```
```css
/* image sprite */
.header .header-icon a{
width: 60px;
height: 60px;
background: url(../img/icon.png);
display: inline-block;
margin: 0 3px;
}
.header .header-icon a.icon1{
background-position: 0 0;
}
.header .header-icon a.icon2{
background-position: 0 -60px;
}
.header .header-icon a.icon3{
background-position: 0 -120px;
}
.header .header-icon a.icon4{
background-position: 0 -180px;
}
.header .header-icon a.icon1:hover{
background-position: -60px 0;
}
.header .header-icon a.icon2:hover{
background-position: -60px -60px;
}
.header .header-icon a.icon3:hover{
background-position: -60px -120px;
}
.header .header-icon a.icon4:hover{
background-position: -60px -180px;
}
```### ๐ 6. ์ด๋ฏธ์ง๋ฅผ ํํํ๋ ๋ฐฉ๋ฒ
```
1. img ํ๊ทธ๋ก ํํ(์๋ฏธ๊ฐ ์์ ๋) alt ํ๊ทธ - ๋์ฒด ๋ฌธ์ ํํ ํ์
2. background ์์ฑ(์๋ฏธ๊ฐ ์์ ๋) - ๋์ฒด ๋ฌธ์ ํ์ x
3. (์ต๊ทผ)์ด๋ฏธ์ง๋ฅผ background ์์ฑ์ผ๋ก ํํ / ๊ฐ์์ผ๋ก ๋์ฒด๋ฅผ ๋ฌธ์๋ฅผ ๋ง๋ค์ด์ค(IR ํจ๊ณผ)
์ด๋ฏธ์ง ์คํ๋ผ์ดํธ ์์ฑ๋๋ฌธ// ์ฉ๋ ์ต์ํ ๋ฑ๋ฑ ํจ๊ณผ์์
```
## ๐ Javascript ๋ผ์ด๋ธ๋ฌ๋ฆฌ(Jquery)
### ๐ 1. html์ css, javascript ์ฝ์ ํ๊ธฐ
```html
```
### ๐ 2. Slick ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ํตํ Slide ๊ตฌํํ๊ธฐ
```javascript
//Banner
$(".ban").slick({
infinite: true,
slidesToShow: 3,
slidesToScroll: 3,
autoplay: true,
autoplaySpeed: 3000, //3์ด์ 1๋ฒ์ฉ autoplay
dots: true
});//Gallery
$(".gallery-img").slick({
arrows: false, //slick์ prev, next ๋ฒํผ
fade: true, //ํ์ด๋ ํจ๊ณผ์ฃผ๊ธฐ
infinite: true, //๋ฃจํ๋ฅผ ๋ฌดํ๋๋ก
pauseOnHover: true, //๋ง์ฐ์ค ์ค๋ฒํ๋ฉด ๋ฉ์ถค
autoplay: true, //์๋ ์ฌ์
speed: 300,
slidesToShow: 1 //์ฌ๋ผ์ด๋๋ฅผ 1์ฉ ๋๊น
});
$(".play").click(function(){
$(".gallery-img").slick("slickPlay")
});
$(".pause").click(function(){
$(".gallery-img").slick("slickPause")
});
$(".prev").click(function(){
$(".gallery-img").slick("slickPrev")
});
$(".next").click(function(){
$(".gallery-img").slick("slickNext")
});
```