From 05283ffd424ac8d0e92aa820c6633a437707399a Mon Sep 17 00:00:00 2001 From: Aaron Cox Date: Wed, 6 Nov 2024 15:46:52 -0800 Subject: [PATCH 01/11] Created EOS variant --- package.json | 8 ++++---- packages/snap/snap.manifest.json | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package.json b/package.json index b611056..1fcbf43 100644 --- a/package.json +++ b/package.json @@ -1,18 +1,18 @@ { - "name": "@greymass/antelope-snap", + "name": "@greymass/eos-wallet", "version": "1.0.0", "private": true, "description": "", - "homepage": "https://github.com/@greymass/antelope-snap#readme", + "homepage": "https://github.com/greymass/antelope-snap/tree/eos", "bugs": { - "url": "https://github.com/@greymass/antelope-snap/issues" + "url": "https://github.com/greymass/antelope-snap/tree/eos" }, "repository": { "type": "git", "url": "git+https://github.com/@greymass/antelope-snap.git" }, "license": "MIT", - "author": "", + "author": "Greymass Inc.", "type": "module", "workspaces": [ "packages/*" diff --git a/packages/snap/snap.manifest.json b/packages/snap/snap.manifest.json index 8647563..2099d53 100644 --- a/packages/snap/snap.manifest.json +++ b/packages/snap/snap.manifest.json @@ -1,10 +1,10 @@ { "version": "1.0.0", - "description": "MetaMask Snap allowing users to interact with Antelope networks", - "proposedName": "Antelope", + "description": "Use MetaMask with the EOS Network", + "proposedName": "EOS Wallet", "repository": { "type": "git", - "url": "https://github.com/@greymass/antelope-snap.git" + "url": "https://github.com/greymass/antelope-snap/tree/eos" }, "source": { "shasum": "N31cL5DFiNXFeN9cGDj5iPje/60K5mgHiqXkhng8rxo=", @@ -12,7 +12,7 @@ "npm": { "filePath": "dist/bundle.js", "iconPath": "src/assets/eos-logo.svg", - "packageName": "snap", + "packageName": "@greymass/eos-wallet", "registry": "https://registry.npmjs.org/" } } From b2c2da7baab28f6e3035dd28ec61d04770930aa7 Mon Sep 17 00:00:00 2001 From: Aaron Cox Date: Wed, 6 Nov 2024 15:47:31 -0800 Subject: [PATCH 02/11] Update yarn.lock --- yarn.lock | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/yarn.lock b/yarn.lock index 72465af..10b208c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1729,9 +1729,21 @@ __metadata: languageName: node linkType: hard -"@greymass/antelope-snap@workspace:.": +"@greymass/create-account@npm:^1.0.2": + version: 1.0.2 + resolution: "@greymass/create-account@npm:1.0.2" + dependencies: + "@greymass/return-path": ^0.0.1 + "@wharfkit/antelope": ^0.7.3 + "@wharfkit/signing-request": ^3.0.0 + tslib: ^2.1.0 + checksum: aad3d0feb158f77bc386dab689c167dfd3ae73259734a6affd8b826aab2c26680f6067c89bee3d3f5ea763ed48998980b41d49ddf8f1e6cf92f146c92df5e32f + languageName: node + linkType: hard + +"@greymass/eos-wallet@workspace:.": version: 0.0.0-use.local - resolution: "@greymass/antelope-snap@workspace:." + resolution: "@greymass/eos-wallet@workspace:." dependencies: "@lavamoat/allow-scripts": ^3.0.0 "@lavamoat/preinstall-always-fail": ^2.0.0 @@ -1758,18 +1770,6 @@ __metadata: languageName: unknown linkType: soft -"@greymass/create-account@npm:^1.0.2": - version: 1.0.2 - resolution: "@greymass/create-account@npm:1.0.2" - dependencies: - "@greymass/return-path": ^0.0.1 - "@wharfkit/antelope": ^0.7.3 - "@wharfkit/signing-request": ^3.0.0 - tslib: ^2.1.0 - checksum: aad3d0feb158f77bc386dab689c167dfd3ae73259734a6affd8b826aab2c26680f6067c89bee3d3f5ea763ed48998980b41d49ddf8f1e6cf92f146c92df5e32f - languageName: node - linkType: hard - "@greymass/return-path@npm:^0.0.1": version: 0.0.1 resolution: "@greymass/return-path@npm:0.0.1" From 9aa8520a442ca28bdf07428837c6450566ca1236 Mon Sep 17 00:00:00 2001 From: Aaron Cox Date: Wed, 6 Nov 2024 15:48:30 -0800 Subject: [PATCH 03/11] Removed private flag --- package.json | 1 - 1 file changed, 1 deletion(-) diff --git a/package.json b/package.json index 1fcbf43..a5ae41f 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,6 @@ { "name": "@greymass/eos-wallet", "version": "1.0.0", - "private": true, "description": "", "homepage": "https://github.com/greymass/antelope-snap/tree/eos", "bugs": { From 933085a26fd86a299757cfff95c9a914d45ba0ad Mon Sep 17 00:00:00 2001 From: Aaron Cox Date: Wed, 6 Nov 2024 15:54:47 -0800 Subject: [PATCH 04/11] Updating URL + lint --- packages/snap/src/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/snap/src/index.ts b/packages/snap/src/index.ts index 6568d17..31176b9 100644 --- a/packages/snap/src/index.ts +++ b/packages/snap/src/index.ts @@ -7,10 +7,10 @@ import { } from '@metamask/snaps-sdk'; import { getPublicKey, signTransaction } from './rpc'; -import { AntelopeRequest, AntelopeSignatureRequest } from './types'; +import type { AntelopeRequest, AntelopeSignatureRequest } from './types'; const SNAP_NAME = 'EOS Wallet'; -const HELP_URL = 'https://unicove.com/eos/metamask'; +const HELP_URL = 'https://unicove.com/eos/signup/wallets/extensions/metamask'; /** * Handle the installation of the snap. From f0718d34d1c3a64e791700333957cb59544665ec Mon Sep 17 00:00:00 2001 From: Aaron Cox Date: Wed, 6 Nov 2024 17:50:25 -0800 Subject: [PATCH 05/11] Renaming workspaces --- package.json | 9 ++-- packages/snap/package.json | 4 +- packages/snap/snap.manifest.json | 4 +- yarn.lock | 90 ++++++++++++++++---------------- 4 files changed, 54 insertions(+), 53 deletions(-) diff --git a/package.json b/package.json index a5ae41f..dfb97c3 100644 --- a/package.json +++ b/package.json @@ -1,14 +1,15 @@ { - "name": "@greymass/eos-wallet", + "name": "root", "version": "1.0.0", + "private": true, "description": "", - "homepage": "https://github.com/greymass/antelope-snap/tree/eos", + "homepage": "https://github.com/greymass/antelope-snap", "bugs": { - "url": "https://github.com/greymass/antelope-snap/tree/eos" + "url": "https://github.com/greymass/antelope-snap" }, "repository": { "type": "git", - "url": "git+https://github.com/@greymass/antelope-snap.git" + "url": "https://github.com/@greymass/antelope-snap.git" }, "license": "MIT", "author": "Greymass Inc.", diff --git a/packages/snap/package.json b/packages/snap/package.json index 8912bf7..6685790 100644 --- a/packages/snap/package.json +++ b/packages/snap/package.json @@ -1,7 +1,7 @@ { - "name": "snap", + "name": "@greymass/eos-wallet", "version": "1.0.0", - "description": "MetaMask Snap allowing users to interact with Antelope networks", + "description": "Use MetaMask with the EOS Network", "repository": { "type": "git", "url": "https://github.com/@greymass/antelope-snap.git" diff --git a/packages/snap/snap.manifest.json b/packages/snap/snap.manifest.json index 2099d53..9c3fbd6 100644 --- a/packages/snap/snap.manifest.json +++ b/packages/snap/snap.manifest.json @@ -4,10 +4,10 @@ "proposedName": "EOS Wallet", "repository": { "type": "git", - "url": "https://github.com/greymass/antelope-snap/tree/eos" + "url": "https://github.com/@greymass/antelope-snap.git" }, "source": { - "shasum": "N31cL5DFiNXFeN9cGDj5iPje/60K5mgHiqXkhng8rxo=", + "shasum": "qrb7Oxl5Q0mqCgXm5wmZ6CIiAuM4S3c1cblLv4vTCys=", "location": { "npm": { "filePath": "dist/bundle.js", diff --git a/yarn.lock b/yarn.lock index 10b208c..de22cbd 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1741,19 +1741,26 @@ __metadata: languageName: node linkType: hard -"@greymass/eos-wallet@workspace:.": +"@greymass/eos-wallet@workspace:packages/snap": version: 0.0.0-use.local - resolution: "@greymass/eos-wallet@workspace:." + resolution: "@greymass/eos-wallet@workspace:packages/snap" dependencies: - "@lavamoat/allow-scripts": ^3.0.0 - "@lavamoat/preinstall-always-fail": ^2.0.0 + "@jest/globals": ^29.5.0 + "@metamask/auto-changelog": ^3.4.4 "@metamask/eslint-config": ^12.2.0 "@metamask/eslint-config-jest": ^12.1.0 "@metamask/eslint-config-nodejs": ^12.1.0 "@metamask/eslint-config-typescript": ^12.1.0 + "@metamask/key-tree": ^9.1.1 + "@metamask/snaps-cli": ^6.1.0 + "@metamask/snaps-jest": ^7.0.0 + "@metamask/snaps-sdk": ^4.0.0 "@typescript-eslint/eslint-plugin": ^5.42.1 "@typescript-eslint/parser": ^5.42.1 - eslint: ^9.0.0 + "@wharfkit/antelope": ^1.0.7 + "@wharfkit/common": ^1.2.2 + buffer: ^6.0.3 + eslint: ^8.45.0 eslint-config-prettier: ^8.5.0 eslint-plugin-import: ~2.26.0 eslint-plugin-jest: ^27.1.5 @@ -1761,12 +1768,12 @@ __metadata: eslint-plugin-n: ^15.7.0 eslint-plugin-prettier: ^4.2.1 eslint-plugin-promise: ^6.1.1 + jest: ^29.5.0 prettier: ^2.7.1 - prettier-plugin-packagejson: ^2.2.18 - prettier-plugin-svelte: ^3.2.4 - sharp: ^0.32.6 + prettier-plugin-packagejson: ^2.2.11 + rimraf: ^3.0.2 + ts-jest: ^29.1.0 typescript: ^4.7.4 - typescript-eslint: ^8.0.0-alpha.20 languageName: unknown linkType: soft @@ -10965,6 +10972,35 @@ __metadata: languageName: node linkType: hard +"root@workspace:.": + version: 0.0.0-use.local + resolution: "root@workspace:." + dependencies: + "@lavamoat/allow-scripts": ^3.0.0 + "@lavamoat/preinstall-always-fail": ^2.0.0 + "@metamask/eslint-config": ^12.2.0 + "@metamask/eslint-config-jest": ^12.1.0 + "@metamask/eslint-config-nodejs": ^12.1.0 + "@metamask/eslint-config-typescript": ^12.1.0 + "@typescript-eslint/eslint-plugin": ^5.42.1 + "@typescript-eslint/parser": ^5.42.1 + eslint: ^9.0.0 + eslint-config-prettier: ^8.5.0 + eslint-plugin-import: ~2.26.0 + eslint-plugin-jest: ^27.1.5 + eslint-plugin-jsdoc: ^41.1.2 + eslint-plugin-n: ^15.7.0 + eslint-plugin-prettier: ^4.2.1 + eslint-plugin-promise: ^6.1.1 + prettier: ^2.7.1 + prettier-plugin-packagejson: ^2.2.18 + prettier-plugin-svelte: ^3.2.4 + sharp: ^0.32.6 + typescript: ^4.7.4 + typescript-eslint: ^8.0.0-alpha.20 + languageName: unknown + linkType: soft + "run-parallel@npm:^1.1.9": version: 1.2.0 resolution: "run-parallel@npm:1.2.0" @@ -11386,42 +11422,6 @@ __metadata: languageName: node linkType: hard -"snap@workspace:packages/snap": - version: 0.0.0-use.local - resolution: "snap@workspace:packages/snap" - dependencies: - "@jest/globals": ^29.5.0 - "@metamask/auto-changelog": ^3.4.4 - "@metamask/eslint-config": ^12.2.0 - "@metamask/eslint-config-jest": ^12.1.0 - "@metamask/eslint-config-nodejs": ^12.1.0 - "@metamask/eslint-config-typescript": ^12.1.0 - "@metamask/key-tree": ^9.1.1 - "@metamask/snaps-cli": ^6.1.0 - "@metamask/snaps-jest": ^7.0.0 - "@metamask/snaps-sdk": ^4.0.0 - "@typescript-eslint/eslint-plugin": ^5.42.1 - "@typescript-eslint/parser": ^5.42.1 - "@wharfkit/antelope": ^1.0.7 - "@wharfkit/common": ^1.2.2 - buffer: ^6.0.3 - eslint: ^8.45.0 - eslint-config-prettier: ^8.5.0 - eslint-plugin-import: ~2.26.0 - eslint-plugin-jest: ^27.1.5 - eslint-plugin-jsdoc: ^41.1.2 - eslint-plugin-n: ^15.7.0 - eslint-plugin-prettier: ^4.2.1 - eslint-plugin-promise: ^6.1.1 - jest: ^29.5.0 - prettier: ^2.7.1 - prettier-plugin-packagejson: ^2.2.11 - rimraf: ^3.0.2 - ts-jest: ^29.1.0 - typescript: ^4.7.4 - languageName: unknown - linkType: soft - "socks-proxy-agent@npm:^8.0.3": version: 8.0.4 resolution: "socks-proxy-agent@npm:8.0.4" From f4b8d1c59829209e6a6f7933e0725ab14c7e1421 Mon Sep 17 00:00:00 2001 From: dafuga Date: Mon, 11 Nov 2024 11:48:44 -0800 Subject: [PATCH 06/11] fix: fixing the eos logo --- packages/snap/snap.manifest.json | 2 +- packages/snap/src/assets/eos-logo.svg | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/packages/snap/snap.manifest.json b/packages/snap/snap.manifest.json index 6ecff43..559365e 100644 --- a/packages/snap/snap.manifest.json +++ b/packages/snap/snap.manifest.json @@ -7,7 +7,7 @@ "url": "https://github.com/@greymass/antelope-snap.git" }, "source": { - "shasum": "JyHwpSdSDLYKueBzFFGWp+Vi2k1inVgiqlAYeeyIiQU=", + "shasum": "6cU0LH55K0NGtqTx30QzZfFJeMRMICsn5HTuc5tAhzw=", "location": { "npm": { "filePath": "dist/bundle.js", diff --git a/packages/snap/src/assets/eos-logo.svg b/packages/snap/src/assets/eos-logo.svg index 67cf064..6920bd0 100644 --- a/packages/snap/src/assets/eos-logo.svg +++ b/packages/snap/src/assets/eos-logo.svg @@ -1,12 +1,13 @@ - + + d="m391.1,218.2v-.5L234.2,0,80.7,217.2l-.2.5L0,561.4v.5l233.3,137.4,1.5.7,235.4-138.2.5-.2-79.6-343.4h0Zm-121.4,345.1l-35.3,111.6-33.6-111.6h68.9Zm-82.2,0l37,118.2-198.5-118.2h161.5Zm194.6-154.9l-32.6-56.2,35-111.2,65.7,284.8-68.1-117.4Zm-142.1-245.4V27.5l138.9,193.1-37.5,117.7-101.4-175.3h0Zm45.3,388.9l59.1-185.8,28,48.2,79.8,137.7h-166.9v-.1Zm159.1,11.7l-200.2,118.2,37.7-118.2h162.5Zm-107.6-210.7l-63.5,199.2h-77.6l-62.8-200.7,101.2-175.6,102.7,177.1h0Zm-152.9,199H18.2l107.7-185.6,58,185.6h0Zm44.7-389.4l-100.2,173.9-36.2-116L228.6,27.5v135h0ZM20.9,523.4L86.1,241l34.5,109.7-99.7,172.7h0Z" + style="fill: #ffffff; fill-opacity: 1;" /> \ No newline at end of file From fa6380713fdfd35e03b8b7e7dcdce1280f995203 Mon Sep 17 00:00:00 2001 From: dafuga Date: Mon, 11 Nov 2024 11:58:19 -0800 Subject: [PATCH 07/11] chore: upped app version --- packages/snap/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/snap/package.json b/packages/snap/package.json index 623dc3f..045bbea 100644 --- a/packages/snap/package.json +++ b/packages/snap/package.json @@ -1,6 +1,6 @@ { "name": "@greymass/eos-wallet", - "version": "1.0.1", + "version": "1.0.2", "description": "Use MetaMask with the EOS Network", "repository": { "type": "git", From 52b395474906005881808a4bdc4ee603f513fb65 Mon Sep 17 00:00:00 2001 From: dafuga Date: Mon, 11 Nov 2024 13:57:17 -0800 Subject: [PATCH 08/11] fix: including the logo with the bundle --- packages/snap/package.json | 3 ++- packages/snap/snap.config.ts | 23 +++++++++++++++++++++++ packages/snap/snap.manifest.json | 4 ++-- 3 files changed, 27 insertions(+), 3 deletions(-) diff --git a/packages/snap/package.json b/packages/snap/package.json index 045bbea..79791b1 100644 --- a/packages/snap/package.json +++ b/packages/snap/package.json @@ -10,7 +10,8 @@ "main": "./dist/bundle.js", "files": [ "dist/", - "snap.manifest.json" + "snap.manifest.json", + "src/assets/eos-logo.svg" ], "scripts": { "allow-scripts": "yarn workspace root allow-scripts", diff --git a/packages/snap/snap.config.ts b/packages/snap/snap.config.ts index ada81eb..4a7fdb5 100644 --- a/packages/snap/snap.config.ts +++ b/packages/snap/snap.config.ts @@ -11,6 +11,29 @@ const config: SnapConfig = { crypto: true, buffer: true, }, + customizeWebpackConfig: (config) => { + return { + ...config, + module: { + ...config.module, + rules: [ + ...(config.module?.rules || []), + { + test: /\.svg$/, + use: [ + { + loader: 'url-loader', + options: { + limit: 10000, + name: 'images/[hash]-[name].[ext]', + }, + }, + ], + }, + ], + }, + }; + }, }; export default config; diff --git a/packages/snap/snap.manifest.json b/packages/snap/snap.manifest.json index 559365e..3e8bb9b 100644 --- a/packages/snap/snap.manifest.json +++ b/packages/snap/snap.manifest.json @@ -1,5 +1,5 @@ { - "version": "1.0.1", + "version": "1.0.2", "description": "Use MetaMask with the EOS Network", "proposedName": "EOS Wallet", "repository": { @@ -7,7 +7,7 @@ "url": "https://github.com/@greymass/antelope-snap.git" }, "source": { - "shasum": "6cU0LH55K0NGtqTx30QzZfFJeMRMICsn5HTuc5tAhzw=", + "shasum": "4w6WYeK6M72k5BF+BAOVaAyyL5E4pwvAMT+JdmER8b4=", "location": { "npm": { "filePath": "dist/bundle.js", From be12d55aebf0123af35fd994df046d7f5552f77e Mon Sep 17 00:00:00 2001 From: dafuga Date: Thu, 14 Nov 2024 11:53:38 -0800 Subject: [PATCH 09/11] chore: updated eos logo --- packages/snap/snap.manifest.json | 2 +- packages/snap/src/assets/eos-logo.svg | 34 +++++++++++++++++---------- 2 files changed, 23 insertions(+), 13 deletions(-) diff --git a/packages/snap/snap.manifest.json b/packages/snap/snap.manifest.json index 3e8bb9b..631dec2 100644 --- a/packages/snap/snap.manifest.json +++ b/packages/snap/snap.manifest.json @@ -7,7 +7,7 @@ "url": "https://github.com/@greymass/antelope-snap.git" }, "source": { - "shasum": "4w6WYeK6M72k5BF+BAOVaAyyL5E4pwvAMT+JdmER8b4=", + "shasum": "UeGzYZLI9e6xDk3Kj6oeDd3ZDckK5gs0HwtaN/kUShg=", "location": { "npm": { "filePath": "dist/bundle.js", diff --git a/packages/snap/src/assets/eos-logo.svg b/packages/snap/src/assets/eos-logo.svg index 6920bd0..349082b 100644 --- a/packages/snap/src/assets/eos-logo.svg +++ b/packages/snap/src/assets/eos-logo.svg @@ -1,13 +1,23 @@ - - - - - - + + + + + + + + + + + + + + + \ No newline at end of file From 98b8650875b3ddc789da53075e0b80d6c5aca7a5 Mon Sep 17 00:00:00 2001 From: dafuga Date: Thu, 14 Nov 2024 11:54:05 -0800 Subject: [PATCH 10/11] chore: upped app version --- packages/snap/package.json | 2 +- packages/snap/snap.manifest.json | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/snap/package.json b/packages/snap/package.json index 79791b1..1a5d0d5 100644 --- a/packages/snap/package.json +++ b/packages/snap/package.json @@ -1,6 +1,6 @@ { "name": "@greymass/eos-wallet", - "version": "1.0.2", + "version": "1.0.3", "description": "Use MetaMask with the EOS Network", "repository": { "type": "git", diff --git a/packages/snap/snap.manifest.json b/packages/snap/snap.manifest.json index 631dec2..890bcd5 100644 --- a/packages/snap/snap.manifest.json +++ b/packages/snap/snap.manifest.json @@ -1,5 +1,5 @@ { - "version": "1.0.2", + "version": "1.0.3", "description": "Use MetaMask with the EOS Network", "proposedName": "EOS Wallet", "repository": { @@ -7,7 +7,7 @@ "url": "https://github.com/@greymass/antelope-snap.git" }, "source": { - "shasum": "UeGzYZLI9e6xDk3Kj6oeDd3ZDckK5gs0HwtaN/kUShg=", + "shasum": "8KEHIHWiIx5VvODKvuVHdloOqkE54WjlGOesElvkqc4=", "location": { "npm": { "filePath": "dist/bundle.js", From ec251c53bcee08bc1e4ae6d377d9ec056792b202 Mon Sep 17 00:00:00 2001 From: Aaron Cox Date: Tue, 26 Nov 2024 08:50:29 -0800 Subject: [PATCH 11/11] Removed audit warning --- README.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/README.md b/README.md index 2eb1b7d..c50baf6 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,3 @@ -# WARNING: This Metamask Snap has not been audited yet and should not be used with real funds. - # @greymass/antelope-snap This is a Metamask Snap that provides a simple way to interface with [Antelope](https://eosnetwork.com/antelope/) blockchains using a Metamask wallet.