Nearby lessons

17 of 61

📦 Tailwind CSS - Box (Shadow, Shadow Color, Sizing & Decoration Break)

📖 Overview

Box utilities control decorative effects like shadows, box sizing behavior, and how box decorations should be handled across line breaks.

🌑 Box Shadow

Control the box shadow of an element:

  • shadow-sm, shadow, shadow-md, shadow-lg, shadow-xl, shadow-2xl
  • shadow-inner, shadow-none
🌀

tailwind Designer

Live Component Playground

html Source
Loading...
Built with Tailwind CSS • Instant Reflection

🎨 Box Shadow Color

Control the color of box shadows:

  • Any Tailwind color: shadow-blue-500
  • Opacity: shadow-blue-500/50
🌀

tailwind Designer

Live Component Playground

html Source
Loading...
Built with Tailwind CSS • Instant Reflection

📐 Box Sizing

Control how the browser calculates the total size of an element:

  • box-border (default) – Border and padding are included in the width and height.
  • box-content – Border and padding are added to the width and height.
🌀

tailwind Designer

Live Component Playground

html Source
Loading...
Built with Tailwind CSS • Instant Reflection

✂️ Box Decoration Break

Control how box decorations like background, border, and shadow are rendered across line breaks:

  • decoration-clone – Renders each fragment as if it were a separate element.
  • decoration-slice (default) – Renders the decoration as if the element was not broken.
🌀

tailwind Designer

Live Component Playground

html Source
Loading...
Built with Tailwind CSS • Instant Reflection

🧠 Test Your Knowledge

3 Questions

Progress: 0 / 3
Keep Going!Tailwind CSS - Display