Padding on bottom and auto-scrolling commands; Fixing Spotify artists library process

This commit is contained in:
James Barnsley
2018-10-26 16:06:31 +13:00
parent f95651116a
commit 57c95adbc3
21 changed files with 14079 additions and 10744 deletions

View File

@ -366,7 +366,7 @@ class Settings extends React.Component {
</div>
</div>}
<div className="field commands-setup">
<div className="field commands-setup" id="commands-setup">
<div className="name">
Commands
</div>

View File

@ -73,10 +73,10 @@ class LibraryArtists extends React.Component{
}
}
if (newProps.spotify_enabled && (newProps.source == 'all' || newProps.source == 'spotify')){
if (newProps.spotify_enabled && (newProps.source == 'all' || newProps.source == 'spotify')){
// Filter changed, but we haven't got this provider's library yet
if (!newProps.spotify_library_artists_status != 'finished' && newProps.spotify_library_artists_status != 'started'){
if (newProps.spotify_library_artists_status != 'finished' && newProps.spotify_library_artists_status != 'started'){
this.props.spotifyActions.getLibraryArtists();
}
}

View File

@ -46,12 +46,28 @@ class EditCommand extends React.Component{
window.history.back();
// A bit hacky, but wait for a moment to allow the back navigation
// and then scroll down to our commands list
setTimeout(() => {
helpers.scrollTo("commands-setup");
},
10
);
return false;
}
handleDelete(e){
this.props.pusherActions.removeCommand(this.state.id);
window.history.back();
// A bit hacky, but wait for a moment to allow the back navigation
// and then scroll down to our commands list
setTimeout(() => {
helpers.scrollTo("commands-setup");
},
10
);
}
render(){