diff --git a/ui/component/fileActions/index.js b/ui/component/fileActions/index.js index 9593f5db7..7a2f5e48d 100644 --- a/ui/component/fileActions/index.js +++ b/ui/component/fileActions/index.js @@ -5,6 +5,7 @@ import { makeSelectClaimForUri, doPrepareEdit, selectMyChannelClaims, + makeSelectClaimIsStreamPlaceholder, } from 'lbry-redux'; import { makeSelectCostInfoForUri } from 'lbryinc'; import { doSetPlayingUri } from 'redux/actions/content'; @@ -21,6 +22,7 @@ const select = (state, props) => ({ renderMode: makeSelectFileRenderModeForUri(props.uri)(state), costInfo: makeSelectCostInfoForUri(props.uri)(state), myChannels: selectMyChannelClaims(state), + isLivestreamClaim: makeSelectClaimIsStreamPlaceholder(props.uri)(state), }); const perform = (dispatch) => ({ diff --git a/ui/component/fileActions/view.jsx b/ui/component/fileActions/view.jsx index 3a90aac4a..59a33725e 100644 --- a/ui/component/fileActions/view.jsx +++ b/ui/component/fileActions/view.jsx @@ -25,6 +25,7 @@ type Props = { myChannels: ?Array, doToast: ({ message: string }) => void, clearPlayingUri: () => void, + isLivestreamClaim: boolean, }; function FileActions(props: Props) { @@ -40,6 +41,7 @@ function FileActions(props: Props) { myChannels, clearPlayingUri, doToast, + isLivestreamClaim, } = props; const { push, @@ -112,7 +114,18 @@ function FileActions(props: Props) { className="button--file-action" icon={ICONS.EDIT} label={__('Edit')} - navigate="/$/upload" + navigate="/$/upload?type=livestream" + onClick={() => { + prepareEdit(claim, editUri, fileInfo); + }} + /> + )} + {claimIsMine && isLivestreamClaim && ( +