A Metamask fork with Infura removed and default networks editable
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.
ciphermask/ui/pages/settings/experimental-tab/experimental-tab.container.js

56 lines
1.7 KiB

import { compose } from 'redux';
import { connect } from 'react-redux';
import { withRouter } from 'react-router-dom';
import {
setUseTokenDetection,
setUseCollectibleDetection,
setOpenSeaEnabled,
setEIP1559V2Enabled,
setTheme,
setCustomNetworkListEnabled,
} from '../../../store/actions';
import {
getUseTokenDetection,
getUseCollectibleDetection,
getOpenSeaEnabled,
getEIP1559V2Enabled,
getTheme,
getIsCustomNetworkListEnabled,
} from '../../../selectors';
import ExperimentalTab from './experimental-tab.component';
const mapStateToProps = (state) => {
return {
useTokenDetection:
getUseTokenDetection(
state,
) /** TODO: Remove during TOKEN_DETECTION_V2 feature flag clean up */,
useCollectibleDetection: getUseCollectibleDetection(state),
openSeaEnabled: getOpenSeaEnabled(state),
eip1559V2Enabled: getEIP1559V2Enabled(state),
theme: getTheme(state),
customNetworkListEnabled: getIsCustomNetworkListEnabled(state),
};
};
const mapDispatchToProps = (dispatch) => {
return {
setUseTokenDetection: (val) =>
dispatch(
setUseTokenDetection(val),
) /** TODO: Remove during TOKEN_DETECTION_V2 feature flag clean up */,
setUseCollectibleDetection: (val) =>
dispatch(setUseCollectibleDetection(val)),
setOpenSeaEnabled: (val) => dispatch(setOpenSeaEnabled(val)),
setEIP1559V2Enabled: (val) => dispatch(setEIP1559V2Enabled(val)),
setTheme: (val) => dispatch(setTheme(val)),
setCustomNetworkListEnabled: (val) =>
dispatch(setCustomNetworkListEnabled(val)),
};
};
export default compose(
withRouter,
connect(mapStateToProps, mapDispatchToProps),
)(ExperimentalTab);