${self._view.iconpanel}
${self._view.sidepanel}
${self._components.resizeFeature.render()}
diff --git a/src/app/components/vertical-icons.js b/src/app/components/vertical-icons.js
index 098cc1dece..cef410640d 100644
--- a/src/app/components/vertical-icons.js
+++ b/src/app/components/vertical-icons.js
@@ -171,6 +171,7 @@ export class VerticalIcons extends Plugin {
* @param {string} name Name of profile of the module to activate
*/
addActive (name) {
+ if (name === 'home') return
const themeType = globalRegistry.get('themeModule').api.currentTheme().quality
const invert = themeType === 'dark' ? 1 : 0
const brightness = themeType === 'dark' ? '150' : '0' // should be >100 for icons with color
diff --git a/src/app/panels/main-view.js b/src/app/panels/main-view.js
index 1640a0279e..8437b7a41e 100644
--- a/src/app/panels/main-view.js
+++ b/src/app/panels/main-view.js
@@ -11,19 +11,12 @@ var ContextView = require('../editor/contextView')
var csjs = require('csjs-inject')
var css = csjs`
- .mainview {
- display : flex;
- flex-direction : column;
- height : 100%;
- }
- .content {
- position : relative;
+ .mainview {
display : flex;
flex-direction : column;
height : 100%;
width : 100%;
}
-
`
export class MainView {
@@ -181,13 +174,13 @@ export class MainView {
}
render () {
var self = this
- if (self._view.el) return self._view.el
+ if (self._view.mainview) return self._view.mainview
self._view.editor = self.editor.render()
self._view.editor.style.display = 'none'
self._view.mainPanel = self.mainPanel.render()
self._view.terminal = self._components.terminal.render()
- self._view.content = yo`
-
+ self._view.mainview = yo`
+
${self.tabProxy.renderTabsbar()}
${self._view.editor}
${self._view.mainPanel}
@@ -195,11 +188,6 @@ export class MainView {
${self._view.terminal}
`
- self._view.el = yo`
-
- ${self._view.content}
-
- `
// INIT
self._adjustLayout('top', self.data._layout.top.offset)
@@ -207,7 +195,7 @@ export class MainView {
if (e.altKey && e.keyCode === 84) self.tabProxy.switchNextTab() // alt + t
})
- return self._view.el
+ return self._view.mainview
}
registerCommand (name, command, opts) {
var self = this
diff --git a/src/app/panels/tab-proxy.js b/src/app/panels/tab-proxy.js
index 47f2988553..d3c46f6cc0 100644
--- a/src/app/panels/tab-proxy.js
+++ b/src/app/panels/tab-proxy.js
@@ -117,10 +117,6 @@ export class TabProxy {
}
}
- showTab (name) {
- this._view.filetabs.activateTab(name)
- }
-
addTab (name, title, switchTo, close, icon) {
if (this._handlers[name]) return
@@ -147,6 +143,14 @@ export class TabProxy {
this.handlers[type] = fn
}
+ onZoomOut () {
+ this.editor.editorFontSize(-1)
+ }
+
+ onZoomIn () {
+ this.editor.editorFontSize(1)
+ }
+
renderTabsbar () {
this._view.filetabs = yo`
`
this._view.filetabs.addEventListener('tabClosed', (event) => {
@@ -160,14 +164,18 @@ export class TabProxy {
this._view.filetabs.canAdd = false
- this._view.tabs = yo`
-
- ${this._view.filetabs}
+ const zoomBtns = yo`
+
+ this.onZoomOut()}>
+ this.onZoomIn()}>
`
- let tabsbar = yo`
-
- ${this._view.tabs}
+
+ // @todo(#2492) remove style after the mainPanel layout fix.
+ this._view.tabs = yo`
+
+ ${zoomBtns}
+ ${this._view.filetabs}
`
@@ -191,6 +199,6 @@ export class TabProxy {
return false
})
- return tabsbar
+ return this._view.tabs
}
}