Add copy to generate address
This commit is contained in:
@@ -47,6 +47,8 @@ interface QRCodeProps {
|
||||
dialogTitle?: string;
|
||||
/** Whether to display the raw encoded value as copyable text above the QR code. */
|
||||
showValue?: boolean;
|
||||
/** Optional subtitle to display below the QR code. */
|
||||
subtitle?: React.ReactNode;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -155,6 +157,7 @@ export function QRCode({
|
||||
dialog = false,
|
||||
dialogTitle = 'QR Code',
|
||||
showValue = false,
|
||||
subtitle = null,
|
||||
}: QRCodeProps): React.ReactElement {
|
||||
const { rows, moduleCount } = useMemo(() => {
|
||||
const matrix = generateMatrix(value);
|
||||
@@ -190,6 +193,7 @@ export function QRCode({
|
||||
return (
|
||||
<DialogWrapper title={dialogTitle} borderColor={colors.primary} width={dialogWidth}>
|
||||
{qrContent}
|
||||
{subtitle}
|
||||
</DialogWrapper>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user