Common components refactor #1
2409
build/index.js
40
src/index.js
|
@ -1,14 +1,26 @@
|
|||
// common
|
||||
import Lbry from 'lbry';
|
||||
import LbryApi from 'lbryapi';
|
||||
import Lbryuri from 'lbryuri';
|
||||
export { Lbry, LbryApi, Lbryuri };
|
||||
export { Lbry, Lbryuri };
|
||||
|
||||
// actions
|
||||
export { doOpenModal, doCloseModal, doShowSnackBar } from 'redux/actions/app';
|
||||
export { doFetchClaimListMine, doAbandonClaim, doResolveUris, doResolveUri } from 'redux/actions/claims';
|
||||
export { doFetchCostInfoForUri } from 'redux/actions/cost_info';
|
||||
export { doFetchFileInfo, doFileList, doFetchFileInfosAndPublishedClaims } from 'redux/actions/file_info';
|
||||
export { doSearch } from 'redux/actions/search';
|
||||
export {
|
||||
doUpdateBalance,
|
||||
doBalanceSubscribe,
|
||||
doFetchTransactions,
|
||||
doFetchBlock,
|
||||
doGetNewAddress,
|
||||
doCheckAddressIsMine,
|
||||
doSendDraftTransaction,
|
||||
doSetDraftTransactionAmount,
|
||||
doSetDraftTransactionAddress,
|
||||
doSendSupport
|
||||
} from 'redux/actions/wallet';
|
||||
|
||||
// reducers
|
||||
export { claimsReducer } from 'redux/reducers/claims';
|
||||
|
@ -54,14 +66,14 @@ export {
|
|||
} from 'redux/selectors/cost_info';
|
||||
|
||||
export {
|
||||
makeSelectFileInfoForUri,
|
||||
makeSelectDownloadingForUri,
|
||||
makeSelectLoadingForUri,
|
||||
selectFileInfosByOutpoint,
|
||||
selectIsFetchingFileList,
|
||||
selectIsFetchingFileListDownloadedOrPublished,
|
||||
makeSelectFileInfoForUri,
|
||||
selectDownloadingByOutpoint,
|
||||
makeSelectDownloadingForUri,
|
||||
selectUrisLoading,
|
||||
makeSelectLoadingForUri,
|
||||
selectFileInfosDownloaded,
|
||||
selectDownloadingFileInfos,
|
||||
selectTotalDownloadProgress
|
||||
|
@ -75,3 +87,21 @@ export {
|
|||
selectWunderBarAddress,
|
||||
selectWunderBarIcon
|
||||
} from 'redux/selectors/search';
|
||||
|
||||
export {
|
||||
makeSelectBlockDate,
|
||||
selectBalance,
|
||||
selectTransactionsById,
|
||||
selectTransactionItems,
|
||||
selectRecentTransactions,
|
||||
selectHasTransactions,
|
||||
selectIsFetchingTransactions,
|
||||
selectIsSendingSupport,
|
||||
selectReceiveAddress,
|
||||
selectGettingNewAddress,
|
||||
selectDraftTransaction,
|
||||
selectDraftTransactionAmount,
|
||||
selectDraftTransactionAddress,
|
||||
selectDraftTransactionError,
|
||||
selectBlocks
|
||||
} from 'redux/selectors/wallet';
|
||||
|
|
24
src/redux/actions/app.js
Normal file
|
@ -0,0 +1,24 @@
|
|||
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
import * as ACTIONS from 'constants/action_types';
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
export function doOpenModal(modal, modalProps = {}) {
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
return {
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
type: ACTIONS.OPEN_MODAL,
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
data: {
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
modal,
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
modalProps,
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
},
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
};
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
}
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
export function doCloseModal() {
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
return {
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
type: ACTIONS.CLOSE_MODAL,
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
};
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
}
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
export function doShowSnackBar(data) {
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
return {
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
type: ACTIONS.SHOW_SNACKBAR,
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
data,
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
};
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
||||
}
|
||||
All of these actions should probably be outside of All of these actions should probably be outside of `lbry-redux`, eh?
Did we decide on something like Did we decide on something like `DO_NOTIFY`?
|
All of these actions should probably be outside of
lbry-redux
, eh?