CSS box-shadows - how to make them look good

แชร์
ฝัง
  • เผยแพร่เมื่อ 9 ก.พ. 2025
  • Knowing how to use the box-shadow property is one thing. Using it in ways that actually make your designs better is a completely different story! This video is all about how to use CSS box shadows in ways that enhance your designs.
    First I look at the very basics, which is pretty much to make them really subtle. If you think that it's too subtle, you've probably nailed it.
    Second I look at how the size of the blur can affect a users perception of height, or how far off the element is from what is below it.
    CodePen 1: codepen.io/kev...
    CodePen 2: codepen.io/kev...
    CodePen 3: codepen.io/kev...
    link to material design
    Much of this was inspired by the material design documentation: material.io/gu...
    ---
    I have a newsletter! www.kevinpowel...
    New to Sass, or want to step up your game with it? I've got a course just for you: www.kevinpowel...
    ---
    My Code Editor: VS Code - code.visualstu...
    How my browser refreshes when I save: • How to automatically r...
    ---
    Support me on Patreon: / kevinpowell
    I'm on some other places on the internet too!
    If you'd like a behind the scenes and previews of what's coming up on my TH-cam channel, make sure to follow me on Instagram and Twitter.
    Instagram: / kevinpowell.co
    Twitter: / kevinjpowell
    Codepen: codepen.io/kev...
    Github: github.com/kev...

