Repository URL to install this package:
|
Version:
3.0.6-working.1 ▾
|
/**
* !!!!!
* @todo TOO MANY PROPS PASSING THROUGH FOR LAYOUT
* THIS IS WHY WE HAVE PRESETS
*
* @todo this is supposed to be the renderProp
*
* @todo - WHAT IS THIS?!!?!?!?!?!!?!? THIS IS A PRESET MOVE IT OUT
* we can also EASILY style this
* order: ${props => props.dropDownAlignmentType === 'top' ? -1 : 1};
*/
const optionListView = (
<StyledOptionList
list={list}
children={listView}
isVisible={isVisible}
shouldBeAbsolute={shouldBeAbsolute}
dropDownAlignmentType={dropDownAlignmentType}
/>
)
const renderDropDownList = (item: string) => {
switch (item) {
case 'top':
return (
<React.Fragment>
{optionListView}
{activeView}
</React.Fragment>
)
case 'bottom':
default:
return (
<React.Fragment>
{activeView}
{optionListView}
</React.Fragment>
)
}
}