r61977 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r61976‎ | r61977 | r61978 >
Date:16:50, 4 February 2010
Author:adam
Status:deferred
Tags:
Comment:
Insert Link Dialog - Moving the link status icons out of img tags and applying them as backgrounds. Adding a RTL version of the external link status icon
Modified paths:
  • /trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php (modified) (history)
  • /trunk/extensions/UsabilityInitiative/WikiEditor/Modules/Toolbar/Toolbar.js (modified) (history)
  • /trunk/extensions/UsabilityInitiative/WikiEditor/WikiEditor.combined.js (modified) (history)
  • /trunk/extensions/UsabilityInitiative/WikiEditor/WikiEditor.combined.min.js (modified) (history)
  • /trunk/extensions/UsabilityInitiative/WikiEditor/WikiEditor.hooks.php (modified) (history)
  • /trunk/extensions/UsabilityInitiative/css/combined.css (modified) (history)
  • /trunk/extensions/UsabilityInitiative/css/combined.min.css (modified) (history)
  • /trunk/extensions/UsabilityInitiative/css/wikiEditor.dialogs.css (modified) (history)
  • /trunk/extensions/UsabilityInitiative/images/wikiEditor/dialogs/insert-link-external-rtl.png (added) (history)

Diff [purge]

Index: trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php
@@ -22,18 +22,18 @@
2323 array( 'src' => 'css/vector.collapsibleNav.css', 'version' => 7 ),
2424 array( 'src' => 'css/vector.footerCleanup.css', 'version' => 1 ),
2525 array( 'src' => 'css/wikiEditor.css', 'version' => 9 ),
26 - array( 'src' => 'css/wikiEditor.dialogs.css', 'version' => 17 ),
 26+ array( 'src' => 'css/wikiEditor.dialogs.css', 'version' => 18 ),
2727 array( 'src' => 'css/wikiEditor.preview.css', 'version' => 1 ),
2828 array( 'src' => 'css/wikiEditor.toc.css', 'version' => 28 ),
2929 array( 'src' => 'css/wikiEditor.toolbar.css', 'version' => 10 ),
3030 array( 'src' => 'css/vector/jquery-ui-1.7.2.css', 'version' => '1.7.2y' ),
3131 ),
3232 'combined' => array(
33 - array( 'src' => 'css/combined.css', 'version' => 61 ),
 33+ array( 'src' => 'css/combined.css', 'version' => 62 ),
3434 array( 'src' => 'css/vector/jquery-ui-1.7.2.css', 'version' => '1.7.2y' ),
3535 ),
3636 'minified' => array(
37 - array( 'src' => 'css/combined.min.css', 'version' => 61 ),
 37+ array( 'src' => 'css/combined.min.css', 'version' => 62 ),
3838 array( 'src' => 'css/vector/jquery-ui-1.7.2.css', 'version' => '1.7.2y' ),
3939 ),
4040 )
Index: trunk/extensions/UsabilityInitiative/images/wikiEditor/dialogs/insert-link-external-rtl.png
Cannot display: file marked as a binary type.
svn:mime-type = image/png
Property changes on: trunk/extensions/UsabilityInitiative/images/wikiEditor/dialogs/insert-link-external-rtl.png
___________________________________________________________________
Name: svn:mime-type
4141 + image/png
Index: trunk/extensions/UsabilityInitiative/css/wikiEditor.dialogs.css
@@ -161,6 +161,27 @@
162162 #wikieditor-toolbar-tool-link-int-target-label {
163163 float: left;
164164 }
 165+#wikieditor-toolbar-link-int-target-status-exists,
 166+#wikieditor-toolbar-link-int-target-status-notexists,
 167+#wikieditor-toolbar-link-int-target-status-invalid,
 168+#wikieditor-toolbar-link-int-target-status-external {
 169+ padding-left: 30px;
 170+ background-position: 0 50%;
 171+ background-repeat: no-repeat;
 172+}
 173+#wikieditor-toolbar-link-int-target-status-exists {
 174+ background-image: url( ../images/wikiEditor/dialogs/insert-link-exists.png );
 175+}
 176+#wikieditor-toolbar-link-int-target-status-notexists {
 177+ background-image: url( ../images/wikiEditor/dialogs/insert-link-notexists.png );
 178+}
 179+#wikieditor-toolbar-link-int-target-status-invalid {
 180+ background-image: url( ../images/wikiEditor/dialogs/insert-link-invalid.png );
 181+}
 182+#wikieditor-toolbar-link-int-target-status-external {
 183+ background-image: url( ../images/wikiEditor/dialogs/insert-link-external.png );
 184+}
 185+
