diff --git a/apps/remix-dapp/src/locales/en/udapp.json b/apps/remix-dapp/src/locales/en/udapp.json index 764fc312368..ab91c7bc8c4 100644 --- a/apps/remix-dapp/src/locales/en/udapp.json +++ b/apps/remix-dapp/src/locales/en/udapp.json @@ -58,7 +58,7 @@ "udapp.resetVmStateDesc1": "Resetting the state of this VM will delete the associated transaction details in this Workspace.", "udapp.resetVmStateDesc2": "It will also delete the data of contracts deployed and pinned in this Workspace.", "udapp.resetVmStateDesc3": "Do you want to continue?", - "udapp.reset": "Yes reset", + "udapp.reset": "Yes, Reset", "udapp.delete": "Delete", "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.createSmartAccount": "Create a Safe Smart Account", 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 16bdcc3e100..cba386cd2f5 100644 --- a/apps/remix-ide/src/app/tabs/locales/en/udapp.json +++ b/apps/remix-ide/src/app/tabs/locales/en/udapp.json @@ -5,6 +5,9 @@ "udapp.gasLimit": "Gas limit", "udapp.gasLimitAuto": "Estimated Gas", "udapp.gasLimitManual": "Custom", + "udapp.gasLimitAutoTooltip": "Currently using auto estimated gas. Click on auto to set custom gas limit", + "udapp.gasLimitBadgeAutoTooltip": "Click to set custom gas limit", + "udapp.gasLimitBadgeCustomTooltip": "Click to use auto estimated gas", "udapp.tooltipText4": "Enter custom Gas Limit.", "udapp._comment_value.tsx": "libs/remix-ui/run-tab/src/lib/components/value.tsx", @@ -59,8 +62,8 @@ "udapp.resetVmStateDesc2": "It will also delete the data of contracts deployed and pinned in this Workspace.", "udapp.resetVmStateDesc3": "Do you want to continue?", "udapp.reset": "Reset", - "udapp.yesReset": "Yes reset", - "udapp.cancelReset": "Cancel reset", + "udapp.yesReset": "Yes, Reset", + "udapp.cancelReset": "Cancel", "udapp.delete": "Delete", "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.createSmartAccount": "Create a Safe Smart Account", @@ -200,8 +203,8 @@ "udapp.noABIAvailable": "No ABI available", "udapp.noBytecodeAvailable": "No bytecode available", "udapp.transactionRecorderTitle": "Transactions recorder", - "udapp.yesClearAll": "Yes clear all", - "udapp.yesClearAllTransactions": "Yes clear all", + "udapp.yesClearAll": "Yes, Clear All", + "udapp.yesClearAllTransactions": "Yes, Clear All", "udapp.viewSourceCode": "View Source Code", "udapp.themes": "Themes", "udapp.verifyContract": "Verify Contract on Explorers", diff --git a/libs/remix-ui/login/src/lib/user-menu-compact.css b/libs/remix-ui/login/src/lib/user-menu-compact.css index e3a49d8f605..1900a8974bc 100644 --- a/libs/remix-ui/login/src/lib/user-menu-compact.css +++ b/libs/remix-ui/login/src/lib/user-menu-compact.css @@ -134,8 +134,10 @@ transition: background-color 0.2s; } -.user-menu-item:hover { - background-color: var(--bs-body-bg, #222336); +.user-menu-items-container .dropdown-item.user-menu-item:hover, +.user-menu-items-container .dropdown-item.user-menu-item:focus { + background-color: var(--bs-dropdown-link-hover-bg); + color: var(--bs-dropdown-link-hover-color); } .user-menu-item-icon { @@ -155,8 +157,10 @@ transition: background-color 0.2s; } -.user-menu-credits-item:hover { - background-color: var(--bs-body-bg, #222336); +.user-menu-items-container .dropdown-item.user-menu-credits-item:hover, +.user-menu-items-container .dropdown-item.user-menu-credits-item:focus { + background-color: var(--bs-dropdown-link-hover-bg); + color: var(--bs-dropdown-link-hover-color); } .user-menu-credits-icon { @@ -189,8 +193,10 @@ font-weight: 500; } -.user-menu-item-danger:hover { - background-color: var(--bs-body-bg, #222336); +.user-menu-items-container .dropdown-item.user-menu-item-danger:hover, +.user-menu-items-container .dropdown-item.user-menu-item-danger:focus { + background-color: var(--bs-dropdown-link-hover-bg); + color: var(--bs-dropdown-link-hover-color); } .user-menu-theme-toggle { diff --git a/libs/remix-ui/run-tab-deploy/src/lib/css/index.css b/libs/remix-ui/run-tab-deploy/src/lib/css/index.css index b17dcd9046f..e5c645ce004 100644 --- a/libs/remix-ui/run-tab-deploy/src/lib/css/index.css +++ b/libs/remix-ui/run-tab-deploy/src/lib/css/index.css @@ -4,9 +4,13 @@ .deploy-address-toggle:hover { background-color: var(--custom-onsurface-layer-3) !important; } -.contract-dropdown-item-hover:hover, .unit-dropdown-item:hover, .unit-dropdown-item-hover:hover { +.contract-dropdown-item-hover:hover { background-color: var(--custom-onsurface-layer-3) !important; border: 1px solid var(--bs-border-color) !important; border-radius: 0 !important; color: var(--theme-text-color, white) !important; +} +.unit-dropdown-item:hover, .unit-dropdown-item-hover:hover { + background-color: var(--bs-dropdown-link-hover-bg) !important; + color: var(--bs-dropdown-link-hover-color) !important; } \ No newline at end of file diff --git a/libs/remix-ui/run-tab-deploy/src/lib/widgets/deployPortraitView.tsx b/libs/remix-ui/run-tab-deploy/src/lib/widgets/deployPortraitView.tsx index c06d13cde4c..44f833a433d 100644 --- a/libs/remix-ui/run-tab-deploy/src/lib/widgets/deployPortraitView.tsx +++ b/libs/remix-ui/run-tab-deploy/src/lib/widgets/deployPortraitView.tsx @@ -1,7 +1,7 @@ import React, { useContext, useEffect, useMemo, useRef, useState } from 'react' import { FormattedMessage } from 'react-intl' import { Dropdown } from 'react-bootstrap' -import { AddressToggle, CustomMenu, CustomToggle, extractNameFromKey, getMultiValsString, ProxyAddressToggle, ProxyDropdownMenu, shortenDate, shortenProxyAddress } from '@remix-ui/helper' +import { AddressToggle, CustomMenu, CustomToggle, CustomTooltip, extractNameFromKey, getMultiValsString, ProxyAddressToggle, ProxyDropdownMenu, shortenDate, shortenProxyAddress } from '@remix-ui/helper' import { CopyToClipboard } from '@remix-ui/clipboard' import { DeployAppContext } from '../contexts' import { Provider } from '@remix-ui/run-tab-environment' @@ -771,51 +771,85 @@ function DeployPortraitView() {
- { - const newMode = widgetState.gasLimit === 0 ? 'custom' : 'auto' - trackMatomoEvent?.({ category: 'udapp', action: 'gasLimitToggle', name: newMode, isClick: true }) - if (widgetState.gasLimit === 0) { - // Switch from auto to custom - set a default value - dispatch({ type: 'SET_GAS_LIMIT', payload: 3000000 }) - } else { - // Switch from custom to auto - set to 0 - dispatch({ type: 'SET_GAS_LIMIT', payload: 0 }) - } - }} + - {widgetState.gasLimit === 0 ? 'auto' : 'custom'} - - { - trackMatomoEvent?.({ category: 'udapp', action: 'gasLimitInput', name: e.target.value }) - dispatch({ type: 'SET_GAS_LIMIT', payload: parseInt(e.target.value) }) - }} - disabled={widgetState.gasLimit === 0} - style={{ - backgroundColor: 'var(--bs-body-bg)', - color: themeQuality === 'dark' ? 'white' : 'black', - flex: 1, - paddingLeft: '4rem', - opacity: widgetState.gasLimit === 0 ? 0.6 : 1, - cursor: widgetState.gasLimit === 0 ? 'not-allowed' : 'text' - }} - /> + { + const newMode = widgetState.gasLimit === 0 ? 'custom' : 'auto' + trackMatomoEvent?.({ category: 'udapp', action: 'gasLimitToggle', name: newMode, isClick: true }) + if (widgetState.gasLimit === 0) { + // Switch from auto to custom - set a default value + dispatch({ type: 'SET_GAS_LIMIT', payload: 3000000 }) + } else { + // Switch from custom to auto - set to 0 + dispatch({ type: 'SET_GAS_LIMIT', payload: 0 }) + } + }} + > + {widgetState.gasLimit === 0 ? 'auto' : 'custom'} + + + {widgetState.gasLimit === 0 ? ( + + { + trackMatomoEvent?.({ category: 'udapp', action: 'gasLimitInput', name: e.target.value }) + dispatch({ type: 'SET_GAS_LIMIT', payload: parseInt(e.target.value) }) + }} + disabled={widgetState.gasLimit === 0} + style={{ + backgroundColor: 'var(--bs-body-bg)', + color: themeQuality === 'dark' ? 'white' : 'black', + flex: 1, + paddingLeft: '4rem', + opacity: widgetState.gasLimit === 0 ? 0.6 : 1, + cursor: widgetState.gasLimit === 0 ? 'not-allowed' : 'text' + }} + /> + + ) : ( + { + trackMatomoEvent?.({ category: 'udapp', action: 'gasLimitInput', name: e.target.value }) + dispatch({ type: 'SET_GAS_LIMIT', payload: parseInt(e.target.value) }) + }} + disabled={widgetState.gasLimit === 0} + style={{ + backgroundColor: 'var(--bs-body-bg)', + color: themeQuality === 'dark' ? 'white' : 'black', + flex: 1, + paddingLeft: '4rem', + opacity: widgetState.gasLimit === 0 ? 0.6 : 1, + cursor: widgetState.gasLimit === 0 ? 'not-allowed' : 'text' + }} + /> + )}
diff --git a/libs/remix-ui/run-tab-deployed-contracts/src/lib/components/DeployedContractItem.tsx b/libs/remix-ui/run-tab-deployed-contracts/src/lib/components/DeployedContractItem.tsx index e7837920292..b64b577eda1 100644 --- a/libs/remix-ui/run-tab-deployed-contracts/src/lib/components/DeployedContractItem.tsx +++ b/libs/remix-ui/run-tab-deployed-contracts/src/lib/components/DeployedContractItem.tsx @@ -674,21 +674,21 @@ Before generating, please ask me about my design preferences first.` className="btn btn-outline-secondary w-100 d-flex align-items-center justify-content-between" style={{ backgroundColor: 'var(--custom-onsurface-layer-3)', - border: '1px solid var(--custom-onsurface-layer-4)', + border: '1px solid var(--bs-border-color)', color: 'var(--dark/text-secondary, #d5d7e3)', padding: '8px 12px' }} icon="fas fa-caret-down" useDefaultIcon={false} > -
- Select a function to interact with... +
+ Select a function to interact with...
e.stopPropagation()} style={{ backgroundColor: 'var(--custom-onsurface-layer-3)', - border: '1px solid var(--custom-onsurface-layer-4)', + border: '1px solid var(--bs-border-color)', color: 'var(--dark/text-secondary, #d5d7e3)', fontSize: '11px' }} @@ -916,7 +916,7 @@ Before generating, please ask me about my design preferences first.` getContent={() => getEncodedCall(selectedFunctionIndex)} >
diff --git a/libs/remix-ui/run-tab-deployed-contracts/src/lib/css/index.css b/libs/remix-ui/run-tab-deployed-contracts/src/lib/css/index.css index 0587cb1c682..ba664a697d5 100644 --- a/libs/remix-ui/run-tab-deployed-contracts/src/lib/css/index.css +++ b/libs/remix-ui/run-tab-deployed-contracts/src/lib/css/index.css @@ -135,3 +135,16 @@ animation: none; box-shadow: 0 6px 16px rgba(100, 196, 255, 0.8) !important; } + +/* Fix hover for function dropdown items */ +.dropdown-item[data-id*="deployedContractItem"][data-id*="function"]:hover, +.dropdown-item[data-id*="deployedContractItem"][data-id*="function"]:focus { + background-color: var(--bs-dropdown-link-hover-bg) !important; + color: var(--bs-dropdown-link-hover-color) !important; +} + +/* Add border to copy buttons */ +button[data-id^="copyCalldata"], +button[data-id^="copyParameters"] { + border: 1px solid var(--bs-border-color) !important; +} diff --git a/libs/remix-ui/run-tab-deployed-contracts/src/lib/widgets/deployedContractsPortraitView.tsx b/libs/remix-ui/run-tab-deployed-contracts/src/lib/widgets/deployedContractsPortraitView.tsx index bb31eae62c7..dd2acfa1ff6 100644 --- a/libs/remix-ui/run-tab-deployed-contracts/src/lib/widgets/deployedContractsPortraitView.tsx +++ b/libs/remix-ui/run-tab-deployed-contracts/src/lib/widgets/deployedContractsPortraitView.tsx @@ -299,11 +299,11 @@ export default function DeployedContractsPortraitView() { diff --git a/libs/remix-ui/run-tab-environment/src/lib/components/envCategoryUI.tsx b/libs/remix-ui/run-tab-environment/src/lib/components/envCategoryUI.tsx index 402e309bc11..302036d3266 100644 --- a/libs/remix-ui/run-tab-environment/src/lib/components/envCategoryUI.tsx +++ b/libs/remix-ui/run-tab-environment/src/lib/components/envCategoryUI.tsx @@ -59,7 +59,7 @@ export const EnvCategoryUI: React.FC = ({ isOpen, onToggle } e.stopPropagation() }} > - +
{{enforceSelect ? '