Finished updating the reformatting of propTypes and set redux, intl functions to end of component

• Finished:
- updating the reformatting of propTypes and set redux, intl functions to end of component

• Removed:
- Gif implementation
This commit is contained in:
mgabdev
2020-08-18 19:22:15 -05:00
parent e21a6ff897
commit 99982c0391
102 changed files with 2540 additions and 3285 deletions

View File

@@ -12,25 +12,8 @@ import {
GroupInfoPanel
} from '../features/ui/util/async_components'
const mapStateToProps = (state, { params }) => {
const groupId = isObject(params) ? params['id'] : null
const group = state.getIn(['groups', groupId])
return { group }
}
export default
@connect(mapStateToProps)
class GroupAbout extends ImmutablePureComponent {
static contextTypes = {
router: PropTypes.object
}
static propTypes = {
group: ImmutablePropTypes.map,
}
render() {
const { group } = this.props
@@ -56,3 +39,16 @@ class GroupAbout extends ImmutablePureComponent {
}
}
const mapStateToProps = (state, { params }) => {
const groupId = isObject(params) ? params['id'] : null
const group = state.getIn(['groups', groupId])
return { group }
}
GroupAbout.propTypes = {
group: ImmutablePropTypes.map,
}
export default connect(mapStateToProps)(GroupAbout)