diff --git a/apps/remix-ide/src/app/editor/SourceHighlighters.js b/apps/remix-ide/src/app/editor/SourceHighlighters.js index 2accd543b3..0d212e74b7 100644 --- a/apps/remix-ide/src/app/editor/SourceHighlighters.js +++ b/apps/remix-ide/src/app/editor/SourceHighlighters.js @@ -32,8 +32,8 @@ class SourceHighlighters { for (const index in this.highlighters[from]) { sourceHighlight.currentSourceLocationFromfileName( this.highlighters[from][index].position, - this.highlighters[from][index].filePath, - this.highlighters[from][index].hexColor + this.highlighters[from][index].source, + this.highlighters[from][index].style ) this.highlighters[from][index] = sourceHighlight } diff --git a/apps/remix-ide/src/app/editor/sourceHighlighter.js b/apps/remix-ide/src/app/editor/sourceHighlighter.js index 54121e8094..5c51225670 100644 --- a/apps/remix-ide/src/app/editor/sourceHighlighter.js +++ b/apps/remix-ide/src/app/editor/sourceHighlighter.js @@ -39,7 +39,8 @@ class SourceHighlighter { this.source = null if (lineColumnPos) { this.source = filePath - if (!this.source) this.source = this._deps.fileManager.currentFile() + this.style = style || 'var(--info)' + //if (!this.source) this.source = this._deps.fileManager.currentFile() if (this._deps.fileManager.currentFile() !== this.source) { await this._deps.fileManager.open(this.source) this.source = this._deps.fileManager.currentFile() @@ -50,16 +51,16 @@ class SourceHighlighter { position:absolute; z-index:20; opacity: 0.3; - background-color: ${style || 'var(--info)'}; + background-color: ${this.style}; } .highlightcode_fullLine { position:absolute; z-index:20; opacity: 0.5; - background-color: ${style || 'var(--info)'}; + background-color: ${this.style}; } .customBackgroundColor { - background-color: ${style || 'var(--info)'}; + background-color: ${this.style}; } `