27 lines
786 B
JavaScript
27 lines
786 B
JavaScript
|
import { connect } from 'react-redux';
|
||
|
import {
|
||
|
makeSelectPublishFormValue,
|
||
|
selectMyClaimForUri,
|
||
|
selectIsResolvingPublishUris,
|
||
|
doUpdatePublishForm,
|
||
|
doPrepareEdit,
|
||
|
selectBalance,
|
||
|
} from 'lbry-redux';
|
||
|
import PublishPage from './view';
|
||
|
|
||
|
const select = state => ({
|
||
|
name: makeSelectPublishFormValue('name')(state),
|
||
|
bid: makeSelectPublishFormValue('bid')(state),
|
||
|
uri: makeSelectPublishFormValue('uri')(state),
|
||
|
isResolvingUri: selectIsResolvingPublishUris(state),
|
||
|
balance: selectBalance(state),
|
||
|
myClaimForUri: selectMyClaimForUri(state),
|
||
|
});
|
||
|
|
||
|
const perform = dispatch => ({
|
||
|
updatePublishForm: value => dispatch(doUpdatePublishForm(value)),
|
||
|
prepareEdit: (claim, uri) => dispatch(doPrepareEdit(claim, uri)),
|
||
|
});
|
||
|
|
||
|
export default connect(select, perform)(PublishPage);
|