Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const selectableProps = isSelectable ? { isSelectable, tabIndex: 0 } : {};
if (view === Views.TABLE) {
return createTableRow(elements, selectableProps, customProps, isSelected, accessoryAlignment);
}
const itemViewStyles = {
layout: listItemLayout, textEmphasis: listItemTextEmphasis, isTruncated: isListItemTruncated, accessoryAlignment,
};
return createListItem(elements, selectableProps, customProps, isSelected, itemViewStyles, showListItemChevron);
};
Item.propTypes = propTypes;
Item.defaultProps = defaultProps;
Item.Display = ItemView.Display;
Item.Comment = ItemView.Comment;
export default Item;
export {
ListItemLayouts, ListItemTextEmphasisTypes, AccessoryAlignments, Views,
};
};
const selectableProps = isSelectable ? { isSelectable, tabIndex: 0 } : {};
if (view === Views.TABLE) {
return createTableRow(elements, selectableProps, customProps, isSelected, accessoryAlignment);
}
const itemViewStyles = {
layout: listItemLayout, textEmphasis: listItemTextEmphasis, isTruncated: isListItemTruncated, accessoryAlignment,
};
return createListItem(elements, selectableProps, customProps, isSelected, itemViewStyles, showListItemChevron);
};
Item.propTypes = propTypes;
Item.defaultProps = defaultProps;
Item.Display = ItemView.Display;
Item.Comment = ItemView.Comment;
export default Item;
export {
ListItemLayouts, ListItemTextEmphasisTypes, AccessoryAlignments, Views,
};