Progress, Deck done

This commit is contained in:
mgabdev
2020-12-16 17:29:06 -05:00
parent 8f94ffad9c
commit 04053c0e31
20 changed files with 473 additions and 93 deletions

View File

@@ -3,7 +3,9 @@ import PropTypes from 'prop-types'
import { connect } from 'react-redux'
import { defineMessages, injectIntl } from 'react-intl'
import { closePopover } from '../../actions/popover'
import { openModal } from '../../actions/modal'
import { meUsername } from '../../initial_state'
import { MODAL_DISPLAY_OPTIONS } from '../../constants'
import PopoverLayout from './popover_layout'
import List from '../list'
@@ -13,6 +15,11 @@ class NavSettingsPopover extends React.PureComponent {
this.props.onClosePopover()
}
handleOpenDisplayOptions = () => {
this.props.onOpenDisplayOptions()
this.handleOnClosePopover()
}
render() {
const { intl, isXS } = this.props
@@ -29,6 +36,10 @@ class NavSettingsPopover extends React.PureComponent {
to: `/${meUsername}`,
onClick: this.handleOnClosePopover,
},
{
title: 'Display options',
onClick: this.handleOpenDisplayOptions,
},
{
title: intl.formatMessage(messages.help),
href: 'https://help.gab.com',
@@ -60,6 +71,9 @@ const mapDispatchToProps = (dispatch) => ({
onClosePopover() {
dispatch(closePopover())
},
onOpenDisplayOptions() {
dispatch(openModal(MODAL_DISPLAY_OPTIONS))
}
})
NavSettingsPopover.propTypes = {