Skip to content

Commit

Permalink
Remove references to cross-chain transfer feature
Browse files Browse the repository at this point in the history
  • Loading branch information
devin-ai-integration[bot] committed Aug 11, 2024
1 parent 3d30235 commit 63d99fa
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 85 deletions.
35 changes: 14 additions & 21 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ MissionEnrolment2024 showcases the potential of blockchain technology in creatin
- **Onchain Attestations**: Creates immutable records of mission enrolment using the Ethereum Attestation Service (EAS).
- **ENS Integration**: Supports Ethereum Name Service for user-friendly addressing.
- **ETHGlobal POAPs Retrieval**: Verifies attendance at ETHGlobal events through Proof of Attendance Protocol tokens.
- **NFT Migration**: Enables cross-chain transfers of POAPs using Chainlink CCIP (Cross-Chain Interoperability Protocol).
- **Interactive Single-Page Application**: Offers a streamlined user experience with stage-based components.
- **Recent Attestations**: Displays a list of recent attestations for public viewing.
- **POAP Integration**: Prepared integration points for future POAP-related features.
Expand All @@ -25,11 +24,10 @@ MissionEnrolment2024 showcases the potential of blockchain technology in creatin

- **Frontend**: Next.js, React
- **State Management**: React Query with singleton QueryClient instance
- **Blockchain Integration**: Ethereum, EAS (Ethereum Attestation Service), Chainlink CCIP
- **Blockchain Integration**: Ethereum, EAS (Ethereum Attestation Service)
- **Wallet Connection**: Wagmi
- **Identity**: ENS (Ethereum Name Service)
- **Event Verification**: POAP (Proof of Attendance Protocol)
- **Cross-Chain Communication**: Chainlink CCIP (Cross-Chain Interoperability Protocol)
- **Styling**: Tailwind CSS
- **Type Checking**: TypeScript
- **Development Tools**: ESLint for code quality
Expand Down Expand Up @@ -83,23 +81,19 @@ MissionEnrolment2024 showcases the potential of blockchain technology in creatin

MissionEnrolment2024 provides a streamlined single-page application flow for mission enrolment, verification, and NFT migration:

1. Connect your Ethereum wallet to the application using the "Connect Wallet" button.
2. Navigate through the mission enrolment stages:
a. Enter your ENS (Ethereum Name Service) name or Ethereum address for identity verification.
b. The application will automatically retrieve and verify your ETHGlobal POAPs to confirm event attendance.
c. Review the details of your mission participation, including verified events and achievements.
3. Transfer your POAP using Chainlink CCIP:
a. Initiate the transfer of your ETHGlobal POAP from Gnosis chain to either Base or Optimism.
b. Confirm the transfer transaction using your connected wallet.
c. Wait for the cross-chain transfer to complete, ensuring data integrity and security.
4. Create an onchain attestation for your mission enrolment:
a. Click the "Create Attestation" button to initiate the process.
b. Sign the attestation transaction using your connected wallet.
c. Wait for the transaction to be confirmed on the Ethereum network.
5. Once confirmed, view your attestation details, which are now immutably recorded on the blockchain.
6. Explore the "Recent Attestations" section to see other verified mission enrolments and the growing community of participants.

This streamlined process ensures a transparent and verifiable record of your mission enrolment, leveraging the security and immutability of blockchain technology. The Chainlink CCIP integration allows for secure cross-chain POAP transfers, enhancing the interoperability of the application. The single-page application design provides a seamless user experience throughout the entire enrolment, verification, and cross-chain transfer process.
1. Connect your Ethereum wallet to the application using the "Connect Wallet" button.
2. Navigate through the mission enrolment stages:
a. Enter your ENS (Ethereum Name Service) name or Ethereum address for identity verification.
b. The application will automatically retrieve and verify your ETHGlobal POAPs to confirm event attendance.
c. Review the details of your mission participation, including verified events and achievements.
3. Create an onchain attestation for your mission enrolment:
a. Click the "Create Attestation" button to initiate the process.
b. Sign the attestation transaction using your connected wallet.
c. Wait for the transaction to be confirmed on the Ethereum network.
4. Once confirmed, view your attestation details, which are now immutably recorded on the blockchain.
5. Explore the "Recent Attestations" section to see other verified mission enrolments and the growing community of participants.

