User "Trevor Parscal" posted a comment on MediaWiki.r96142.

Full URL: http://www.mediawiki.org/wiki/Special:Code/MediaWiki/96142#c22490
Commit summary:

Change position of Narayam controls to personal tools/menu area as proposed by 
Trevor Pascal, codes with help from Santhosh. Tested in FF, Chrome and Opera.

Comment:

The CSS code looks fine, but I did want to just mention that the way @noflip is 
being used here is perhaps more confusing than it needs to be.

Example:
 /* @noflip */
 div#narayam-menu {
        direction: ltr;
        float: left;
        cursor: pointer;
 }
 /* @noflip */
 body.rtl div#narayam-menu {
        direction: rtl;
 }

In this code, both rules are using @noflip, which means we aren't using 
CSSJanus at all, and the 2nd rule has to compensate for that by using body.rtl 
before the selector. If only a portion of a rule shouldn't be flipped, the 
better way to go is to write the rule without the properties to be preserved, 
then write it again with @noflip, this time only including the properties to be 
preserved:

Example:
 div#narayam-menu {
        direction: ltr;
 }
 /* @noflip */
 div#narayam-menu {
        float: left;
        cursor: pointer;
 }

This will make the code simpler, more readable, and takes advantage of the 
CSSJanus system for all the other rules that should be flipped.

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

Reply via email to