Gmail Dark Theme

Dark theme for Gmail. Changing default dark theme, some backround colors and adding some borders

θα χρειαστεί να εγκαταστήσετε μια επέκταση όπως το Tampermonkey, το Greasemonkey ή το Violentmonkey για να εγκαταστήσετε αυτόν τον κώδικα.

You will need to install an extension such as Tampermonkey to install this script.

θα χρειαστεί να εγκαταστήσετε μια επέκταση όπως το Tampermonkey ή το Violentmonkey για να εγκαταστήσετε αυτόν τον κώδικα.

θα χρειαστεί να εγκαταστήσετε μια επέκταση όπως το Tampermonkey ή το Userscripts για να εγκαταστήσετε αυτόν τον κώδικα.

You will need to install an extension such as Tampermonkey to install this script.

Θα χρειαστεί να εγκαταστήσετε μια επέκταση διαχείρισης κώδικα χρήστη για να εγκαταστήσετε αυτόν τον κώδικα.

(Έχω ήδη έναν διαχειριστή κώδικα χρήστη, επιτρέψτε μου να τον εγκαταστήσω!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(Έχω ήδη έναν διαχειριστή στυλ χρήστη, επιτρέψτε μου να τον εγκαταστήσω!)

// ==UserScript==
// @name        Gmail Dark Theme
// @version     1.0.1
// @date        2020-05-03
// @author      Getsumi3
// @description Dark theme for Gmail. Changing default dark theme, some backround colors and adding some borders
// @match       *://mail.google.com/*
// @grant       none
// @run-at      document-start
// @license     MIT
// @copyright 2020, Getsumi3 (https://https://github.com/Getsumi3)
// @namespace https://greasyfork.org/users/549792
// ==/UserScript==

function addGlobalStyle(css) {
  var head, style;
  head = document.getElementsByTagName('head')[0];
  if (!head) {
    return;
  }
  style = document.createElement('style');
  style.type = 'text/css';
  style.innerHTML = css;
  head.appendChild(style);
}

//making the loading screen dark! so your eyes will not burn while gmail is loading
addGlobalStyle('#loading { background-color: #111111; }');
addGlobalStyle('#bhlf { color: rgba(255,255,255,0.70); }');

//adding some space between inbox categories and e-mails, and removing the bg color
addGlobalStyle('.aKh { padding-bottom: 10px; background-color: inherit !important; }');

//changing border for each inbox category
addGlobalStyle('.aIf-aLe { border-right: 2px solid #ff9800 !important; }');
addGlobalStyle('.aKe-aLe { border-right: 3px solid #2196F3 !important; }');
addGlobalStyle('.aJi-aLe { border-right: 3px solid #74b973 !important; }');

//pretifying hover for inbox categories
addGlobalStyle('.aRz.J-KU:hover { background: rgb(255,255,255) !important; background: linear-gradient(45deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.25) 100%) !important; }');

//changing bg-color for unread e-mails,adding left border to mark unread e-mails
addGlobalStyle('.zE { background-color: #191a1f !important; border-left: 3px solid #ff9800; margin-bottom: 5px;}');

//changing bg-color for read e-mails,adding left border to mark read e-mails
addGlobalStyle('.yO { background-color: #111111 !important; border-left: 3px solid #2196F3; margin-bottom: 5px;}');

//TODO: Changing colors for message itself