This streamlined process ensures a transparent and verifiable record of your mission enrolment, leveraging the security and immutability of blockchain technology. The single-page application design provides a seamless user experience throughout the entire enrolment and verification process.

## Disclaimer

Expand All @@ -111,6 +105,5 @@ While the attestations are immutably recorded on the blockchain, users should ve
- [Ethereum Attestation Service Documentation](https://docs.attest.sh/)
- [ENS Documentation](https://docs.ens.domains/)
- [POAP Documentation](https://documentation.poap.tech/)
- [Chainlink CCIP Documentation](https://docs.chain.link/ccip)

For more detailed information on each component, please refer to the respective documentation.
67 changes: 3 additions & 64 deletions components/CrossChainTransfer.tsx
Original file line number Diff line number Diff line change
@@ -1,71 +1,10 @@
import React, { useState } from "react";
import { useChainId, useSwitchChain } from "wagmi";

// Note: This is a simplified implementation. In a real-world scenario,
// you would need to integrate with actual CCIP contracts and handle
// the complexities of cross-chain transfers.

const CrossChainTransfer: React.FC<{ onTransferComplete: () => void }> = ({ onTransferComplete }) => {
const chainId = useChainId();
const { switchChain } = useSwitchChain();
const [isTransferring, setIsTransferring] = useState(false);
const [transferStatus, setTransferStatus] = useState<string | null>(null);

const gnosisChainId = 100; // Gnosis Chain ID
const optimismChainId = 10; // Optimism (OP) Chain ID

const handleTransfer = async () => {
setIsTransferring(true);
setTransferStatus("Initiating transfer...");

try {
// Step 1: Ensure user is on Gnosis Chain
if (chainId !== gnosisChainId) {
await switchChain({ chainId: gnosisChainId });
setTransferStatus("Switched to Gnosis Chain");
}

// Step 2: Simulate POAP transfer from Gnosis to OP Chain
await new Promise(resolve => setTimeout(resolve, 2000)); // Simulating blockchain interaction
setTransferStatus("POAP transferred to OP Chain");

// Step 3: Switch to OP Chain to verify transfer
await switchChain({ chainId: optimismChainId });
setTransferStatus("Switched to OP Chain");

// Step 4: Simulate verification on OP Chain
await new Promise(resolve => setTimeout(resolve, 2000)); // Simulating blockchain interaction
setTransferStatus("Transfer verified on OP Chain");

// Step 5: Transfer back to Gnosis Chain
await switchChain({ chainId: gnosisChainId });
setTransferStatus("Transferring back to Gnosis Chain");

// Step 6: Final verification
await new Promise(resolve => setTimeout(resolve, 2000)); // Simulating blockchain interaction
setTransferStatus("Transfer completed successfully");

onTransferComplete();
} catch (error) {
console.error("Transfer error:", error);
setTransferStatus("Transfer failed. Please try again.");
} finally {
setIsTransferring(false);
}
};
import React from "react";

const CrossChainTransfer: React.FC = () => {
return (
<div className="p-4 bg-white shadow rounded-lg">
<h2 className="text-2xl font-bold mb-4">Cross-Chain Transfer</h2>
<p className="mb-4">Transfer your ETHGlobal POAP between Gnosis Chain and OP Chain:</p>
<button
onClick={handleTransfer}
disabled={isTransferring}
className="bg-blue-500 text-white p-2 rounded hover:bg-blue-600 disabled:bg-gray-300"
>
{isTransferring ? "Transferring..." : "Start Transfer"}
</button>
{transferStatus && <p className="mt-4 text-green-500">{transferStatus}</p>}
<p className="mb-4">Cross-chain transfer functionality has been removed.</p>
</div>
);
};
Expand Down

0 comments on commit 63d99fa

Please sign in to comment.