165186 /* RTL Changes */
166187 body.rtl .wikiEditor-toolbar-dialog .ui-dialog-buttonpane button {
167188 float: left;
@@ -184,6 +205,17 @@
185206 margin-right: 0;
186207 margin-left: 2em;
187208 }
 209+body.rtl #wikieditor-toolbar-link-int-target-status-exists,
 210+body.rtl #wikieditor-toolbar-link-int-target-status-notexists,
 211+body.rtl #wikieditor-toolbar-link-int-target-status-invalid,
 212+body.rtl #wikieditor-toolbar-link-int-target-status-external {
 213+ padding-left: 0;
 214+ padding-right: 30px;
 215+ background-position: 100% 50%;
 216+}
 217+body.rtl #wikieditor-toolbar-link-int-target-status-external {
 218+ background-image: url( ../images/wikiEditor/dialogs/insert-link-external-rtl.png );
 219+}
188220 /* Self Clearing Floats */
189221 .wikieditor-toolbar-table-dimension-fields:after,
190222 .wikieditor-toolbar-dialog-wrapper:after {
Index: trunk/extensions/UsabilityInitiative/css/combined.css
@@ -388,6 +388,27 @@
389389 #wikieditor-toolbar-tool-link-int-target-label {
390390 float: left;
391391 }
 392+#wikieditor-toolbar-link-int-target-status-exists,
 393+#wikieditor-toolbar-link-int-target-status-notexists,
 394+#wikieditor-toolbar-link-int-target-status-invalid,
 395+#wikieditor-toolbar-link-int-target-status-external {
 396+ padding-left: 30px;
 397+ background-position: 0 50%;
 398+ background-repeat: no-repeat;
 399+}
 400+#wikieditor-toolbar-link-int-target-status-exists {
 401+ background-image: url( ../images/wikiEditor/dialogs/insert-link-exists.png );
 402+}
 403+#wikieditor-toolbar-link-int-target-status-notexists {
 404+ background-image: url( ../images/wikiEditor/dialogs/insert-link-notexists.png );
 405+}
 406+#wikieditor-toolbar-link-int-target-status-invalid {
 407+ background-image: url( ../images/wikiEditor/dialogs/insert-link-invalid.png );
 408+}
 409+#wikieditor-toolbar-link-int-target-status-external {
 410+ background-image: url( ../images/wikiEditor/dialogs/insert-link-external.png );
 411+}
 412+
392413 /* RTL Changes */
393414 body.rtl .wikiEditor-toolbar-dialog .ui-dialog-buttonpane button {
394415 float: left;
@@ -411,6 +432,17 @@
412433 margin-right: 0;
413434 margin-left: 2em;
414435 }
 436+body.rtl #wikieditor-toolbar-link-int-target-status-exists,
 437+body.rtl #wikieditor-toolbar-link-int-target-status-notexists,
 438+body.rtl #wikieditor-toolbar-link-int-target-status-invalid,
 439+body.rtl #wikieditor-toolbar-link-int-target-status-external {
 440+ padding-left: 0;
 441+ padding-right: 30px;
 442+ background-position: 100% 50%;
 443+}
 444+body.rtl #wikieditor-toolbar-link-int-target-status-external {
 445+ background-image: url( ../images/wikiEditor/dialogs/insert-link-external-rtl.png );
 446+}
