front
developer

6개월 동안 열심히 공부하여 만들었습니다. 즐겁게 봐주세요.

work

  • 이미지
  • HTML
  • CSS
  • 자바스크립트
<!-- box -->
<section class="color-shape class">
  <a href="class/index.html" target="_blank">
    <div class="image-wrap">
      <div class="hover-wrap">
        <span class="overlay-img-donut">CLASS</span>
        <span class="overlay-text-thumb-donut">클래스</span>
        <span class="overlay-text-thumb1-donut">클래스</span>
        <span class="overlay-text-thumb2-donut">CLASS</span>
      </div>
      <img src="assets/img/kidaha-01.svg" alt="portfolio" />
      <div class="img-text donutImg">
        <h5>CLASS</h5>
        <p>클래스</p>
        <span>CLASS</span>
      </div>
    </div>
  </a>
</section>
<!-- //box -->                        

  #clock {
    display: block;
  }

  .link1 {
    background: #fff;
    left: 50%;
    transform: translatex(-50%);
    color: #000;
    display: inline-block;
    border-radius: 5px;
    font-weight: bold;
    padding: 10px 30px !important;
    height: auto !important;
    box-sizing: border-box;
    width: auto !important;
    font-size: 20px !important;
    margin-top: 36px !important;
  }

  .link2 {
    background: #fff;
    left: 50%;
    transform: translatex(-50%);
    color: #000;
    display: inline-block;
    border-radius: 5px;
    font-weight: bold;
    padding: 10px 30px !important;
    height: auto !important;
    box-sizing: border-box;
    width: auto !important;
    font-size: 20px !important;
    margin-top: 86px !important;
  }

  .disqus {
    margin-right: 20px;
    margin-top: 40px;
  }

 

레퍼런스 정리 사이트

제가 공부한 내용들이 정리된 메인 사이트 입니다.
목록들이 한눈에 들어올 수 있게 정리하였고 목록에 마우스 오버 효과를 주어 소스보기와 바로가기 버튼을 만들었습니다.

사이트 직접 보기

  • 이미지
  • HTML
  • CSS
  • 자바스크립트
<main>
  <div class="link">
      <ul>
          <li><a href="https://fkdldhs8484.tistory.com/" target="_blank">t</a></li>
          <li><a href="https://github.com/fkdldhs8484/coding2" target="_blank">g</a></li>
          <li><a href="https://github1s.com/fkdldhs8484/coding2" target="_blank">v</a></li>
      </ul>
  </div>
  <div class="dog">
      <div class="wrap">
          <div class="body">
              <div class="leg l">
                  <div class="paw"></div>
              </div>
              <div class="leg r">
                  <div class="paw"></div>
              </div>
              <div class="spots"></div>
              <div class="head">
                  <div class="snout">
                      <div class="nose"></div>
                  </div>
                  <div class="eyes"></div>
                  <div class="ear"></div>
                  <div class="ear right"></div>
                  <div class="inner">
                      <div class="spot"></div>
                  </div>
                  <div class="eyes"></div>
                  <div class="ear"></div>
                  <div class="ear right"></div>
                  <div class="inner">
                      <div class="spot"></div>
                  </div>
              </div>
          </div>
      </div>
      <svg xmlns="http://www.w3.org/2000/svg" version="1.1" style="display:none">
          <defs>
              <filter id="squiggly-0">
                  <feTurbulence id="turbulence" baseFrequency="0.02" numOctaves="3" result="noise" seed="0" />
                  <feDisplacementMap id="displacement" in="SourceGraphic" in2="noise" scale="2" />
              </filter>
              <filter id="squiggly-1">
                  <feTurbulence id="turbulence" baseFrequency="0.02" numOctaves="3" result="noise" seed="1" />
                  <feDisplacementMap in="SourceGraphic" in2="noise" scale="3" />
              </filter>
              <filter id="squiggly-2">
                  <feTurbulence id="turbulence" baseFrequency="0.02" numOctaves="3" result="noise" seed="2" />
                  <feDisplacementMap in="SourceGraphic" in2="noise" scale="2" />
              </filter>
              <filter id="squiggly-3">
                  <feTurbulence id="turbulence" baseFrequency="0.02" numOctaves="3" result="noise" seed="3" />
                  <feDisplacementMap in="SourceGraphic" in2="noise" scale="3" />
              </filter>
              <filter id="squiggly-4">
                  <feTurbulence id="turbulence" baseFrequency="0.02" numOctaves="3" result="noise" seed="4" />
                  <feDisplacementMap in="SourceGraphic" in2="noise" scale="1" />
              </filter>
          </defs>
      </svg>
  </div>
  <!-- //dog -->
  <h1>javascript</h1>
  <nav>
      <ul>
          <li><a href="javascript01.html">데이터 저장하기</a></li>
          <li><a href="javascript02.html">데이터 불러오기</a></li>
          <li><a href="javascript03.html">데이터 실행하기</a></li>
          <li><a href="javascript04.html">데이터 제어하기</a></li>
      </ul>
      <ul>
          <li><a href="javascript05.html">문자열 객체</a></li>
          <li><a href="javascript06.html">배열 객체</a></li>
          <li><a href="javascript07.html">수학 객체</a></li>
          <li><a href="javascript08.html">숫자 객체</a></li>
          <li><a href="javascript09.html">브라우저 객체</a></li>
          <li><a href="javascript10.html">요소 객체</a></li>
          <li><a href="javascript11.html">이벤트 객체</a></li>
      </ul>
  </nav>
</main>
 * {
    margin: 0;
    padding: 0;
}

main {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    height: 100vh;
    font-family: "GmarketSans";
    text-align: center;
    padding: 2vw;
    border: 8px solid #936da1;
    box-sizing: border-box;
    border-radius: 20px;
    position: relative;
}

main::before {
    content: "";
    border: 8px solid #936da1;
    position: absolute;
    top: 0;
    left: 0;
    width: calc(100% - 16px);
    height: calc(100vh - 32px);
    border-radius: 12px;
    z-index: -1;
}

h1 {
    font-size: 8vw;
    color: #936da1;
    margin-bottom: 4vw;
    text-transform: capitalize;
    /* text-transform: capitalize; 영어 앞글자 대문자로 */
}

nav ul li {
    display: inline;
    list-style: none;
}

