← Înapoi la Urmăritori

Cel mai recent articol

Ultima verificare

Urmăritori 0 urmăritori
Articole: 124
  1. Use the CSS inset shorthand to set top, right, bottom, and left in one declaration.

  2. Create CSS drop caps with the initial-letter property.

  3. Truncate multiline text in CSS with line-clamp.

  4. Derive lighter and darker color variants at runtime with CSS relative color syntax.

  5. Use CSS wide-gamut color with oklch, display-p3, and rec2020.

  6. Customize a native HTML select dropdown with appearance: base-select.

  7. Close a CSS dialog on outside click or ESC with the closedby attribute.

  8. Open and close CSS modal dialogs with the commandfor and command attributes on a button.

  9. Show CSS hover tooltips with popover=hint and the interestfor attribute.

  10. Vertically center text in CSS with text-box-trim and text-box-edge.

  11. Build CSS-only carousel navigation with the scroll-button and scroll-marker pseudo-elements.

  12. Create staggered CSS animation delays with the sibling-index() function.

  13. Fill available space in CSS with width: stretch or height: stretch.

  14. Highlight the current section with a CSS scroll spy using scroll-target-group and :target-current.

  15. Create responsive CSS clip-path shapes with the shape() function.

  16. Create squircle, scoop, and notch corners with CSS corner-shape instead of clip-path polygon hacks or SVG masks.

  17. Define reusable CSS logic with the native @function at-rule.

  18. Write inline conditional styles with the CSS if() function.

  19. Read HTML attribute values as typed CSS data with advanced attr().

  20. Style sticky and snapped elements with CSS scroll-state() container queries.

  21. Write range comparisons in CSS style queries directly, like style(--progress > 50%).

  22. Animate height to and from auto in CSS with interpolate-size: allow-keywords.

  23. Auto-resize a textarea in CSS with field-sizing: content.

  24. Show CSS form validation styles only after the user interacts using :user-invalid.

  25. Use object-fit: cover on img elements for responsive images.

  26. Write CSS media query ranges with comparison operators like (width < 768px) instead of min-width and max-width.

  27. Define bounce, spring, and elastic easing curves with the CSS linear() timing function.

  28. Build an exclusive CSS accordion where only one panel opens at a time using the details name attribute.

  29. Detect CSS feature support with @supports instead of JavaScript CSS.supports() checks or Modernizr.

  30. Respect the user's prefers-reduced-motion setting in CSS.

  31. Fix the 100vh mobile overflow with dynamic viewport units. dvh, svh, and lvh adapt to the visible area as browser chrome appears and disappears.

  32. Style scrollbars in CSS with scrollbar-color and scrollbar-width.

  33. Stop scroll from leaking out of modals and dropdowns with CSS overscroll-behavior: contain.

  34. Prevent scrollbar layout shift with scrollbar-gutter: stable.

  35. Add native HTML autocomplete to any input with the datalist element.

  36. Build a CSS accordion with the native details and summary elements.

  37. Lazy load images in HTML with the loading="lazy" attribute.

  38. Display live form output with the HTML output element.

  39. Show the right mobile keyboard with the inputmode attribute.

  40. Animate elements along a curved motion path in CSS with offset-path and offset-distance.

  41. Create a frosted glass effect in CSS with backdrop-filter: blur().

  42. Define CSS colors with oklch for perceptually uniform lightness across hues.

  43. Auto-pick readable text color based on background luminance with CSS contrast-color().

  44. Scale elements with the CSS zoom property instead of transform: scale() plus negative margins. zoom shrinks the element and its layout footprint together.

  45. Build an automatic CSS type scale using :heading(), sibling-index(), and pow().

  46. Build data-driven CSS layouts by reading typed attr() values from data attributes.

  47. Generate per-element random values with the CSS random(min, max) function.

  48. Create responsive clip-path shapes with the CSS shape() function.

  49. Highlight arbitrary text ranges with the CSS Custom Highlight API and ::highlight().

  50. Style video and audio by playback state with the CSS :playing, :paused, :muted, :seeking, :buffering, and :stalled pseudo-classes.