415447 /* Self Clearing Floats */
416448 .wikieditor-toolbar-table-dimension-fields:after,
417449 .wikieditor-toolbar-dialog-wrapper:after {
Index: trunk/extensions/UsabilityInitiative/css/combined.min.css
@@ -367,6 +367,26 @@
368368 #wikieditor-toolbar-tool-link-int-target-label{
369369 float:left;
370370 }
 371+#wikieditor-toolbar-link-int-target-status-exists,
 372+#wikieditor-toolbar-link-int-target-status-notexists,
 373+#wikieditor-toolbar-link-int-target-status-invalid,
 374+#wikieditor-toolbar-link-int-target-status-external{
 375+padding-left:30px;
 376+background-position:0 50%;
 377+background-repeat:no-repeat;
 378+}
 379+#wikieditor-toolbar-link-int-target-status-exists{
 380+background-image:url( ../images/wikiEditor/dialogs/insert-link-exists.png );
 381+}
 382+#wikieditor-toolbar-link-int-target-status-notexists{
 383+background-image:url( ../images/wikiEditor/dialogs/insert-link-notexists.png );
 384+}
 385+#wikieditor-toolbar-link-int-target-status-invalid{
 386+background-image:url( ../images/wikiEditor/dialogs/insert-link-invalid.png );
 387+}
 388+#wikieditor-toolbar-link-int-target-status-external{
 389+background-image:url( ../images/wikiEditor/dialogs/insert-link-external.png );
 390+}
371391 body.rtl .wikiEditor-toolbar-dialog .ui-dialog-buttonpane button{
372392 float:left;
373393 margin:0.5em 0.4em 0.5em 0 !important;
@@ -389,6 +409,17 @@
390410 margin-right:0;
391411 margin-left:2em;
392412 }
 413+body.rtl #wikieditor-toolbar-link-int-target-status-exists,
 414+body.rtl #wikieditor-toolbar-link-int-target-status-notexists,
 415+body.rtl #wikieditor-toolbar-link-int-target-status-invalid,
 416+body.rtl #wikieditor-toolbar-link-int-target-status-external{
 417+padding-left:0;
 418+padding-right:30px;
 419+background-position:100% 50%;
 420+}
 421+body.rtl #wikieditor-toolbar-link-int-target-status-external{
 422+background-image:url( ../images/wikiEditor/dialogs/insert-link-external-rtl.png );
 423+}