nav ul li a {
    text-decoration: none;
    border: 1px dashed #936da1;
    color: #936da1;
    padding: 10px 24px;
    display: inline-block;
    margin: 6px 3px;
    border-radius: 50px;
    font-size: 18px;
    transition: all 0.3s;
}

nav ul li a:hover {
    background-color: #936da1;
    color: aliceblue;
}     
@media (max-height:700px) {
  main::before {
      display: none;
  }
}

@media (max-width: 800px) {
  main {
      min-height: 700px;
  }

  h1 {
      font-size: 40px;
  }

  nav ul:nth-child(2) {
      display: none;
  }
}

.link {
  position: absolute;
  right: 30px;
  top: 30px;
  z-index: 10000;
}
.link li {
  list-style: none;
  display: inline;
}
.link li a {
  font-family: "GmarketSans";
  width: 30px;
  height: 30px;
  border-radius: 50%;
  text-align: center;
  line-height: 30px;
  border: 1px solid #936da1;
  display: inline-block;
  text-decoration: none;
  text-transform: uppercase;
  font-size: 14px;
  padding-top: 1px;
  transition: all 0.3s;
  background: #936da1;
  color: #fff;
}
.link li a:hover {
  background: #fff;
  color: #936da1;
}   
<script>
  var $eyes = $('.eyes'),
      $snout = $('.snout'),
      $spot = $('.spot'),
      $nose = $('.nose'),
      $ear = $('.ear'),
      $rightear = $('.right'),
      $leftleg = $('.l'),
      $rightleg = $('.r'),
      $leftpaw = $('.l .paw'),
      $rightpaw = $('.r .paw'),
      $container = $('.wrap'),
      $outer = $('body'),
      container_w = $container.width(),
      container_h = $container.height();

  $('body').on('mousemove.parallax', function (event) {
      var pos_x = event.pageX,
          pos_y = event.pageY,
          left = 0,
          bottom = 0,
          top = 0;

      left = container_w / 0.5 - pos_x;
      top = container_h / 2 - pos_y;
      bottom = container_h / 0.25 - (pos_y * 2.5);


      TweenMax.to(
          $snout,
          1,
          {
              css: {
                  transform: 'translateX(' + left / -32 + 'px) translateY(' + top / -26 + 'px) translateZ(1px)'
              },
              ease: Expo.easeOut,
              overwrite: 'all'
          });

      TweenMax.to(
          $spot,
          1,
          {
              css: {
                  transform: 'translateX(' + left / -32 + 'px) translateY(' + top / -56 + 'px) translateZ(1px)'
              },
              ease: Expo.easeOut,
              overwrite: 'all'
          });

      TweenMax.to(
          $eyes,
          1,
          {
              css: {
                  transform: 'translateX(' + left / -40 + 'px) translateY(' + top / -40 + 'px) translateZ(0px)'
              },
              ease: Expo.easeOut,
              overwrite: 'all'
          });

      TweenMax.to(
          $nose,
          1,
          {
              css: {
                  transform: 'translateX(' + left / -40 + 'px) translateY(' + top / -50 + 'px) translateZ(0px)'
              },
              ease: Expo.easeOut,
              overwrite: 'all'
          });

      TweenMax.to(
          $ear,
          1,
          {
              css: {
                  transform: 'rotate(' + bottom / -60 + 'deg) translatex(' + left / 60 + 'px) translateY(' + top / 40 + 'px) translateZ(-2px)'
              },
              ease: Expo.easeOut,
              overwrite: 'all'
          });

      TweenMax.to(
          $rightear,
          1,
          {
              css: {
                  transform: 'rotate(' + bottom / 60 + 'deg) translatex(' + left / 60 + 'px) translateY(' + top / 40 + 'px) translateZ(-2px)'
              },
              ease: Expo.easeOut,
              overwrite: 'all'
          });

      TweenMax.to(
          $leftleg,
          1,
          {
              css: {
                  transform: 'rotate(' + left / 30 + 'deg) translateY(' + top / -100 + 'px) translateZ(-2px)',
              },
              ease: Expo.easeOut,
              overwrite: 'all'
          });

      TweenMax.to(
          $rightleg,
          1,
          {
              css: {
                  transform: 'rotate(' + left / 30 + 'deg) translateY(' + top / -100 + 'px) translateZ(-2px)',
              },
              ease: Expo.easeOut,
              overwrite: 'all'
          });
      TweenMax.to(
          $leftpaw,
          1,
          {
              css: {
                  transform: 'rotate(' + left / -30 + 'deg) translateY(' + bottom / -120 + 'px) translatex(' + left / -50 + 'px) translateZ(2px)',
              },
              ease: Expo.easeOut,
              overwrite: 'all'
          });
      TweenMax.to(
          $rightpaw,
          1,
          {
              css: {
                  transform: 'rotate(' + left / -30 + 'deg) translateY(' + bottom / -120 + 'px) translatex(' + left / -50 + 'px) translateZ(2px)',
              },
              ease: Expo.easeOut,
              overwrite: 'all'
          });


  });
</script>

자바스크립트 정리 사이트

제가 공부했던 자바스크립트의 내용이 정리된 사이트 입니다. 기본
개념부터 메서드가 정리되어 있으며, 문제와 결과보기가 있습니다.
결과보기 버튼을 클릭시 정답이 나오게 작업하였습니다.

사이트 직접 보기

  • 이미지
  • 코드보기
  • 자바스크립트
  • HTML/CSS
