import React, { PropTypes } from 'react' import { connect } from 'react-redux' import { createStore, bindActionCreators } from 'redux' import { hashHistory } from 'react-router' import FontAwesome from 'react-fontawesome' import ArtistSentence from './ArtistSentence' import Dater from './Dater' import URILink from './URILink' import ContextMenuTrigger from './ContextMenuTrigger' import * as helpers from '../helpers' import * as uiActions from '../services/ui/actions' class List extends React.Component{ constructor(props){ super(props); } handleClick(e, uri){ // make sure we haven't clicked a nested link (ie Artist name) if (e.target.tagName.toLowerCase() !== 'a'){ hashHistory.push((this.props.link_prefix ? this.props.link_prefix : '') + encodeURIComponent(uri)); } } handleContextMenu(e,item){ if (this.props.handleContextMenu){ e.preventDefault() this.props.handleContextMenu(e,item) } } renderHeader(){ if (!this.props.columns || this.props.noheader) return null return (