fix compilation details

pull/4420/head
Joseph Izang 1 year ago committed by Aniket
parent 3778cd0d8f
commit 67d3f78816
  1. 10
      libs/remix-ui/vyper-compile-details/src/lib/vyperCompile.tsx

@ -58,18 +58,22 @@ export default function VyperCompile({result, theme, themeStyle}: VyperCompilePr
<Tab eventKey={content.eventKey} title={content.tabHeadingText} as={'span'} key={`${index}-${content.eventKey}`}> <Tab eventKey={content.eventKey} title={content.tabHeadingText} as={'span'} key={`${index}-${content.eventKey}`}>
<div className="d-flex flex-column w-75 justify-content-center mx-auto rounded-2"> <div className="d-flex flex-column w-75 justify-content-center mx-auto rounded-2">
<CopyToClipboard getContent={() => (content.eventKey !== 'abi' ? content.tabPayload : JSON.stringify(result['abi']))}> <CopyToClipboard getContent={() => (content.eventKey !== 'abi' ? content.tabPayload : JSON.stringify(result['abi']))}>
<Button variant="info" className="copy mt-3 ml-2" data-id={content.eventKey === 'abi' ? 'copy-abi' : ''}> <Button
variant="info"
className="copy mt-3 ml-2"
data-id={content.eventKey === 'abi' ? 'copy-abi' : ''}
>
<span className="far fa-copy mr-2"></span> <span className="far fa-copy mr-2"></span>
{content.tabButtonText()} {content.tabButtonText()}
</Button> </Button>
</CopyToClipboard> </CopyToClipboard>
{content.eventKey === 'abi' ? ( {content.eventKey === 'abi' ? (
<div className="my-3"> <div className="my-3">
<JSONTree {JSON.stringify(content?.tabPayload)?.length > 1 ? <JSONTree
src={content.tabPayload as ABIDescription[]} src={content.tabPayload as ABIDescription[]}
theme={theme} theme={theme}
style={themeStyle} style={themeStyle}
/> /> : null}
</div> </div>
) : ( ) : (
<div className="w-100 mt-2 p-2 mx-auto"> <div className="w-100 mt-2 p-2 mx-auto">

Loading…
Cancel
Save