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.
42 lines
1.1 KiB
42 lines
1.1 KiB
import SecurityTab from './security-tab.component'
|
|
import { compose } from 'recompose'
|
|
import { connect } from 'react-redux'
|
|
import { withRouter } from 'react-router-dom'
|
|
import {
|
|
displayWarning,
|
|
revealSeedConfirmation,
|
|
setFeatureFlag,
|
|
showModal,
|
|
setParticipateInMetaMetrics,
|
|
} from '../../../store/actions'
|
|
|
|
const mapStateToProps = state => {
|
|
const { appState: { warning }, metamask } = state
|
|
const {
|
|
featureFlags: {
|
|
privacyMode,
|
|
} = {},
|
|
participateInMetaMetrics,
|
|
} = metamask
|
|
|
|
return {
|
|
warning,
|
|
privacyMode,
|
|
participateInMetaMetrics,
|
|
}
|
|
}
|
|
|
|
const mapDispatchToProps = dispatch => {
|
|
return {
|
|
displayWarning: warning => dispatch(displayWarning(warning)),
|
|
revealSeedConfirmation: () => dispatch(revealSeedConfirmation()),
|
|
setPrivacyMode: enabled => dispatch(setFeatureFlag('privacyMode', enabled)),
|
|
showClearApprovalModal: () => dispatch(showModal({ name: 'CLEAR_APPROVED_ORIGINS' })),
|
|
setParticipateInMetaMetrics: (val) => dispatch(setParticipateInMetaMetrics(val)),
|
|
}
|
|
}
|
|
|
|
export default compose(
|
|
withRouter,
|
|
connect(mapStateToProps, mapDispatchToProps)
|
|
)(SecurityTab)
|
|
|