Splitting out helpers into separate files

This commit is contained in:
James Barnsley
2020-03-03 16:39:37 +13:00
parent 57dd18e870
commit 5a1f08fdf0
105 changed files with 5456 additions and 5574 deletions

View File

@ -1,23 +1,16 @@
import React from 'react';
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
import TrackList from '../components/TrackList';
import Header from '../components/Header';
import Icon from '../components/Icon';
import * as uiActions from '../services/ui/actions';
import * as pusherActions from '../services/pusher/actions';
import * as spotifyActions from '../services/spotify/actions';
import * as mopidyActions from '../services/mopidy/actions';
class QueueHistory extends React.Component {
constructor(props) {
super(props);
}
class QueueHistory extends React.Component {
componentDidMount() {
this.props.uiActions.setWindowTitle('Queue history');
this.loadHistory();
@ -38,7 +31,7 @@ class QueueHistory extends React.Component {
render() {
const options = (
<a className="button button--no-hover" onClick={(e) => this.props.history.push('/queue')}>
<Icon name="keyboard_backspace" />
<Icon name="keyboard_backspace" />
&nbsp;
Back
</a>
@ -71,7 +64,7 @@ class QueueHistory extends React.Component {
className="queue-history-track-list"
track_context="history"
tracks={tracks}
show_source_icon
show_source_icon
/>
</section>
@ -100,4 +93,4 @@ const mapDispatchToProps = (dispatch) => ({
mopidyActions: bindActionCreators(mopidyActions, dispatch),
});
export default connect(mapStateToProps, mapDispatchToProps)(QueueHistory);
export default connect(mapStateToProps, mapDispatchToProps)(QueueHistory);