An open API service indexing awesome lists of open source software.

https://github.com/ssi02014/webstandardsite

๐Ÿ’ป W3C ์›น ํ‘œ์ค€ ์ค€์ˆ˜ ์›น์‚ฌ์ดํŠธ
https://github.com/ssi02014/webstandardsite

Last synced: 8 days ago
JSON representation

๐Ÿ’ป W3C ์›น ํ‘œ์ค€ ์ค€์ˆ˜ ์›น์‚ฌ์ดํŠธ

Awesome Lists containing this project

README

          

# ๐Ÿ’ป WebStandardSite
### HTML, CSS, JS(Jquery)๋ฅผ ์ด์šฉํ•ด์„œ ๋งŒ๋“  W3C ์›น ํ‘œ์ค€ ์ค€์ˆ˜ ์‚ฌ์ดํŠธ (๋ฐ˜์‘ํ˜•X)
### โญ Github Page : https://ssi02014.github.io/WebStandardSite/




## ๐ŸŽฅ index.html

![1](https://user-images.githubusercontent.com/64779472/92410375-da5e2e00-f17e-11ea-8eb1-c3d9706a29c5.PNG)
![2](https://user-images.githubusercontent.com/64779472/92410378-db8f5b00-f17e-11ea-8c82-dbd915f72eb7.PNG)






## ๐ŸŽฅ W3C Check

![1](https://user-images.githubusercontent.com/64779472/92410522-53f61c00-f17f-11ea-89e5-e0b42acdd479.PNG)


![2](https://user-images.githubusercontent.com/64779472/92410524-548eb280-f17f-11ea-96f0-15deef31fbd5.PNG)






## ๐Ÿ”– 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")
});
```