cleanup
This commit is contained in:
parent
dfcb80ac56
commit
c9ff94d061
6 changed files with 22 additions and 18 deletions
|
@ -38,7 +38,7 @@ function ChannelContent(props: Props) {
|
||||||
{hasContent && <ClaimList header={false} uris={claimsInChannel.map(claim => claim.permanent_url)} />}
|
{hasContent && <ClaimList header={false} uris={claimsInChannel.map(claim => claim.permanent_url)} />}
|
||||||
|
|
||||||
<Paginate
|
<Paginate
|
||||||
onPageChange={page => fetchClaims(uri, page)}
|
onPageChange={page => console.log('fetch') || fetchClaims(uri, page)}
|
||||||
totalPages={totalPages}
|
totalPages={totalPages}
|
||||||
loading={fetching && !hasContent}
|
loading={fetching && !hasContent}
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
// @flow
|
// @flow
|
||||||
import * as React from 'react';
|
import * as React from 'react';
|
||||||
import Button from 'component/button';
|
import Button from 'component/button';
|
||||||
|
import cookie from 'cookie';
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
cancelButton: React.Node,
|
|
||||||
email: string,
|
email: string,
|
||||||
resendVerificationEmail: string => void,
|
resendVerificationEmail: string => void,
|
||||||
checkEmailVerified: () => void,
|
checkEmailVerified: () => void,
|
||||||
|
@ -47,7 +47,19 @@ class UserEmailVerify extends React.PureComponent<Props> {
|
||||||
emailVerifyCheckInterval: ?IntervalID;
|
emailVerifyCheckInterval: ?IntervalID;
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
const { cancelButton, email } = this.props;
|
const { email } = this.props;
|
||||||
|
|
||||||
|
// Below is duplicated in UserEmail
|
||||||
|
// This should just be a UserEmailResetButton component
|
||||||
|
const buttonProps = IS_WEB
|
||||||
|
? {
|
||||||
|
onClick: () => {
|
||||||
|
clearInterval(this.emailVerifyCheckInterval);
|
||||||
|
document.cookie = cookie.serialize('auth_token', '');
|
||||||
|
window.location.reload();
|
||||||
|
},
|
||||||
|
}
|
||||||
|
: { href: 'https://lbry.com/faq/how-to-change-email' };
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<React.Fragment>
|
<React.Fragment>
|
||||||
|
@ -67,7 +79,8 @@ class UserEmailVerify extends React.PureComponent<Props> {
|
||||||
label={__('Resend verification email')}
|
label={__('Resend verification email')}
|
||||||
onClick={this.handleResendVerificationEmail}
|
onClick={this.handleResendVerificationEmail}
|
||||||
/>
|
/>
|
||||||
{cancelButton}
|
|
||||||
|
<Button button="link" label={__('Reset')} {...buttonProps} />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<p className="help">
|
<p className="help">
|
||||||
|
|
|
@ -60,6 +60,7 @@ function ChannelPage(props: Props) {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Page>
|
<Page>
|
||||||
|
{window.location.href}
|
||||||
<div className="card">
|
<div className="card">
|
||||||
<header className="channel-cover">
|
<header className="channel-cover">
|
||||||
{!editing && cover && <img className="channel-cover__custom" src={cover} />}
|
{!editing && cover && <img className="channel-cover__custom" src={cover} />}
|
||||||
|
|
|
@ -232,7 +232,6 @@ export const doPublish = () => (dispatch: Dispatch, getState: () => {}) => {
|
||||||
contentIsFree,
|
contentIsFree,
|
||||||
fee,
|
fee,
|
||||||
uri,
|
uri,
|
||||||
nsfw,
|
|
||||||
tags,
|
tags,
|
||||||
locations,
|
locations,
|
||||||
} = publishData;
|
} = publishData;
|
||||||
|
@ -287,17 +286,6 @@ export const doPublish = () => (dispatch: Dispatch, getState: () => {}) => {
|
||||||
publishPayload.release_time = Number(myClaimForUri.value.release_time);
|
publishPayload.release_time = Number(myClaimForUri.value.release_time);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (nsfw) {
|
|
||||||
if (!publishPayload.tags.includes('mature')) {
|
|
||||||
publishPayload.tags.push('mature');
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
const indexToRemove = publishPayload.tags.indexOf('mature');
|
|
||||||
if (indexToRemove > -1) {
|
|
||||||
publishPayload.tags.splice(indexToRemove, 1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (channelId) {
|
if (channelId) {
|
||||||
publishPayload.channel_id = channelId;
|
publishPayload.channel_id = channelId;
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,6 +11,8 @@
|
||||||
max-width: 1200px;
|
max-width: 1200px;
|
||||||
margin-left: auto;
|
margin-left: auto;
|
||||||
margin-right: auto;
|
margin-right: auto;
|
||||||
|
padding-left: var(--spacing-large);
|
||||||
|
padding-right: var(--spacing-large);
|
||||||
padding-bottom: var(--spacing-main-padding);
|
padding-bottom: var(--spacing-main-padding);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -6653,9 +6653,9 @@ lazy-val@^1.0.3, lazy-val@^1.0.4:
|
||||||
yargs "^13.2.2"
|
yargs "^13.2.2"
|
||||||
zstd-codec "^0.1.1"
|
zstd-codec "^0.1.1"
|
||||||
|
|
||||||
lbry-redux@lbryio/lbry-redux#122acf2266f6ef554d797e107fd06fb02bccd750:
|
lbry-redux@lbryio/lbry-redux#85ade7e57ce0bc4195524fa2c3055aa8cd986af8:
|
||||||
version "0.0.1"
|
version "0.0.1"
|
||||||
resolved "https://codeload.github.com/lbryio/lbry-redux/tar.gz/122acf2266f6ef554d797e107fd06fb02bccd750"
|
resolved "https://codeload.github.com/lbryio/lbry-redux/tar.gz/85ade7e57ce0bc4195524fa2c3055aa8cd986af8"
|
||||||
dependencies:
|
dependencies:
|
||||||
proxy-polyfill "0.1.6"
|
proxy-polyfill "0.1.6"
|
||||||
reselect "^3.0.0"
|
reselect "^3.0.0"
|
||||||
|
|
Loading…
Add table
Reference in a new issue