💄 window bar matches app
This commit is contained in:
@@ -15,6 +15,7 @@ function createWindow(): void {
|
|||||||
minWidth: 900,
|
minWidth: 900,
|
||||||
minHeight: 600,
|
minHeight: 600,
|
||||||
title: 'Hohoff Editor',
|
title: 'Hohoff Editor',
|
||||||
|
titleBarStyle: 'hiddenInset',
|
||||||
show: false,
|
show: false,
|
||||||
webPreferences: {
|
webPreferences: {
|
||||||
preload: join(__dirname, '../preload/index.js'),
|
preload: join(__dirname, '../preload/index.js'),
|
||||||
|
|||||||
@@ -32,6 +32,9 @@ export default function App(): JSX.Element {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="app-layout">
|
<div className="app-layout">
|
||||||
|
<div className="app-titlebar">
|
||||||
|
<span className="app-titlebar-title">Hohoff Editor</span>
|
||||||
|
</div>
|
||||||
<aside className="sidebar">
|
<aside className="sidebar">
|
||||||
<FileTree />
|
<FileTree />
|
||||||
</aside>
|
</aside>
|
||||||
|
|||||||
@@ -1,11 +1,33 @@
|
|||||||
.app-layout {
|
.app-layout {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template-columns: 220px 1fr 340px;
|
grid-template-columns: 220px 1fr 340px;
|
||||||
grid-template-rows: 100vh;
|
grid-template-rows: 38px calc(100vh - 38px);
|
||||||
height: 100vh;
|
height: 100vh;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.app-titlebar {
|
||||||
|
grid-column: 1 / -1;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
background: var(--sidebar-bg);
|
||||||
|
border-bottom: 1px solid var(--border);
|
||||||
|
/* Makes the entire bar draggable so the window can be moved */
|
||||||
|
-webkit-app-region: drag;
|
||||||
|
user-select: none;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.app-titlebar-title {
|
||||||
|
font-size: 12px;
|
||||||
|
font-family: var(--font-sans);
|
||||||
|
font-weight: 600;
|
||||||
|
letter-spacing: 0.08em;
|
||||||
|
color: var(--text-muted);
|
||||||
|
text-transform: uppercase;
|
||||||
|
}
|
||||||
|
|
||||||
/* ─── Sidebar ──────────────────────────────────────────────────── */
|
/* ─── Sidebar ──────────────────────────────────────────────────── */
|
||||||
.sidebar {
|
.sidebar {
|
||||||
background: var(--sidebar-bg);
|
background: var(--sidebar-bg);
|
||||||
|
|||||||
Reference in New Issue
Block a user