mirror of
https://github.com/tlsnotary/explorer.git
synced 2026-01-09 14:58:09 -05:00
refactor: trying to fix proof upload
This commit is contained in:
@@ -6,6 +6,7 @@ import Modal, { ModalContent, ModalHeader, ModalFooter } from '../Modal';
|
||||
import { copyText } from '../../utils';
|
||||
import { useSelectedProof } from '../../store/proofupload';
|
||||
import { uploadFileToIpfs } from '../../store/upload';
|
||||
import { EXPLORER_URL } from '../../utils/constants';
|
||||
import Icon from '../Icon';
|
||||
|
||||
interface ProofDetailsProps {
|
||||
@@ -69,7 +70,7 @@ const ProofDetails: React.FC<ProofDetailsProps> = ({
|
||||
const inputValue =
|
||||
process.env.NODE_ENV === 'development'
|
||||
? `http://localhost:3000/${selectedProof?.ipfsCID ? selectedProof?.ipfsCID : cid}`
|
||||
: `www.tlsnexplorer.com/${selectedProof?.ipfsCID ? selectedProof?.ipfsCID : cid}`;
|
||||
: `${EXPLORER_URL}/${selectedProof?.ipfsCID ? selectedProof?.ipfsCID : cid}`;
|
||||
|
||||
// TODO - Format proof details for redacted data
|
||||
|
||||
|
||||
@@ -122,10 +122,11 @@ function ShareWarningModal(props: {
|
||||
setUploading(false);
|
||||
}
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<Modal className="w-2/3 max-w-[45rem]" onClose={props.onClose}>
|
||||
<ModalHeader>Sharing a Proof</ModalHeader>
|
||||
<ModalContent className="py-2 px-4">
|
||||
<ModalContent className="py-2 px-4 text-center">
|
||||
This will upload your proof to IPFS. Anyone with the url will be able to
|
||||
view your proof. Are you sure you want to proceed?
|
||||
</ModalContent>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
export const EXPLORER_URL =
|
||||
process.env.NODE_ENV === 'development'
|
||||
? 'http://localhost:3000'
|
||||
: 'https://explorer-tlsn.pse.dev';
|
||||
: 'https://explorer.tlsnotary.org/';
|
||||
|
||||
Reference in New Issue
Block a user