• Stars
    star
    141
  • Rank 259,971 (Top 6 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created about 8 years ago
  • Updated about 4 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Adds the Windows 10 ModernUI (Metro)-style titlebars to any Electron-based desktop app.

electron-titlebar-windows

Adds CSS-based Windows 10 Modern UI title bars to any Electron-based desktop app.

screen

Installation

$ npm install --save electron-titlebar-windows

API

Importing the module

const ElectronTitlebarWindows = require('electron-titlebar-windows');

Creating a new instance

The module takes a single optional options argument and exports the TitleBar class:

const titlebar = new ElectronTitlebarWindows(options);

Properties of options:

  • (optional) darkMode - String - Light titlebar buttons (for dark backgrounds)
  • (optional) color - String - Icon color (Hex)
  • (optional) backgroundColor - String - Bar color (Hex)
  • (optional) draggable - Boolean - Titlebar enables dragging of contained window
  • (optional) fullscreen - Boolean - Resize button initializes in fullscreen mode

Methods

#appendTo

Shows the Title Bar.

titlebar.appendTo(contextElement);
  • (optional) contextElement - HTMLElement - Default: document.body - Element to which to add the titlebar

#destroy

Removes the Title Bar.

titlebar.destroy();

Events

TitleBar emits the following events:

  • minimize
  • maximize
  • fullscreen
  • close
titlebar.on('close', function(e) {
    console.log('close');
});

License

MIT © sidneys

Related

Based on titlebar

More Repositories

1

pb-for-desktop

The missing Desktop application for Pushbullet.
JavaScript
507
star
2

desktop-dimmer

Enable darker-than-dark dimming for internal and external screens.
JavaScript
374
star
3

ffmpeg-progressbar-cli

A colored progress bar for FFmpeg.
JavaScript
206
star
4

live-wallpaper-ecorp

Animated Wallpaper featuring the E-Corp company logo from Mr. Robot.
JavaScript
36
star
5

homebrew-homebrew

sidneys.github.io Homebrew Tap
Ruby
23
star
6

youtube-playlist-player

Watch and edit YouTube playlists on the desktop.
CSS
17
star
7

cordova-plugin-progressview

Cordova+PhoneGap Extension for displaying a native determinate progress dialog.
Objective-C
7
star
8

xml-to-srt-cli

Convert XML subtitles (EBU-TT format) from online broadcasting platforms like MediathekView (Germany) or the BBC (UK) into SRT (SubRip) subtitles.
JavaScript
6
star
9

quicklook-thumbnail

Use NodeJS to generate thumbnail images for all QuickLook-enabled filetypes (e.g. .mp4 videos, iMessage transcripts, text files) on Apple OSX.
JavaScript
6
star
10

open-with-iina

Discover & open web-based media inside macOS' IINA media player
JavaScript
5
star
11

cordova-autocrosswalk

Shell / Bash script to auto-convert Cordova 3.6 projects to Cordova Crosswalk.
Shell
4
star
12

notificationcenter-settings-macos

Exposes a streamlined interface to the Notification Center settings for macOS applications.
JavaScript
3
star
13

specialkey-emulator

Emulate special keys (e.g. brightness, play/pause, increase volume) by emitting low-level global keyboard events - using NodeJS.
JavaScript
3
star
14

specialkey-emulator-cli

Emulate special keys from the command line.
JavaScript
2
star
15

macos-accessibility-keyboard

The missing interface for the hidden native virtual on-screen keyboard on macOS.
JavaScript
2
star
16

npm-check-global-updates

Find newer versions of global npm packages
JavaScript
2
star