diff --git a/.tool-versions b/.tool-versions
index d064b3ea..dfe63496 100644
--- a/.tool-versions
+++ b/.tool-versions
@@ -1 +1 @@
-nodejs 18.19.0
+nodejs 20.13.1
diff --git a/README.md b/README.md
index 17261b7b..dacfb864 100644
--- a/README.md
+++ b/README.md
@@ -32,7 +32,7 @@ CHAINLINK_BASEURL=http://localhost:6688 yarn start
Now navigate to http://localhost:3000.
-If sign-in doesn't work, check your network console, it's probably a CORS issue. You may need to run your chainlink node with `ALLOW_ORIGINS=http://localhost:3000` set.
+If sign-in doesn't work, check your network console, it's probably a CORS issue. You may need to run your chainlink node with `[WebServer] AllowOrigins=http://localhost:3000` set in TOML config.
## Running Tests
diff --git a/package.json b/package.json
index 38d1a2e7..c1fa6974 100644
--- a/package.json
+++ b/package.json
@@ -8,7 +8,7 @@
"artifacts"
],
"engines": {
- "node": "^18.0.0"
+ "node": "^20.0.0"
},
"scripts": {
"lint": "eslint --ext js,jsx,ts,tsx .",
diff --git a/src/Private.tsx b/src/Private.tsx
index 8f89756a..16ae852a 100644
--- a/src/Private.tsx
+++ b/src/Private.tsx
@@ -62,7 +62,7 @@ const Private = ({ classes }: { classes: { content: string } }) => {
-
+
diff --git a/src/actionCreators.ts b/src/actionCreators.ts
index e2361cd4..707349c2 100644
--- a/src/actionCreators.ts
+++ b/src/actionCreators.ts
@@ -333,12 +333,6 @@ const RECEIVE_CREATE_SUCCESS_ACTION = {
type: ResourceActionType.RECEIVE_CREATE_SUCCESS,
}
-const receiveDeleteSuccess = (id: string) =>
- ({
- type: ResourceActionType.RECEIVE_DELETE_SUCCESS,
- id,
- } as const)
-
export const submitSignIn = (data: Parameter) =>
sendSignIn(data)
@@ -346,32 +340,6 @@ export const submitSignOut = () => sendSignOut
export const beginRegistration = () => sendBeginRegistration()
-export const deleteChain = (
- id: string,
- successCallback: React.ReactNode,
- errorCallback: React.ReactNode,
-) => {
- return (dispatch: Dispatch) => {
- dispatch({ type: ResourceActionType.REQUEST_DELETE })
-
- const endpoint = api.v2.chains
-
- return endpoint
- .destroyChain(id)
- .then((doc) => {
- dispatch(receiveDeleteSuccess(id))
- dispatch(notifySuccess(successCallback, doc))
- })
- .catch((error: Errors) => {
- curryErrorHandler(
- dispatch,
- ResourceActionType.RECEIVE_DELETE_ERROR,
- )(error)
- dispatch(notifyError(errorCallback, error))
- })
- }
-}
-
export const createJobRunV2 = (
id: string,
pipelineInput: string,
diff --git a/src/api/v2/chains.ts b/src/api/v2/chains.ts
index c8968b1e..d056f075 100644
--- a/src/api/v2/chains.ts
+++ b/src/api/v2/chains.ts
@@ -1,52 +1,20 @@
import * as jsonapi from 'utils/json-api-client'
import * as models from 'core/store/models'
-export const ENDPOINT = '/v2/chains/evm'
-const UPDATE_ENDPOINT = `${ENDPOINT}/:id`
+export const ENDPOINT = '/v2/chains/:network'
+
export class Chains {
constructor(private api: jsonapi.Api) {}
- public getChains = (): Promise> => {
- return this.index()
- }
-
- public createChain = (
- request: models.CreateChainRequest,
- ): Promise> => {
- return this.create(request)
- }
-
- public destroyChain = (id: string): Promise> => {
- return this.destroy(undefined, { id })
+ public getChains = (
+ network: string,
+ ): Promise> => {
+ return this.index(undefined, { network })
}
- public updateChain = (
- id: string,
- req: models.UpdateChainRequest,
- ): Promise> => {
- return this.update(req, { id })
- }
-
- private index = this.api.fetchResource