0.0.1 • Published 3 years ago
rjs-tabs v0.0.1
About
rjs-tabs is a tabs component for react web apps.
Getting Started
Install with npm:
npm i rjs-tabs
Install with yarn
yarn add rjs-tabs
Include in your project
import Tabs from 'rjs-tabs/Tabs';
<Tabs
tabs={[{label:'Tab One',tab:<TabOne/>},{label:'Tab Two',tab:<TabTwo/>},{label:'Tab Three',tab:<TabThree/>}]}
whenActive={{color:"#FF55FF", fontWeight:'bold',textDecoration:'underline'}}
whenInActive={{color:"green",fontWeight:"bold"}}
labelContainer={{display:'flex', width:300}}
tabContainer={{height:'auto', width:300,padding:3}}
type={'classic'}
/>
Props
Props | Details | Examples |
---|---|---|
tabs | array of objects | {label:'Tab One',tab:},{label:'Tab Two',tab:},{label:'Tab Three',tab:} |
whenActive | active style for label | {color:"#FF55FF", fontWeight:'bold',textDecoration:'underline'} |
whenInActive | inactive style for label | {color:"green",fontWeight:"bold"} |
labelContainer | label row/column style | {display:'flex', width:300} |
tabContainer | tab container style | {height:'auto', width:300,padding:3} |
type | type of tabs. can be one of: classic or pill | 'classic' |
0.0.1
3 years ago