diff --git a/includes/FooterHooks.php b/includes/FooterHooks.php index e0d76502..c28f185d 100644 --- a/includes/FooterHooks.php +++ b/includes/FooterHooks.php @@ -142,6 +142,14 @@ class FooterHooks { "styles" => array( "resources/ext.relatedArticles.readMore/readMore.less" ), + "skinStyles" => array( + "default" => "resources/ext.relatedArticles.readMore/readMore.default.less", + "monobook" => array( + "resources/ext.relatedArticles.readMore/readMore.default.less", + "resources/ext.relatedArticles.readMore/readMore.monobook.less" + ), + "minerva" => "resources/ext.relatedArticles.readMore/readMore.minerva.less" + ), "messages" => array( "relatedarticles-read-more-heading" ), diff --git a/resources/ext.relatedArticles.readMore/readMore.default.less b/resources/ext.relatedArticles.readMore/readMore.default.less new file mode 100644 index 00000000..795723ef --- /dev/null +++ b/resources/ext.relatedArticles.readMore/readMore.default.less @@ -0,0 +1,15 @@ +// Hide RelatedArticles when VE is activated (https://phabricator.wikimedia.org/T120443) +.ve-activated { + .ra-read-more { + display: none; + } +} + +.ra-read-more { + margin: 0 0 0 10em; + padding: 1em; + + .ext-cards-card-list { + margin-left: 0; + } +} diff --git a/resources/ext.relatedArticles.readMore/readMore.less b/resources/ext.relatedArticles.readMore/readMore.less index d07d0f6b..7f613eb6 100644 --- a/resources/ext.relatedArticles.readMore/readMore.less +++ b/resources/ext.relatedArticles.readMore/readMore.less @@ -1,16 +1,6 @@ @import "mediawiki.ui/variables"; -// Hide RelatedArticles when VE is activated (https://phabricator.wikimedia.org/T120443) -.ve-activated { - .ra-read-more { - display: none; - } -} - .ra-read-more { - margin-top: 35px; - margin-bottom: 70px; - h2 { border-bottom: none; font-size: .8em; @@ -20,19 +10,4 @@ text-transform: uppercase; letter-spacing: 1px; } - - .page-list { - border-top: 1px solid @colorGray14; - } -} - -body.skin-vector { - .ra-read-more { - margin: 0 0 0 10em; - padding: 1em; - - .ext-cards-card-list { - margin-left: 0; - } - } } diff --git a/resources/ext.relatedArticles.readMore/readMore.minerva.less b/resources/ext.relatedArticles.readMore/readMore.minerva.less new file mode 100644 index 00000000..9c77aab7 --- /dev/null +++ b/resources/ext.relatedArticles.readMore/readMore.minerva.less @@ -0,0 +1,7 @@ +@import "mediawiki.ui/variables"; + +.ra-read-more { + margin-top: 35px; + margin-bottom: 70px; +} + diff --git a/resources/ext.relatedArticles.readMore/readMore.monobook.less b/resources/ext.relatedArticles.readMore/readMore.monobook.less new file mode 100644 index 00000000..59e0a032 --- /dev/null +++ b/resources/ext.relatedArticles.readMore/readMore.monobook.less @@ -0,0 +1,6 @@ +// inherits from vector styles + +.ra-read-more { + margin: 0 0 0 12.2em; + padding: 1em 0; +}