npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

css-media-all

v1.3.0

Published

css file with media queries for all devices

Downloads

4

Readme

CSS MEDIA ALL

A library written in css consisted of media queries to support the responsiveness of webpage.

CMA(Css Media All) makes your webpage responsive, idea behind this library is to make webpage more responsive to differrent screens, the media queries used in this library is a LIFTOFF from CSS tricks.

Support

it is written in vanila CSS and is mostly supported in all major browsers it is a small libarary for small websites where you dont have different code for desktop and mobile

Use CMA in your site?

install using npm

npm install css-media-all --save

install using bower

bower install css-media-all --save

clone the git repo

git clone https://github.com/siddarthvader/CSS-MEDIA-ALL.git

Add to your CSS

import url('css-media-all.css');

p {
    font-size:1rem;// this `rem` unit is now a variable and you can use it the way you want
    padding:0.5rem;
}

Add to your html (this is standard setting, in case you forget)

    <meta name="viewport" content="width=device-width, initial-scale=1">

this is advised that refrain using rem in width property, use % for width;

Idea behind it

for years we developers/designers are constantly arguing which is the best unit for css measurements, is it px or em or rem or vw or mm? nobody has a solid answer to it, because it varies according understanding of developer, but one thing remain unchanged which is rendering of page.

I personally find rem to be the best of all, it is relative to the font-size of html tag, i mean now you have an absolute base unit which is directly dependent on the font-size property of html, what more can you ask for?

with rem, you want to zoom-in your site?

  • change the font-size of html tag?

you want to render your site on mobile viewport but you are not sure about the text size rendering?

  • well change the font-size of html tag?

Measurements

When it comes to rem you have to set the font-size of html tag, now in this module the default setting goes like this

| Desktop | Mobile(Portrait) | Mobile(Landscape) | Tab(Portrait) | Tab(Landscape) |
|---------|------------------|-------------------|---------------|----------------|
|  .65vw    |       1.5vw      |        .65vw        |       1.5vw   |        1vw     |

where vw is the % of width of view port;

for example:

    //device width is 1280px
    html{
        font-size:1vw; // meant 12.8px
    }

    p{
        font-size:1.2rem;// (12.8*1.2)
    }