Explain Codes LogoExplain Codes Logo

Css

Simulate background-size:cover on <video> or <img>

css
responsive-design
viewport-units
transforms

Line break (like ``) using only CSS

css
responsive-design
pseudo-elements
best-practices

Is there an equivalent to background-size: cover and contain for image elements?

css
responsive-design
object-fit
css-tricks

Inline style to act as :hover in CSS

css
responsive-design
best-practices
css-animations

How to style the parent element when hovering a child element?

css
responsive-design
best-practices
pointer-events

How to set max width of an image in CSS

css
responsive-design
max-width
css-selectors

How to prevent the click event using CSS?

css
pointer-events
css-properties
user-experience

How to make a parent div auto size to the width of its children divs

css
responsive-design
best-practices
css-grid

How to line-break from CSS, without using <br />?

css
responsive-design
pseudo-elements
white-space-properties

How to affect other elements when one element is hovered

css
responsive-design
best-practices
transitions

How do I keep two side-by-side div elements the same height?

css
responsive-design
best-practices
flexbox

How can I center a div within another div?

css
responsive-design
best-practices
css-chaos

Changing the cursor to a finger pointer

css
responsive-design
best-practices
performance

Crop text too long inside div

css
responsive-design
best-practices
css-tricks

Allow specific tag to override overflow:hidden

css
responsive-design
best-practices
positioning

Invert CSS font-color depending on background-color

css
responsive-design
best-practices
performance

Css selector by inline style attribute

css
responsive-design
best-practices
css-specificity

What is default list styling (CSS)?

css
responsive-design
best-practices
list-styles

Overflow:hidden dots at the end

css
responsive-design
best-practices
css-pseudo-elements

Is there a srcset equivalent for css background image

css
responsive-design
image-optimization
css-features