-
Notifications
You must be signed in to change notification settings - Fork 447
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Allow changing network name before submitting a "Add network" F…
…E-1183 (#1725) This PR - Adds an input field to the review step when adding a network to allow adding multiple networks that have the same name. Specially useful for testing and development. - Also adds type safety for chainId to make sure it is always a String (Avoid controlled/uncontrolled input fields issue). ![image](https://github.com/user-attachments/assets/97635bf5-bbf9-4d24-85c9-5ff416764e01) <details> <summary>Sample docker-compse.yml to run two local nodes to test this PR.</summary> ``` version: '3' services: fuel-core-1: platform: linux/amd64 container_name: '${PROJECT:-fuel-node}_fuel-core-1' environment: FUEL_IP: ${FUEL_IP} FUEL_CORE_PORT: 4000 NETWORK_NAME: '${PROJECT} local 1' MIN_GAS_PRICE: ${MIN_GAS_PRICE} CONSENSUS_KEY_SECRET: ${WALLET_SECRET} build: ./fuel-core ports: - '${FUEL_CORE_PORT_1:-4000}:4000' volumes: - fuel-core-db-1:/mnt/db healthcheck: test: curl --fail http://localhost:4000/v1/health || exit 1 interval: 1s timeout: 5s retries: 20 fuel-core-2: platform: linux/amd64 container_name: '${PROJECT:-fuel-node}_fuel-core-2' environment: FUEL_IP: ${FUEL_IP} FUEL_CORE_PORT: 4001 NETWORK_NAME: '${PROJECT} local 2' MIN_GAS_PRICE: ${MIN_GAS_PRICE} CONSENSUS_KEY_SECRET: ${WALLET_SECRET} build: ./fuel-core ports: - '${FUEL_CORE_PORT_2:-4001}:4001' volumes: - fuel-core-db-2:/mnt/db healthcheck: test: curl --fail http://localhost:4001/v1/health || exit 1 interval: 1s timeout: 5s retries: 20 faucet-1: platform: linux/amd64 container_name: '${PROJECT:-fuel-node}_faucet-1' environment: MIN_GAS_PRICE: ${MIN_GAS_PRICE} WALLET_SECRET_KEY: ${WALLET_SECRET} DISPENSE_AMOUNT: ${DISPENSE_AMOUNT} FUEL_NODE_URL: http://${PROJECT:-fuel-node}_fuel-core-1:4000/v1/graphql image: ghcr.io/fuellabs/faucet:4f7bec0 ports: - '${FUEL_FAUCET_PORT_1:-4040}:3000' links: - fuel-core-1 depends_on: fuel-core-1: condition: service_healthy faucet-2: platform: linux/amd64 container_name: '${PROJECT:-fuel-node}_faucet-2' environment: MIN_GAS_PRICE: ${MIN_GAS_PRICE} WALLET_SECRET_KEY: ${WALLET_SECRET} DISPENSE_AMOUNT: ${DISPENSE_AMOUNT} FUEL_NODE_URL: http://${PROJECT:-fuel-node}_fuel-core-2:4001/v1/graphql image: ghcr.io/fuellabs/faucet:4f7bec0 ports: - '${FUEL_FAUCET_PORT_2:-4041}:3000' links: - fuel-core-2 depends_on: fuel-core-2: condition: service_healthy volumes: fuel-core-db-1: name: '${PROJECT:-fuel-node}_fuel-core-db-1' fuel-core-db-2: name: '${PROJECT:-fuel-node}_fuel-core-db-2' ``` </details> --------- Co-authored-by: Luiz Gomes <[email protected]>
- Loading branch information
1 parent
0a3fbed
commit 28628cb
Showing
6 changed files
with
102 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"fuels-wallet": patch | ||
--- | ||
|
||
Allow editing network name when adding. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters