diff --git a/apps/remix-ide/src/app/panels/tab-proxy.js b/apps/remix-ide/src/app/panels/tab-proxy.js index 984efe7534..fa6521023a 100644 --- a/apps/remix-ide/src/app/panels/tab-proxy.js +++ b/apps/remix-ide/src/app/panels/tab-proxy.js @@ -224,9 +224,23 @@ export class TabProxy extends Plugin { this.removeTab(oldName) } + /** + * + * @param {string} name + * @param {string} title + * @param {Function} switchTo + * @param {Function} close + * @param {string} icon + * @param {string} description + * @returns + */ addTab (name, title, switchTo, close, icon, description = '') { if (this._handlers[name]) return this.renderComponent() + if ((name.endsWith('.vy') && icon === undefined) || title.includes('Vyper')) { + icon = 'assets/img/vyperLogo2.webp' + } + var slash = name.split('/') const tabPath = slash.reverse() const tempTitle = [] @@ -292,7 +306,7 @@ export class TabProxy extends Plugin { if (!previous && tab.name === name) { if(index - 1 >= 0 && this.loadedTabs[index - 1]) previous = this.loadedTabs[index - 1] - else if (index + 1 && this.loadedTabs[index + 1]) + else if (index + 1 && this.loadedTabs[index + 1]) previous = this.loadedTabs[index + 1] } return tab.name !== name diff --git a/apps/remix-ide/src/assets/img/vyperLogo2.webp b/apps/remix-ide/src/assets/img/vyperLogo2.webp new file mode 100644 index 0000000000..fc85993627 Binary files /dev/null and b/apps/remix-ide/src/assets/img/vyperLogo2.webp differ