UNPKG

ldx-widgets

Version:

widgets

45 lines (37 loc) 990 B
(function() { var PvrContent, React, div; React = require('react'); div = React.DOM.div; /* Popover Content, see pvr_wrapper.coffee for docs */ PvrContent = React.createClass({ displayName: 'PvrContent', render: function() { var className, hasSubLabel, item, itemHeight, lh, ref; ref = this.props, item = ref.item, itemHeight = ref.itemHeight, hasSubLabel = ref.hasSubLabel; className = 'plain-pvr-content-item'; lh = itemHeight / 2; if (hasSubLabel) { className += ' has-sublabel'; } return div({ className: className, style: { minHeight: itemHeight, lineHeight: lh + "px" } }, [ div({ key: 'info', className: 'pvr-info', title: item.info }, item.info), div({ key: 'label', className: 'pvr-info-label' }, item.label) ]); } }); module.exports = PvrContent; }).call(this);