1.0.0 • Published 4 years ago

@react-theming/theme-swatch v1.0.0

Weekly downloads
2,340
License
MIT
Repository
github
Last release
4 years ago

npm version

@react-theming/theme-swatch

Install

npm i @react-theming/theme-swatch

Usage

import { createSwatch } from '@react-theming/theme-swatch';
/* you need to provide a `styled` functions from Styled Components, Emotion or '@storybook/theming'  */
import styled from '@emotion/styled';

const ThemeSwatch = createSwatch(styled);

colors = ['red', 'green', '#13f0b7', 'rgb(100,180,250)'];

const YourComponent = () => {
  return <ThemeSwatch theme={colors} size={64} />;
};

example

Credits

1.0.0

4 years ago

0.2.1

4 years ago

0.2.2

4 years ago

0.2.0

5 years ago

0.1.1

5 years ago

0.1.0

6 years ago