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

@comparaonline/ui-grid

v2.1.3

Published

Grid components based on the Foundation's float grid

Downloads

51

Readme

@comparaonline/ui-grid

code style: prettier npm version

  • Row and Column components based on react-foundation project
  • Breakpoints json file included has screen breakpoints sizes

Installation

$ npm install --save @comparaonline/ui-grid

Usage

This package relies on the existence of the stylesheet located at dist/index.css, please import it accordly to your project needs.

Row

import { Row } from '@comparaonline/ui-grid';

The known props for Row are:

| name | description | default value | | :----------------------- | :--------------------------------------------------------------------------- | :------------ | | collapse | Removes the columns gutter | false | | expanded | Sets width to 100% | false | | collapseOn[breakpoint] | Removes the gutters on the given breakpoint | undefined | | uncollapseOn[breakpoint] | Overrides collapseOn rules inherited from smaller sizes | undefined | | equalHeightColumns | Sets all the columns height to the max column height (requires flex support) | false | | addVerticalGutters | Adds vertical gutters to all the children columns | false |

Column

import { Column } from '@comparaonline/ui-grid';

The known props for Column are:

| name | description | default value | | :---------------------------------------------- | :-------------------------------------------------------- | :------------ | | small, medium, large, xlarge, xxlarge | Sets the column size per breakpoint | small=12 | | offsetOn[breakpoint] | Moves block to right according to offset, | undefined | | pushOn[breakpoint] | Right shift column | undefined | | pullOn[breakpoint] | Left shift column | undefined | | centeredOn[breakpoint] | Centers the column on the given breakpoint | undefined | | uncenteredOn[breakpoint] | Overrides centeredOn rules inherited from smaller sizes | undefined |

Example:

<Row>
  <Column small={2} large={4} pushOnSmall={2} pullOnLarge={2}>
    Content
  </Column>
  <Column small={2} offsetOnLarge={4} centeredOnSmall uncenteredOnLarge>
    Content
  </Column>
</Row>

Visibility props

| name | description | default value | | :----------------- | :----------------------------------------------- | :------------ | | showOn[breakpoint] | Shows itself from the given breakpoint an higher | undefined | | hideOn[breakpoint] | Hides itself from the given breakpoint an higher | undefined |

Breakpoints

The breakpoints values are exported as a literal object with the following properties:

| name | size | | :------ | :----- | | xsmall | 0px | | small | 480px | | medium | 600px | | large | 840px | | xlarge | 960px | | xxlarge | 1280px |

To access to this values, simply import them:

import { breakpoints } from '@comparaonline/ui-grid';

Other settings

Other relevant values are exposed using the settings object.

import { settings } from '@comparaonline/ui-grid';

The current output is:

{
  gutters: {
    default: "16px"
  }
}