|
|
@ -477,12 +477,11 @@ export const RemixUiStaticAnalyser = (props: RemixUiStaticAnalyserProps) => { |
|
|
|
return ( |
|
|
|
return ( |
|
|
|
<div className="analysis_3ECCBV px-3 pb-1"> |
|
|
|
<div className="analysis_3ECCBV px-3 pb-1"> |
|
|
|
<div className="my-2 d-flex flex-column align-items-left"> |
|
|
|
<div className="my-2 d-flex flex-column align-items-left"> |
|
|
|
testing... |
|
|
|
<div className="d-flex justify-content-between mb-3" id="staticanalysisButton"> |
|
|
|
<div className="d-flex justify-content-between" id="staticanalysisButton"> |
|
|
|
|
|
|
|
<RemixUiCheckbox |
|
|
|
<RemixUiCheckbox |
|
|
|
id="autorunstaticanalysis" |
|
|
|
id="autorunstaticanalysis" |
|
|
|
inputType="checkbox" |
|
|
|
inputType="checkbox" |
|
|
|
title="Run static analysis after the compilation" |
|
|
|
title="Run solhint static analysis on file save" |
|
|
|
onClick={handleAutoRun} |
|
|
|
onClick={handleAutoRun} |
|
|
|
checked={autoRun} |
|
|
|
checked={autoRun} |
|
|
|
label="Linter" |
|
|
|
label="Linter" |
|
|
@ -498,29 +497,42 @@ export const RemixUiStaticAnalyser = (props: RemixUiStaticAnalyserProps) => { |
|
|
|
return x._index.toString() |
|
|
|
return x._index.toString() |
|
|
|
})) |
|
|
|
})) |
|
|
|
}).flat().every(el => categoryIndex.includes(el))} |
|
|
|
}).flat().every(el => categoryIndex.includes(el))} |
|
|
|
label="Select all" |
|
|
|
label="Basic" |
|
|
|
onClick={() => handleCheckAllModules(groupedModules)} |
|
|
|
onClick={() => handleCheckAllModules(groupedModules)} |
|
|
|
onChange={() => {}} |
|
|
|
onChange={() => {}} |
|
|
|
tooltipPlacement={'top-start'} |
|
|
|
tooltipPlacement={'top-start'} |
|
|
|
/> |
|
|
|
/> |
|
|
|
|
|
|
|
<div className="d-flex mt-1" id="enableSlitherAnalysis"> |
|
|
|
<RemixUiCheckbox |
|
|
|
<RemixUiCheckbox |
|
|
|
id="autorunstaticanalysis" |
|
|
|
id="enableSlither" |
|
|
|
inputType="checkbox" |
|
|
|
inputType="checkbox" |
|
|
|
title="Run static analysis after the compilation" |
|
|
|
onClick={handleSlitherEnabled} |
|
|
|
onClick={handleAutoRun} |
|
|
|
checked={slitherEnabled} |
|
|
|
checked={autoRun} |
|
|
|
label="Slither" |
|
|
|
label="Autorun" |
|
|
|
disabled={showSlither} |
|
|
|
onChange={() => {}} |
|
|
|
onChange={() => {}} |
|
|
|
tooltipPlacement={'bottom-start'} |
|
|
|
|
|
|
|
/> |
|
|
|
/> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<a className="mt-1 text-nowrap" href='https://remix-ide.readthedocs.io/en/latest/slither.html#enable-slither-analysis' target={'_blank'}> |
|
|
|
|
|
|
|
<CustomTooltip |
|
|
|
|
|
|
|
placement={'right'} |
|
|
|
|
|
|
|
tooltipClasses="text-nowrap" |
|
|
|
|
|
|
|
tooltipId="overlay-tooltip" |
|
|
|
|
|
|
|
tooltipText={<span className="border bg-light text-dark p-1 pr-3" style={{minWidth: '230px' }}>Learn how to use Slither Analysis</span>} |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
<i style={{ fontSize: 'medium' }} className={'fal fa-info-circle ml-3'} aria-hidden="true"></i> |
|
|
|
|
|
|
|
</CustomTooltip> |
|
|
|
|
|
|
|
</a> |
|
|
|
|
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<Button |
|
|
|
<Button |
|
|
|
buttonText="Run" |
|
|
|
buttonText="Run" |
|
|
|
title={runButtonTitle} |
|
|
|
title={runButtonTitle} |
|
|
|
|
|
|
|
classList="btn btn-sm btn-primary btn-block" |
|
|
|
onClick={async () => await run(state.data, state.source, state.file)} |
|
|
|
onClick={async () => await run(state.data, state.source, state.file)} |
|
|
|
disabled={(state.data === null || categoryIndex.length === 0) && !slitherEnabled || !isSupportedVersion } |
|
|
|
disabled={(state.data === null || categoryIndex.length === 0) && !slitherEnabled || !isSupportedVersion } |
|
|
|
/> |
|
|
|
/> |
|
|
|
{ showSlither && |
|
|
|
{/* { showSlither && |
|
|
|
<div className="d-flex mt-2" id="enableSlitherAnalysis"> |
|
|
|
<div className="d-flex mt-2" id="enableSlitherAnalysis"> |
|
|
|
<RemixUiCheckbox |
|
|
|
<RemixUiCheckbox |
|
|
|
id="enableSlither" |
|
|
|
id="enableSlither" |
|
|
@ -528,7 +540,7 @@ export const RemixUiStaticAnalyser = (props: RemixUiStaticAnalyserProps) => { |
|
|
|
onClick={handleSlitherEnabled} |
|
|
|
onClick={handleSlitherEnabled} |
|
|
|
checked={slitherEnabled} |
|
|
|
checked={slitherEnabled} |
|
|
|
label="Enable Slither Analysis" |
|
|
|
label="Enable Slither Analysis" |
|
|
|
|
|
|
|
disabled={showSlither} |
|
|
|
onChange={() => {}} |
|
|
|
onChange={() => {}} |
|
|
|
/> |
|
|
|
/> |
|
|
|
|
|
|
|
|
|
|
@ -543,7 +555,7 @@ export const RemixUiStaticAnalyser = (props: RemixUiStaticAnalyserProps) => { |
|
|
|
</CustomTooltip> |
|
|
|
</CustomTooltip> |
|
|
|
</a> |
|
|
|
</a> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
} |
|
|
|
} */} |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
{/* <div id="staticanalysismodules" className="list-group list-group-flush"> |
|
|
|
{/* <div id="staticanalysismodules" className="list-group list-group-flush"> |
|
|
|
{Object.keys(groupedModules).map((categoryId, i) => { |
|
|
|
{Object.keys(groupedModules).map((categoryId, i) => { |
|
|
|