react-windows-controls
v1.1.1
Published
Windows title bar control buttons for React
Downloads
595
Maintainers
Readme
react-windows-controls
Windows 10 title bar control buttons for React.
Installation
To install this package, just run
$ npm install react-windows-controls
Quick example
import { remote } from 'electron';
import { WindowsControls } from 'react-windows-controls';
export default () => (
<WindowsControls isMaximized={remote.getCurrentWindow().isMaximized()} />
);
Components
<WindowsControls />
dark
boolean - whether to invert icons colorsonClose
Function - on close button click eventisMaximized
boolean - whether to show the restore buttononMaximize
Function - on maximize button click eventonMinimize
Function - on minimize button click eventonMouseUp
FunctiononMouseDown
Functionstyle
any
<WindowsControl />
maximize
boolean - whether the button is a maximize buttonclose
boolean - whether the button is a close buttonminimize
boolean - whether the button is a minimize buttonrestore
boolean - whether the button is a restore buttonwhiteIcon
boolean - whether to invert icon coloronClick
FunctiononMouseUp
FunctiononMouseDown
Functionstyle
any