jenkins-bot has submitted this change and it was merged.
Change subject: Story 1030: Clean up common.less
......................................................................
Story 1030: Clean up common.less
Remove undocumented rules, move hacks to hacks.less, scope all
content-related rules inside .content.
Change-Id: Ia00fc80fc01aa84db197b0f7d3e5ed46c3ce8cd0
---
M less/common/common.less
M stylesheets/common/common.css
2 files changed, 81 insertions(+), 241 deletions(-)
Approvals:
Jdlrobson: Looks good to me, approved
jenkins-bot: Verified
diff --git a/less/common/common.less b/less/common/common.less
index 76c2a9a..0e5bd23 100644
--- a/less/common/common.less
+++ b/less/common/common.less
@@ -35,10 +35,6 @@
}
}
-input {
- word-break: normal;
-}
-
textarea {
padding: 5px 0 5px 5px;
}
@@ -56,36 +52,24 @@
}
// For old style forms
+// Special:MovePage?target=San%20Francisco
+// Special:Import
+// Special:NewPages
+// Special:RecentChanges
+// Special:Prefixindex
+// Special:Contributions
+// Special:ChangePassword
+// Special:ChangeEmail
+// Special:Allpages
.mw-input [type=submit],
-.mw-submit input,
-.mw-submit[type=submit],
.mw-submit {
margin-top: 8px;
- display: block;
min-width: 80%;
-}
-
-button.disabled {
- opacity: 0.2;
}
a.external {
background: url(images/external-link-ltr-icon.png) center right
no-repeat;
padding-right: 13px;
-}
-
-.info {
- margin: @infoMargin;
- color: @infoColor;
-
- img {
- width: 100%;
- max-width: 600px;
- }
-
- .button {
- margin: 2em 0 0;
- }
}
/* Galleries */
@@ -126,78 +110,8 @@
}
}
-// FIXME: Review what introduces .mwm-notice
-.mwm-notice {
- padding: 5px;
- background: #dddddd;
- border-radius: 5px;
- margin-top: 5px;
- text-align: center;
- border: 1px solid gray;
-
- &.mwm-message {
- background: #FFFFFF;
- font-size: 1.1em;
- color: #000000;
-
- a {
- text-decoration: underline;
- font-weight: bold;
- color: #000000;
- }
- }
-}
-
#content {
position: relative; // allow absolute positioned children e.g. edit link
-
- table {
- /* following 5 rules are needed for scrolling */
- overflow: auto; /* for browsers that don't support overflow-y */
- overflow-y: hidden;
- overflow-x: auto;
- word-break: normal;
- display: block;
- }
-
- // Hide the image magnification icon normally displayed in image
captions
- div.magnify {
- display: none;
- }
-}
-
-table {
- .box-sizing( border-box );
-
- tbody {
- display: inline-block;
- }
-
- td,
- th {
- padding: 3px;
- }
-
- th {
- word-break: normal;
- }
-
- &.wikitable {
- th {
- background: #f3f3f3;
- }
- }
-
- table {
- border: 0;
- margin-bottom: 0;
-
- td,
- th {
- border: 0;
- padding: 0;
- }
- }
}
p,
@@ -234,41 +148,13 @@
}
img.thumbborder {
- border: 1px solid #cccccc;
+ border: 1px solid #ccc;
}
-/* @noflip */div.floatright, table.floatright {
- float: right;
-}
-
-/* @noflip */div.floatleft, table.floatright {
- float: left;
-}
-
-.sibling-page,
-// FIXME: Remove styling on id in 1 month
-#mw-mf-last-modified {
+.sibling-page {
display: block;
font-size: .9em;
margin-top: 1.5em;
-}
-
-.mwm-message.mwm-notice {
- font-size: 1.1em;
-}
-
-@media all and (max-width: 500px) {
- .mobile div.tleft,
- .mobile div.floatleft,
- .mobile table.floatleft,
- .mobile div.tright,
- .mobile div.floatright,
- .mobile table.floatright {
- float: none;
- clear: none;
- margin: auto;
- width: auto !important;
- }
}
/* Plainlinks - this can be used to switch
@@ -283,6 +169,11 @@
font-weight: bold;
}
+em,
+i {
+ font-style: italic;
+}
+
.hlist > ul, // FIXME: to support hlists on enwiki projects - this should be
deprecated
ul.hlist {
li {
@@ -291,18 +182,32 @@
}
}
-.content_block {
+.content {
ul {
list-style: square inside;
}
+
ol {
list-style: decimal inside;
}
-}
-em,
-i {
- font-style: italic;
+ table {
+ /* following 4 rules are needed for scrolling */
+ overflow: auto; /* for browsers that don't support overflow-y */
+ overflow-y: hidden;
+ overflow-x: auto;
+ display: block;
+
+ td,
+ th {
+ padding: 3px;
+ }
+ }
+
+ // Hide the image magnification icon normally displayed in image
captions
+ div.magnify {
+ display: none;
+ }
}
.jsonly {
@@ -337,3 +242,17 @@
.nomobile {
display: none;
}
+
+// classes added by thumbnails
+// e.g. [[File:Scholars mate animation.gif|frame|left|"[[Scholar's mate]]"]]
+@media all and (min-width: 768px) {
+ .content {
+ .tleft {
+ float: left;
+ }
+
+ .tright {
+ float: right;
+ }
+ }
+}
diff --git a/stylesheets/common/common.css b/stylesheets/common/common.css
index b3859ef..9fb06f9 100644
--- a/stylesheets/common/common.css
+++ b/stylesheets/common/common.css
@@ -39,9 +39,6 @@
-webkit-box-sizing: border-box;
box-sizing: border-box;
}
-input {
- word-break: normal;
-}
textarea {
padding: 5px 0 5px 5px;
}
@@ -57,30 +54,13 @@
padding: 5px;
}
.mw-input [type=submit],
-.mw-submit input,
-.mw-submit[type=submit],
.mw-submit {
margin-top: 8px;
- display: block;
min-width: 80%;
-}
-button.disabled {
- opacity: 0.2;
}
a.external {
background: url(images/external-link-ltr-icon.png) center right no-repeat;
padding-right: 13px;
-}
-.info {
- margin: 4em;
- color: #707070;
-}
-.info img {
- width: 100%;
- max-width: 600px;
-}
-.info .button {
- margin: 2em 0 0;
}
/* Galleries */
/* See
https://www.mediawiki.org/wiki/Help:Images#Rendering_a_gallery_of_images */
@@ -114,67 +94,8 @@
padding: 2px 4px;
word-wrap: break-word;
}
-.mwm-notice {
- padding: 5px;
- background: #dddddd;
- border-radius: 5px;
- margin-top: 5px;
- text-align: center;
- border: 1px solid gray;
-}
-.mwm-notice.mwm-message {
- background: #FFFFFF;
- font-size: 1.1em;
- color: #000000;
-}
-.mwm-notice.mwm-message a {
- text-decoration: underline;
- font-weight: bold;
- color: #000000;
-}
#content {
position: relative;
-}
-#content table {
- /* following 5 rules are needed for scrolling */
-
- overflow: auto;
- /* for browsers that don't support overflow-y */
-
- overflow-y: hidden;
- overflow-x: auto;
- word-break: normal;
- display: block;
-}
-#content div.magnify {
- display: none;
-}
-table {
- -moz-box-sizing: border-box;
- -webkit-box-sizing: border-box;
- box-sizing: border-box;
-}
-table tbody {
- display: inline-block;
-}
-table td,
-table th {
- padding: 3px;
-}
-table th {
- word-break: normal;
-}
-table.wikitable th {
- background: #f3f3f3;
-}
-table table {
- border: 0;
- margin-bottom: 0;
-}
-table table td,
-table table th {
- border: 0;
- padding: 0;
}
p,
li,
@@ -203,37 +124,12 @@
color: #cc0000;
}
img.thumbborder {
- border: 1px solid #cccccc;
+ border: 1px solid #ccc;
}
-/* @noflip */div.floatright,
-table.floatright {
- float: right;
-}
-/* @noflip */div.floatleft,
-table.floatright {
- float: left;
-}
-.sibling-page,
-#mw-mf-last-modified {
+.sibling-page {
display: block;
font-size: .9em;
margin-top: 1.5em;
-}
-.mwm-message.mwm-notice {
- font-size: 1.1em;
-}
-@media all and (max-width: 500px) {
- .mobile div.tleft,
- .mobile div.floatleft,
- .mobile table.floatleft,
- .mobile div.tright,
- .mobile div.floatright,
- .mobile table.floatright {
- float: none;
- clear: none;
- margin: auto;
- width: auto !important;
- }
}
/* Plainlinks - this can be used to switch
* off special external link styling */
@@ -245,20 +141,37 @@
b {
font-weight: bold;
}
+em,
+i {
+ font-style: italic;
+}
.hlist > ul li,
ul.hlist li {
display: inline-block;
margin-right: 8px;
}
-.content_block ul {
+.content ul {
list-style: square inside;
}
-.content_block ol {
+.content ol {
list-style: decimal inside;
}
-em,
-i {
- font-style: italic;
+.content table {
+ /* following 4 rules are needed for scrolling */
+
+ overflow: auto;
+ /* for browsers that don't support overflow-y */
+
+ overflow-y: hidden;
+ overflow-x: auto;
+ display: block;
+}
+.content table td,
+.content table th {
+ padding: 3px;
+}
+.content div.magnify {
+ display: none;
}
.jsonly {
display: none;
@@ -282,3 +195,11 @@
.nomobile {
display: none;
}
+@media all and (min-width: 768px) {
+ .content .tleft {
+ float: left;
+ }
+ .content .tright {
+ float: right;
+ }
+}
--
To view, visit https://gerrit.wikimedia.org/r/86785
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ia00fc80fc01aa84db197b0f7d3e5ed46c3ce8cd0
Gerrit-PatchSet: 5
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: JGonera <[email protected]>
Gerrit-Reviewer: JGonera <[email protected]>
Gerrit-Reviewer: Jdlrobson <[email protected]>
Gerrit-Reviewer: jenkins-bot
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits