poll

v1.0.11arrow_drop_down
v1.0.11
v1.0.10
v1.0.9
v1.0.8
v1.0.7
v1.0.6
v1.0.5
v1.0.4
v1.0.3
v1.0.2
v1.0.1
v1.0.0
STATUS
Passing
DOWNLOADS
397
LICENSE
MIT
VISIBILITY
Public
PUBLISHED
3 years ago
SIZE
14 KB
Poll component
1 contributor
Install poll as a package?
Copied
npm i @bit/dennisdigital.components.molecules.poll
Set Bit as a scoped registryLearn more
npm config set '@bit:registry' https://node.bit.dev
Component Example
React
React
Vue
Angular
React Native
Add dependency... help_outline
Just
import
any of the 1 million components
and packages in Bit or NPM to the example.
import Button from '@bit/grommet.grommet.button';
import Lodash from 'lodash';
toggle layout
modifieddraft
chevron_left
chevron_right
Poll ()

Poll component

Properties
NameTypeDefault value
title
string'Poll Component'
status
string''
date
string''
options
{"id":"string","label":"string","votes":"number"}[][]
voted
boolfalse
totalVotes
number0
onChange
function() => {}
extraClassNames
objectOf{}
context
{}{}
Test Summary

should render without any props

Pass

checks title props

Pass

checks status props

Pass

checks date props

Pass

should match the number of input in the inputs array

Pass

should show the options if the user has not voted

Pass

should not show the options if the user has voted

Pass

checks onChange props

Pass

check extraClassNames props

Pass
Help and resources