Note: TouseGeth&https://remix.ethereum.org, configure it to allow requests from Remix:(see <a href="https://geth.ethereum.org/docs/rpc/server" target="_blank" rel="noreferrer">Geth Docs on rpc server</a>)
if(!address)returnreject('"from" is not defined. Please make sure an account is selected. If you are using a public node, it is likely that no account will be provided. In that case, add the public node to your injected provider (type Metamask) and use injected provider in Remix.')
returnresolve(address)
})
}
@ -548,9 +549,18 @@ export class Blockchain extends Plugin {
<iid="remixRunSignMsg"data-id="settingsRemixRunSignMsg"className="mx-1 fas fa-edit udapp_icon"aria-hidden="true"onClick={signMessage}title="Sign a message using this account key"></i>
<divstyle={{marginLeft:-5}}><CopyToClipboardtip='Copy account to clipboard'content={selectedAccount}direction='top'/></div>
<iid="remixRunSignMsg"data-id="settingsRemixRunSignMsg"className="mx-1 fas fa-edit udapp_icon"aria-hidden="true"onClick={signMessage}title="Sign a message using this account"></i>
@ -119,12 +119,12 @@ export function ContractDropdownUI (props: ContractDropdownProps) {
if(enable){
setAtAddressOptions({
disabled: false,
title:'Interact with the given contract.'
title:'Interact with the deployed contract - requires the .abi file or compiled .sol file to be selected in the editor (with the same compiler configuration)'
})
}else{
setAtAddressOptions({
disabled: true,
title: loadedAddress?'⚠ Compile *.sol file or select *.abi file.':'⚠ Compile *.sol file or select *.abi file & then enter the address of deployed contract.'
title: loadedAddress?'Compile a *.sol file or select a *.abi file.':'To interact with a deployed contract, enter its address and compile its source *.sol file (with the same compiler settings) or select its .abi file in the editor. '
})
}
}
@ -133,12 +133,12 @@ export function ContractDropdownUI (props: ContractDropdownProps) {
if(enable){
setContractOptions({
disabled: false,
title:'Select contract for Deploy or At Address.'
title:'Select a compiled contract to deploy or to use with At Address.'
})
}else{
setContractOptions({
disabled: true,
title: loadType==='sol'?'⚠ Select and compile *.sol file to deploy or access a contract.':'⚠ Selected *.abi file allows accessing contracts, select and compile *.sol file to deploy and access one.'
title: loadType==='sol'?'Select and compile *.sol file to deploy or access a contract.':'When there is a compiled .sol file, the choice of contracts to deploy or to use with AtAddress is made here.'
@ -8,7 +8,7 @@ export function EnvironmentUI (props: EnvironmentProps) {
constfork=provider.fork// can be undefined if connected to an external source (web3 provider / injected)
letcontext=provider.value
context=context.startsWith('vm')?'vm':context// context has to be 'vm', 'web3' or 'injected'
context=context.startsWith('vm')?'vm':context
props.setExecutionContext({context,fork})
}
@ -29,7 +29,7 @@ export function EnvironmentUI (props: EnvironmentProps) {
)
}
</select>
<ahref="https://remix-ide.readthedocs.io/en/latest/run.html#run-setup"target="_blank"rel="noreferrer"><iclassName="udapp_infoDeployAction ml-2 fas fa-info"title="check out docs to setup Environment"></i></a>
<ahref="https://remix-ide.readthedocs.io/en/latest/run.html#environment"target="_blank"rel="noreferrer"><iclassName="udapp_infoDeployAction ml-2 fas fa-info"title="Click for docs about Environment"></i></a>
<inputtype="number"className="form-control udapp_gasNval udapp_col2"title="The default gas limit is 3M. Adjust as needed."id="gasLimit"value={props.gasLimit}onChange={handleGasLimit}/>
title:'Execution environment does not connect to any node, everything is local and in memory only.',
title:'Execution environment is local to Remix. Data is only saved to browser memory and will vanish upon reload.',
value:'vm-london',
fork:'london',
content:'JavaScript VM (London)'
content:'Remix VM (London)'
},{
id:'vm-mode-berlin',
dataId:'settingsVMBerlinMode',
title:'Execution environment does not connect to any node, everything is local and in memory only.',
title:'Execution environment is local to Remix. Data is only saved to browser memory and will vanish upon reload.',
value:'vm-berlin',
fork:'berlin',
content:'JavaScript VM (Berlin)'
content:'Remix VM (Berlin)'
},{
id:'injected-mode',
dataId:'settingsInjectedMode',
title:'Execution environment has been provided by Metamask or similar provider.',
value:'injected',
content:'Injected Web3'
},{
id:'web3-mode',
dataId:'settingsWeb3Mode',
title:`Execution environment connects to node at localhost (or via IPC if available), transactions will be sent to the network and can cause loss of money or worse!
exportconstetherscanAccessTokenText='Manage the api key used to interact with Etherscan.'
exportconstetherscanAccessTokenText2='Go to Etherscan api key page (link below) to create a new api key and save it in Remix.'
exportconstethereunVMText='Always use Javascript VM at load'
exportconstethereunVMText='Always use Remix VM at load'
exportconstwordWrapText='Word wrap in editor'
exportconstenablePersonalModeText=' Enable Personal Mode for web3 provider. Transaction sent over Web3 will use the web3.personal API.\n'
exportconstenablePersonalModeText=' Enable Personal Mode for Remix Provider. Transaction sent over Web3 will use the web3.personal API.\n'
exportconstuseAutoCompleteText='Enable code completion in editor.'
exportconstmatomoAnalytics='Enable Matomo Analytics. We do not collect personally identifiable information (PII). The info is used to improve the site’s UX & UI. See more about '
<selectonChange={(e)=>handleLanguageChange(e.target.value)}disabled={state.useFileConfiguration}value={state.language}className="custom-select"id="compilierLanguageSelector"title="Available since v0.5.7">
<selectonChange={(e)=>handleLanguageChange(e.target.value)}disabled={state.useFileConfiguration}value={state.language}className="custom-select"id="compilierLanguageSelector"title="Language specification available from Compiler >= v0.5.7">
plugin.call('notification','toast',`Looking for contract(s) verified on different networks of Etherscan for contract address ${contractAddress} .....`)
plugin.call('notification','toast',`Added ${count} verified contract${count===1?'':'s'} from ${foundOnNetworks.join(',')} network${foundOnNetworks.length===1?'':'s'} of Etherscan for contract address ${contractAddress} !!`)