Skip to content

Commit 1729273

Browse files
CoveMBericglau
andauthored
Plat 6273 defender provide information in UI on how to verify via (#47)
* Allow connecting deploy plugin with local Defender * Get currently configured block explorer api keys * Add typing in compile server request * Match deploy note for missing API key * remove tracking of vscode directory * 0.0.2 * Update src/lib/models/auth.ts Co-authored-by: Eric Lau <ericglau@outlook.com> * revert changes in compiler * refactor vite config * Update src/routes/auth/+server.ts Co-authored-by: Eric Lau <ericglau@outlook.com> * make component required * remove get relayer function * Apply suggestions from code review Co-authored-by: Eric Lau <ericglau@outlook.com> * Update src/lib/wizard/components/Deploy.svelte Co-authored-by: Eric Lau <ericglau@outlook.com> * adjust type * Simplify compiler endpoint * Update @openzeppelin-sdk package * Update @openzeppelin-sdk package --------- Co-authored-by: Eric Lau <ericglau@outlook.com>
1 parent ec19031 commit 1729273

File tree

15 files changed

+192
-164
lines changed

15 files changed

+192
-164
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,4 @@ Thumbs.db
2222
vite.config.js.timestamp-*
2323
vite.config.ts.timestamp-*
2424

25-
/.vscode/
25+
.vscode/

package.json

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "defender-remix-plugin-sveltekit",
3-
"version": "0.0.1",
3+
"private": true,
44
"type": "module",
55
"scripts": {
66
"prepare": "node scripts/prepare.js",
@@ -23,16 +23,18 @@
2323
"vite": "^5.0.3"
2424
},
2525
"dependencies": {
26-
"@openzeppelin/defender-sdk": "^2.1.0",
26+
"@openzeppelin/defender-sdk": "^2.4.0",
2727
"@remixproject/plugin": "^0.3.38",
2828
"@remixproject/plugin-api": "^0.3.38",
2929
"@remixproject/plugin-iframe": "^0.3.38",
3030
"@remixproject/plugin-utils": "^0.3.38",
3131
"@sveltejs/adapter-netlify": "^4.3.6",
3232
"bootstrap": "^5.3.3",
33+
"dotenv": "^16.4.7",
3334
"ethers": "^6.13.4",
3435
"solc": "^0.8.28",
3536
"file-saver": "^2.0.5",
3637
"superchain-registry": "github:ethereum-optimism/superchain-registry"
37-
}
38+
},
39+
"version": "0.0.1"
3840
}

pnpm-lock.yaml

Lines changed: 78 additions & 75 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/lib/api.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
import type { CreateApprovalProcessRequest } from "./models/approval-process";
2-
import type { Credentials } from "./models/auth";
2+
import type { AuthenticationResponse, Credentials } from "./models/auth";
33
import type { DeployContractRequest, UpdateDeploymentRequest } from "./models/deploy";
44
import type { CompilerInput } from "./models/solc";
5+
import type { APIResponse } from "./models/ui";
56

67
class ApiClient {
78
credentials: Credentials | null = null;
89

9-
async authenticate(credentials: Credentials) {
10+
async authenticate(credentials: Credentials): Promise<APIResponse<AuthenticationResponse>> {
1011
const response = await fetch("/auth", {
1112
method: "POST",
1213
headers: { "Content-Type": "application/json" },

0 commit comments

Comments
 (0)