Skip to content

Commit

Permalink
smhi: migrate to css
Browse files Browse the repository at this point in the history
  • Loading branch information
aruncveli committed Feb 2, 2025
1 parent 6b2e898 commit f872057
Show file tree
Hide file tree
Showing 7 changed files with 192 additions and 210 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ style.
| snowfl | [Install](https://raw.githubusercontent.com/aruncveli/userstyles/refs/heads/main/sites/snowfl/snowfl.user.css) | [Info](sites/snowfl) |
| Hacker News | [Install](https://raw.githubusercontent.com/aruncveli/userstyles/refs/heads/main/sites/hackernews/hackernews.user.css) | [Info](sites/hackernews) |
| Apotea | [Install](https://raw.githubusercontent.com/aruncveli/userstyles/refs/heads/main/sites/apotea/apotea.user.css) | [Info](sites/apotea) |
| SMHI | [Install](https://github.com/aruncveli/userstyles/raw/main/smhi/smhi.user.styl) | [Info](smhi) |
| SMHI | [Install](https://raw.githubusercontent.com/aruncveli/userstyles/refs/heads/main/sites/smhi/smhi.user.css) | [Info](sites/smhi) |
| Trafikinformation tåg | [Install](https://raw.githubusercontent.com/aruncveli/userstyles/refs/heads/main/sites/trafikinformation-tåg/trafikinformation-tåg.user.css) | [Info](sites/trafikinformation-tåg) |
| npm Docs | [Install](https://raw.githubusercontent.com/aruncveli/userstyles/refs/heads/main/sites/npm-docs/npm-docs.user.css) | [Info](sites/npm-docs) |
| npm | [Install](https://raw.githubusercontent.com/aruncveli/userstyles/refs/heads/main/sites/npm/npm.user.css) | [Info](sites/npm) |
Expand Down
2 changes: 1 addition & 1 deletion sites/npm-docs/npm-docs.user.css
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
color: var(--fg) !important;
background-color: var(--bg1) !important;
}
.VTnRl.token /*Code blocks*/ {
.VTnRl.token /* Code blocks */ {
&.function {
color: var(--link-color) !important;
}
Expand Down
2 changes: 1 addition & 1 deletion smhi/README.md → sites/smhi/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SMHI Dark

[Install](https://github.com/aruncveli/userstyles/raw/main/smhi/smhi.user.styl)
[Install](https://raw.githubusercontent.com/aruncveli/userstyles/refs/heads/main/sites/smhi/smhi.user.css)

Dark theme for SMHI's
[ten day forecast](https://www.smhi.se/en/weather/forecasts/ten-day-forecast/).
Expand Down
Binary file added sites/smhi/screenshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
189 changes: 189 additions & 0 deletions sites/smhi/smhi.user.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,189 @@
/* ==UserStyle==
@name SMHI Dark (Ten day forecast)
@namespace github.com/aruncveli/userstyles
@version 25.2.2
@description Dark theme for SMHI's ten day forecast page
@author Arun Chandanaveli <aruncveli@gmail.com> (https://github.com/aruncveli)
@homepageURL https://github.com/aruncveli/userstyles
@supportURL https://github.com/aruncveli/userstyles/issues
@updateURL https://raw.githubusercontent.com/aruncveli/userstyles/refs/heads/main/sites/smhi/smhi.user.css
@license MIT
@preprocessor default
@var color fg "Foreground" white
@var color fg5 "Foreground darkened 5" #aaa
@var color bg "Background" black
@var color bg1 "Background lightened 1" #111
@var color bg2 "Background lightened 2" #222
==/UserStyle== */
@-moz-document url-prefix("https://www.smhi.se/en/weather/forecasts/ten-day-forecast/") {
:root {
color-scheme: dark;
}

a:hover,
._expandedData_330y8_57,
._labelDate_et9mg_152,
._forecastIssued_1tq7k_1,
.nextgen,
a._warningTextContainer_2n9on_1._warningTextContainer_2n9on_1 span,
a._warningTextContainer_2n9on_1._warningTextContainer_2n9on_1 svg,
#leftmenu.leftnav-nextgen a,
#leftmenu.leftnav-nextgen .active-page.active-page a,
#leftmenu.leftnav-nextgen .leaf .leaf,
._eosMenuItem_13wan_1,
._eosMenuItem_13wan_1 ._text_13wan_31 ._typeText_13wan_35,
._list_1sluo_219 ._favoritesHeader_1sluo_222,
._card_330y8_1 /* Day weather cards */,
._card_330y8_1._largeCard_330y8_200
._cardContent_330y8_140
._block_330y8_153
._valueCol_330y8_161
> *:first-child,
._label_y73h5_127,
._label_et9mg_127,
._gale_et9mg_200,
._gale_y73h5_187,
._temperatureAxisTitle_y73h5_198::before,
._temperatureAxisTitle_et9mg_211::before,
._windAxisTitle_y73h5_213::before,
._windAxisTitle_et9mg_226::before,
._precipitationAxisTitle_y73h5_206::before,
._precipitationAxisTitle_et9mg_219::before,
._labelDate_y73h5_139 {
color: var(--fg);
}

.nextgen,
.nextgen #headcontent,
.nextgen .smhialternating,
#top-menu .nav-drop:hover,
#top-menu .nav-drop.active-page,
#top-menu .nav-drop.active-page:hover,
#leftmenu.leftnav-nextgen,
#leftmenu.leftnav-nextgen .overview-link,
#leftmenu.leftnav-nextgen .navigation-heading-wrapper,
#leftmenu.leftnav-nextgen .leaf .leaf,
._autocomplete_1sluo_126,
._tooltip_et9mg_234 span,
._tooltip_y73h5_221 span {
background-color: var(--bg);
}

#leftmenu.leftnav-nextgen .overview-link:hover,
#leftmenu.leftnav-nextgen .navigation-heading-wrapper:hover,
#leftmenu.leftnav-nextgen .active-page.active-page,
#leftmenu.leftnav-nextgen .active-page-leaf a:hover,
._autocomplete_1sluo_126:hover /* Location search autocomplete */,
._autocomplete_1sluo_126:focus-within,
._eosMenuItem_13wan_1,
._eosMenuItem_13wan_1:active,
._eosMenuItem_13wan_1._active_13wan_13,
._list_1sluo_219 ._favoritesHeader_1sluo_222,
.tab-module_tab__dWFgU:hover:not(:disabled):not(.tab-module_selected__x8WYO),
.SimpleSelect-module_select__VWv7m
.SimpleSelect-module_toggleButton__XNSud:hover:not([disabled]):not(
.SimpleSelect-module_disabled__LDaMe
) {
background-color: var(--bg1);
}

._eosMenuItem_13wan_1:hover {
background-color: var(--bg2);
}

.nextgen,
.nextgen #headcontent,
#leftmenu.leftnav-nextgen .next-nav-main li,
.tabs-module_tabs__4BiXZ
.tabs-module_tabsHeader__g7zIj
.tabs-module_tabsWrapper__tN17g:not(
.tabs-module_noBottomBorder__CBn3H
):before,
._tableContainer_u7j8u_140 table tr {
border-bottom-color: var(--bg);
}

.nextgen .breadcrumbs ul a {
color: #0c6bc4;
}

#mainLogo,
._legendSwatch_et9mg_264 img,
._windDirection_1cjv5_1 img,
.highcharts-root image[width="16"] {
filter: invert(1);
}

#leftmenu.leftnav-nextgen {
.next-nav-main li {
&:first-of-type,
li:first-of-type {
border-top-color: var(--bg);
}
}
.overview-link .expand-button-symbol svg,
.navigation-heading-wrapper .expand-button-symbol svg {
fill: var(--fg);
}
}

._card_330y8_1._largeCard_330y8_200
._cardContent_330y8_140
._block_330y8_153._dayCell_330y8_1 {
border-right-color: var(--bg);
&:hover {
border-right-color: var(--bg1);
}
}

.aurora-root-module_root__QHlfl {
--color10: #022440;
--colorCloud100: var(--fg);
--colorCloud70: var(--fg);
--colorCloud10: var(--bg1);
--colorSky10: var(--bg1);
--colorZenith: var(--bg);
--hoverFillColor: var(--bg1);
--selectedHoverFillColor: var(--bg1);
--activeFillColor: var(--bg1);
--selectedActiveFillColor: var(--bg1);
--colorNadir: var(--fg);
--borderColor: var(--bg);
--borderColorSecondary: var(--bg);
}

._placeContainer_114oc_2 ._markerContent_om9tb_18 ._markerLabel_om9tb_30,
._forecastContainer_om9tb_1 ._markerContent_om9tb_18 ._markerLabel_om9tb_30 {
text-shadow: none;
color: var(--bg);
}

.highcharts-background {
fill: var(--bg);
}

._tooltip_et9mg_234 span,
._tooltip_y73h5_221 span {
color: var(--fg) !important;
}

.button-module_button__V-oN8.button-module_buttonSecondary__csP-q,
.card-module_card__CJdzk .card-module_cardWrapper__iNImr,
.badge-module_badge__FqSIG.badge-module_badgeInformative__cL3rv {
border-color: var(--bg);
}

@media (hover: hover) {
._card_330y8_1._largeCard_330y8_200:hover
._cardContent_330y8_140
._block_330y8_153._dayCell_330y8_1 {
border-right-color: var(--bg);
}
}

._forecastContainer_om9tb_1
._markerContent_om9tb_18
._weatherSymbol_om9tb_46 {
background-color: var(--fg);
}
}
Binary file removed smhi/screenshot.png
Binary file not shown.
Loading

0 comments on commit f872057

Please sign in to comment.