Gmail - show full date and time in mail list

Just show the full date and time on the list instead of only short date. Useful if you need to create a report and you base on your activity and it's timing. Or when you look at mails and want to find one visually by looking on times.

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name        Gmail - show full date and time in mail list
// @description Just show the full date and time on the list instead of only short date. Useful if you need to create a report and you base on your activity and it's timing. Or when you look at mails and want to find one visually by looking on times.
// @namespace   https://www.facebook.com/zbyszek.matuszewski
// @include     https://mail.google.com/mail/*
// @version     0.3.2
// @grant       none
// ==/UserScript==

(function() {
  window.setInterval(function() {
    var date_titles_main = Array.from(document.getElementsByClassName("xW xY"));
    var date_titles_thread = Array.from(document.getElementsByClassName("g3"));
    date_titles_main.forEach(function(element, index, array) {
      var elements = element.childNodes;
      var title = elements.length > 0 ? elements[0].title : false;
      if (title && elements[0].innerHTML != title) { elements[0].innerHTML = title; }
    });
    date_titles_thread.forEach(function(element, index, array) {
      if (element.title && element.innerHTML != element.title) { element.innerHTML = element.title; }
    });
    Array.from(document.getElementsByClassName("xX")).forEach(function(element, index, array) {
      element.style.width = '20ex';
    });
    Array.from(document.getElementsByClassName("xW")).forEach(function(element, index, array) {
      element.style['max-width'] = '145px';
      element.style['flex-basis'] = '145ex';
    });
  }, 2000);
})();