Implement #2001 by Avar and www.kryogenix.org (see .js file for full credit)
authorAntoine Musso <hashar@users.mediawiki.org>
Wed, 13 Jul 2005 23:58:00 +0000 (23:58 +0000)
committerAntoine Musso <hashar@users.mediawiki.org>
Wed, 13 Jul 2005 23:58:00 +0000 (23:58 +0000)
It adds the ability to get client-side sortable tables by assigning an
id and a class ("sortable") to a table.

RELEASE-NOTES
includes/Skin.php
skins/MonoBook.php
skins/monobook/main.css

index 0c6b485..1fe7000 100644 (file)
@@ -153,6 +153,10 @@ External hooks:
   application is included. This may not be on by default in final release,
   depending on support.
 
+Sortable tables:
+  Since beta4 you can have a client-side sortable table. To make a table
+  sortable use class="sortable" and give it a uniq id ( id="foo" ).
+
 And...
   A bunch of stuff we forgot to mention.
 
@@ -575,6 +579,7 @@ of MediaWiki:Newpagetext) to &action=edit, if page is new.
 * show comment subject in preview when using section=new
 * use comment form when creating a new talk page
 * (bug 460) Properly handle <center> tags as a block.
+* (bug 2001) Implement client-side sorting of table fields with JavaScript
 
 === Caveats ===
 
index 458a7a2..3548dc8 100644 (file)
@@ -176,6 +176,7 @@ class Skin extends Linker {
        function getHeadScripts() {
                global $wgStylePath, $wgUser, $wgContLang, $wgAllowUserJs, $wgJsMimeType;
                $r = "<script type=\"{$wgJsMimeType}\" src=\"{$wgStylePath}/common/wikibits.js\"></script>\n";
+               $r.= "<script type=\"{$wgJsMimeType}\" src=\"{$wgStylePath}/common/sorttable.js\"></script>\n";
                if( $wgAllowUserJs && $wgUser->isLoggedIn() ) {
                        $userpage = $wgUser->getUserPage();
                        $userjs = htmlspecialchars( $this->makeUrl(
index 5d94cff..a89f00a 100644 (file)
@@ -64,8 +64,9 @@ class MonoBookTemplate extends QuickTemplate {
     <!--[if IE]><script type="<?php $this->text('jsmimetype') ?>" src="<?php $this->text('stylepath') ?>/common/IEFixes.js"></script>
     <meta http-equiv="imagetoolbar" content="no" /><![endif]-->
     <?php if($this->data['jsvarurl'  ]) { ?><script type="<?php $this->text('jsmimetype') ?>" src="<?php $this->text('jsvarurl'  ) ?>"></script><?php } ?>
-    <script type="<?php $this->text('jsmimetype') ?>" src="<?php                                   $this->text('stylepath' ) ?>/common/wikibits.js"></script>
-    <?php if($this->data['usercss'   ]) { ?><style type="text/css"><?php              $this->html('usercss'   ) ?></style><?php    } ?>
+    <script type="<?php $this->text('jsmimetype') ?>" src="<?php $this->text('stylepath' ) ?>/common/wikibits.js"></script>
+    <script type="<?php $this->text('jsmimetype') ?>" src="<?php $this->text('stylepath' ) ?>/common/sorttable.js"></script>
+    <?php if($this->data['usercss'   ]) { ?><style type="text/css"><?php $this->html('usercss'   ) ?></style><?php    } ?>
     <?php if($this->data['userjs'    ]) { ?><script type="<?php $this->text('jsmimetype') ?>" src="<?php $this->text('userjs'    ) ?>"></script><?php } ?>
     <?php if($this->data['userjsprev']) { ?><script type="<?php $this->text('jsmimetype') ?>"><?php      $this->html('userjsprev') ?></script><?php   } ?>
   </head>
index 318b16c..9369c67 100644 (file)
@@ -1181,3 +1181,13 @@ p.revision_saved {
        color: green;
        font-weight:bold;
 }
+
+/* for OpenId */
+input#wpName {
+       /* FIXME : icon is not transparent */
+       background: url(openid-inputicon.gif) no-repeat;
+       background-position: 0 50%;
+       background-color : #FFFFFF;
+       color : #000000;
+       padding-left: 18px;
+}