node package manager
Easy sharing. Manage teams and permissions with one click. Create a free org »

resin-components

Resin Components

Build Status

A collection of resin.io UI components, built using React, recompose, styled-components and styled-system.

Usage

You can import react components directly into your project:

import React from 'react';
import { Button, Box } from 'resin-components';
 
const Example = () => {
  return (
    <Box my={3} className="example-button-wrapper">
      <Button primary emphasized>Click me</Button>
    </Box>
  )
};
 
export default Example;

Provider

Wrap your application in the <Provider> component so that child components can correctly inherit the resin theme. You can optionally provide your own theme.

Styled system

All components support styled-system attributes, allowing you to use fontSize, color, px etc.

UI Components

For and interactive demo of all components, see https://resin-io-modules.github.io/resin-components

Developing

Clone this repository and then run:

npm install

The interactive storybook can be launched by running:

npm run storybook

Code is automatically linted and formatted by Husky as a pre-commit hook.

The interactive storybook can be published by running:

npm run publish-storybook

Testing

npm test