forked from Kieran/void.cat
Improve lightning paywall display
This commit is contained in:
parent
a8541ec700
commit
5ef56b7c77
7
VoidCat/spa/src/FilePaywall.css
Normal file
7
VoidCat/spa/src/FilePaywall.css
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
.paywall {
|
||||||
|
text-align: center;
|
||||||
|
border: 1px solid lightgreen;
|
||||||
|
padding: 10px;
|
||||||
|
margin: 10px;
|
||||||
|
border-radius: 10px;
|
||||||
|
}
|
@ -1,3 +1,4 @@
|
|||||||
|
import "./FilePaywall.css";
|
||||||
import {FormatCurrency} from "./Util";
|
import {FormatCurrency} from "./Util";
|
||||||
import {PaywallServices} from "./Const";
|
import {PaywallServices} from "./Const";
|
||||||
import {useState} from "react";
|
import {useState} from "react";
|
||||||
@ -35,9 +36,10 @@ export function FilePaywall(props) {
|
|||||||
if (!order) {
|
if (!order) {
|
||||||
return (
|
return (
|
||||||
<div className="paywall">
|
<div className="paywall">
|
||||||
<h3>You must pay {FormatCurrency(pw.cost.amount, pw.cost.currency)} to view this
|
<h3>
|
||||||
file.</h3>
|
You must pay {FormatCurrency(pw.cost.amount, pw.cost.currency)} to view this file.
|
||||||
<button onClick={fetchOrder}>Pay</button>
|
</h3>
|
||||||
|
<div className="btn" onClick={fetchOrder}>Pay</div>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
background-size: cover;
|
background-size: cover;
|
||||||
background-position: center;
|
background-position: center;
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
|
border: 2px solid;
|
||||||
}
|
}
|
||||||
|
|
||||||
.small-profile .name {
|
.small-profile .name {
|
||||||
|
@ -36,6 +36,7 @@ export function LightningPaywall(props) {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="lightning-invoice" onClick={openInvoice}>
|
<div className="lightning-invoice" onClick={openInvoice}>
|
||||||
|
<h1>Pay with Lightning ⚡</h1>
|
||||||
<QRCode
|
<QRCode
|
||||||
value={link}
|
value={link}
|
||||||
size={512}
|
size={512}
|
||||||
|
Loading…
Reference in New Issue
Block a user