← Înapoi la Urmăritori

Cel mai recent articol

Ultima verificare

Urmăritori 0 urmăritori
Articole: 107
  1. Transition an element to its natural height in CSS

    Compare the practical CSS techniques for animating dynamic height, including Grid, interpolate-size, and calc-size(), without guessing max-height.

  2. Understand every CSS object-fit value

    Control how images and videos fill a fixed media box with the five object-fit values: fill, contain, cover, none, and scale-down.

  3. Apply hover styles only when a device can hover

    Use the CSS hover media feature to avoid mouse-only interactions on touchscreens and provide appropriate behavior for each input type.

  4. Build dark mode with CSS only

    Create a CSS-only dark mode with a checkbox and :has(), follow the system preference, or let light-dark() select theme-aware colors.

  5. Animate elements along a path with CSS Motion Path

    Use offset-path, offset-distance, and offset-rotate to move an element along a curve or custom SVG path without animating left and top.

  6. Replace six typography declarations with the CSS font shorthand

    Combine font style, variant, weight, size, line height, and family in one font declaration, while avoiding the shorthand reset trap.

  7. Create reusable CSS logic with @function

    Define reusable custom CSS functions for calculations, colors, and fluid values without repeating the same expressions across a stylesheet.

  8. Build accessible accordions with details and summary

    Use the native details and summary elements for keyboard-friendly accordions, then add a smooth CSS Grid animation without replacing their semantics.

  9. Add alternative text to CSS generated images

    Use the slash syntax of the CSS content property to provide replacement text for generated images while keeping meaningful content in HTML.

  10. CSS if(): Conditional Styling Without JavaScript

    Use the CSS if() function to choose property values from style, media, and support queries without writing JavaScript state glue.

  11. CSS Anchor Positioning: Tooltips and Dropdowns Without JavaScript Math

    A modern CSS guide to Anchor Positioning for popovers, tooltips, and dropdowns without getBoundingClientRect, scroll listeners, or layout JavaScript.

  12. Open Dialogs and Popovers Without JavaScript Using commandfor

    Use HTML command and commandfor to control dialogs and popovers declaratively, with less JavaScript and native browser behavior.

  13. Build an animated perspective grid in pure CSS.

    Layer two linear gradients, tilt with a 3D perspective transform, fade with a mask, and animate the background position.

  14. How to Use @starting-style in CSS for Entry Transitions

    Use @starting-style for modern CSS entry transitions on dialogs, popovers, drawers, and display:none elements without JavaScript timing hacks.

  15. You can now style browser find-in-page matches in CSS.

    Style browser find-in-page matches with CSS ::search-text and :current.

  16. You can now create true randomness in CSS.

    CSS random() lets you generate values inside a range and share random base values across properties.

  17. HTML in Canvas API Explained: Render HTML Inside Canvas

    Explore the experimental HTML in Canvas API, which renders real HTML inside canvas while preserving DOM interaction and accessibility.

  18. How to Create Animated Gradient Borders in CSS

    Animated gradient borders are easier with modern CSS: conic gradients, pseudo-elements, and @property replace JavaScript-heavy tricks.

  19. Shrink a sticky header only when it sticks. In CSS.

    Use CSS scroll-state queries to shrink a sticky header only after it becomes stuck.

  20. You can now detect when sticky is actually stuck. In CSS.

    Use CSS scroll-state queries to style a sticky element only when it is actually stuck to the top.

  21. Your slider can now know the active card. In CSS.

    Use CSS scroll-state queries to detect the snapped slide in a carousel and style the active card without Intersection Observer, scroll listeners, or JavaScript.

  22. Reset Form Inputs Natively with button type="reset"

    Use the native reset button to restore inputs, selects, checkboxes, and validation state without JavaScript.

  23. Fix z-index leaks with CSS isolation: isolate

    Use isolation: isolate to create a new stacking context and keep pseudo-elements, blend effects, and negative z-index layers inside their component.

  24. React to Scroll with CSS Scroll State Queries

    Use CSS scroll state queries to style elements based on scroll position.

  25. Align Numbers Perfectly with CSS tabular-nums

    Use CSS tabular-nums to align numbers in tables, dashboards, prices, and stats for cleaner, more readable interfaces and layouts.

  26. CSS Relative Colors: Build Palettes Without Color Pickers

    CSS relative colors turn one base color into hover states, borders, shadows, and accents, a practical modern CSS pattern for UI systems.

  27. Create a Mirror Reflection Effect with CSS box-reflect

    Create a mirror reflection effect in CSS with -webkit-box-reflect and add glossy image reflections with a single property and graceful fallback.

  28. CSS corner-shape: Shape Corners Beyond border-radius

    Learn the CSS corner-shape property to create scoop, bevel, squircle, and custom corners beyond border-radius with progressive enhancement.

  29. Position Elements with CSS sibling-index()

    Learn how CSS sibling-index() lets elements position themselves based on sibling order.

  30. When Relative Units Behave Differently: EM vs REM in CSS

    Learn the difference between CSS em and rem units, when to use each one, and how they affect scalable typography, spacing, and layouts.

  31. Designing Better CSS Box Shadows Easily

    Better box shadows start with light direction, layering, and color.

  32. Scroll-Driven Animations in CSS with @starting-style

    Learn how to combine entry animations and scroll-driven motion using modern CSS.

  33. My Iterative Process to Design a Book Cover

    A behind the scenes look at how I designed my ebook cover, from AI drafts and Photopea mockups to a clean, minimal design style.

  34. Build a Masonry Layout with Pure CSS column-width

    Create responsive Masonry layouts using the CSS column-width property.

  35. Responsive Components with CSS Container Queries

    Use CSS container queries to make components respond to their parent’s size, not the viewport.

  36. Style Scrollbars with CSS scrollbar-color & scrollbar-width

    Customize scrollbars to match your UI using scrollbar-color and scrollbar-width.

  37. CSS image-rendering: pixelated. Scale Pixel Art Without Blur

    Preserve sharp edges when scaling pixel art, icons, retro screenshots, or QR codes using one line of CSS supported by modern browsers.

  38. Create Multi-Column Layouts with CSS Columns

    Build column layouts with the CSS columns property.

  39. CSS backdrop-filter: Frosted Glass Effect Made Easy

    Enhance your UI with the CSS backdrop-filter property.

  40. Crisp Background Images with CSS image-set()

    Serve sharp, responsive backgrounds with CSS image-set().

  41. Pure CSS Typing Animation Effect without JavaScript

    Create a smooth typing text animation using pure CSS with keyframes, steps(), overflow, and a blinking caret.

  42. CSS Moving Background Text Effect without JavaScript

    Learn how to animate text with a moving background using only CSS.

  43. CSS clamp(): Responsive Design Without Media Queries

    Learn how CSS clamp() creates fluid, responsive layouts by defining min, preferred, and max values—reducing media queries with 95% browser support.

  44. CSS @property: Animate and Validate Custom Variables

    Learn how CSS @property upgrades custom variables with validation, debugging, and animation support.

  45. Native CSS Nesting vs Preprocessors, no more excuses

    CSS nesting is now natively supported with 91% browser coverage.

  46. Dynamic Layouts with CSS :has() without JavaScript

    Learn how to build interactive layouts using CSS :has() and :checked.

  47. CSS @scope: Encapsulated Styles Without CSS-in-JS

    Discover how CSS @scope lets you limit style leakage, write cleaner HTML, and gain true encapsulation—no BEM, utility classes, or CSS-in-JS needed.

  48. HTML inert: Disable Interactions and Improve Accessibility

    Learn how the HTML inert attribute blocks interactions, hides content from screen readers, and improves accessibility for modals and pop-ups.

  49. Custom List Bullets in CSS with @counter-style

    Discover how to customize each list bullet in CSS using @counter-style and list-style-type.

  50. CSS Light Sweep Animation for Cards without JavaScript

    Learn how to create a smooth light sweep effect on cards using only CSS gradients and keyframes.