@@ -298,6 +304,17 @@ class SignatureImporter extends React.Component {
+ {signedPsbt && (
+
+
+
+ )}
)}
{keystore.type === HERMIT &&
- test.interaction().displayer &&
+ test.interaction().workflow[0] === "request" &&
status === PENDING && (
)}
@@ -178,7 +178,7 @@ Derivation: ${test.params.derivation}
onStart={this.start}
onSuccess={this.resolve}
onClear={this.reset}
- startText="Scan Hermit Response"
+ startText="Scan QR Codes From Hermit"
interaction={test.interaction()}
/>
diff --git a/src/components/UnsignedTransaction.jsx b/src/components/UnsignedTransaction.jsx
index 52d05d12..680dfef2 100644
--- a/src/components/UnsignedTransaction.jsx
+++ b/src/components/UnsignedTransaction.jsx
@@ -15,7 +15,7 @@ class UnsignedTransaction extends React.Component {
render = () => {
const { showUnsignedTransaction } = this.state;
- const { unsignedTransaction } = this.props;
+ const { unsignedTransaction, unsignedPSBT } = this.props;
if (showUnsignedTransaction) {
const hex = unsignedTransaction.toHex();
return (
@@ -28,6 +28,13 @@ class UnsignedTransaction extends React.Component {
+ {unsignedPSBT && (
+
+
+ Unsigned PSBT
+
+
+ )}
);
}
@@ -53,11 +60,13 @@ UnsignedTransaction.propTypes = {
unsignedTransaction: PropTypes.shape({
toHex: PropTypes.func,
}).isRequired,
+ unsignedPSBT: PropTypes.string.isRequired,
};
function mapStateToProps(state) {
return {
unsignedTransaction: state.spend.transaction.unsignedTransaction,
+ unsignedPSBT: state.spend.transaction.unsignedPSBT,
};
}
diff --git a/src/components/Wallet/TransactionPreview.jsx b/src/components/Wallet/TransactionPreview.jsx
index f455f2ef..428873de 100644
--- a/src/components/Wallet/TransactionPreview.jsx
+++ b/src/components/Wallet/TransactionPreview.jsx
@@ -14,6 +14,7 @@ import {
TableCell,
Grid,
} from "@mui/material";
+import { downloadFile } from "../../utils";
import UnsignedTransaction from "../UnsignedTransaction";
import { setChangeOutputMultisig as setChangeOutputMultisigAction } from "../../actions/transactionActions";
@@ -152,6 +153,10 @@ class TransactionPreview extends React.Component {
).toString();
};
+ handleDownloadPSBT = (psbtBase64) => {
+ downloadFile(psbtBase64, "transaction.psbt");
+ };
+
render = () => {
const {
feeRate,
@@ -159,6 +164,7 @@ class TransactionPreview extends React.Component {
inputsTotalSats,
editTransaction,
handleSignTransaction,
+ unsignedPSBT,
} = this.props;
return (
@@ -208,6 +214,17 @@ class TransactionPreview extends React.Component {
Sign Transaction
+ {unsignedPSBT && (
+