Nikerabbit has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/290248

Change subject: Use .background-image-svg mixing in messge table
......................................................................

Use .background-image-svg mixing in messge table

Fixes a bug where the fallback png image was wrong for this style:
  .tux-action-bar .page-mode-button.down:before

Change-Id: Ieeaa2bdfbe886aa5831f0cd434c97bd4db3fa455
---
M resources/css/ext.translate.messagetable.less
1 file changed, 14 insertions(+), 40 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate 
refs/changes/48/290248/1

diff --git a/resources/css/ext.translate.messagetable.less 
b/resources/css/ext.translate.messagetable.less
index fb59bc0..0378926 100644
--- a/resources/css/ext.translate.messagetable.less
+++ b/resources/css/ext.translate.messagetable.less
@@ -1,3 +1,5 @@
+@import "mediawiki.mixins";
+
 /* Default colors */
 .tux-messagelist {
        color: #252525;
@@ -79,32 +81,22 @@
 }
 
 .tux-status-unsaved {
-       background-image: url(../images/label-pen.png);
-       background-image: -webkit-linear-gradient(transparent, transparent), 
url(../images/label-pen.svg);
-       /* @embed */
-       background-image: linear-gradient(transparent, transparent), 
url(../images/label-pen.svg);
+       .background-image-svg( '../images/label-pen.svg', 
'../images/label-pen.png' );
 }
 
 .tux-status-translated,
 .tux-status-proofread {
-       background-image: url(../images/label-tick.png);
-       background-image: -webkit-linear-gradient(transparent, transparent), 
url(../images/label-tick.svg);
-       /* @embed */
-       background-image: linear-gradient(transparent, transparent), 
url(../images/label-tick.svg);
+       .background-image-svg( '../images/label-tick.svg', 
'../images/label-tick.png' );
 }
 
 .tux-status-fuzzy {
-       background-image: url(../images/label-clock.png);
-       background-image: -webkit-linear-gradient(transparent, transparent), 
url(../images/label-clock.svg);
-       /* @embed */
-       background-image: linear-gradient(transparent, transparent), 
url(../images/label-clock.svg);
+       .background-image-svg( '../images/label-clock.svg', 
'../images/label-clock.png' );
 }
 
 .tux-list-edit a {
-       background: transparent url(../images/action-edit.png) left center 
no-repeat;
-       background-image: -webkit-linear-gradient(transparent, transparent), 
url(../images/action-edit.svg);
-       /* @embed */
-       background-image: linear-gradient(transparent, transparent), 
url(../images/action-edit.svg);
+       .background-image-svg( '../images/action-edit.svg', 
'../images/action-edit.png' );
+       background-position: left center;
+       background-repeat: no-repeat;
        background-size: 18px 18px;
        padding-left: 19px;
 }
@@ -206,17 +198,11 @@
 }
 
 .tux-action-bar .translate-mode-button:before {
-       background: transparent url(../images/view-list.png) center center 
no-repeat;
-       background-image: -webkit-linear-gradient(transparent, transparent), 
url(../images/view-list.svg);
-       /* @embed */
-       background-image: linear-gradient(transparent, transparent), 
url(../images/view-list.svg);
+       .background-image-svg( '../images/view-list.svg', 
'../images/view-list.png' );
 }
 
 .tux-action-bar .translate-mode-button.down:before {
-       background: transparent url(../images/view-list-hi.png) center center 
no-repeat;
-       background-image: -webkit-linear-gradient(transparent, transparent), 
url(../images/view-list-hi.svg);
-       /* @embed */
-       background-image: linear-gradient(transparent, transparent), 
url(../images/view-list-hi.svg);
+       .background-image-svg( '../images/view-list-hi.svg', 
'../images/view-list-hi.png' );
 }
 
 .tux-action-bar .page-mode-button {
@@ -224,17 +210,11 @@
 }
 
 .tux-action-bar .page-mode-button:before {
-       background: transparent url(../images/view-page.png) center center 
no-repeat;
-       background-image: -webkit-linear-gradient(transparent, transparent), 
url(../images/view-page.svg);
-       /* @embed */
-       background-image: linear-gradient(transparent, transparent), 
url(../images/view-page.svg);
+       .background-image-svg( '../images/view-page.svg', 
'../images/view-page.png' );
 }
 
 .tux-action-bar .page-mode-button.down:before {
-       background: transparent url(../images/view-list-hi.png) center center 
no-repeat;
-       background-image: -webkit-linear-gradient(transparent, transparent), 
url(../images/view-page-hi.svg);
-       /* @embed */
-       background-image: linear-gradient(transparent, transparent), 
url(../images/view-page-hi.svg);
+       .background-image-svg( '../images/view-page-hi.svg', 
'../images/view-page-hi.png' );
 }
 
 .tux-action-bar .proofread-mode-button {
@@ -242,17 +222,11 @@
 }
 
 .tux-action-bar .proofread-mode-button:before {
-       background: transparent url(../images/view-proofread.png) center center 
no-repeat;
-       background-image: -webkit-linear-gradient(transparent, transparent), 
url(../images/view-proofread.svg);
-       /* @embed */
-       background-image: linear-gradient(transparent, transparent), 
url(../images/view-proofread.svg);
+       .background-image-svg( '../images/view-proofread.svg', 
'../images/view-proofread.png' );
 }
 
 .tux-action-bar .proofread-mode-button.down:before {
-       background: transparent url(../images/view-proofread-hi.png) center 
center no-repeat;
-       background-image: -webkit-linear-gradient(transparent, transparent), 
url(../images/view-proofread-hi.svg);
-       /* @embed */
-       background-image: linear-gradient(transparent, transparent), 
url(../images/view-proofread-hi.svg);
+       .background-image-svg( '../images/view-proofread-hi.svg', 
'../images/view-proofread-hi.png' );
 }
 
 .ext-translate-container .tux-messagelist .tux-message-filter-result {

-- 
To view, visit https://gerrit.wikimedia.org/r/290248
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ieeaa2bdfbe886aa5831f0cd434c97bd4db3fa455
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Translate
Gerrit-Branch: master
Gerrit-Owner: Nikerabbit <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to