393424 .wikieditor-toolbar-table-dimension-fields:after,
394425 .wikieditor-toolbar-dialog-wrapper:after{
395426 visibility:hidden;
Index: trunk/extensions/UsabilityInitiative/WikiEditor/WikiEditor.hooks.php
@@ -16,14 +16,14 @@
1717 array( 'src' => 'Modules/Preview/Preview.js', 'version' => 6 ),
1818 array( 'src' => 'Modules/Publish/Publish.js', 'version' => 6 ),
1919 array( 'src' => 'Modules/Toc/Toc.js', 'version' => 7 ),
20 - array( 'src' => 'Modules/Toolbar/Toolbar.js', 'version' => 44 ),
 20+ array( 'src' => 'Modules/Toolbar/Toolbar.js', 'version' => 45 ),
2121 array( 'src' => 'Modules/TemplateEditor/TemplateEditor.js', 'version' => 4 ),
2222 ),
2323 'combined' => array(
24 - array( 'src' => 'WikiEditor.combined.js', 'version' => 46 ),
 24+ array( 'src' => 'WikiEditor.combined.js', 'version' => 47 ),
2525 ),
2626 'minified' => array(
27 - array( 'src' => 'WikiEditor.combined.min.js', 'version' => 46 ),
 27+ array( 'src' => 'WikiEditor.combined.min.js', 'version' => 47 ),
2828 ),
2929 );
3030 static $messages = array(
Index: trunk/extensions/UsabilityInitiative/WikiEditor/WikiEditor.combined.js
@@ -1085,26 +1085,18 @@
10861086 $j( '#wikieditor-toolbar-link-int-target-status' )
10871087 .append( $j( '<div />' )
10881088 .attr( 'id', 'wikieditor-toolbar-link-int-target-status-exists' )
1089 - .append( $j( '<img />' ).attr( 'src',
1090 - $j.wikiEditor.imgPath + 'dialogs/' + 'insert-link-exists.png' ) )
10911089 .append( existsMsg )
10921090 )
10931091 .append( $j( '<div />' )
10941092 .attr( 'id', 'wikieditor-toolbar-link-int-target-status-notexists' )
1095 - .append( $j( '<img />' ).attr( 'src',
1096 - $j.wikiEditor.imgPath + 'dialogs/' + 'insert-link-notexists.png' ) )
10971093 .append( notexistsMsg )
10981094 )
10991095 .append( $j( '<div />' )
11001096 .attr( 'id', 'wikieditor-toolbar-link-int-target-status-invalid' )
1101 - .append( $j( '<img />' ).attr( 'src',
1102 - $j.wikiEditor.imgPath + 'dialogs/' + 'insert-link-invalid.png' ) )
11031097 .append( invalidMsg )
11041098 )
11051099 .append( $j( '<div />' )
11061100 .attr( 'id', 'wikieditor-toolbar-link-int-target-status-external' )
1107 - .append( $j( '<img />' ).attr( 'src',
1108 - $j.wikiEditor.imgPath + 'dialogs/' + 'insert-link-external.png' ) )
11091101 .append( externalMsg )
11101102 )
11111103 .append( $j( '<div />' )
Index: trunk/extensions/UsabilityInitiative/WikiEditor/WikiEditor.combined.min.js
@@ -49,7 +49,7 @@
5050 $j('#wikieditor-toolbar-link-type-ext').attr('checked','checked');else
5151 $j('#wikieditor-toolbar-link-type-int').attr('checked','checked');if($j('#wikieditor-toolbar-link-int-text').data('untouched'))
5252 $j('#wikieditor-toolbar-link-int-text').val($j('#wikieditor-toolbar-link-int-target').val()).change();},0);});$j('#wikieditor-toolbar-link-int-text').bind('change keydown paste cut',function(){var oldVal=$j(this).val();var that=this;setTimeout(function(){if($j(that).val()!=oldVal)
53 -$j(that).data('untouched',false);},0);});var existsMsg=u.getMsg('wikieditor-toolbar-tool-link-int-target-status-exists');var notexistsMsg=u.getMsg('wikieditor-toolbar-tool-link-int-target-status-notexists');var invalidMsg=u.getMsg('wikieditor-toolbar-tool-link-int-target-status-invalid');var externalMsg=u.getMsg('wikieditor-toolbar-tool-link-int-target-status-external');var loadingMsg=u.getMsg('wikieditor-toolbar-tool-link-int-target-status-loading');$j('#wikieditor-toolbar-link-int-target-status').append($j('<div />').attr('id','wikieditor-toolbar-link-int-target-status-exists').append($j('<img />').attr('src',$j.wikiEditor.imgPath+'dialogs/'+'insert-link-exists.png')).append(existsMsg)).append($j('<div />').attr('id','wikieditor-toolbar-link-int-target-status-notexists').append($j('<img />').attr('src',$j.wikiEditor.imgPath+'dialogs/'+'insert-link-notexists.png')).append(notexistsMsg)).append($j('<div />').attr('id','wikieditor-toolbar-link-int-target-status-invalid').append($j('<img />').attr('src',$j.wikiEditor.imgPath+'dialogs/'+'insert-link-invalid.png')).append(invalidMsg)).append($j('<div />').attr('id','wikieditor-toolbar-link-int-target-status-external').append($j('<img />').attr('src',$j.wikiEditor.imgPath+'dialogs/'+'insert-link-external.png')).append(externalMsg)).append($j('<div />').attr('id','wikieditor-toolbar-link-int-target-status-loading').append($j('<img />').attr({'src':$j.wikiEditor.imgPath+'dialogs/'+'loading.gif','alt':loadingMsg,'title':loadingMsg}))).data('existencecache',{}).children().hide();$j('#wikieditor-toolbar-link-int-target').bind('keyup paste cut',function(){if(typeof $j(this).data('timerID')!='undefined'){clearTimeout($j(this).data('timerID'));}
 53+$j(that).data('untouched',false);},0);});var existsMsg=u.getMsg('wikieditor-toolbar-tool-link-int-target-status-exists');var notexistsMsg=u.getMsg('wikieditor-toolbar-tool-link-int-target-status-notexists');var invalidMsg=u.getMsg('wikieditor-toolbar-tool-link-int-target-status-invalid');var externalMsg=u.getMsg('wikieditor-toolbar-tool-link-int-target-status-external');var loadingMsg=u.getMsg('wikieditor-toolbar-tool-link-int-target-status-loading');$j('#wikieditor-toolbar-link-int-target-status').append($j('<div />').attr('id','wikieditor-toolbar-link-int-target-status-exists').append(existsMsg)).append($j('<div />').attr('id','wikieditor-toolbar-link-int-target-status-notexists').append(notexistsMsg)).append($j('<div />').attr('id','wikieditor-toolbar-link-int-target-status-invalid').append(invalidMsg)).append($j('<div />').attr('id','wikieditor-toolbar-link-int-target-status-external').append(externalMsg)).append($j('<div />').attr('id','wikieditor-toolbar-link-int-target-status-loading').append($j('<img />').attr({'src':$j.wikiEditor.imgPath+'dialogs/'+'loading.gif','alt':loadingMsg,'title':loadingMsg}))).data('existencecache',{}).children().hide();$j('#wikieditor-toolbar-link-int-target').bind('keyup paste cut',function(){if(typeof $j(this).data('timerID')!='undefined'){clearTimeout($j(this).data('timerID'));}
5454 var timerID=setTimeout(updateExistence,120);$j(this).data('timerID',timerID);}).change(function(){if(typeof $j(this).data('timerID')!='undefined'){clearTimeout($j(this).data('timerID'));}
5555 updateExistence();});$j('#wikieditor-toolbar-link-int-target').data('suggcache',{}).suggestions({fetch:function(query){var that=this;var title=$j(this).val();if(isExternalLink(title)||title.indexOf('|')!=-1||title==''){$j(this).suggestions('suggestions',[]);return;}
5656 var cache=$j(this).data('suggcache');if(typeof cache[title]!='undefined'){$j(this).suggestions('suggestions',cache[title]);return;}
Index: trunk/extensions/UsabilityInitiative/WikiEditor/Modules/Toolbar/Toolbar.js
@@ -1036,26 +1036,18 @@
10371037 $j( '#wikieditor-toolbar-link-int-target-status' )
10381038 .append( $j( '<div />' )
10391039 .attr( 'id', 'wikieditor-toolbar-link-int-target-status-exists' )
1040 - .append( $j( '<img />' ).attr( 'src',
1041 - $j.wikiEditor.imgPath + 'dialogs/' + 'insert-link-exists.png' ) )
10421040 .append( existsMsg )
10431041 )
10441042 .append( $j( '<div />' )
10451043 .attr( 'id', 'wikieditor-toolbar-link-int-target-status-notexists' )
1046 - .append( $j( '<img />' ).attr( 'src',
1047 - $j.wikiEditor.imgPath + 'dialogs/' + 'insert-link-notexists.png' ) )
10481044 .append( notexistsMsg )
10491045 )
10501046 .append( $j( '<div />' )
10511047 .attr( 'id', 'wikieditor-toolbar-link-int-target-status-invalid' )
1052 - .append( $j( '<img />' ).attr( 'src',
1053 - $j.wikiEditor.imgPath + 'dialogs/' + 'insert-link-invalid.png' ) )
10541048 .append( invalidMsg )
10551049 )
10561050 .append( $j( '<div />' )
10571051 .attr( 'id', 'wikieditor-toolbar-link-int-target-status-external' )
1058 - .append( $j( '<img />' ).attr( 'src',
1059 - $j.wikiEditor.imgPath + 'dialogs/' + 'insert-link-external.png' ) )
10601052 .append( externalMsg )
10611053 )
10621054 .append( $j( '<div />' )

Status & tagging log