Merge pull request #4248 from ethereum/tabsed

refactored UI of templates on hometab
pull/4254/head
Liana Husikyan 1 year ago committed by GitHub
commit 1103269a86
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 10
      apps/remix-ide/src/assets/css/themes/bootstrap-cyborg.min.css
  2. BIN
      apps/remix-ide/src/assets/img/gnosissafeLogo.png
  3. BIN
      apps/remix-ide/src/assets/img/openzeppelinLogo.png
  4. BIN
      apps/remix-ide/src/assets/img/oxprojectLogo.png
  5. BIN
      apps/remix-ide/src/assets/img/remixverticaltextLogo.png
  6. 2
      apps/remix-ide/src/blockchain/execution-context.js
  7. 2
      libs/ghaction-helper/src/methods.ts
  8. 4
      libs/remix-ui/home-tab/src/lib/components/homeTabFeaturedPlugins.tsx
  9. 18
      libs/remix-ui/home-tab/src/lib/components/homeTabGetStarted.tsx
  10. 21
      libs/remix-ui/home-tab/src/lib/components/workspaceTemplate.tsx
  11. 4
      libs/remix-ui/home-tab/src/lib/remix-ui-home-tab.css

@ -284,19 +284,19 @@ template {
color:#fff
}
.h1,h1 {
font-size:4rem
font-size:3rem
}
.h2,h2 {
font-size:3rem
font-size:2.5rem
}
.h3,h3 {
font-size:2.5rem
font-size:2rem
}
.h4,h4 {
font-size:2rem
font-size:1.6rem
}
.h5,h5 {
font-size:1.5rem
font-size:1.3rem
}
.h6,h6 {
font-size:.875rem

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 919 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 56 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

@ -7,7 +7,7 @@ const _paq = window._paq = window._paq || []
let web3
const config = { defaultTransactionType: '0x0' }
const config = { defaultTransactionType: '0x0', ignoreGasPricing: true }
if (typeof window !== 'undefined' && typeof window.ethereum !== 'undefined') {
var injectedProvider = window.ethereum
web3 = new Web3(injectedProvider)

@ -11,7 +11,7 @@ const providerConfig = {
blockNumber: global.blockNumber || null
}
const config = { defaultTransactionType: '0x0' }
const config = { defaultTransactionType: '0x0', ignoreGasPricing: true }
global.remixProvider = new Provider(providerConfig)
global.remixProvider.init()
global.web3Provider = new ethers.providers.Web3Provider(global.remixProvider)

@ -74,8 +74,8 @@ function HomeTabFeaturedPlugins({plugin}: HomeTabFeaturedPluginsProps) {
}
const startCookbook = async () => {
await plugin.appManager.activatePlugin(['cookbookdev'])
plugin.verticalIcons.select('cookbook.dev')
_paq.push(['trackEvent', 'hometabActivate', 'userActivate', 'cookbook.dev'])
plugin.verticalIcons.select('cookbookdev')
_paq.push(['trackEvent', 'hometabActivate', 'userActivate', 'cookbookdev'])
}
const startSolidityUnitTesting = async () => {
await plugin.appManager.activatePlugin(['solidity', 'solidityUnitTesting'])

@ -106,48 +106,54 @@ function HomeTabGetStarted({plugin}: HomeTabGetStartedProps) {
>
<WorkspaceTemplate
gsID="sUTLogo"
workspaceTitle="Gnosis Safe MultiSig"
workspaceTitle="MultiSig"
description={
intl.formatMessage({ id: 'home.gnosisSafeMultisigTemplateDesc' })
}
projectLogo="assets/img/gnosissafeLogo.png"
callback={() => createWorkspace("gnosisSafeMultisig")}
/>
<WorkspaceTemplate
gsID="sUTLogo"
workspaceTitle="0xProject ERC20"
workspaceTitle="ERC20"
description={
intl.formatMessage({ id: 'home.zeroxErc20TemplateDesc' })
}
projectLogo="assets/img/oxprojectLogo.png"
callback={() => createWorkspace("zeroxErc20")}
/>
<WorkspaceTemplate
gsID="sourcifyLogo"
workspaceTitle="OpenZeppelin ERC20"
workspaceTitle="ERC20"
description={intl.formatMessage({id: 'home.ozerc20TemplateDesc'})}
projectLogo="assets/img/openzeppelinLogo.png"
callback={() => createWorkspace('ozerc20')}
/>
<WorkspaceTemplate
gsID="sUTLogo"
workspaceTitle="OpenZeppelin ERC721"
workspaceTitle="ERC721"
description={intl.formatMessage({
id: 'home.ozerc721TemplateDesc'
})}
projectLogo="assets/img/openzeppelinLogo.png"
callback={() => createWorkspace("ozerc721")}
/>
<WorkspaceTemplate
gsID="sUTLogo"
workspaceTitle="OpenZeppelin ERC1155"
workspaceTitle="ERC1155"
description={intl.formatMessage({
id: 'home.ozerc1155TemplateDesc'
})}
projectLogo="assets/img/openzeppelinLogo.png"
callback={() => createWorkspace("ozerc1155")}
/>
<WorkspaceTemplate
gsID="solhintLogo"
workspaceTitle="Remix Basic"
workspaceTitle="Basic"
description={intl.formatMessage({
id: 'home.remixDefaultTemplateDesc'
})}
projectLogo="assets/img/remixverticaltextLogo.png"
callback={() => createWorkspace("remixDefault")}
/>
</Carousel>

@ -1,23 +1,34 @@
/* eslint-disable @typescript-eslint/no-unused-vars */
import React, {useContext} from 'react'
import {CustomTooltip} from '@remix-ui/helper'
import {ThemeContext} from '../themeContext'
interface WorkspaceTemplateProps {
gsID: string
workspaceTitle: string
projectLogo: string
callback: any
description: string
}
function WorkspaceTemplate({gsID, workspaceTitle, description, callback}: WorkspaceTemplateProps) {
function WorkspaceTemplate({gsID, workspaceTitle, description, projectLogo, callback}: WorkspaceTemplateProps) {
const themeFilter = useContext(ThemeContext)
console.log("theme ", themeFilter)
return (
<div className="d-flex remixui_home_workspaceTemplate">
<button
className="btn border-secondary p-1 d-flex flex-column text-nowrap justify-content-center align-items-center mr-2 remixui_home_workspaceTemplate"
className="btn border-secondary p-1 d-flex flex-column text-nowrap justify-content-center mr-2 remixui_home_workspaceTemplate"
data-id={'landingPageStart' + gsID}
onClick={() => callback()}
>
<div className="mb-2 w-100 p-2 h-100 align-items-start d-flex flex-column">
<label className="h6 pb-1 text-uppercase text-dark remixui_home_cursorStyle">{workspaceTitle}</label>
<div className="remixui_home_gtDescription">{description}</div>
<div className="w-100 p-1 h-100 align-items-center d-flex flex-column">
<CustomTooltip placement={'top'} tooltipClasses="text-wrap" tooltipId="etherscan-receipt-proxy-status" tooltipText={description}>
<div className='d-flex flex-column align-items-center'>
<label className="h5 pb-1 mt-1 text-uppercase remixui_home_cursorStyle" style={{color: themeFilter.name == "dark" ? "var(--white)" : "var(--black)"}}>{workspaceTitle}</label>
<img className="" src={projectLogo} alt="" style={{height: "20px", width: "fit-content", filter: themeFilter.name == "dark" ? "invert(1)" : "invert(0)"}} />
</div>
</CustomTooltip>
</div>
</button>
</div>

@ -76,8 +76,8 @@
text-align: left;
}
.remixui_home_cursorStyle {
cursor: pointer;
font-size: 0.8rem;
cursor: pointer;
font-weight: 900;
}
.remixui_home_envButton {
width: 220px;

Loading…
Cancel
Save