mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-13 02:07:12 -07:00
Initial Commit Rework
This commit is contained in:
parent
74a4cc048c
commit
95051cbd63
2483 changed files with 101351 additions and 111396 deletions
34
frontend/src/Artist/Index/Table/ArtistIndexTableConnector.js
Normal file
34
frontend/src/Artist/Index/Table/ArtistIndexTableConnector.js
Normal file
|
@ -0,0 +1,34 @@
|
|||
import { createSelector } from 'reselect';
|
||||
import connectSection from 'Store/connectSection';
|
||||
import createClientSideCollectionSelector from 'Store/Selectors/createClientSideCollectionSelector';
|
||||
import { setArtistSort } from 'Store/Actions/artistIndexActions';
|
||||
import ArtistIndexTable from './ArtistIndexTable';
|
||||
|
||||
function createMapStateToProps() {
|
||||
return createSelector(
|
||||
(state) => state.app.dimensions,
|
||||
createClientSideCollectionSelector(),
|
||||
(dimensions, series) => {
|
||||
return {
|
||||
isSmallScreen: dimensions.isSmallScreen,
|
||||
...series
|
||||
};
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
function createMapDispatchToProps(dispatch, props) {
|
||||
return {
|
||||
onSortPress(sortKey) {
|
||||
dispatch(setArtistSort({ sortKey }));
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
export default connectSection(
|
||||
createMapStateToProps,
|
||||
createMapDispatchToProps,
|
||||
undefined,
|
||||
{ withRef: true },
|
||||
{ section: 'series', uiSection: 'seriesIndex' }
|
||||
)(ArtistIndexTable);
|
Loading…
Add table
Add a link
Reference in a new issue