mirror of
https://github.com/spacedriveapp/spacedrive
synced 2024-07-08 07:12:49 +00:00
fixed traffic lights bar showing all the time (#464)
desconstructed props inside TrafficLights Co-authored-by: Erik Podušel <podusel@gomerch.company>
This commit is contained in:
parent
a403224b3b
commit
90890bbc1c
|
@ -80,7 +80,7 @@ async fn main() -> Result<(), Box<dyn Error>> {
|
|||
use macos::*;
|
||||
|
||||
let window = window.ns_window().unwrap();
|
||||
set_titlebar_style(window, true, true);
|
||||
set_titlebar_style(window, true, false);
|
||||
blur_window_background(window);
|
||||
}
|
||||
});
|
||||
|
|
|
@ -14,15 +14,17 @@ export interface TrafficLightsProps extends DefaultProps {
|
|||
}
|
||||
|
||||
export function MacTrafficLights(props: TrafficLightsProps) {
|
||||
const {onClose, onMinimize, onFullscreen, className} = props;
|
||||
const [focused] = useFocusState();
|
||||
|
||||
return (
|
||||
<div
|
||||
data-tauri-drag-region
|
||||
className={clsx('flex flex-row space-x-[7.5px] group', props.className)}
|
||||
className={clsx('flex flex-row space-x-[7.5px] group', className)}
|
||||
>
|
||||
<TrafficLight type="close" onClick={props.onClose} colorful={focused} />
|
||||
<TrafficLight type="minimize" onClick={props.onMinimize} colorful={focused} />
|
||||
<TrafficLight type="fullscreen" onClick={props.onFullscreen} colorful={focused} />
|
||||
<TrafficLight type="close" onClick={onClose} colorful={focused} />
|
||||
<TrafficLight type="minimize" onClick={onMinimize} colorful={focused} />
|
||||
<TrafficLight type="fullscreen" onClick={onFullscreen} colorful={focused} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue