From 3a21f312ad2fc7e94204ec59581287b237ee0d50 Mon Sep 17 00:00:00 2001 From: Mohamed Magdy Date: Sat, 21 Feb 2009 15:03:54 +0000 Subject: [PATCH] Fix bug 1061 CSS-added icons next to links display through the text and makes it unreadable in RTL Patch by Ahmad Sherif --- RELEASE-NOTES | 1 + skins/common/wikibits.js | 5 +++++ skins/monobook/FF2Fixes.css | 4 ++++ skins/monobook/IE60Fixes.css | 11 ++++++++++ skins/monobook/IE70Fixes.css | 10 +++++++++ skins/monobook/Opera6Fixes.css | 6 ++++++ skins/monobook/Opera7Fixes.css | 10 +++++++++ skins/monobook/Opera9Fixes.css | 11 ++++++++++ skins/monobook/external-rtl.png | Bin 0 -> 198 bytes skins/monobook/main.css | 37 ++++++++++++++++++++++++-------- skins/monobook/rtl.css | 3 ++- 11 files changed, 88 insertions(+), 10 deletions(-) create mode 100644 skins/monobook/FF2Fixes.css create mode 100644 skins/monobook/Opera9Fixes.css create mode 100644 skins/monobook/external-rtl.png diff --git a/RELEASE-NOTES b/RELEASE-NOTES index f6c9175d80..cb4546c5eb 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -209,6 +209,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN * (bug 17538) Use shorter URLs in elements * (bug 13778) Hidden input added to the search form so that using the Enter key on IE will do a fulltext search like clicking the button does +* (bug 1061) CSS-added icons next to links display through the text and makes it unreadable in RTL == API changes in 1.15 == * (bug 16858) Revamped list=deletedrevs to make listing deleted contributions diff --git a/skins/common/wikibits.js b/skins/common/wikibits.js index 5abd73888f..1881cd9522 100644 --- a/skins/common/wikibits.js +++ b/skins/common/wikibits.js @@ -14,6 +14,7 @@ var is_khtml = navigator.vendor == 'KDE' || ( document.childNodes && !document.all && !navigator.taintEnabled ); // For accesskeys; note that FF3+ is included here! var is_ff2 = /firefox\/[2-9]|minefield\/3/.test( clientPC ); +var is_ff2_ = /firefox\/2/.test( clientPC ); // These aren't used here, but some custom scripts rely on them var is_ff2_win = is_ff2 && clientPC.indexOf('windows') != -1; var is_ff2_x11 = is_ff2 && clientPC.indexOf('x11') != -1; @@ -91,8 +92,12 @@ if (typeof stylepath != 'undefined' && typeof skin != 'undefined') { importStylesheetURI(stylepath+'/'+skin+'/Opera6Fixes.css'); } else if (is_opera_seven && !is_opera_95) { importStylesheetURI(stylepath+'/'+skin+'/Opera7Fixes.css'); + } else if (is_opera_95) { + importStylesheetURI(stylepath+'/'+skin+'/Opera9Fixes.css'); } else if (is_khtml) { importStylesheetURI(stylepath+'/'+skin+'/KHTMLFixes.css'); + } else if (is_ff2_) { + importStylesheetURI(stylepath+'/'+skin+'/FF2Fixes.css'); } } diff --git a/skins/monobook/FF2Fixes.css b/skins/monobook/FF2Fixes.css new file mode 100644 index 0000000000..dcf54178b7 --- /dev/null +++ b/skins/monobook/FF2Fixes.css @@ -0,0 +1,4 @@ +.rtl .external, a.feedlink { + padding: 0 !important; + background: none !important; +} diff --git a/skins/monobook/IE60Fixes.css b/skins/monobook/IE60Fixes.css index bf78413d8b..c373393d6c 100644 --- a/skins/monobook/IE60Fixes.css +++ b/skins/monobook/IE60Fixes.css @@ -61,6 +61,17 @@ padding-right: 13px; } +.rtl #bodyContent a.external { + background-image: url(external-rtl.png); + padding-right: 13px; +} + +.rtl a.feedlink { + background-position: right; + padding-right: 0; + padding-left: 16px; +} + /* show the hand */ #p-logo a, #p-logo a:hover { diff --git a/skins/monobook/IE70Fixes.css b/skins/monobook/IE70Fixes.css index 43ff7076d5..d31a47a203 100644 --- a/skins/monobook/IE70Fixes.css +++ b/skins/monobook/IE70Fixes.css @@ -18,6 +18,16 @@ margin-top: 160px; } +.rtl #bodyContent a.external { + background-image: url(external-rtl.png); + padding: 0 13px 0 0; +} + +.rtl a.feedlink { + background-position: right; + padding-right: 0; + padding-left: 16px; +} /* the tabs */ #p-cactions { diff --git a/skins/monobook/Opera6Fixes.css b/skins/monobook/Opera6Fixes.css index 88704739ae..48b67bfdd6 100644 --- a/skins/monobook/Opera6Fixes.css +++ b/skins/monobook/Opera6Fixes.css @@ -12,3 +12,9 @@ background: url(external.png) center right no-repeat; padding-right: 13px; } + +.rtl a.feedlink { + background-position: right; + padding-right: 0; + padding-left: 16px; +} diff --git a/skins/monobook/Opera7Fixes.css b/skins/monobook/Opera7Fixes.css index 446ea44cdb..4ec7ec0d04 100644 --- a/skins/monobook/Opera7Fixes.css +++ b/skins/monobook/Opera7Fixes.css @@ -9,3 +9,13 @@ background: url(external.png) center right no-repeat; padding-right: 13px; } +.rtl #bodyContent a.external { + background-image: url(external-rtl.png); + padding-right: 13px; +} + +.rtl a.feedlink { + background-position: right; + padding-right: 0; + padding-left: 16px; +} diff --git a/skins/monobook/Opera9Fixes.css b/skins/monobook/Opera9Fixes.css new file mode 100644 index 0000000000..fff26a4058 --- /dev/null +++ b/skins/monobook/Opera9Fixes.css @@ -0,0 +1,11 @@ +.rtl #bodyContent a.external { + background-image: url(external-rtl.png); + padding-right: 0; + padding-left: 13px; +} + +.rtl a.feedlink { + background-position: right; + padding-right: 0; + padding-left: 16px; +} diff --git a/skins/monobook/external-rtl.png b/skins/monobook/external-rtl.png new file mode 100644 index 0000000000000000000000000000000000000000..c5cd84db028781a8af80dfb7baf592298b5f546f GIT binary patch literal 198 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kYDTR;us<^ zHFv^A-opkQF7sFC9Pz7Avk^X1^0z?Ba;v|UqT&Na-su(|j@9Wgvu%RJG(G?95sg~% zPG)LXSbJ;k6Z2j6kHCwQ8l;fCzJWUxw-`&b8Z10!r