<section id="cardType" class="card__wrap NexonLv1Gothic section">
  <span class="blind">카드 유형 01</span>
  <h2>말티즈 강의</h2>
  <p>우리집 말티즈의 귀여움을 알아보자.</p>
  <div class="card__inner container">
      <article class="card">
          <!-- alt 웹 표준성  화살표 모양은 백터 방식이나 이미지파일로 넣을수 있다.
          css 벡터/비트맵 방식 정리 하기.비트맵 방식-> png투명도 처리,jpg 화려한 효과, jif 애니메이션 효과 가능 256색깔만 지원해서 단순한 것만 사용가능
          이미지 표현 3가지 img->의미,로고->의미x backgvad, 이미지
          -->
          <figure class="card__header">
              <img src="img/card_bg01_01.jpg" alt="웹표준 사이트 만들기">
          </figure>
          <div class="card__body">
              <h3 class="tit">말티즈가 한심하게 처다볼때</h3>
              <p class="decs">말티즈는 가끔 아니 자주 주인을 한심하게 처다볼때가 많습니다.성격이 치와와급으로 더럽습니다.자기 마음에 안들면 짖습니다. 간식주면 다
                  따라갑니다.
              </p>
              <a class="btn" href="/">
                  더 자세히 보기
                  <span aria-hidden="true">
                      <svg width="65" height="8" viewBox="0 0 65 8" fill="none"
                          xmlns="http://www.w3.org/2000/svg">
                          <path
                              d="M64.3536 4.35355C64.5488 4.15829 64.5488 3.84171 64.3536 3.64645L61.1716 0.464466C60.9763 0.269203 60.6597 0.269203 60.4645 0.464466C60.2692 0.659728 60.2692 0.97631 60.4645 1.17157L63.2929 4L60.4645 6.82843C60.2692 7.02369 60.2692 7.34027 60.4645 7.53553C60.6597 7.7308 60.9763 7.7308 61.1716 7.53553L64.3536 4.35355ZM0 4.5H64V3.5H0L0 4.5Z"
                              fill="black" />
                      </svg>
                  </span>
              </a>
          </div>
      </article>
      <article class="card ">
          <figure class="card__header">
              <img src="img/card_bg01_02.jpg" alt="웹표준 사이트 만들기">
          </figure>
          <div class="card__body ">
              <h3 class="tit">말티즈가 산책할때</h3>
              <p class="decs">말티즈는 산책을 아주 좋아합니다. 간식을 들고 가도 산책을 더 좋아해서 간식을 처다도 안봅니다.주인이 멈춰도 알아서 자기가 갈길을 갑니다.
              </p>
              <a class="btn" href="/">
                  더 자세히 보기
                  <span aria-hidden="true">
                      <svg width="65" height="8" viewBox="0 0 65 8" fill="none"
                          xmlns="http://www.w3.org/2000/svg">
                          <path
                              d="M64.3536 4.35355C64.5488 4.15829 64.5488 3.84171 64.3536 3.64645L61.1716 0.464466C60.9763 0.269203 60.6597 0.269203 60.4645 0.464466C60.2692 0.659728 60.2692 0.97631 60.4645 1.17157L63.2929 4L60.4645 6.82843C60.2692 7.02369 60.2692 7.34027 60.4645 7.53553C60.6597 7.7308 60.9763 7.7308 61.1716 7.53553L64.3536 4.35355ZM0 4.5H64V3.5H0L0 4.5Z"
                              fill="black" />
                      </svg>
                  </span>
              </a>
          </div>
      </article>
      <article class="card">
          <figure class="card__header">
              <img src="img/card_bg01_03.jpg" alt="웹표준 사이트 만들기">
          </figure>
          <div class="card__body">
              <h3 class="tit">말티즈가 간식 달라고 할때</h3>
              <p class="decs">말티즈는 간식을 원할 때 주인을 뚫어져라 처다보거나 간식이 있는 곳으로 가 짖습니다.한개만 주면 더 달라고 쪼릅니다. 안주면 주인 다리를
                  발톱으로 박박
                  긁습니다.</p>
              <a class="btn" href="/">
                  더 자세히 보기
                  <span aria-hidden="true">
                      <svg width="65" height="8" viewBox="0 0 65 8" fill="none"
                          xmlns="http://www.w3.org/2000/svg">
                          <path
                              d="M64.3536 4.35355C64.5488 4.15829 64.5488 3.84171 64.3536 3.64645L61.1716 0.464466C60.9763 0.269203 60.6597 0.269203 60.4645 0.464466C60.2692 0.659728 60.2692 0.97631 60.4645 1.17157L63.2929 4L60.4645 6.82843C60.2692 7.02369 60.2692 7.34027 60.4645 7.53553C60.6597 7.7308 60.9763 7.7308 61.1716 7.53553L64.3536 4.35355ZM0 4.5H64V3.5H0L0 4.5Z"
                              fill="black" />
                      </svg>
                  </span>
              </a>
          </div>
      </article>
  </div>
</section>
<!--cardType-->
// 슬라이드효과
var swiper = new Swiper(".mySwiper", {
  navigation: {
      nextEl: ".swiper-button-next",
      prevEl: ".swiper-button-prev",
  },
  autoplay: {
      delay: 5000,
      disableOnInteraction: false,
  },
  pagination: {
      el: ".swiper-pagination",
      type: 'bullets',
      clickable: true,
  },
});

const btnStop = document.querySelector(".swiper-button-stop");  // 스와이퍼 버튼
const btnStart = document.querySelector(".swiper-button-play");

const btnMenu = document.querySelector(".header__menu");        // 메뉴
const btnMenuList = btnMenu.querySelectorAll("ul li a");        // 메뉴리스트

btnStart.style.display = "none";

btnStop.addEventListener("click", () => {
    swiper.autoplay.stop();
    btnStart.style.display = "block";
    btnStop.style.display = "none";
});
btnStart.addEventListener("click", () => {
    swiper.autoplay.start();
    btnStart.style.display = "none";
    btnStop.style.display = "block";
});

btnMenuList.forEach((list) => {
    list.addEventListener("click", () => {
        document.body.classList.remove("fixed");
        btnMenu.classList.remove("active");
        btnHam.classList.remove("active");
    });
});

window.addEventListener("resize", () => {
    let width = window.innerWidth;
    if (width > 1300) {
        document.body.classList.remove("fixed");
        btnMenu.classList.remove("active");
        btnHam.classList.remove("active");
    }
});

//스크롤 이동
document.querySelectorAll("a").forEach(li => {
    li.addEventListener("click", (e) => {
        e.preventDefault();
        document.querySelector(li.getAttribute("href")).scrollIntoView({
            behavior: "smooth"
        });
    });
});
/* 이미지 대체(ir) 효과 */
  .ir {
    display: block;
    overflow: hidden;
    font-size: 0;
    line-height: 0;
    text-indent: -9999px;
  }

웹 표준 사이트

처음으로 만들어본 웹 표준 사이트입니다.
처음엔 많이 어려웠지만, 하나씩 하나씩 배워가면서 열심히 만들었습니다.
웹 표준이라는 개념을 익히게 되면서 접근성을 어떻게 지켜야 하는 지 배웠습니다.
웹 접근성을 지키기 위해 ir효과를 적용하고 alt 속성도 잘 지켜줬습니다.

