r_light
yann300 4 months ago
parent e389209a4c
commit 234d0765d4
  1. 6
      apps/remix-ide/src/app/providers/environment-explorer.tsx
  2. 22
      apps/remix-ide/src/app/udapp/run-tab.js
  3. 1
      apps/remix-ide/src/blockchain/blockchain.tsx
  4. 2
      libs/remix-ui/grid-view/src/lib/remix-ui-grid-cell.tsx

@ -106,7 +106,7 @@ export class EnvironmentExplorer extends ViewPlugin {
return <RemixUIGridCell
plugin={this}
title={provider.displayName}
logo={provider.logo}
logos={provider.logos}
classList='EECellStyle'
payload={provider.description}
pinned={this.pinnedProviders.includes(provider.name)}
@ -139,7 +139,7 @@ export class EnvironmentExplorer extends ViewPlugin {
return <RemixUIGridCell
plugin={this}
title={provider.displayName}
logo={provider.logo}
logos={provider.logos}
classList='EECellStyle'
payload={provider.description}
pinned={this.pinnedProviders.includes(provider.name)}
@ -171,7 +171,7 @@ export class EnvironmentExplorer extends ViewPlugin {
return <RemixUIGridCell
plugin={this}
title={provider.displayName}
logo={provider.logo}
logos={provider.logos}
payload={provider.description}
classList='EECellStyle'
pinned={this.pinnedProviders.includes(provider.name)}

@ -152,11 +152,21 @@ export class RunTab extends ViewPlugin {
}
const logos = {
'injected-metamask-optimism': 'assets/img/optimism-ethereum-op-logo.png',
'injected-metamask-arbitrum': 'assets/img/arbitrum-arb-logo.png',
'injected-MetaMask': 'assets/img/metamask.png',
'hardhat-provider': 'assets/img/hardhat.png',
'walletconnect': 'assets/img/Walletconnect-logo.png'
'injected-metamask-optimism': ['assets/img/optimism-ethereum-op-logo.png', 'assets/img/metamask.png'],
'injected-metamask-arbitrum': ['assets/img/arbitrum-arb-logo.png', 'assets/img/metamask.png'],
'injected-metamask-sepolia': ['assets/img/metamask.png'],
'injected-metamask-ephemery': ['assets/img/metamask.png'],
'injected-MetaMask': ['assets/img/metamask.png'],
'hardhat-provider': ['assets/img/hardhat.png'],
'walletconnect': ['assets/img/Walletconnect-logo.png'],
'vm-cancun': ['assets/img/guitarRemiCroped.webp'],
'vm-shanghai': ['assets/img/bgRemi_small.webp'],
'vm-paris': ['assets/img/home.webp'],
'vm-london': ['assets/img/remixLogo.webp'],
'vm-berlin': ['assets/img/sleepingRemiCroped.webp'],
'vm-mainnet-fork': ['assets/img/guitarRemiCroped.webp'],
'vm-sepolia-fork': ['assets/img/sleepingRemiCroped.webp'],
'vm-custom-fork': ['assets/img/remixLogo.webp'],
}
const addProvider = async (position, name, displayName, isInjected, isVM, fork = '', dataId = '', title = '') => {
@ -167,7 +177,7 @@ export class RunTab extends ViewPlugin {
name,
displayName,
description: descriptions[name] || displayName,
logo: logos[name],
logos: logos[name],
fork,
isInjected,
isVM,

@ -50,6 +50,7 @@ export type Provider = {
name: string
displayName: string
logo?: string,
logos?: string[],
fork: string
description?: string
isInjected: boolean

@ -16,6 +16,7 @@ interface RemixUIGridCellProps {
pinned?: boolean
pinStateCallback?: any
logo?: string
logos?: string[]
title: string
payload?: string
tagList?: string[] // max 8, others will be ignored
@ -71,6 +72,7 @@ export const RemixUIGridCell = (props: RemixUIGridCellProps) => {
<div className="d-flex remixui_grid_cell flex-column">
<div className='d-flex flex-row pb-1 align-items-end' style={{ width: '8rem', height: '1rem' }}>
{ props.logo && <img className='remixui_grid_view_logo mr-1' src={props.logo} style={{ width: '1rem', height: '1rem' }}/> }
{ props.logos && props.logos.map((logo) => <img className='remixui_grid_view_logo mr-1' src={logo} style={{ width: '1rem', height: '1rem' }}/>)}
{ props.title && <label
className='m-0 p-0 align-items-left'
style={{ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', fontSize: 'xx-small' }}

Loading…
Cancel
Save