๋ถˆ์„ ์ผœ์ž ๐Ÿ”ฅ .

9144 ๋‹จ์–ด cssanimationwebdevemoji
์ด์ „ ๊ฒŒ์‹œ๋ฌผ์—์„œ ์›จ์ด๋ธŒ ๐Ÿ‘‹ ์ด๋ชจํ‹ฐ์ฝ˜๊ณผ ํ•จ๊ป˜ ์• ๋‹ˆ๋ฉ”์ด์…˜์„ ์‚ฌ์šฉํ•˜๋Š” ๊ฒƒ์ด ์–ผ๋งˆ๋‚˜ ๋†€๋ผ์šด์ง€ ๋ณด์•˜์Šต๋‹ˆ๋‹ค! ์ด๋ฒˆ ํฌ์ŠคํŠธ์—์„œ๋Š” ๋ถˆ๊ฝƒ ๐Ÿ”ฅ ์ด๋ชจํ‹ฐ์ฝ˜๋„ ๋™์ผํ•˜๊ฒŒ ๋‹ฌ์„ฑํ•˜๋„๋ก ๋…ธ๋ ฅํ•˜๊ฒ ์Šต๋‹ˆ๋‹ค!

์•„๋ž˜๋Š” CSS ์ฝ”๋“œ์ž…๋‹ˆ๋‹ค.

:root {
  --flame-size: 100;
}

@keyframes flame-animation {
  0%,
  100% {
    opacity: 0;
    transform: translate3d(0, 0, 0) scale(0.75) rotate(0) scale(1);
  }
  25% {
    opacity: 0.35;
    transform: translate3d(0, -10%, 0) scale(1) rotate(-3deg) scale(1.05);
  }
  50% {
    opacity: 0.35;
    transform: translate3d(0, -4%, 0) scale(1) rotate(3deg) scale(1.1);
  }
  75% {
    opacity: 0.35;
    transform: translate3d(0, -20%, 0) scale(1) rotate(-3deg) scale(1.05);
  }
  99% {
    opacity: 0;
    transform: translate3d(0, -50%, 0) scale(0.8) rotate(0) scale(1);
  }
}

.fire {
  position: relative;
  display: inline-block;
}

.flame {
  position: absolute;
  transform-origin: 70% 70%;
  z-index: 2;
  display: inline-block;
  top: calc(var(--flame-size) * -1px);
}

.flame.animate {
  animation-duration: 2.5s;
  animation-iteration-count: infinite;
  animation-name: flame-animation;
  opacity: 0;
  z-index: 1;
  transform: translate3d(0, 15px, 0) scale(0.75) rotate(0);
  z-index: 1;
  animation-timing-function: ease-in;
}

.flame.animate:nth-child(2) {
  animation-delay: 0.5s;
}
.flame.animate:nth-child(3) {
  animation-delay: 1s;
}


HTML์€ ๋‹ค์Œ๊ณผ ๊ฐ™์Šต๋‹ˆ๋‹ค.

<div class="container">
  <p>
    Light up
    <span class="fire">
      <span class="flame base">๐Ÿ”ฅ</span>
      <span class="flame animate">๐Ÿ”ฅ</span>
      <span class="flame animate">๐Ÿ”ฅ</span>
      <span class="flame animate">๐Ÿ”ฅ</span>
    </span>
  </p>
</div>


์•„๋ž˜ codepen์—์„œ ์œ„ ์ฝ”๋“œ์˜ ์ถœ๋ ฅ์„ ๋ณผ ์ˆ˜๋„ ์žˆ์Šต๋‹ˆ๋‹ค.



์œ„์˜ ์ด๋ฏธ์ง€๊ฐ€ ์‹ค์ œ ๋ถˆ๊ฝƒ์ฒ˜๋Ÿผ ๋ณด์ด์ง€ ์•Š๋Š”๋‹ค๋Š” ๊ฒƒ์„ ์•Œ๊ณ  ์žˆ์ง€๋งŒ ์ ์–ด๋„ ์‹œ์ž‘ํ•˜๋Š” ๊ฒƒ์ด ์ข‹๋‹ค๊ณ  ์ƒ๊ฐํ•ฉ๋‹ˆ๋‹ค!

์˜๊ฒฌ ์„น์…˜์—์„œ ๊ท€ํ•˜์˜ ์ƒ๊ฐ๊ณผ ํ”ผ๋“œ๋ฐฑ์„ ์•Œ๋ ค์ฃผ์‹ญ์‹œ์˜ค.

์ฆ๊ฑฐ์šด ์ฝ”๋”ฉ!!!

๐ŸŒฒ ๐ŸŒž ๐Ÿ˜Š

์ข‹์€ ์›นํŽ˜์ด์ง€ ์ฆ๊ฒจ์ฐพ๊ธฐ