사이트 직접 보기

  • 이미지
  • 코드보기
  • 자바스크립트
  • HTML/CSS

 
const btnHam = document.querySelector(".header__ham");

btnHam.addEventListener("click", () => {
    btnHam.classList.toggle("active");
    btnMenu.classList.toggle("active");
    document.body.classList.toggle("fixed");
});
/* media */
@media (max-width: 1300px) {
  .header__menu {
    position: fixed;
    right: -100%;
    top: 69px;
    background: #fff;
    width: 60%;
    height: 100vh;
    padding: 20px;
    text-align: right;
    transition: right 0.4s ease-in;
  }
  .header__menu ul li {
    display: block;
    margin: 20px;
  }
  .header__menu ul li a {
    padding: 10px;
    white-space: nowrap;
  }
  .header__menu.active {
    right: 0;
  }
  .header__member {
    margin-right: 50px;
  }
  .header__ham {
    display: block;
  }
  .header__logo {
    width: 50%;
  }
  .header__member {
    width: 50%;
  }
}
 

웹표준 사이트 반응형

웹 표준을 준수한 기본 형태의 반응형 사이트 입니다.
미디어 쿼리를 이용하여 작은 모바일 화면에서도 깨짐없이 모바일화면에 맞는 반응형으로 만들었습니다.
화면이 줄어들면 헤더에있는 메뉴들이 깨지기 때문에 없애는 대신 햄버거를 이용하여 탭 메뉴를 만들었습니다.

사이트 직접 보기

  • 이미지
  • 코드보기
  • 자바스크립트
  • HTML/CSS
<template>
  <div>
    <HeaderCont />
    <section className="cont__main">
      <div className="container">
        <div className="main__inner">
          <div v-for="title in titles" v-bind:key="title.text">
            {{ title.text }}
          </div>
        </div>
      </div>
    </section>
    <FooterCont />
  </div>
</template>
<style lang="scss" scoped>
.main__inner {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  flex-direction: column;
  height: 100vh;
  color: var(--black);
  > div {
    font-size: 9.4vw;
    line-height: 0.9;
    text-transform: uppercase;
  }
}
</style>
import HeaderCont from "@/components/HeaderCont.vue";
import FooterCont from "@/components/FooterCont.vue";
export default {
  components: {
    HeaderCont,
    FooterCont,
  },
  data: function () {
    return {
      titles: [
        { text: "we provide" },
        { text: "visual coding" },
        { text: "solutions" },
        { text: "for you API" },
      ],
    };
  },
};

Vue 사이트

Node.js를 통해 vue 프레임워크를 사용하여 제작한 웹 사이트 입니다.
리액트 사이트의 디자인은 같으며, 바탕 색상과 글자색을 다르게 하여 만들었습니다.
Youtube, Movie, Unsplash 페이지가 있으며 각 페이지에 api를 이용하여 정보를 넣었습니다.

사이트 직접 보기

  • 이미지
  • 코드보기
  • CSS
  • APP.js
import React from "react";

const mainInfo = [
  { text: "we provide" },
  { text: "visual coding" },
  { text: "solutions" },
  { text: "for you API" },
];

const MainText = ({ text }) => {
  return <div>{text}</div>;
};

const MainCont = () => {
  return (
    <section className="cont__main">
      <div className="container">
        <div className="main__inner">
          {mainInfo.map((text, idx) => (
            <MainText key={idx} text={text.text} />
          ))}
        </div>
      </div>
    </section>
  );
};

export default MainCont;
.main__inner {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  flex-direction: column;
  height: 100vh;
  color: var(--white);

  > div {
    font-size: 9.4vw;
    line-height: 0.9;
    text-transform: uppercase;
  }
}
import React from "react";
import { BrowserRouter, Route, Routes } from "react-router-dom";
import Main from "./components/pages/Main";
import Youtube from "./components/pages/Youtube";
import Movie from "./components/pages/Movie";
import Unsplash from "./components/pages/Unsplash";
import About from "./components/pages/About";
import Reference from "./components/pages/Reference";

const App = () => {
  return (
    <BrowserRouter>
      <Routes>
        <Route path="/" element={<Main />} />
        <Route path="/about" element={<About />} />
        <Route path="/reference" element={<Reference />} />
        <Route path="/youtube" element={<Youtube />} />
        <Route path="/movie" element={<Movie />} />
        <Route path="/unsplash" element={<Unsplash />} />
      </Routes>
    </BrowserRouter>
  );
};

export default App;

React 사이트

react 라이브러리를 이용하여 작업한 사이트 입니다.
컴퍼넌트를 생성하여 싱글페이지를 출력시 켰고 레퍼런스 탭메뉴를 구현하였습니다.
Youtube, Movie, Unsplash 페이지가 있으며 각 페이지에 api를 이용하여 정보를 넣었습니다.

사이트 직접 보기

  • 이미지
  • 코드보기
  • 자바스크립트
  • HTML/CSS
import React, { useEffect, useState } from 'react'

  import { fetchAPI } from '../utils/fetchAPI'
  import { Category, Videos, Loader } from './'
  
  const MainConts = () => {
    const [selectCategory, setSelectCategory] = useState('dog')
    const [videos, setVideos] = useState(null)
  
    // &type=videos --> 만약 사진이 안나오는게 있다면  옆에 붙이기
    useEffect(() => {
      fetchAPI(`search?part=snippet&q=${selectCategory}&type=video`).then(
        (data) => setVideos(data.items)
      )
    }, [selectCategory])
  
    return (
      <main id="main">
        <aside id="aside">
          <Category
            selectCategory={selectCategory}
            setSelectCategory={setSelectCategory}
          />
        </aside>
        <section id="contents">
          <h2>
            <em>{selectCategory}</em> 유튜버
          </h2>
          <Videos videos={videos} />
        </section>
      </main>
    )
  }
  
  export default MainConts



 

recipe 유튜브 페이지

api를 이용하여 유튜브 페이지를 만들었습니다.
메뉴에 있는건 유튜버들이고 클릭하면 제목의 이름과 그 유튜버의 영상들이 나오게 구현하였습니다. 검색창도 구현했습니다.

사이트 직접 보기

script

  • 미리보기
  • HTML
  • CSS
  • 자바스크립트
<body class="img01">
 <header id="header">
      <h1>Javascript Slider Effect01</h1>
      <p>슬라이드 이펙트 - 트랜지션 효과 </p>
      <ul>
          <li class="active"><a href="sliderEffect01.html">1</a></li>
          <li><a href="sliderEffect02.html">2</a></li>
          <li><a href="sliderEffect03.html">3</a></li>
          <li><a href="sliderEffect04.html">4</a></li>
          <li><a href="sliderEffect05.html">5</a></li>
          <li><a href="sliderEffect06.html">6</a></li>
          <li><a href="sliderEffect07.html">7</a></li>
      </ul>
  </header>
  
  <main id="main">
      <section id="sliderType01">
          <div class="slider__wrap">
              <div class="slider__img">
                  <div class="slider"> <img src="../assets/img/effect_bg11-min.jpg" alt="이미지"> </div>
                  <div class="slider"> <img src="../assets/img/effect_bg12-min.jpg" alt="이미지"> </div>
                  <div class="slider"> <img src="../assets/img/effect_bg13-min.jpg" alt="이미지"> </div>
                  <div class="slider"> <img src="../assets/img/effect_bg14-min.jpg" alt="이미지"> </div>
                  <div class="slider"> <img src="../assets/img/effect_bg15-min.jpg" alt="이미지"> </div>
              </div>
          </div>
      </section>
  </main>
</body>
<script>
  const sliderWrap = document.querySelector(".slider__wrap");
  const sliderImg = sliderWrap.querySelector(".slider__img");
  const slider = sliderWrap.querySelectorAll(".slider");

  let currentIndex = 0;                           //현재 보이는 이미지
  let sliderCount = slider.length;                //이미지 갯수

  setInterval(() => {
      let nextIndex = (currentIndex + 1) % sliderCount;     //다음 이미지
      // 1, 2, 3, 4, 5, 6, 7, 8, 9, ....
      // 1 % 5 = 1, 2, 3, 4, 0, 1, 2, 3, 4, 0 ....

      slider[currentIndex].style.opacity = "0";   //첫번째 이미지를 안보이게
      slider[nextIndex].style.opacity = "1";      //두번째 이미지를 보이게

      currentIndex = nextIndex;
      //0 1 2 3 4 0 1 2 3 4...
  }, 3000);

  //     slider[1].style.opacity = "0";  //두번째 이미지를 안보이게
  //     slider[2].style.opacity = "1";  //세번째 이미지를 보이게

  //     slider[2].style.opacity = "0";  //세번째 이미지를 안보이게
  //     slider[3].style.opacity = "1";  //네번째 이미지를 보이게

  //     slider[4].style.opacity = "0";  //네번째 이미지를 안보이게
  //     slider[5].style.opacity = "1";  //다섯번째 이미지를 보이게

  //     slider[4].style.opacity = "0";  //다섯번째 이미지를 안보이게
  //     slider[0].style.opacity = "1";  //첫번째 이미지를 보이게
</script>
<style>
  /* slider */
  /* slider */
  .slider__wrap {
      width: 100%;
      height: 100vh;
      display: flex;
      align-items: center;
      justify-content: center;
  }

  .slider__img {
      position: relative;
      width: 800px;
      height: 450px;
  }

  .slider {
      position: absolute;
      left: 0;
      top: 0;
  }

  .slider::before {
      position: absolute;
      left: 5px;
      top: 5px;
      background: rgba(0, 0, 0, 0.4);
      color: #fff;
      padding: 5px 10px;
  }

  .slider:nth-child(1)::before {
      content: '이미지1';
  }

  .slider:nth-child(2)::before {
      content: '이미지2';
  }

  .slider:nth-child(3)::before {
      content: '이미지3';
  }

  .slider:nth-child(4)::before {
      content: '이미지4';
  }

  .slider:nth-child(5)::before {
      content: '이미지5';
  }

  .slider:nth-child(1) {
      z-index: 5;
  }

  .slider:nth-child(2) {
      z-index: 4;
  }

  .slider:nth-child(3) {
      z-index: 3;
  }

  .slider:nth-child(4) {
      z-index: 2;
  }

  .slider:nth-child(5) {
      z-index: 1;
  }

  @media (max-width: 800px) {
      .slider__img {
          width: 400px;
          height: 225px;
      }
  }
</style>

슬라이드 이펙트 페이지 입니다.

슬라이드 이펙트 효과는 총 7개로 트렌지션효과, 좌, 좌(연속적), 버튼, 닷메뉴, 무한, 플레이 버튼, 정지버튼, 자동플레이 로 나누었습니다.
자바스크립트를 이용하여 이미지슬라이드 효과를 연출하였습니다.

사이트 직접 보기

  • 미리보기
  • HTML
  • CSS
  • 자바스크립트
<body>
<header id="header">
    <h1><a href="../javascript01.html">Quiz</a> <em>정답 확인하기 유형</em></h1>
    <nav>
        <ul>
            <li class="active"><a href="quizEffect01.html">1</a></li>
            <li><a href="quizEffect02.html">2</a></li>
            <li><a href="quizEffect03.html">3</a></li>
            <li><a href="quizEffect04.html">4</a></li>
            <li><a href="quizEffect05.html">5</a></li>
            <li><a href="quizEffect06.html">6</a></li>
        </ul>
    </nav>
</header>

<main id="main">
    <div class="quiz__wrap">
        <div class="quiz">
            <span class="quiz__type"></span>
            <h2 class="quiz__question">
                <span class="number"></span>
                <div class="ask">
            </h2>
            <div class="quiz__view">
                <div class="dog">
                    <div class="head">
                        <div class="ears"></div>
                        <div class="face"></div>
                        <div class="eyes">
                            <div class="teardrop"></div>
                        </div>
                        <div class="nose"></div>
                        <div class="mouth">
                            <div class="tongue"></div>
                        </div>
                        <div class="chin"></div>
                    </div>
                    <div class="body">
                        <div class="tail"></div>
                        <div class="legs"></div>
                    </div>
                </div>
            </div>
            <div class="quiz__answer">
                <button class="confirm">정답확인하기</button>
                <div class="Result"></div>
            </div>
        </div>
    </div>
