MWSkin Timeless Patches: Difference between revisions
(Created page with "<div class="p44_navbar"> Wiki Top This page Minetest MTWorlds Bucket Game Trolltest Downloads Contact Devel Center </div> <div class="p44_navbar"> [https://minetest.org/ minetest.org] [https://minetest.io minetest.io] [https://git.minetest.io/ 9,000 gits] [https://irc.minetest.org:9000/ CoderChat] [https://edgy1.net/ EdgyNet] </div> <span id...") |
No edit summary |
||
Line 50: | Line 50: | ||
== Timeless Alt-Tag patch == | == Timeless Alt-Tag patch == | ||
This patch adds support for an optional "alt" tag that can be added to Timeless wordmark image. | This patch adds support for an optional "alt" tag that can be added to a Timeless wordmark image. | ||
--- Timeless.old/includes/TimelessTemplate.php | --- Timeless.old/includes/TimelessTemplate.php | ||
Line 60: | Line 60: | ||
'height' => $wordmarkData['height'] ?? null, | 'height' => $wordmarkData['height'] ?? null, | ||
'width' => $wordmarkData['width'] ?? null, | 'width' => $wordmarkData['width'] ?? null, | ||
+ 'alt' | + 'alt' => $wordmarkData['alt'] ?? null, | ||
] ); | ] ); | ||
} | } |
Revision as of 11:11, 3 September 2023
Introduction
For the Final Minetest wiki, and for MediaWiki wikis in general, the Timeless skin is recommended because as of mid-2023 it's more responsive than other bundled skins.
However, some patches to the Timeless skin are recommended. The patches are provided and discussed below. Note: These aren't directly applicable Linux "patch" files. Instead, these are condensed patches that are intended for human readers. They need to be edited in manually.
Timeless Real-Estate patch
This patch prevents, except for very wide screens, the creation of an unnecessary 3rd column on the right.
--- Timeless.old/skin.json +++ Timeless/skin.json - "media": "screen and (min-width: 1340px)" + "media": "screen and (min-width: 1800px)" - "media": "screen and (min-width: 1100px) and (max-width: 1339px)" + "media": "screen and (min-width: 1100px) and (max-width: 1799px)" --- Timeless.old/resources/variables.less +++ Timeless/resources/variables.less -@desktop-mid-width: 1339px; -@desktop-large-floor: 1340px; +@desktop-mid-width: 1799px; +@desktop-large-floor: 1800px;
Timeless Alt-Tag patch
This patch adds support for an optional "alt" tag that can be added to a Timeless wordmark image.
--- Timeless.old/includes/TimelessTemplate.php +++ Timeless/includes/TimelessTemplate.php if ( !$wordmarkImage && isset( $logos['wordmark'] ) ) { $wordmarkData = $logos['wordmark']; $wordmarkImage = Html::element( 'img', [ 'src' => $wordmarkData['src'], 'height' => $wordmarkData['height'] ?? null, 'width' => $wordmarkData['width'] ?? null, + 'alt' => $wordmarkData['alt'] ?? null, ] ); }
To use the added feature, you'd put something similar to the 'wordmark' part below in your $wgLogos block:
$wgLogos = [ '1x' => "fmwikismall.png" , 'icon' => "fmwikismall.png" , 'wordmark' => [ # recommended size is 200x38 or less 'src' => 'fmwordmark-text.png' , 'alt' => 'Final Minetest wordmark' , ] , ];