ความคิดเห็น • 57

  • @Hopewe
    @Hopewe 6 ปีที่แล้ว +38

    I just wanted to say that your content is simply amazing, because while not only you're being consistent with uploading, your exlanation is very good and the variety of advanced topics just top it off! Hats off!!

    • @KevinPowell
      @KevinPowell  6 ปีที่แล้ว +7

      Thank you so much for the kind words, I'm really glad that you're enjoying my videos 😊

    • @sobeidalagrange7129
      @sobeidalagrange7129 6 ปีที่แล้ว

      Agree with Hopewe 0247!!! :)

    • @tobycollin5759
      @tobycollin5759 3 ปีที่แล้ว

      Dunno if you guys cares but if you guys are bored like me atm then you can stream all the new series on instaflixxer. Been streaming with my girlfriend these days xD

    • @sincereace6053
      @sincereace6053 3 ปีที่แล้ว

      @Toby Collin yup, have been watching on InstaFlixxer for years myself :)

  • @paritoshbatish9984
    @paritoshbatish9984 4 ปีที่แล้ว +6

    Thank's a lot man! For someone who has lazily done his CSS, your videos are really helpful.

  • @eetede84
    @eetede84 ปีที่แล้ว

    you're the best Kevin

  • @rezarahman1782
    @rezarahman1782 4 ปีที่แล้ว +2

    Lots of thanks. You are just awesome .💖💖

  • @patrickbroaden9820
    @patrickbroaden9820 3 ปีที่แล้ว +2

    Great video..keep them coming..💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯💯

  • @christopherikpat5512
    @christopherikpat5512 6 ปีที่แล้ว +2

    thanks kevin. you're a great teacher

    • @KevinPowell
      @KevinPowell  6 ปีที่แล้ว +1

      Thanks Christopher :D

  • @CarlosReveles
    @CarlosReveles 6 ปีที่แล้ว +5

    Shawdows .... Just saying! I'm creating my own website and I've learned a lot from you, so a big thank you!

    • @KevinPowell
      @KevinPowell  6 ปีที่แล้ว +2

      Thanks for pointing that out! And I'm glad the video helped 😁

  • @nagahumanbeingzooofparticl8836
    @nagahumanbeingzooofparticl8836 6 ปีที่แล้ว +1

    Another awesome tip for box-shadows. Thank you.

    • @KevinPowell
      @KevinPowell  6 ปีที่แล้ว

      Glad you liked it :)

  • @sobeidalagrange7129
    @sobeidalagrange7129 6 ปีที่แล้ว +2

    Very enlightening!!!

  • @shreejitpal6598
    @shreejitpal6598 3 ปีที่แล้ว

    This video gives me all sorts of ideas 🤔

  • @emmanuelmwangi3071
    @emmanuelmwangi3071 3 ปีที่แล้ว

    good tutorial Kevin really enjoyed it🤗

  • @lekhavlekhav9882
    @lekhavlekhav9882 6 ปีที่แล้ว +2

    Thank you soo much Mr. Kevin.. Keep going.. Helped a lot.. 😊😊

  • @forrest_lump
    @forrest_lump 4 ปีที่แล้ว +1

    I think you should show the spread-radius in combination with blur-radius=0. That way you can easily show how this value reduces and enlarges the shadow layer.

  • @clevermissfox
    @clevermissfox ปีที่แล้ว +1

    Can box shadows use a gradient for the color? Assuming no bc I don’t think you can have a background image on a shadow. In this case you would make the shadow from a pseudo element?

  • @mareksawinski8225
    @mareksawinski8225 6 ปีที่แล้ว +1

    Great video. I would like to see more stuff like this. TH-cam does not need more videos about box model or other standard crap. This is stellar. Thanks Kevin. :-)

    • @KevinPowell
      @KevinPowell  6 ปีที่แล้ว

      Thanks Marek, glad you liked it!

  • @sumankathet2560
    @sumankathet2560 6 ปีที่แล้ว

    I was eagerly waiting for this video..
    Thank you very much sir for these awesome contents😉

    • @KevinPowell
      @KevinPowell  6 ปีที่แล้ว +1

      No problem, glad you like them 😁

  • @jacqueskousteau788
    @jacqueskousteau788 หลายเดือนก่อน

    Thanks @kevinpowell for the helpful content. If transitioning the box-shadow property is still (in '24 - in case anything changed in the 6yrs since recording of this vid) bad for performance, what's a more performance optimal way to achieve the transition of a box shadow property?

  • @roytating4915
    @roytating4915 3 ปีที่แล้ว

    Awesome!

  • @toderox
    @toderox 2 ปีที่แล้ว

    Great!

  • @Justin-nf6tw
    @Justin-nf6tw 2 ปีที่แล้ว

    thank you sir

  • @andrewnoonan5418
    @andrewnoonan5418 3 ปีที่แล้ว

    was modifying a project n khan academy and when adding box-shadow , nothing happened-it was in a div-perhaps when i added another id tag to a h2 within that div will it stop seeing a box-shadow effect ??

  • @naimur634
    @naimur634 3 ปีที่แล้ว

    Do u have any videos about styling custom video elements?

  • @yunmulu1659
    @yunmulu1659 9 หลายเดือนก่อน

    thanks.

  • @Rocadamis
    @Rocadamis 3 ปีที่แล้ว +1

    CHALLENGE! Make a parallax box shadow that moves with scrolling to suggest a moving of the light source!

  • @yassmaboby296
    @yassmaboby296 6 ปีที่แล้ว +2

    cool !!

  • @user-tp1rw8xb8i
    @user-tp1rw8xb8i 6 ปีที่แล้ว

    Thank you :) you help us a lot

    • @KevinPowell
      @KevinPowell  6 ปีที่แล้ว

      No problem at all :D

  • @md.rakibulislam8064
    @md.rakibulislam8064 5 ปีที่แล้ว

    Good video

  • @litellavi
    @litellavi 4 ปีที่แล้ว

    hi, you enplane so good so maybe you can help me understand how do i add a box shadow to each photo in a gallery of photos?

  • @Destinymusic506
    @Destinymusic506 6 ปีที่แล้ว

    greetings from Costa Rica

    • @KevinPowell
      @KevinPowell  6 ปีที่แล้ว

      I wish I were in Costa Rica, it's snowing here :\

    • @Destinymusic506
      @Destinymusic506 6 ปีที่แล้ว

      @@KevinPowell jajajaja here summer time jajajja

    • @Destinymusic506
      @Destinymusic506 6 ปีที่แล้ว

      @@KevinPowell I have learned too much with their videos and that I am a beginner.

  • @thangjamkishorchand
    @thangjamkishorchand 6 ปีที่แล้ว +2

    Kevin do a Website review ? Just curious

    • @KevinPowell
      @KevinPowell  6 ปีที่แล้ว +2

      Never done one for the channel, but doesn't mean I wouldn't do one :)

    • @thangjamkishorchand
      @thangjamkishorchand 6 ปีที่แล้ว +1

      @@KevinPowell coz i want to summit my site for review lol

  • @mohammedriyazuddin5649
    @mohammedriyazuddin5649 6 ปีที่แล้ว

    thanks

  • @tilakmadichettitheappdeveloper
    @tilakmadichettitheappdeveloper 4 ปีที่แล้ว

    i wanted inset shadowing . can you explain ?

  • @Epicradarofficial
    @Epicradarofficial 5 ปีที่แล้ว

    Thanks dude. Could you please upload a tut on translate and mobile first website?? Thanks.

  • @stoyanchorbov7159
    @stoyanchorbov7159 6 ปีที่แล้ว +2

    Video idea: How to make your website good looking on every device

    • @KevinPowell
      @KevinPowell  6 ปีที่แล้ว +1

      I'll sort of be talking about that when I do my next 'building out a full-page' series, though that's a little while off.

  • @rbhakusho3843
    @rbhakusho3843 6 ปีที่แล้ว

    cool

    • @KevinPowell
      @KevinPowell  6 ปีที่แล้ว

      Glad you liked it :)

  • @adone.business
    @adone.business 5 ปีที่แล้ว

    T
    haks kevin powell

  • @amyp.575
    @amyp.575 5 ปีที่แล้ว

    No more yellow background, please. I could barely see any shadows at all