1.27.0 • Published 5 years ago

react-skills v1.27.0

Weekly downloads
8
License
MIT
Repository
github
Last release
5 years ago

react-skills

npm_version license

A dependency-free, pure-css animated, resizable, customizable, skill bars panel React component.

react-skills preview



Links

Installation

npm i react-skills

Usage

import { SkillBars } from 'react-skills';

const skillsData= [
  {
    name: 'ReactJS',
    level: 100,
    color: 'blue',
  },
  {
    name: 'SomeOtherTech',
    level: 85,
    color: 'red',
  }
]

// ...

<SkillBars skills={skillsData} />

or you can use the SkillBar (singular) component this way:

import { SkillBar } from 'react-skills';

// ...

<SkillBar name="ReactJS" level={100} color="blue" />
<SkillBar name="SomeOtherTech" level={80} color="red" />

Developers

Start

npm run start or yarn start

Runs the library in development mode. Open http://localhost:3000 to view it in the browser.

Test

npm run test or yarn test

Runs the test watcher in an interactive mode.

Build

npm run build or yarn build

Builds the library for production to the build folder. It correctly bundles React in production mode and optimizes the build for the best performance.

Deploy

npm run deploy or yarn deploy Builds the component then push it on NPM as new version. Builds the github page app for production to the demo folder. Creates a gh-page github branch and push the demo build on that branch.

Props API

SkillBar

Displays a animated skill bar

PropertyTypeRequiredDefault valueDescription
namestringyesThe name of the skill.
levelnumberyesThe skill level.
colorstringyesThe background color.
durationnumberno2The animation duration in seconds.
heightnumberno30The component height.
levelProgressboolnofalseWhether or not the level text should increment as the bar grows up or directly display the level value.
flatboolnofalseWhether the component owns a box shadow or not.
labelWidthnumberno100The label width.
customLabelfuncnonullUser defined function that takes a skill parameter and returns a React component to display instead of the default label.

SkillBars

Group your Skillbars components together

PropertyTypeRequiredDefault valueDescription
skillsarrayOfyesAn array of SkillBar props data
durationnumberno2The animation duration in seconds.
levelProgressboolnofalseWhether or not the level text should increment as the bar grow up or directly display the level value.
flatboolnofalseWhether the skillbars own a box shadow or not.
barsHeightnumberno30The SkillBar component height.
labelsWidthnumberno100The SkillBar component label width.
spacingnumberno15The spacing between each SkillBar row.
customLabelsfuncnonullUser defined function that takes a skill parameter and returns a React component to display instead of the default labels.

This document was generated by the Create React Readme v1.0.2.

1.27.0

5 years ago

1.25.0

5 years ago

1.26.0

5 years ago

1.24.0

5 years ago

1.22.0

5 years ago

1.20.0

5 years ago

1.18.0

5 years ago

1.17.0

5 years ago

1.15.0

5 years ago

1.14.0

5 years ago

1.13.0

5 years ago

1.16.0

5 years ago

1.12.0

5 years ago

1.11.0

5 years ago

1.10.0

5 years ago

1.9.0

5 years ago

1.8.0

5 years ago

1.7.0

5 years ago

1.6.0

5 years ago

1.5.0

5 years ago

1.4.0

5 years ago

1.3.0

5 years ago

1.2.0

5 years ago

1.1.0

5 years ago

1.0.0

5 years ago