2.0.2 • Published 4 years ago

react-moon v2.0.2

Weekly downloads
94
License
MIT
Repository
github
Last release
4 years ago

🌚 react-moon

Moon component for React

NPM

🌑🌒🌓🌔🌕🌖🌗🌘🌑

Install

npm install --save react-moon

Usage

import React from 'react';
import Moon from 'react-moon';

export default () => <Moon phase={0.16} size={128} />;

props

propdescriptiontypedefault
phaseMoon phase from 0 to 1. Full moon is 0.5.Number0.16
sizeDiameter in pixelsNumber80
lightColorColor of the light sideStringwhite
darkColorColor of the dark sideStringblack
borderCSS value for borderString4px solid black
rotationCSS value for rotation \<angle>String0deg

Known issues

  • Size must be static and, if bigger, the moon will overflow its container
2.0.2

4 years ago

2.0.1

4 years ago

2.0.0

4 years ago

1.1.1

5 years ago

1.1.0

5 years ago

1.0.0

5 years ago