</main>
</body>
body {
  background-color: #f6f6f6;
  background-image:
      linear-gradient(90deg, #cdcccc 0px, #cdcccc 1px, transparent 1px, transparent 99px, transparent 100px),
      linear-gradient(#cdcccc 0px, #cdcccc 1px, transparent 1px, transparent 99px, transparent 100px),
      linear-gradient(#e0e0e0 0px, #e0e0e0 1px, transparent 1px, transparent 99px, transparent 100px),
      linear-gradient(90deg, #e0e0e0 0px, #e0e0e0 1px, transparent 1px, transparent 99px, transparent 100px),
      linear-gradient(transparent 0px, transparent 5px, #f6f6f6 5px, #f6f6f6 95px, transparent 95px, transparent 100px),
      linear-gradient(90deg, #e0e0e0 0px, #e0e0e0 1px, transparent 1px, transparent 99px, #e0e0e0 99px, #e0e0e0 100px),
      linear-gradient(90deg, transparent 0px, transparent 5px, #f6f6f6 5px, #f6f6f6 95px, transparent 95px, transparent 100px),
      linear-gradient(transparent 0px, transparent 1px, #f6f6f6 1px, #f6f6f6 99px, transparent 99px, transparent 100px),
      linear-gradient(#cdcccc, #cdcccc);
  background-size: 100px 100%, 100% 100px, 100% 10px, 10px 100%, 100% 100px, 100px 100%, 100px 100%, 100px 100px, 100px 100px;
}

#header {
  background: #262626;
  color: #fff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px;
  position: relative;
  z-index: 10;
}

#header::before {
  content: "";
  border: 4px ridge #a3a3a3;
  position: absolute;
  left: 5px;
  top: 5px;
  width: calc(100% - 10px);
  height: calc(100% - 10px);
  box-sizing: border-box;
  z-index: -1;
}

#header h1 {
  padding: 3px 3px 6px 10px;
  font-family: "DungGeunMo";
  font-size: 30px;
}

#header h1 a {
  color: #fff;
}

#header h1 em {
  font-size: 16px;
  font-style: normal;
}

@media (max-width:600px) {
  #header h1 em {
      display: none;
  }
}

#header nav {
  padding-right: 10px;
}

#header nav li {
  display: inline;
}

#header nav li a {
  color: #fff;
  padding: 0 10px;
  border: 1px dashed #fff;
  font-family: "DungGeunMo";
}

#header nav li.active a {
  color: #000;
  background: #fff;
}

#footer {
  background: #fff;
  text-align: center;
  padding: 20px;
  width: 100%;
  box-sizing: border-box;
  margin-top: 150px;
  position: fixed;
  left: 0;
  bottom: 0;
  z-index: 10000;
}

#footer a {
  color: #000;
  font-family: "DungGeunMo";
}

#footer a:hover {
  text-decoration: underline;
}

/* quiz__wrap  */
.quiz__wrap {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  margin-top: 50px;
  margin-bottom: 150px;
  flex-wrap: wrap;
}

.quiz {
  max-width: 500px;
  width: 100%;
  background-color: #fff;
  border: 8px ridge #cacaca;
  margin: 10px;
}

.quiz__type {
  background-color: #cacaca;
  text-align: center;
  display: block;
  font-size: 16px;
  border: 3px ridge #cacaca;
  color: #3b3b3b;
  font-family: "DungGeunMo";
  padding: 4px;
}

.quiz__question {
  border-top: 6px ridge #cacaca;
  border-bottom: 6px ridge #cacaca;
  padding: 20px;
  font-family: "Cafe24Dangdanghae";
  line-height: 1.3;
}

.quiz__question .number {
  color: rgb(160, 86, 86);
}

.quiz__question .ask {
  display: inline;
}

.quiz__answer {
  border-top: 6px ridge #cacaca;
  padding: 10px;
  background-color: #f5f5f5;
}

.quiz__answer .confirm {
  border: 6px ridge #cacaca;
  width: 100%;
  font-size: 22px;
  background-color: #d6d6d6;
  font-family: "Cafe24Dangdanghae";
  cursor: pointer;
  padding: 13px 20px;
}

.quiz__answer .result {
  width: 100%;
  padding: 13px 20px;
  font-size: 22px;
  line-height: 1.3;
  box-sizing: border-box;
  text-align: center;
  font-family: "Cafe24Dangdanghae";
  border: 6px ridge #cacaca;
}

.quiz__answer .input {
  width: 100%;
  border: 6px ridge #cacaca;
  font-size: 22px;
  padding: 13px 20px;
  background-color: #fff;
  font-family: "Cafe24Dangdanghae";
  margin-bottom: 10px;
}

.quiz__view {
  background-color: #f5f5f5;
  font-family: "Cafe24Dangdanghae";
  position: relative;
  overflow: hidden;
}

.quiz__view .true {
  width: 120px;
  height: 120px;
  line-height: 120px;
  background-color: rgb(160, 86, 86);
  color: #fff;
  border-radius: 50%;
  text-align: center;
  position: absolute;
  left: 70%;
  top: 100px;
  opacity: 0;
}

.quiz__view .false {
  width: 120px;
  height: 120px;
  line-height: 120px;
  background-color: #fff;
  border-radius: 50%;
  text-align: center;
  position: absolute;
  right: 70%;
  top: 100px;
  opacity: 0;
}

.quiz__view.like .true {
  opacity: 1;
  animation: wobble 0.6s;
}

.quiz__view.dislike .false {
  opacity: 1;
  animation: wobble 0.6s;
}

/* 애니메이션 */
.quiz__selects {
  margin: 5px 0;
}

.quiz__selects label {
  display: flex;
}

.quiz__selects label input {
  position: absolute;
  left: -9999px;
}

.quiz__selects label span {
  font-size: 20px;
  line-height: 1.3;
  font-family: "Cafe24Dangdanghae";
  padding: 10px;
  display: flex;
  align-items: center;
  width: 100%;
  border-radius: 5px;
  cursor: pointer;
}

.quiz__selects label span::before {
  content: '';
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background-color: #fff;
  margin-right: 15px;
  display: flex;
  flex-shrink: 0;
  box-shadow: inset 0px 0px 0px 4px #936da1;
  transition: all 0.25s;
}
/* box-shadow 원안 그림자 효과?,
transition 애니메이션 효과,
flex-shrink,
cursor: pointer; 커서를 손가락 모양으로.. */
.quiz__selects label input:checked+span {
  background-color: #e9d6ee;
}

