CSS: meteoblue.com

Minor corrections to UI of meteoblue.com

目前为 2021-01-01 提交的版本。查看 最新版本

  1. // ==UserScript==
  2. // @name CSS: meteoblue.com
  3. // @description Minor corrections to UI of meteoblue.com
  4. // @author MK
  5. // @homepage https://greasyfork.org/en/scripts/419280
  6. // @namespace https://greasyfork.org/users/309172
  7. // @include https://www.meteoblue.com/*
  8. // @include http://www.meteoblue.com/*
  9. // @version 1.2
  10. // @note v1.2 2021-01-01 - code is rewritten to add CSS to the end of the document instead of <HEAD> tag in order to overcome possible server side CSS with !important rule
  11. // @note v1.1 2020-12-29 - code rectified
  12. // @note v1.0 2020-12-28 - initial release
  13. // ==/UserScript==
  14.  
  15. (function() {
  16. var css = `
  17. /*Position of cloud icons*/
  18. .picto .weekday.alt {
  19. line-height: unset !important;
  20. }
  21.  
  22. /*Font size in hourly forecast table*/
  23. .hourly-forecast .hourlywind > tbody {
  24. font-size: 70% !important;
  25. }
  26.  
  27. /*Dividers between cloud icons*/
  28. /*.hourly-forecasr .hourlywind > tbody > tr:nth-of-type(1),*/
  29. .hourly-forecast .hourlywind tr.pictos_3h td {
  30. padding: 0 !important;
  31. border-right-color: gray !important;
  32. border-right-style: solid !important;
  33. border-right-width: thin !important;
  34. }
  35.  
  36. /*Active tab colour*/
  37. .tab.active {
  38. background: #ffc4000f !important;
  39. /*background: #ffffff !important;*/
  40. }
  41. /*Tab colour*/
  42. .tab {
  43. background: #e7ecf0 !important;
  44. /*background: #eaeaea !important;*/
  45. }
  46. /*Predictability meter background*/
  47. .tab_content .tab_predictability .meter_outer {
  48. background-color: hsl(0, 0%, 96.9%) !important;
  49. }
  50.  
  51. /*Social icons*/
  52. .social {
  53. font-size: 100% !important;
  54. }
  55. .social a {
  56. font-size: 100% !important;
  57. }
  58.  
  59. /*Headers*/
  60. h2, h3 {
  61. font-size: 150% !important;
  62. }
  63. `;
  64.  
  65. if (typeof GM_addStyle != 'undefined') {
  66. GM_addStyle(css);
  67. } else if (typeof PRO_addStyle != 'undefined') {
  68. PRO_addStyle(css);
  69. } else if (typeof addStyle != 'undefined') {
  70. addStyle(css);
  71. } else {
  72. var node = document.createElement('style');
  73. node.type = 'text/css';
  74. node.appendChild(document.createTextNode(css));
  75. document.documentElement.appendChild(node);
  76. }
  77. })();