You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
901 B
26 lines
901 B
import { connect } from 'react-redux';
|
|
import { createSelector } from 'reselect';
|
|
import createDimensionsSelector from 'Store/Selectors/createDimensionsSelector';
|
|
import createUISettingsSelector from 'Store/Selectors/createUISettingsSelector';
|
|
import ArtistIndexPosters from './ArtistIndexPosters';
|
|
|
|
function createMapStateToProps() {
|
|
return createSelector(
|
|
(state) => state.artistIndex.posterOptions,
|
|
createUISettingsSelector(),
|
|
createDimensionsSelector(),
|
|
(posterOptions, uiSettings, dimensions) => {
|
|
return {
|
|
posterOptions,
|
|
showRelativeDates: uiSettings.showRelativeDates,
|
|
shortDateFormat: uiSettings.shortDateFormat,
|
|
longDateFormat: uiSettings.longDateFormat,
|
|
timeFormat: uiSettings.timeFormat,
|
|
isSmallScreen: dimensions.isSmallScreen
|
|
};
|
|
}
|
|
);
|
|
}
|
|
|
|
export default connect(createMapStateToProps)(ArtistIndexPosters);
|