.quiz__selects label input:checked+span::before {
  box-shadow: inset 0px 0px 0px 10px #936da1;
}
.quiz__confirm {
  width: 100%;
  text-align: center;
}
.quiz__confirm .check {
  font-size: 22px;
  line-height: 1.3;
  padding: 13px 60px;
  border: 6px ridge #cacaca;
  box-sizing: border-box;
  text-align: center;
  font-family: "Cafe24Dangdanghae";
  cursor: pointer;
  margin: 40px 0;
  transition: background 0.3s;
}
.quiz__confirm .check:hover {
  background-color: #936da1;
}
@keyframes wobble {
  0% {
      transform: translatex(0) rotate(0deg)
  }

  15% {
      transform: translatex(-25%) rotate(-5deg)
  }

  30% {
      transform: translatex(20%) rotate(3deg)
  }

  45% {
      transform: translatex(-15%) rotate(-3deg)
  }

  60% {
      transform: translatex(10%) rotate(2deg)
  }

  75% {
      transform: translatex(-5%) rotate(-1deg)
  }

  100% {
      transform: translatex(0) rotate(0deg)
  }
}
<script>
  //선택자
  const quizType = document.querySelector(".quiz__type");   //퀴즈종류
  const quizNum = document.querySelector(".quiz__question .number "); //퀴즈번호
  const quizask = document.querySelector(".quiz__question .ask"); //퀴즈 질문
  const quizconfirm = document.querySelector(".quiz__answer .confirm"); //정답확인버튼
  const quizResult = document.querySelector(".quiz__answer .Result"); //정답결과
  const quizDog = document.querySelector(".quiz__view .dog"); //강아지
  //문제 정보
  const answeType = "웹디자인기능사";
  const answerNum = 1;
  const answerask = " 인접하는 두 색의 경계 부분에 색상, 명도, 채도의대비가 더욱 강하게 일어나는 현상은?"
  const answerResult = "연변대비";

  //문제 출력
  quizType.innerText = answeType;
  quizNum.innerText = answerNum + ".";
  quizask.innerText = answerask;
  quizResult.innerText = answerResult;

  //정답 숨기기
  quizResult.style.display = "none";

  // 정답 확인 버튼
  // 정답 버튼을 클릭하면 확인버튼 안보이게... 숨겨진 정답은 보이게...
  // 정답을 확인하면 강아지가 웃고 있어야 함 // 클래스 like 추가함
  quizconfirm.addEventListener("click", function () {
      quizconfirm.style.display = "none";
      quizResult.style.display = "block";
      quizDog.classList.add("like");
  });
</script>

퀴즈 이펙트 페이지 입니다.

퀴즈 이펙트는 총 6개로 정답확인하기, 주관식 확인하기, 주관식(여러문제) 확인하기, 객관시 확인하기, 객관식(여러문제) 확인하기 : 점수, 슬라이드 방식으로 나누었습니다.
정답을 숨겨 정답확인하기버튼을 클랙하면 정답이 나오게 만들었고, 객관식에는 정답버튼을 체크시 설명과 정답이 나오게 작업하였습니다.

사이트 직접 보기

  • 미리보기
  • HTML
  • CSS
  • 자바스크립트
<body class="img01">
  <header id="header">
    <h1>Javascript Mouse Effect01</h1>
    <p>마우스 이펙트 - 마우스 따라다니기</p>
    <ul>
      <li class="active"><a href="mouseEffect01.html">1</a></li>
      <li><a href="mouseEffect02.html">2</a></li>
      <li><a href="mouseEffect03.html">3</a></li>
      <li><a href="mouseEffect04.html">4</a></li>
      <li><a href="mouseEffect05.html">5</a></li>
      <li><a href="mouseEffect06.html">6</a></li>
      <li><a href="mouseEffect07.html">7</a></li>
    </ul>
  </header>
  <!-- //header -->

  <main id="main">
    <section id="mouseType">
      <div class="mouse__cursor"></div>
      <div class="mouse__wrap">
        <p>
          The <span class="style1">future</span>
          <span class="style2">depends</span> on What we do in the<span
            class="style3"
          >
            present.</span
          >
        </p>
        <p>
          <span class="style4">미래</span>는 현재
          <span class="style5">우리가</span> 무엇을
          <span class="style6">하는가에</span> 달려있다.
        </p>
      </div>
    </section>

    <div class="mouse__info">
      <ul>
        <li>clientX : <span class="clientX">0</span>px</li>
        <li>clientY : <span class="clientY">0</span>px</li>
        <li>offsetX : <span class="offsetX">0</span>px</li>
        <li>offsetY : <span class="offsetY">0</span>px</li>
        <li>pageX : <span class="pageX">0</span>px</li>
        <li>pageY : <span class="pageY">0</span>px</li>
        <li>screenX : <span class="screenX">0</span>px</li>
        <li>screenY : <span class="screenY">0</span>px</li>
      </ul>
    </div>
  </main>
  <!-- //main -->
