fix title-bar drag area

This commit is contained in:
sawka 2023-10-14 14:30:50 -07:00
parent fbcf8f2fbb
commit 18fa085fa1
3 changed files with 12 additions and 2 deletions

View File

@ -126,7 +126,7 @@ svg.icon {
#title-bar { #title-bar {
-webkit-app-region: drag; -webkit-app-region: drag;
height: 30px; height: 10px;
width: 100%; width: 100%;
position: absolute; position: absolute;
top: 0; top: 0;

View File

@ -197,6 +197,7 @@ class MainSideBar extends React.Component<{}, {}> {
let mainView = GlobalModel.activeMainView.get(); let mainView = GlobalModel.activeMainView.get();
return ( return (
<div className={cn("main-sidebar", { collapsed: isCollapsed }, { "is-dev": GlobalModel.isDev })}> <div className={cn("main-sidebar", { collapsed: isCollapsed }, { "is-dev": GlobalModel.isDev })}>
<div className="title-bar-drag"/>
<div className="arrow-container hoverEffect" onClick={this.toggleCollapsed}> <div className="arrow-container hoverEffect" onClick={this.toggleCollapsed}>
<LeftChevronIcon className="icon" /> <LeftChevronIcon className="icon" />
</div> </div>
@ -206,7 +207,7 @@ class MainSideBar extends React.Component<{}, {}> {
<AppsIcon className="icon" /> <AppsIcon className="icon" />
Apps Apps
<span className="hotkey">&#x2318;A</span> <span className="hotkey">&#x2318;A</span>
</div>*/} </div>*/}
<div className="item hoverEffect" onClick={this.handleHistoryClick}> <div className="item hoverEffect" onClick={this.handleHistoryClick}>
<HistoryIcon className="icon" /> <HistoryIcon className="icon" />
History History

View File

@ -8,6 +8,15 @@
flex-direction: column; flex-direction: column;
position: relative; position: relative;
.title-bar-drag {
-webkit-app-region: drag;
height: 20px;
position: absolute;
top: 0;
left: 0;
width: 100%;
}
&.collapsed { &.collapsed {
width: 6em; width: 6em;
min-width: 6em; min-width: 6em;