-
-
+
diff --git a/examples/hardhat-sol/bun.lockb b/examples/hardhat-sol/bun.lockb
index c304d048..07dc573f 100755
Binary files a/examples/hardhat-sol/bun.lockb and b/examples/hardhat-sol/bun.lockb differ
diff --git a/examples/hardhat-sol/contracts/TestToken.sol b/examples/hardhat-sol/contracts/TestToken.sol
new file mode 100644
index 00000000..d7bb6962
--- /dev/null
+++ b/examples/hardhat-sol/contracts/TestToken.sol
@@ -0,0 +1,16 @@
+// SPDX-License-Identifier: Unlicensed
+pragma solidity ^0.8.19;
+
+import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
+import "@openzeppelin/contracts/access/Ownable.sol";
+import "@openzeppelin/contracts/token/ERC20/extensions/ERC20Burnable.sol";
+
+contract TestToken is ERC20, Ownable, ERC20Burnable {
+ constructor(string memory name, string memory symbol) ERC20(name, symbol) Ownable(msg.sender) {
+ _mint(msg.sender, 100 * 10 ** decimals());
+ }
+
+ function mint(address to, uint256 amount) public onlyOwner {
+ _mint(to, amount);
+ }
+}
\ No newline at end of file
diff --git a/examples/hardhat-sol/contracts/ZeekMessages.sol b/examples/hardhat-sol/contracts/ZeekMessages.sol
new file mode 100644
index 00000000..6ab50be6
--- /dev/null
+++ b/examples/hardhat-sol/contracts/ZeekMessages.sol
@@ -0,0 +1,32 @@
+// SPDX-License-Identifier: MIT
+pragma solidity ^0.8.0;
+
+contract ZeekMessages {
+ string[] private messages;
+
+ // Event to acknowledge a new message
+ event MessageReceived(string);
+
+ constructor() {
+ // Zeek initializes the contract with a welcome message
+ emit MessageReceived("Zeek welcomes you to ZKsync!");
+ }
+
+ function sendMessage(string memory _message) public {
+ messages.push(_message);
+
+ // Acknowledge the message receipt with Zeek's reply
+ emit MessageReceived("ZK is the endgame - Message received!");
+ }
+
+ // Function to count the total messages sent to Zeek
+ function getTotalMessages() public view returns (uint) {
+ return messages.length;
+ }
+
+ // Function to return the last message sent to Zeek
+ function getLastMessage() public view returns (string memory) {
+ require(messages.length > 0, "No messages sent to Zeek yet!");
+ return messages[messages.length - 1];
+ }
+}
diff --git a/examples/hardhat-sol/hardhat.config.ts b/examples/hardhat-sol/hardhat.config.ts
index 8cb3f331..1ed194ff 100644
--- a/examples/hardhat-sol/hardhat.config.ts
+++ b/examples/hardhat-sol/hardhat.config.ts
@@ -45,7 +45,7 @@ const config: HardhatUserConfig = {
},
// ANCHOR_END: zksolc
solidity: {
- version: '0.8.17',
+ version: '0.8.24',
},
};
diff --git a/examples/hardhat-sol/package.json b/examples/hardhat-sol/package.json
index 23842432..6f9fed70 100644
--- a/examples/hardhat-sol/package.json
+++ b/examples/hardhat-sol/package.json
@@ -13,8 +13,8 @@
"devDependencies": {
"@matterlabs/hardhat-zksync": "^1.1.0",
"@matterlabs/zksync-contracts": "^0.6.1",
- "@openzeppelin/contracts": "^4.9.2",
"@nomicfoundation/hardhat-verify": "^2.0.9",
+ "@openzeppelin/contracts": "^5.3.0",
"@types/chai": "^4.3.16",
"@types/mocha": "^10.0.7",
"chai": "^4.5.0",
diff --git a/examples/hardhat-sol/scripts/mint-token.ts b/examples/hardhat-sol/scripts/mint-token.ts
new file mode 100644
index 00000000..63e6bb82
--- /dev/null
+++ b/examples/hardhat-sol/scripts/mint-token.ts
@@ -0,0 +1,47 @@
+/* eslint-disable @typescript-eslint/no-explicit-any */
+import ERC20_ABI from '../artifacts-zk/contracts/TestToken.sol/TestToken.json';
+// ANCHOR: start
+import { ethers } from 'ethers';
+
+// Address of the ERC20 token contract
+const TOKEN_CONTRACT_ADDRESS = '';
+// Wallet that will receive tokens
+const RECEIVER_WALLET = '';
+// Amount of tokens to mint in ETH format, e.g. 1.23
+const TOKEN_AMOUNT = '';
+
+(async () => {
+ try {
+ // ANCHOR_END: start
+ // // Note that the script needs the ABI which is generated from the compilation artifact.
+ // // Make sure contract is compiled and artifacts are generated
+ // const artifactsPath = `browser/contracts/artifacts/TestToken.json`
+ // console.log(artifactsPath)
+
+ // const metadata = JSON.parse(await remix.call('fileManager', 'getFile', artifactsPath))
+
+ // 'web3Provider' is a remix global variable object
+ // const signer = (new ethers.BrowserProvider(web3Provider)).getSigner(0)
+ const metadata = ERC20_ABI;
+
+ const browserWindow = window as any;
+ const signer = await new ethers.BrowserProvider(browserWindow.ethereum).getSigner(0);
+
+ // ANCHOR: end
+ // initialise token contract with address, abi and signer
+ const tokenContract = new ethers.Contract(TOKEN_CONTRACT_ADDRESS, metadata.abi, signer);
+
+ console.log('Minting tokens...');
+ const tx = await tokenContract.mint(RECEIVER_WALLET, ethers.parseEther(TOKEN_AMOUNT));
+ console.log(`Mint transaction is ${tx.hash}`);
+ await tx.wait();
+ console.log('Success!');
+
+ const balance = await tokenContract.balanceOf(RECEIVER_WALLET);
+
+ console.log(`The account ${RECEIVER_WALLET} now has ${balance} tokens`);
+ } catch (e: any) {
+ console.log(e.message);
+ }
+})();
+// ANCHOR_END: end
diff --git a/public/images/101-erc20/atlas-deploy-erc20.png b/public/images/101-erc20/atlas-deploy-erc20.png
deleted file mode 100644
index 5b44ef4a..00000000
Binary files a/public/images/101-erc20/atlas-deploy-erc20.png and /dev/null differ
diff --git a/public/images/101-erc20/atlas-erc20-interact.png b/public/images/101-erc20/atlas-erc20-interact.png
deleted file mode 100644
index a1e251ac..00000000
Binary files a/public/images/101-erc20/atlas-erc20-interact.png and /dev/null differ
diff --git a/public/images/101-erc20/deploy-erc20.gif b/public/images/101-erc20/deploy-erc20.gif
new file mode 100644
index 00000000..eb8002f6
Binary files /dev/null and b/public/images/101-erc20/deploy-erc20.gif differ
diff --git a/public/images/101-erc20/run-script-evm.png b/public/images/101-erc20/run-script-evm.png
new file mode 100644
index 00000000..ca552b89
Binary files /dev/null and b/public/images/101-erc20/run-script-evm.png differ
diff --git a/public/images/101-paymasters/atlas-paymaster-script.png b/public/images/101-paymasters/atlas-paymaster-script.png
deleted file mode 100644
index e6c189f0..00000000
Binary files a/public/images/101-paymasters/atlas-paymaster-script.png and /dev/null differ
diff --git a/public/images/101-quickstart/101-atlas-contract.png b/public/images/101-quickstart/101-atlas-contract.png
deleted file mode 100644
index e61a8642..00000000
Binary files a/public/images/101-quickstart/101-atlas-contract.png and /dev/null differ
diff --git a/public/images/101-quickstart/101-atlas-deployed.png b/public/images/101-quickstart/101-atlas-deployed.png
deleted file mode 100644
index 52202ca7..00000000
Binary files a/public/images/101-quickstart/101-atlas-deployed.png and /dev/null differ
diff --git a/public/images/101-quickstart/deploy.gif b/public/images/101-quickstart/deploy.gif
new file mode 100644
index 00000000..67b6ac0e
Binary files /dev/null and b/public/images/101-quickstart/deploy.gif differ
diff --git a/public/images/101-quickstart/explorer.png b/public/images/101-quickstart/explorer.png
new file mode 100644
index 00000000..da8ec49b
Binary files /dev/null and b/public/images/101-quickstart/explorer.png differ
diff --git a/public/images/101-quickstart/interact.gif b/public/images/101-quickstart/interact.gif
new file mode 100644
index 00000000..30a44f82
Binary files /dev/null and b/public/images/101-quickstart/interact.gif differ
diff --git a/public/images/101-quickstart/remix-clone-template.gif b/public/images/101-quickstart/remix-clone-template.gif
new file mode 100644
index 00000000..b069002a
Binary files /dev/null and b/public/images/101-quickstart/remix-clone-template.gif differ
diff --git a/public/images/101-quickstart/remix-connect-evm.gif b/public/images/101-quickstart/remix-connect-evm.gif
new file mode 100644
index 00000000..25cb39a7
Binary files /dev/null and b/public/images/101-quickstart/remix-connect-evm.gif differ