25 lines
548 B
JavaScript
Raw Normal View History

2025-04-02 17:47:30 -05:00
import React, { useEffect } from 'react';
import { nip19 } from 'nostr-tools';
import appConfig from '@/config/appConfig';
2024-04-22 19:09:46 -05:00
const ZapForm = ({ event }) => {
2025-04-02 17:47:30 -05:00
const nAddress = nip19.naddrEncode({
kind: event?.kind,
pubkey: event?.pubkey,
identifier: event.d,
relays: appConfig.defaultRelayUrls,
});
2024-04-22 19:09:46 -05:00
2025-04-02 17:47:30 -05:00
return (
<iframe
src={`https://zapper.nostrapps.org/zap?id=${nAddress}`}
width="100%"
height="100%"
style={{ border: 'none' }}
title="zapper app"
></iframe>
);
2024-04-22 19:09:46 -05:00
};
export default ZapForm;