New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

react-waveview

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-waveview

WaveView for React

latest
Source
npmnpm
Version
2.0.1
Version published
Weekly downloads
5
-28.57%
Maintainers
1
Weekly downloads
 
Created
Source

WaveView

Wave view component in React

Screenshot

wave.png

Install

npm i react-waveview --save

Get started

Example

import Wave from 'react-waveview';

const waveItems: WaveItem[] = [
  { A: 10, T: 180, fill: '#62c2ff' },
  { A: 15, T: 140, fill: '#0087dc' },
  { A: 20, T: 100, fill: '#1aa7ff' }
];

const MyComponent = () => (
  <Wave H={30} waveParams={waveItems} animated={true}></Wave>
);

Props

/**
  ---------+------------------------+
  <-- P -->|<--    T    -->|        |______
           |   /\          |   /\   |  ^
           |  /  \         |  /  \  |  A
           | /    \        | /    \ |  |
           |/      \       |/      \|__V___
           |        \      /        |  ^
           |         \    /         |  |
           |          \  /          |  |
           |           \/           |  H
           |                        |  |
           |        fill            |  |
  ---------+------------------------+__V___
*/

nametypedescriptiondefaultrequired
HnumberBaseline height-true
waveParamsWaveItem[]List of waves-true
animatedbooleanIf true, animation when mountedfalsefalse
easingTimingFunctionSpecifies the speed curve of an animationTimingFunction.LINEARfalse
speednumberBase duration in ms of one wave cycle5000false
speedIncreasePerWavenumberIncrease in speed in ms per each wave1000false
classNamestringclassName for wave container-false
styleCSSPropertiesstyle for wave container-false

Interfaces and Enums

WaveItem

nametypedescription
Anumberdistance protruding from baseline
Tnumberdistance of a wavelength
fillanybackground color of wave

TimingFunction

An enum containing all of speed curve of an animation

{
  EASE = 'ease',
  EASE_IN = 'ease-in',
  EASE_OUT = 'ease-out',
  EASE_IN_OUT = 'ease-in-out',
  LINEAR = 'linear',
  STEP_START = 'step-start',
  STEP_END = 'step-end',
}

FAQs

Package last updated on 18 Jun 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts