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 🙏

© 2026 – Pkg Stats / Ryan Hefner

postcss-bubbly-grid

v1.0.5

Published

An easy-to-use and very flexible grid system, made with flexbox and calc()

Readme

Bubbly Grid System

This is not another 12-column grid system, this is an up-to-you-column grid system.

This is also not an HTML grid system, meaning you're gonna be able to keep your markup clean and tidy.

Made with calc() and Flexbox, so it will support the latest versions of Chrome, Firefox, Safari, Opera (not opera mini) & IE 11+.

Built in PostCSS, so it will work with the preprocessor of your choice.


Wanna see some nicer doc?

Wanna see some demos?

npm

Installation

npm install postcss-bubbly-grid

Usage

:arrow_up: back to top

How to use it :

// postcss.config.js

const bubblyGrid = require('postcss-bubbly-grid')

module.exports = {
  plugins: [
    bubblyGrid()
  ]
}

Sym Grid (symmetrical only)

sym-grid: [col: number] [gutter?: value<px | % | em | rem>] [stretch?: 'stretch' | 'nostretch']

Make sure the parent container is set to display flex :

.container {
  display: flex;
  flex-wrap: wrap;
}

Col

:arrow_up: back to top

  • number of columns per row
.container {
  display: flex;
  flex-wrap: wrap;
}

.item {
  sym-grid: 4 20px;
}
  • You'll get 4 columns per row
  • and a gutter of 20px between each column

The HTML :

<div class="container">
  <div class="item">
    item 01
  </div>
  ...
  <div class="item">
    item 08
  </div>
</div>

col

Gutter

:arrow_up: back to top

  • width of the gutter (values can be in 'px', 'em', 'rem' or '%')

.item {
  sym-grid: 3 2em;
}
  • You'll get 3 columns per row
  • You'll get a gutter of 2em between each column

gutter

Stretch

:arrow_up: back to top

  • Use it when you want the last item in the row to take the full width of the remaining space :

.item {
  sym-grid: 3 2em stretch;
}

The HTML :

<div class="container">
  <div class="item">
    item 01
  </div>
  ...
  <div class="item">
    item 05
  </div>
</div>

stretch

media-queries

:arrow_up: back to top

Media queries and new cycles :

Let's say that when the window width gets below 420px, you wanna change the number of cols per row :

.item {
  sym-grid: 4 20px;
}

@media screen and (max-width: 420px) {
  sym-grid: 2 2em stretch;
}
  • First, we set a new cycle with: 2
  • Then, we set a new value for the gutter: 2em

sym-mq

Media queries and stretch :

Let's say that when the window width gets below 420px, you wanna get rid of the stretching stuff :

.item {
  sym-grid: 4 20px stretch;
}

@media screen and (max-width: 420px) {
  sym-grid: 2 20px nostretch;
}

Asym Grid (asymmetrical grid)

:arrow_up: back to top

asym-grid: [ratio: <number / number>] [gutter?: value<px | ‰ | em | rem>] [last?: 'last']

  • The gutter value must be the same across the different declarations defining a row
  • To remove the margin-right on the last element of a row, we must pass the last parameter
  • You can set up another ratio everytime you defining a new row
  • Make sure the parent container is set to display flex

Let's make an asymmetrical grid :

.container {
  display: flex;
  flex-wrap: wrap;
}

/* -- first row -- */

.LeftSide {
  asym-grid: 2/10 20px;
}

.InBetween {
  asym-grid: 6/10 20px;
}

.RightSide {
  asym-grid: 2/10 20px last;
}


/* -- second row -- */

.left-side {
  asym-grid: 10/20 10px;
}

.in-between {
  asym-grid: 7/20 10px;
}

.right-side {
  asym-grid: 3/20 10px last;
}


/* -- third row -- */

.left__side {
  asym-grid: 3/12 2em;

}

.in__between {
  asym-grid: 3/12 2em;
}

.right__side {
  asym-grid: 6/12 2em last;
}

The HTML :

<div class="container">
  <!-- first row -->
  <div class="LeftSide">
    LeftSide
  </div>
  <div class="InBetween">
    InBetween
  </div>
  <div class="RightSide">
    RightSide
  </div>
  <!-- second row -->
  <div class="left-side">
    left-side
  </div>
  <div class="in-between">
    in-between
  </div>
  <div class="right-side">
    right-side
  </div>
  <!-- third row -->
  <div class="left__side">
    left__side
  </div>
  <div class="in__between">
    in__between
  </div>
  <div class="right__side">
    right__side
  </div>
</div>

asym-grid

Push

:arrow_up: back to top

push: [ratio: <number / number>] | [reset: 'reset']

Wanna push that one col to the right so that it's centered? easy :

.one {
  asym-grid: 4/12 20px;
}

.two {
  asym-grid: 2/12 20px;
  push: 1/12;
}

.three {
  asym-grid: 4/12 20px last;
}

The HTML :

<div class="container">
  <div class="one">
    one
  </div>
  <div class="two">
    two
  </div>
  <div class="three">
    three
  </div>
</div>

push

Alternatively, you can also use negative values if you wanna push an element to the left, e.g., push: -1/12 is the same as pull: 1/12

Pull

:arrow_up: back to top

pull: [ratio: <number / number>] | [reset: 'reset']

Wanna pull a col to the left? :

.one {
  asym-grid: 4/12 20px;
}

.two {
  asym-grid: 2/12 20px;
  push: 6/12;
}

.three {
  asym-grid: 4/12 20px;
  pull: 3/12;
}

The HTML :

<div class="container">
  <div class="one">
    one
  </div>
  <div class="two">
    two
  </div>
  <div class="three">
    three
  </div>
</div>

push

Alternatively, you can also use negative values if you wanna pull an element to the right, e.g., pull: -1/12 is the same as push: 1/12

Center

:arrow_up: back to top

center: [boolean];

If you wish to have an element centered and by itself on his own line, you can use center: true;

Media-queries

:arrow_up: back to top

Above 760px :

.one {
  asym-grid: 2/10 20px;
  push: 8/10;
}

.two {
  asym-grid: 6/10 20px;
}

.three {
  asym-grid: 2/10 20px last;
  pull: 8/10;
}

asym-mq-b

Below 760px :

If you get bored of all the pushing and pulling around, use push: reset; or pull: reset;

.one {
  @media screen and (max-width: 760px) {
    asym-grid: 1/3 20px;
    push: reset;
  }
}

.two {
  @media screen and (max-width: 760px) {
   asym-grid: 1/3 20px;
  }
}

.three {
  @media screen and (max-width: 760px) {
    asym-grid: 1/3 10px;
    pull: reset;
  }
}

asym-mq-a

The End

Et voilà, I guess this is it...Now it's your turn to build some crazy layouts :)

:arrow_up: back to top