Commit e48b1b88 authored by LianaHus's avatar LianaHus

some fixes

parent a3cf9ec6
......@@ -7,7 +7,7 @@ module.exports = (sources, opts) => {
settings: {
optimizer: {
enabled: opts.optimize === true || opts.optimize === 1,
runs: opts.runs
runs: opts.runs || 200
},
libraries: opts.libraries,
outputSelection: {
......
......@@ -176,7 +176,7 @@ class CompilerContainer {
this.compileTabLogic.compiler.event.register('compilerLoaded', (version) => this.setVersionText(version))
this.fetchAllVersion((allversions, selectedVersion, isURL) => {
this.data.allversions = allversions
if(isURL) this._updateVersionSelector(selectedVersion)
if (isURL) this._updateVersionSelector(selectedVersion)
else {
this.data.selectedVersion = selectedVersion
if (this._view.versionSelector) this._updateVersionSelector()
......@@ -194,9 +194,8 @@ class CompilerContainer {
if (this.compileTabLogic.optimize) this._view.optimize.setAttribute('checked', '')
this._view.runs = yo`<input
onkeypress="return event.charCode >= 48"
min="1"
class="custom-select ml-2 w-50"
class="custom-select ml-2 ${css.runs}"
id="runs"
placeholder="200"
type="number"
......@@ -496,8 +495,8 @@ class CompilerContainer {
// Check if version is a URL and corresponding filename starts with 'soljson'
if (selectedVersion.startsWith('https://')) {
const urlArr = selectedVersion.split('/')
if(urlArr[urlArr.length - 1].startsWith('soljson')) isURL = true
}
if (urlArr[urlArr.length - 1].startsWith('soljson')) isURL = true
}
if (wasmRes.event.type !== 'error') {
allVersionsWasm = JSON.parse(wasmRes.json).builds.slice().reverse()
}
......
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment