Add download button for terms and conditions PDF #31

Merged
nabarun merged 2 commits from deep-stack/testnet-onboarding-app:sk-UI-enhancements into main 2024-08-11 09:47:19 +00:00
5 changed files with 17 additions and 7 deletions

View File

@ -16,7 +16,12 @@ const TermsAndConditionsDialog: React.FC<TermsDialogProps> = ({ open, onClose })
<TermsAndConditionsBox height='65vh' />
</DialogContent>
<DialogActions>
<Button onClick={onClose} color="primary">
<Button>
<a href="/TermsAndConditions.pdf" download style={{textDecoration: "none", color: "inherit"}}>
Download PDF
</a>
</Button>
<Button onClick={onClose}>
Close
</Button>
</DialogActions>

View File

@ -37,7 +37,12 @@ const LandingPage = () => {
</Typography>
</Box>
<TermsAndConditionsBox height="43vh" onLoad={()=>{setIsDisabled(false);}} />
<Box m={2} display="flex" justifyContent="center">
<Box m={2} display="flex" justifyContent="center" gap={2}>
<Button variant="outlined" color="primary" disabled={isDisabled}>
<a href="/TermsAndConditions.pdf" download style={{textDecoration: "none", color: "inherit"}}>
Download PDF
</a>
</Button>
<Button variant="contained" color="primary" onClick={handleAccept} disabled={isDisabled}>
Accept
</Button>

View File

@ -33,7 +33,7 @@ const OnboardingSuccess = () => {
const fetchParticipants = async () => {
try {
if (!cosmosAddress) {
enqueueSnackbar("Cosmos address is not provided", { variant: "error" });
enqueueSnackbar("Laconic address is not provided", { variant: "error" });
return;
}
const participant: Participant = await registry.getParticipantByAddress(cosmosAddress);
@ -93,7 +93,7 @@ const OnboardingSuccess = () => {
<pre style={{ whiteSpace: "pre-wrap", margin: 0 }}>
{participant && (
<div>
Cosmos Address: {participant.cosmosAddress} <br />
Laconic Address: {participant.cosmosAddress} <br />
Nitro Address: {participant.nitroAddress} <br />
Role: {participant.role} <br />
KYC ID: {participant.kycId} <br />

View File

@ -157,7 +157,7 @@ const SignWithCosmos = () => {
<Typography variant="h5" display={`${isTncAccepted ? "none" : "block"}`}>Please accept terms and conditions to continue</Typography>
<SelectRoleCard handleAccept={() => setIsTncAccepted(true)} handleRoleChange={setRole}/>
<Typography variant="h5">Send transaction to chain</Typography>
<Typography>Cosmos Account:</Typography>
<Typography>Laconic Account:</Typography>
<Card className='mt-1 mb-1'>
<CardContent>
<Grid container spacing={2}>

View File

@ -177,7 +177,7 @@ const Validator = () => {
>
{participant && (
<pre style={{ whiteSpace: "pre-wrap", margin: 0 }}>
Cosmos Address: {participant.cosmosAddress} <br />
Laconic Address: {participant.cosmosAddress} <br />
Nitro Address: {participant.nitroAddress} <br />
Role: {participant.role} <br />
KYC ID: {participant.kycId} <br />