Merge pull request #295 from lbryio/optimizeState
save optimize check state to allow page navigation
This commit is contained in:
commit
aa6830d9f3
2 changed files with 15 additions and 2 deletions
7
dist/bundle.es.js
vendored
7
dist/bundle.es.js
vendored
|
@ -5497,6 +5497,9 @@ function _objectWithoutProperties$3(obj, keys) { var target = {}; for (var i in
|
|||
const defaultState$6 = {
|
||||
editingURI: undefined,
|
||||
filePath: undefined,
|
||||
fileDur: 0,
|
||||
fileSize: 0,
|
||||
fileVid: false,
|
||||
contentIsFree: true,
|
||||
fee: {
|
||||
amount: 1,
|
||||
|
@ -5530,7 +5533,9 @@ const publishReducer = handleActions({
|
|||
const { data } = action;
|
||||
return _extends$e({}, state, data);
|
||||
},
|
||||
[CLEAR_PUBLISH]: state => _extends$e({}, defaultState$6, { bid: state.bid, optimize: state.optimize
|
||||
[CLEAR_PUBLISH]: state => _extends$e({}, defaultState$6, {
|
||||
bid: state.bid,
|
||||
optimize: state.optimize
|
||||
}),
|
||||
[PUBLISH_START]: state => _extends$e({}, state, {
|
||||
publishing: true,
|
||||
|
|
|
@ -9,6 +9,9 @@ type PublishState = {
|
|||
editingURI: ?string,
|
||||
filePath: ?string,
|
||||
contentIsFree: boolean,
|
||||
fileDur: number,
|
||||
fileSize: number,
|
||||
fileVid: boolean,
|
||||
fee: {
|
||||
amount: number,
|
||||
currency: string,
|
||||
|
@ -34,6 +37,9 @@ type PublishState = {
|
|||
const defaultState: PublishState = {
|
||||
editingURI: undefined,
|
||||
filePath: undefined,
|
||||
fileDur: 0,
|
||||
fileSize: 0,
|
||||
fileVid: false,
|
||||
contentIsFree: true,
|
||||
fee: {
|
||||
amount: 1,
|
||||
|
@ -72,7 +78,9 @@ export const publishReducer = handleActions(
|
|||
};
|
||||
},
|
||||
[ACTIONS.CLEAR_PUBLISH]: (state: PublishState): PublishState => ({
|
||||
...defaultState, bid: state.bid, optimize: state.optimize,
|
||||
...defaultState,
|
||||
bid: state.bid,
|
||||
optimize: state.optimize,
|
||||
}),
|
||||
[ACTIONS.PUBLISH_START]: (state: PublishState): PublishState => ({
|
||||
...state,
|
||||
|
|
Loading…
Add table
Reference in a new issue