mirror of
https://github.com/comit-network/xmr-btc-swap.git
synced 2025-05-12 03:35:06 -04:00
feat(gui): Dedicated react component for truncating swap ids, peer ids, ...
This commit is contained in:
parent
c486ca5de9
commit
5e87be8a8b
8 changed files with 32 additions and 10 deletions
|
@ -11,6 +11,7 @@ import KeyboardArrowDownIcon from "@material-ui/icons/KeyboardArrowDown";
|
|||
import KeyboardArrowUpIcon from "@material-ui/icons/KeyboardArrowUp";
|
||||
import { GetSwapInfoResponse } from "models/tauriModel";
|
||||
import { useState } from "react";
|
||||
import TruncatedText from "renderer/components/other/TruncatedText";
|
||||
import { PiconeroAmount, SatsAmount } from "../../../other/Units";
|
||||
import HistoryRowActions from "./HistoryRowActions";
|
||||
import HistoryRowExpanded from "./HistoryRowExpanded";
|
||||
|
@ -52,7 +53,9 @@ export default function HistoryRow(swap: GetSwapInfoResponse) {
|
|||
{expanded ? <KeyboardArrowUpIcon /> : <KeyboardArrowDownIcon />}
|
||||
</IconButton>
|
||||
</TableCell>
|
||||
<TableCell>{swap.swap_id}</TableCell>
|
||||
<TableCell>
|
||||
<TruncatedText>{swap.swap_id}</TruncatedText>
|
||||
</TableCell>
|
||||
<TableCell>
|
||||
<AmountTransfer
|
||||
xmrAmount={swap.xmr_amount}
|
||||
|
|
|
@ -9,6 +9,7 @@ import {
|
|||
} from "@material-ui/core";
|
||||
import { ButtonProps } from "@material-ui/core/Button/Button";
|
||||
import { BobStateName, GetSwapInfoResponseExt } from "models/tauriModelExt";
|
||||
import TruncatedText from "renderer/components/other/TruncatedText";
|
||||
import PromiseInvokeButton from "renderer/components/PromiseInvokeButton";
|
||||
import { getMoneroRecoveryKeys } from "renderer/rpc";
|
||||
import { store } from "renderer/store/storeRenderer";
|
||||
|
@ -38,7 +39,9 @@ function MoneroRecoveryKeysDialog({
|
|||
return (
|
||||
<Dialog open onClose={onClose} maxWidth="sm" fullWidth>
|
||||
<DialogHeader
|
||||
title={`Recovery Keys for swap ${swap_id.substring(0, 5)}...`}
|
||||
title=<>
|
||||
Recovery Keys for swap <TruncatedText>{swap_id}</TruncatedText>
|
||||
</>
|
||||
/>
|
||||
<DialogContent>
|
||||
<DialogContentText>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue