merge cleanup

This commit is contained in:
Jeremy Kauffman 2017-09-07 09:38:44 -04:00
parent 8b47b8e71d
commit ff12ff3d36
8 changed files with 19 additions and 25 deletions

View file

@ -9,7 +9,7 @@ import {
} from "selectors/app";
import { doFetchDaemonSettings } from "actions/settings";
import { doAuthenticate } from "actions/user";
import { doFileList } from "actions/file_info";
import { doFetchFileInfosAndPublishedClaims } from "actions/file_info";
const { remote, ipcRenderer, shell } = require("electron");
const path = require("path");
@ -177,7 +177,7 @@ export function doDaemonReady() {
dispatch(doAuthenticate());
dispatch({ type: types.DAEMON_READY });
dispatch(doFetchDaemonSettings());
dispatch(doFileList());
dispatch(doFetchFileInfosAndPublishedClaims());
};
}

View file

@ -155,9 +155,3 @@ export function doFetchFileInfosAndPublishedClaims() {
if (!isFetchingFileInfo) dispatch(doFileList());
};
}
export function doEditClaim(fileInfo) {
return function(dispatch, getState) {
dispatch(doNavigate("/publish", fileInfo));
};
}

View file

@ -10,9 +10,13 @@ import { makeSelectIsAvailableForUri } from "selectors/availability";
import { makeSelectCostInfoForUri } from "selectors/cost_info";
import { doCloseModal, doOpenModal } from "actions/app";
import { doFetchAvailability } from "actions/availability";
import { doOpenFileInShell, doOpenFileInFolder, doEditClaim, } from "actions/file_info";
import { makeSelectClaimForUri,makeSelectClaimForUriIsMine } from "selectors/claims";
import { doOpenFileInShell, doOpenFileInFolder } from "actions/file_info";
import {
makeSelectClaimForUri,
makeSelectClaimForUriIsMine,
} from "selectors/claims";
import { doPurchaseUri, doLoadVideo, doStartDownload } from "actions/content";
import { doNavigate } from "actions/navigation";
import FileActions from "./view";
const makeSelect = () => {
@ -49,7 +53,7 @@ const perform = dispatch => ({
startDownload: uri => dispatch(doPurchaseUri(uri, "affirmPurchase")),
loadVideo: uri => dispatch(doLoadVideo(uri)),
restartDownload: (uri, outpoint) => dispatch(doStartDownload(uri, outpoint)),
editClaim: fileInfo => dispatch(doEditClaim(fileInfo)),
editClaim: fileInfo => dispatch(doNavigate("/publish", fileInfo)),
});
export default connect(makeSelect, perform)(FileActions);

View file

@ -191,13 +191,13 @@ class FileActions extends React.PureComponent {
label={openInFolderMessage}
/>
{claimIsMine &&
<DropDownMenuItem
key={1}
onClick={() => editClaim({ name, channel })}
label={__("Edit claim")}
/>}
<DropDownMenuItem
key={1}
onClick={() => editClaim({ name, channel })}
label={__("Edit claim")}
/>}
<DropDownMenuItem
key={1}
key={2}
onClick={() => openModal(modals.CONFIRM_FILE_REMOVE)}
label={__("Remove...")}
/>

View file

@ -74,11 +74,6 @@ export class FormRow extends React.PureComponent {
}
getOptions() {
if (!this._field || !this._field.getOptions) {
console.log(this);
console.log(this._field);
console.log(this._field.getOptions);
}
return this._field.getOptions();
}

View file

@ -1,6 +1,7 @@
import React from "react";
import { connect } from "react-redux";
import { doCloseModal, doNavigate } from "actions/app";
import { doCloseModal } from "actions/app";
import { doNavigate } from "actions/navigation";
import ModalInsufficientBalance from "./view";
const select = state => ({});

View file

@ -259,7 +259,6 @@ class SettingsPage extends React.PureComponent {
<h3>{__("Theme")}</h3>
</div>
<div className="card__content">
{console.log(theme)}
<FormField
type="select"
onChange={this.onThemeChange.bind(this)}

View file

@ -134,7 +134,8 @@ input[type="text"].input-copyable {
}
}
.form-field__label--error {
.form-row__label-row .form-field__label--error {
/*the row restriction is to prevent coloring checkboxes and radio labels*/
color: var(--color-error);
}