From 85e272a9b617059b9669594ec8720f21b7a06f0e Mon Sep 17 00:00:00 2001 From: aniket-engg Date: Wed, 18 Dec 2024 15:21:55 +0530 Subject: [PATCH] vm reset modal --- apps/remix-dapp/src/locales/en/udapp.json | 5 +++ .../src/app/tabs/locales/en/udapp.json | 5 +++ .../src/lib/components/environment.tsx | 33 +++++++++++++++++-- 3 files changed, 40 insertions(+), 3 deletions(-) diff --git a/apps/remix-dapp/src/locales/en/udapp.json b/apps/remix-dapp/src/locales/en/udapp.json index 4ac33242ea..ebe7f61e8a 100644 --- a/apps/remix-dapp/src/locales/en/udapp.json +++ b/apps/remix-dapp/src/locales/en/udapp.json @@ -52,6 +52,11 @@ "udapp.saveVmStateTitle": "Save VM state", "udapp.saveVmStateLabel": "State Name", "udapp.saveVmStateTip": "Saved VM states can be pinned as environment using Environment Explorer", + "udapp.resetVmStateTitle": "Reset VM state", + "udapp.resetVmStateDesc1": "Resetting state of selected environment will delete all your previously saved transaction details for selected workspace.", + "udapp.resetVmStateDesc2": "It will also delete data for deployed and pinned contracts.", + "udapp.resetVmStateDesc3": "Do you want to continue?", + "udapp.reset": "Reset", "udapp.injectedTitle": "Unfortunately it's not possible to create an account using injected provider. Please create the account directly from your provider (i.e metamask or other of the same type).", "udapp.createNewAccount": "Create a new account", "udapp.web3Title": "Creating an account is possible only in Personal mode. Please go to Settings to enable it.", diff --git a/apps/remix-ide/src/app/tabs/locales/en/udapp.json b/apps/remix-ide/src/app/tabs/locales/en/udapp.json index a025fcaccd..5de86bb254 100644 --- a/apps/remix-ide/src/app/tabs/locales/en/udapp.json +++ b/apps/remix-ide/src/app/tabs/locales/en/udapp.json @@ -52,6 +52,10 @@ "udapp.saveVmStateTitle": "Save VM state", "udapp.saveVmStateLabel": "State Name", "udapp.saveVmStateTip": "Saved VM states can be pinned as environment using Environment Explorer", + "udapp.resetVmStateTitle": "Reset VM state", + "udapp.resetVmStateDesc1": "Resetting state of selected environment will delete all your previously saved transaction details for selected workspace.", + "udapp.resetVmStateDesc2": "It will also delete data for deployed and pinned contracts.", + "udapp.resetVmStateDesc3": "Do you want to continue?", "udapp.injectedTitle": "Unfortunately it's not possible to create an account using injected provider. Please create the account directly from your provider (i.e metamask or other of the same type).", "udapp.createNewAccount": "Create new account", "udapp.web3Title": "Creating an account is possible only in Personal mode. Please go to Settings to enable it.", @@ -68,6 +72,7 @@ "udapp.environmentDocs": "Click for docs about Environment", "udapp.saveVmState": "Save VM state", "udapp.resetVmStateTooltip": "Reset VM state", + "udapp.reset": "Reset", "udapp.tooltipText2": "Open chainlist.org and get the connection specs of the chain you want to interact with.", "udapp.tooltipText3": "Click to open a bridge for converting L1 mainnet ETH to the selected network currency.", diff --git a/libs/remix-ui/run-tab/src/lib/components/environment.tsx b/libs/remix-ui/run-tab/src/lib/components/environment.tsx index 7c58cf2c3e..a5a27c4e0f 100644 --- a/libs/remix-ui/run-tab/src/lib/components/environment.tsx +++ b/libs/remix-ui/run-tab/src/lib/components/environment.tsx @@ -30,7 +30,7 @@ export function EnvironmentUI(props: EnvironmentProps) { const saveVmStatePrompt = (defaultName: string) => { return (
-