css

[css] ํ…์ŠคํŠธ์— ๊ทธ๋ผ๋ฐ์ด์…˜ ๋„ฃ๊ธฐ

natrue 2021. 1. 13. 17:02
728x90

 

 

1.  ๊ทธ๋ผ๋ฐ์ด์…˜ ์ผ์ž๋กœ ๋„ฃ๊ธฐ

background: linear-gradient ( ๋ฐฉํ–ฅ, ์ƒ‰์ƒ1, ์ƒ‰์ƒ2 ... )

<style>
    .gradtext {
        background: #55ffaa;
        background: -webkit-linear-gradient(left, #55ff55, #55ffff);
        background:    -moz-linear-gradient(right, #55ff55, #55ffff);
        background:      -o-linear-gradient(right, #55ff55, #55ffff);
        background:         linear-gradient(to right, #55ff55, #55ffff);
        -webkit-background-clip: text;
                background-clip: text;
        color: transparent;
        font-size: 48px;
        font-weight: bold;
    }
</style>

 

 

 

 

 


 

 

2.  ๊ทธ๋ผ๋ฐ์ด์…˜ ๊ธฐ์šธ๊ธฐ์žˆ๊ฒŒ ๋„ฃ๊ธฐ

 

<style>
  .gradtext {
      background: linear-gradient(to right bottom,#002fff,#09ff00,#ffe100,#ff0000);
      -webkit-background-clip: text;
      background-clip: text;
      color: transparent;
      font-weight: bold;
  }
</style>

 

 

 

 

 

์ƒ‰์ƒ : www.w3schools.com/colors/colors_picker.asp

 

HTML Color Picker

Selected Color: Black Text Shadow White Text Shadow

www.w3schools.com

์ฐธ๊ณ  : parkjuwan.dothome.co.kr/wordpress/2017/04/01/css-text-gradient/