</body>                  
<style>
  /* mouseType */
  .mouse__wrap {
      width: 100%;
      height: 100vh;
      display: flex;
      align-items: center;
      justify-content: center;
      color: #fff;
      overflow: hidden;
      flex-direction: column;
      cursor: none;
  }

  .mouse__wrap p {
      font-size: 2vw;
      line-height: 2;
      font-weight: 300;
  }

  .mouse__wrap p:last-child {
      font-size: 3vw;
      font-weight: 300;
  }

  .mouse__wrap p span {
      border-bottom: 0.15vw dashed orange;
      color: orange;
  }

  @media (max-width: 800px) {
      .mouse__wrap p {
          padding: 0 20px;
          font-size: 24px;
          line-height: 1.5;
          text-align: center;
          margin-bottom: 10px;
      }

      .mouse__wrap p:last-child {
          font-size: 40px;
          line-height: 1.5;
          text-align: center;
          word-break: keep-all;
      }
  }

  /* 커서 */
  .mouse__cursor {
      position: absolute;
      left: 0;
      top: 0;
      width: 50px;
      height: 50px;
      border-radius: 50%;
      border: 3px solid #fff;
      background-color: rgba(255, 255, 255, 0.1);
      user-select: none;
      pointer-events: none;
      transition:
          background-color 0.3s,
          border-color 0.3s,
          transform 0.6,
          border-radius 0.3s;
  }

  .mouse__cursor.style1 {
      background-color: rgba(255, 165, 0, 0.4);
      border-color: orange;
  }

  .mouse__cursor.style2 {
      background-color: rgba(140, 0, 255, 0.4);
      border-color: rgb(140, 0, 255);
      transform: scale(2) rotateY(720deg);
  }

  .mouse__cursor.style3 {
      background-color: rgb(0, 47, 255, 0.4);
      border-color: rgb(0, 47, 255);
      transform: scale(1.5) rotateX(45deg);
  }

  .mouse__cursor.style4 {
      background-color: rgb(0., 47, 255, 0.4);
      border-color: rgb(0, 47, 255);
      transform: scale(10);
  }

  .mouse__cursor.style5 {
      background-color: rgb(255, 0, 85, 0.4);
      border-color: rgb(255, 0, 85);
      transform: scale(0.1);
  }

  .mouse__cursor.style6 {
      background-color: rgb(255, 81, 0, 0.4);
      border-color: rgb(255, 81, 0);
      border-radius: 0;
      transform: scale(5);
  }

  .mouse__info {
      position: absolute;
      left: 20px;
      bottom: 10px;
      font-size: 14px;
      line-height: 1.6;
      color: #fff;
  }
</style>
<script>
  window.addEventListener("mousemove", (event) => {   //event : mouse 움직이는 값
      document.querySelector(".clientX").innerText = event.clientX;
      document.querySelector(".clientY").innerText = event.clientY;
      document.querySelector(".offsetX").innerText = event.offsetX;
      document.querySelector(".offsetY").innerText = event.offsetY;
      document.querySelector(".pageX").innerText = event.pageX;
      document.querySelector(".pageY").innerText = event.pageY;
      document.querySelector(".screenX").innerText = event.screenX;
      document.querySelector(".screenY").innerText = event.screenY;
  });

  const cursor = document.querySelector(".mouse__cursor");
  window.addEventListener("mousemove", (e) => {
      cursor.style.left = e.clientX - 25 + "px";   //단위 꼭 붙여주기
      cursor.style.top = e.clientY - 25 + "px";
  });

  // document.querySelector(".style1").addEventListener("mouseover", () => {
  //     cursor.classList.add("style1");
  // });
  // document.querySelector(".style1").addEventListener("mouseout", () => {
  //     cursor.classList.remove("style1");
  // });
  // document.querySelector(".style2").addEventListener("mouseover", () => {
  //     cursor.classList.add("style2");
  // });
  // document.querySelector(".style2").addEventListener("mouseout", () => {
  //     cursor.classList.remove("style2");
  // });
  // document.querySelector(".style3").addEventListener("mouseover", () => {
  //     cursor.classList.add("style3");
  // });
  // document.querySelector(".style3").addEventListener("mouseout", () => {
  //     cursor.classList.remove("style3");
  // });
  // document.querySelector(".style4").addEventListener("mouseover", () => {
  //     cursor.classList.add("style4");
  // });
  // document.querySelector(".style4").addEventListener("mouseout", () => {
  //     cursor.classList.remove("style4");
  // });
  // document.querySelector(".style5").addEventListener("mouseover", () => {
  //     cursor.classList.add("style5");
  // });
  // document.querySelector(".style5").addEventListener("mouseout", () => {
  //     cursor.classList.remove("style5");
  // });
  // document.querySelector(".style6").addEventListener("mouseover", () => {
  //     cursor.classList.add("style6");
  // });
  // document.querySelector(".style6").addEventListener("mouseout", () => {
  //     cursor.classList.remove("style6");
  // });

  //for문
  // for (let i = 1; i < 7; i++) {
  //     document.querySelector(".style" + i).addEventListener("mouseover", () => {
  //         cursor.classList.add("style" + i);
  //     });
  // }
  // for (let i = 1; i < 7; i++) {
  //     document.querySelector(".style" + i).addEventListener("mouseout", () => {
  //         cursor.classList.remove("style" + i);
  //     })
  // }

  //forEach()
  // document.querySelectorAll(".mouse__wrap span").forEach((span, num) => {
  //     span.addEventListener("mouseover", () => {
  //         cursor.classList.add("style" + (num + 1));
  //     });
  //     span.addEventListener("mouseout", () => {
  //         cursor.classList.remove("style" + (num + 1));
  //     })
  // });

  //getAttribute()
  document.querySelectorAll(".mouse__wrap span").forEach(span => {
      let attr = span.getAttribute("class");

      span.addEventListener("mouseover", () => {
          cursor.classList.add(attr);
      });
      span.addEventListener("mouseout", () => {
          cursor.classList.remove(attr);
      })
  });
</script>

마우스 이펙트 페이지 입니다.

자바스크립트와 gsap.js 로 만든 여러가지 마우스 효과입니다.
마우스 효과는 총 6개로 마우스 따라다니기, (gsap), 조명효과, 이미지효과, 기울기 효과, 텍스트 효과 방식으로 나누었습니다.

사이트 직접 보기

study

YEAR RECODE PROJECT DESC LINK
2022 리액트 윹유툽 크론 코딩 프론트앤드 유튜브 API를 이용하여 사이트를 구현함 바로가기
2022 리액트 윹api 코딩 프론트앤드 유튜브 API를 이용하여 사이트를 구현함 바로가기
2022 뷰 api 코딩 프론트앤드 유튜브 API를 이용하여 사이트를 구현함 바로가기
2022 서치 이펙트 프론트앤드 검색 이펙트 바로가기
2022 패럴랙스 이펙트 프론트앤드 스크롤 부드러운 효과 바로가기
2022 게임 이펙트 프론트앤드 여러가지 게임 이펙트 바로가기
2022 HTML 정리 사이트 프론트앤드 HTML 총 정리 사이트 바로가기
2022 CSS 정리 사이트 프론트앤드 CSS 총 정리 사이트 바로가기
2022 my sql 프론트앤드 데이터 소프트 웨어 사이트 바로가기
2022 애니메이션 svg 프론트앤드 스케일러블 벡터 그래픽스 정리 사이트 바로가기
2022 애니메이션 css 프론트앤드 스케일러블 벡터 그래픽스 css 정리 사이트 바로가기