removed titlebar

This commit is contained in:
Eugene Pankov 2017-01-18 22:13:50 +01:00
parent 24f28bba06
commit c18936f6e5
2 changed files with 32 additions and 61 deletions

View file

@ -13,7 +13,6 @@
background: @body-bg; background: @body-bg;
} }
@titlebar-height: 35px;
@tabs-height: 40px; @tabs-height: 40px;
@tab-border-radius: 4px; @tab-border-radius: 4px;
@ -29,35 +28,6 @@
} }
} }
.titlebar {
height: @titlebar-height;
background: #141c23;
flex: none;
display: flex;
flex-direction: row;
.title {
flex: auto;
padding-left: 15px;
line-height: @titlebar-height;
-webkit-app-region: drag;
}
.btn-minimize, .btn-maximize, .btn-close {
flex: none;
line-height: @titlebar-height - 2px;
padding: 0 15px;
font-size: 8px;
.button-states();
cursor: pointer;
}
.btn-close {
font-size: 12px;
}
}
.tabs { .tabs {
flex: none; flex: none;
height: @tabs-height; height: @tabs-height;
@ -66,28 +36,29 @@
display: flex; display: flex;
flex-direction: row; flex-direction: row;
.btn-settings, .btn-new-tab, .tab { &>button {
line-height: @tabs-height - 2px; border: none;
cursor: pointer;
}
.btn-new-tab, .btn-settings {
padding: 0 15px;
flex: none; flex: none;
flex-grow: 0; line-height: @tabs-height;
border-bottom: 2px solid transparent; padding: 0 15px;
transition: 0.25s all; font-size: 8px;
text-transform: uppercase;
font-weight: bold;
color: #888;
background: #141c23; background: #141c23;
i { .button-states();
margin-right: 10px; cursor: pointer;
&.btn-close {
font-size: 12px;
} }
.button-states(); &.btn-new-tab {
border-bottom-left-radius: @tab-border-radius;
font-size: 14px;
}
&.btn-settings {
font-size: 14px;
}
} }
.tab { .tab {
@ -95,6 +66,12 @@
flex-basis: 0; flex-basis: 0;
flex-grow: 1000; flex-grow: 1000;
&:active {
-webkit-app-region: drag;
}
line-height: @tabs-height - 2px;
display: flex; display: flex;
overflow: hidden; overflow: hidden;
min-width: 0; min-width: 0;
@ -180,8 +157,6 @@
.content-wrapper { .content-wrapper {
//border-bottom: 2px solid #69bbea; //border-bottom: 2px solid #69bbea;
background: @body-bg; background: @body-bg;
border-top-left-radius: @tab-border-radius;
border-top-right-radius: @tab-border-radius;
} }
} }
} }

View file

@ -1,12 +1,3 @@
.titlebar
.title((dblclick)='hostApp.maximizeWindow()') Term
.btn-minimize((click)='hostApp.minimizeWindow()')
i.fa.fa-window-minimize
.btn-maximize((click)='hostApp.maximizeWindow()')
i.fa.fa-window-maximize
.btn-close((click)='hostApp.quit()')
i.fa.fa-close
.tabs .tabs
.tab( .tab(
*ngFor='let tab of tabs; let idx = index; trackBy: tab?.id', *ngFor='let tab of tabs; let idx = index; trackBy: tab?.id',
@ -20,11 +11,16 @@
div.index {{idx + 1}} div.index {{idx + 1}}
div.name {{tab.name || 'Terminal'}} div.name {{tab.name || 'Terminal'}}
button((click)='closeTab(tab)') × button((click)='closeTab(tab)') ×
.btn-new-tab((click)='newTab()') button.btn-new-tab((click)='newTab()')
i.fa.fa-plus i.fa.fa-plus
span Tab button.btn-settings((click)='showSettings()')
.btn-settings((click)='showSettings()')
i.fa.fa-cog i.fa.fa-cog
button.btn-minimize((click)='hostApp.minimizeWindow()')
i.fa.fa-window-minimize
button.btn-maximize((click)='hostApp.maximizeWindow()')
i.fa.fa-window-maximize
button.btn-close((click)='hostApp.quit()')
i.fa.fa-close
.tabs-content .tabs-content
.tab(*ngFor='let tab of tabs; trackBy: tab?.id', [class.active]='tab == activeTab') .tab(*ngFor='let tab of tabs; trackBy: tab?.id', [class.active]='tab == activeTab')