mirror of
https://github.com/LBRYFoundation/lbry-desktop.git
synced 2025-09-01 17:55:11 +00:00
Add extra URLs
Can add more based on content type later?
This commit is contained in:
parent
419b3890cd
commit
8c8989bc03
1 changed files with 4 additions and 3 deletions
|
@ -4,7 +4,7 @@ import React from 'react';
|
||||||
import Button from 'component/button';
|
import Button from 'component/button';
|
||||||
import CopyableText from 'component/copyableText';
|
import CopyableText from 'component/copyableText';
|
||||||
import EmbedTextArea from 'component/embedTextArea';
|
import EmbedTextArea from 'component/embedTextArea';
|
||||||
import { generateDirectUrl } from 'util/lbrytv';
|
import { generateDownloadUrl } from 'util/lbrytv';
|
||||||
|
|
||||||
const IOS = !!navigator.platform && /iPad|iPhone|iPod/.test(navigator.platform);
|
const IOS = !!navigator.platform && /iPad|iPhone|iPod/.test(navigator.platform);
|
||||||
|
|
||||||
|
@ -49,7 +49,7 @@ class SocialShare extends React.PureComponent<Props, State> {
|
||||||
const encodedLbryURL: string = `${OPEN_URL}${encodeURIComponent(lbryWebUrl)}`;
|
const encodedLbryURL: string = `${OPEN_URL}${encodeURIComponent(lbryWebUrl)}`;
|
||||||
const referralParam: string = referralCode && rewardsApproved ? `?r=${referralCode}` : '';
|
const referralParam: string = referralCode && rewardsApproved ? `?r=${referralCode}` : '';
|
||||||
const lbryURL: string = `${OPEN_URL}${lbryWebUrl}${referralParam}`;
|
const lbryURL: string = `${OPEN_URL}${lbryWebUrl}${referralParam}`;
|
||||||
const directUrl = generateDirectUrl(name, claimId);
|
const downloadUrl = `${OPEN_URL}${generateDownloadUrl(name, claimId)}`;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<React.Fragment>
|
<React.Fragment>
|
||||||
|
@ -114,7 +114,8 @@ class SocialShare extends React.PureComponent<Props, State> {
|
||||||
{showEmbed && <EmbedTextArea label={__('Embedded')} claim={claim} />}
|
{showEmbed && <EmbedTextArea label={__('Embedded')} claim={claim} />}
|
||||||
{showExtra && (
|
{showExtra && (
|
||||||
<div className="section">
|
<div className="section">
|
||||||
<CopyableText label={__('Direct Link')} copyable={directUrl} />
|
<CopyableText label={__('LBRY URL')} copyable={lbryUrl} />
|
||||||
|
<CopyableText label={__('Download')} copyable={downloadUrl} />
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</React.Fragment>
|
</React.Fragment>
|
||||||
|
|
Loading…
Add table
Reference in a new issue