A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://marcj.github.io/css-element-queries/ below:

Css-element-queries by marcj

CSS-Element-Queries

Element responsiveness for a modern web

An event-based CSS element dimension query library with valid CSS selector syntax to change styles and allow responsive images based on element's dimensions and not window's viewport.

It's exactly what we need when it comes to responsive Web Components.

Installation Download

Download the zip file using the buttons on the right side and include both files at the head section of your page. ElementQueries start automatically to listen to

window.load event

and parses all available css files to attach the ResizeSensor and start the magic.

NPM

npm install css-element-queries --save

Highlights Examples

Drag the gray line at the right to see it in action.

Responsive Text

Element responsiveness FTW!

Responsive Image

The image above has a default of 700px. Shrink or expend the container too see responsive image working. Thanks

@placehold.it Responsive Widget

Demo 1 This is content from the first responsive demo without media queries. It uses the element queries provided by this library.

Responsive Layout Demo 2

Box

First 1/2 box

Second 1/2 box

Responsive Animation Demo 3 - width

This box is animated through css transitions. We attached a resize-listener to this box. See below.

No changes.

Demo 4 - height

This box is animated through css transitions. We attached a resize-listener to this box. See below.

No changes.

ResizeSensor Demo

CSS-Element-Queries comes with a Javascript ResizeSensor class you can use in Javascript directly.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4