mirror of
https://github.com/LBRYFoundation/lbry-desktop.git
synced 2025-08-27 23:41:29 +00:00
Naomi comment websockets increase slow mode time to 5 seconds fix to prevent duplicate comments update livestream details fix channel pin electron boom fix rebase prune unused icons updating meme updating meme update livestream for naomi fix rebase DigitalCashNetwork remove electroboom pin Slavguns Joel So he can edit his claims add streamTypes param to claimTilesDiscover so following section can search for all types of content fix typo update meme fixes publish page fixes pending fix notifications fix comments finally fix claim preview no mature for simplesite Revert "no mature for simplesite" This reverts commit 9f89242d85e0cacf44cbf0a683bebbe50840c466. fix livestream preview click no mature on simple site try fixing invite page crash probably needs more changes.
59 lines
1.5 KiB
JavaScript
59 lines
1.5 KiB
JavaScript
// @flow
|
|
import * as React from 'react';
|
|
import Button from 'component/button';
|
|
import { buildURI } from 'lbry-redux';
|
|
import I18nMessage from 'component/i18nMessage';
|
|
|
|
type Props = {
|
|
uri: ?string,
|
|
myClaimForUri: ?StreamClaim,
|
|
isStillEditing: boolean,
|
|
onEditMyClaim: (any, string) => void,
|
|
};
|
|
|
|
function NameHelpText(props: Props) {
|
|
const { uri, myClaimForUri, onEditMyClaim, isStillEditing } = props;
|
|
let nameHelpText;
|
|
|
|
if (isStillEditing) {
|
|
nameHelpText = __('You are currently editing this claim.');
|
|
} else if (uri && myClaimForUri) {
|
|
const editUri = buildURI({
|
|
streamName: myClaimForUri.name,
|
|
streamClaimId: myClaimForUri.claim_id,
|
|
});
|
|
|
|
nameHelpText = (
|
|
<React.Fragment>
|
|
<div className="error__text">
|
|
<I18nMessage
|
|
tokens={{
|
|
existing_uri: (
|
|
<u>
|
|
<em>{uri}</em>
|
|
</u>
|
|
),
|
|
}}
|
|
>
|
|
You already have a claim at %existing_uri%. Publishing will update (overwrite) your existing claim.
|
|
</I18nMessage>
|
|
</div>
|
|
<Button
|
|
button="link"
|
|
label={__('Edit existing claim instead')}
|
|
onClick={() => onEditMyClaim(myClaimForUri, editUri)}
|
|
/>
|
|
</React.Fragment>
|
|
);
|
|
}
|
|
|
|
return (
|
|
<React.Fragment>
|
|
{nameHelpText || (
|
|
<span>{__('Create a URL for this content. Simpler names are easier to find and remember.')}</span>
|
|
)}
|
|
</React.Fragment>
|
|
);
|
|
}
|
|
|
|
export default NameHelpText;
|