<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[55971] trunk/src/wp-admin: Administration: Set accessible state for list table headers.</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { white-space: pre-line; overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta" style="font-size: 105%">
<dt style="float: left; width: 6em; font-weight: bold">Revision</dt> <dd><a style="font-weight: bold" href="https://core.trac.wordpress.org/changeset/55971">55971</a><script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","description":"Review this Commit","action":{"@type":"ViewAction","url":"https://core.trac.wordpress.org/changeset/55971","name":"Review Commit"}}</script></dd>
<dt style="float: left; width: 6em; font-weight: bold">Author</dt> <dd>joedolson</dd>
<dt style="float: left; width: 6em; font-weight: bold">Date</dt> <dd>2023-06-21 21:45:52 +0000 (Wed, 21 Jun 2023)</dd>
</dl>

<pre style='padding-left: 1em; margin: 2em 0; border-left: 2px solid #ccc; line-height: 1.25; font-size: 105%; font-family: sans-serif'>Administration: Set accessible state for list table headers.

Implement `aria-sort` and change icon states to indicate current sort for list tables. Allow screen reader users to get context about the current sort and allow sighted users to know how the table is currently sorted.

Props afercia, rianrietveld, joedolson, alexstine, johnjamesjacoby.
Fixes <a href="https://core.trac.wordpress.org/ticket/32170">#32170</a>.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunksrcwpadmincsslisttablescss">trunk/src/wp-admin/css/list-tables.css</a></li>
<li><a href="#trunksrcwpadminincludesclasswpcommentslisttablephp">trunk/src/wp-admin/includes/class-wp-comments-list-table.php</a></li>
<li><a href="#trunksrcwpadminincludesclasswplinkslisttablephp">trunk/src/wp-admin/includes/class-wp-links-list-table.php</a></li>
<li><a href="#trunksrcwpadminincludesclasswplisttablephp">trunk/src/wp-admin/includes/class-wp-list-table.php</a></li>
<li><a href="#trunksrcwpadminincludesclasswpmedialisttablephp">trunk/src/wp-admin/includes/class-wp-media-list-table.php</a></li>
<li><a href="#trunksrcwpadminincludesclasswpmssiteslisttablephp">trunk/src/wp-admin/includes/class-wp-ms-sites-list-table.php</a></li>
<li><a href="#trunksrcwpadminincludesclasswpmsthemeslisttablephp">trunk/src/wp-admin/includes/class-wp-ms-themes-list-table.php</a></li>
<li><a href="#trunksrcwpadminincludesclasswpmsuserslisttablephp">trunk/src/wp-admin/includes/class-wp-ms-users-list-table.php</a></li>
<li><a href="#trunksrcwpadminincludesclasswppostslisttablephp">trunk/src/wp-admin/includes/class-wp-posts-list-table.php</a></li>
<li><a href="#trunksrcwpadminincludesclasswptermslisttablephp">trunk/src/wp-admin/includes/class-wp-terms-list-table.php</a></li>
<li><a href="#trunksrcwpadminincludesclasswpuserslisttablephp">trunk/src/wp-admin/includes/class-wp-users-list-table.php</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunksrcwpadmincsslisttablescss"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/css/list-tables.css</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/css/list-tables.css    2023-06-21 21:30:26 UTC (rev 55970)
+++ trunk/src/wp-admin/css/list-tables.css      2023-06-21 21:45:52 UTC (rev 55971)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -461,17 +461,19 @@
</span><span class="cx" style="display: block; padding: 0 10px">        width: 160px;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+.sorting-indicators {
+       display: grid;
+}
+
</ins><span class="cx" style="display: block; padding: 0 10px"> .sorting-indicator {
</span><span class="cx" style="display: block; padding: 0 10px">        display: block;
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-        visibility: hidden;
</del><span class="cx" style="display: block; padding: 0 10px">         width: 10px;
</span><span class="cx" style="display: block; padding: 0 10px">        height: 4px;
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-        margin-top: 8px;
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ margin-top: 4px;
</ins><span class="cx" style="display: block; padding: 0 10px">         margin-left: 7px;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px"> .sorting-indicator:before {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-        content: "\f142";
</del><span class="cx" style="display: block; padding: 0 10px">         font: normal 20px/1 dashicons;
</span><span class="cx" style="display: block; padding: 0 10px">        speak: never;
</span><span class="cx" style="display: block; padding: 0 10px">        display: inline-block;
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -478,7 +480,6 @@
</span><span class="cx" style="display: block; padding: 0 10px">        padding: 0;
</span><span class="cx" style="display: block; padding: 0 10px">        top: -4px;
</span><span class="cx" style="display: block; padding: 0 10px">        left: -8px;
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-        color: #3c434a;
</del><span class="cx" style="display: block; padding: 0 10px">         line-height: 0.5;
</span><span class="cx" style="display: block; padding: 0 10px">        position: relative;
</span><span class="cx" style="display: block; padding: 0 10px">        vertical-align: top;
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -485,26 +486,39 @@
</span><span class="cx" style="display: block; padding: 0 10px">        -webkit-font-smoothing: antialiased;
</span><span class="cx" style="display: block; padding: 0 10px">        -moz-osx-font-smoothing: grayscale;
</span><span class="cx" style="display: block; padding: 0 10px">        text-decoration: none !important;
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-        color: #3c434a;
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ color: #a7aaad;
</ins><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-.column-comments .sorting-indicator:before {
-       top: 0;
-       left: -10px;
-}
-
-th.sorted.asc .sorting-indicator:before,
-th.desc:hover span.sorting-indicator:before,
-th.desc a:focus span.sorting-indicator:before {
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+.sorting-indicator.asc:before {
</ins><span class="cx" style="display: block; padding: 0 10px">         content: "\f142";
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-th.sorted.desc .sorting-indicator:before,
-th.asc:hover span.sorting-indicator:before,
-th.asc a:focus span.sorting-indicator:before {
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+.sorting-indicator.desc:before {
</ins><span class="cx" style="display: block; padding: 0 10px">         content: "\f140";
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+th.sorted.desc .sorting-indicator.desc:before {
+       color: #1d2327;
+}
+
+th.sorted.asc .sorting-indicator.asc:before {
+       color: #1d2327;
+}
+
+th.sorted.asc a:focus .sorting-indicator.asc:before,
+th.sorted.asc:hover .sorting-indicator.asc:before,
+th.sorted.desc a:focus .sorting-indicator.desc:before,
+th.sorted.desc:hover .sorting-indicator.desc:before {
+       color: #a7aaad;
+}
+
+th.sorted.asc a:focus .sorting-indicator.desc:before,
+th.sorted.asc:hover .sorting-indicator.desc:before,
+th.sorted.desc a:focus .sorting-indicator.asc:before,
+th.sorted.desc:hover .sorting-indicator.asc:before {
+       color: #1d2327;
+}
+
</ins><span class="cx" style="display: block; padding: 0 10px"> .wp-list-table .toggle-row {
</span><span class="cx" style="display: block; padding: 0 10px">        position: absolute;
</span><span class="cx" style="display: block; padding: 0 10px">        right: 8px;
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -613,10 +627,6 @@
</span><span class="cx" style="display: block; padding: 0 10px">        display: none;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-.fixed .column-comments .sorting-indicator {
-       margin-top: 3px;
-}
-
</del><span class="cx" style="display: block; padding: 0 10px"> #menu-locations-wrap .widefat {
</span><span class="cx" style="display: block; padding: 0 10px">        width: 60%;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -644,14 +654,6 @@
</span><span class="cx" style="display: block; padding: 0 10px">        cursor: pointer;
</span><span class="cx" style="display: block; padding: 0 10px"> }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-th.sorted .sorting-indicator,
-th.desc:hover span.sorting-indicator,
-th.desc a:focus span.sorting-indicator,
-th.asc:hover span.sorting-indicator,
-th.asc a:focus span.sorting-indicator {
-       visibility: visible;
-}
-
</del><span class="cx" style="display: block; padding: 0 10px"> .tablenav-pages .current-page {
</span><span class="cx" style="display: block; padding: 0 10px">        margin: 0 2px 0 0;
</span><span class="cx" style="display: block; padding: 0 10px">        font-size: 13px;
</span></span></pre></div>
<a id="trunksrcwpadminincludesclasswpcommentslisttablephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/includes/class-wp-comments-list-table.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-wp-comments-list-table.php      2023-06-21 21:30:26 UTC (rev 55970)
+++ trunk/src/wp-admin/includes/class-wp-comments-list-table.php        2023-06-21 21:45:52 UTC (rev 55971)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -540,8 +540,8 @@
</span><span class="cx" style="display: block; padding: 0 10px">         */
</span><span class="cx" style="display: block; padding: 0 10px">        protected function get_sortable_columns() {
</span><span class="cx" style="display: block; padding: 0 10px">                return array(
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                        'author'   => 'comment_author',
-                       'response' => 'comment_post_ID',
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                 'author'   => array( 'comment_author', false, __( 'Author' ), __( 'Table ordered by Comment Author.' ) ),
+                       'response' => array( 'comment_post_ID', false, _x( 'In Response To', 'column name' ), __( 'Table ordered by Post Replied To.' ) ),
</ins><span class="cx" style="display: block; padding: 0 10px">                         'date'     => 'comment_date',
</span><span class="cx" style="display: block; padding: 0 10px">                );
</span><span class="cx" style="display: block; padding: 0 10px">        }
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -580,6 +580,14 @@
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">                ?>
</span><span class="cx" style="display: block; padding: 0 10px"> <table class="wp-list-table <?php echo implode( ' ', $this->get_table_classes() ); ?>">
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                <?php
+               if ( ! isset( $_GET['orderby'] ) ) {
+                       // In the initial view, Comments are ordered by comment's date but there's no column for that.
+                       echo '<caption class="screen-reader-text">' . __( 'Ordered by Comment Date, descending.' ) . '</p>';
+               } else {
+                       $this->print_table_description();
+               }
+               ?>
</ins><span class="cx" style="display: block; padding: 0 10px">         <thead>
</span><span class="cx" style="display: block; padding: 0 10px">        <tr>
</span><span class="cx" style="display: block; padding: 0 10px">                <?php $this->print_column_headers(); ?>
</span></span></pre></div>
<a id="trunksrcwpadminincludesclasswplinkslisttablephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/includes/class-wp-links-list-table.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-wp-links-list-table.php 2023-06-21 21:30:26 UTC (rev 55970)
+++ trunk/src/wp-admin/includes/class-wp-links-list-table.php   2023-06-21 21:45:52 UTC (rev 55971)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -143,10 +143,10 @@
</span><span class="cx" style="display: block; padding: 0 10px">         */
</span><span class="cx" style="display: block; padding: 0 10px">        protected function get_sortable_columns() {
</span><span class="cx" style="display: block; padding: 0 10px">                return array(
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                        'name'    => 'name',
-                       'url'     => 'url',
-                       'visible' => 'visible',
-                       'rating'  => 'rating',
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                 'name'    => array( 'name', false, _x( 'Name', 'link name' ), __( 'Table ordered by Name.' ), 'asc' ),
+                       'url'     => array( 'url', false, __( 'URL' ), __( 'Table ordered by URL.' ) ),
+                       'visible' => array( 'visible', false, __( 'Visible' ), __( 'Table ordered by Visibility.' ) ),
+                       'rating'  => array( 'rating', false, __( 'Rating' ), __( 'Table ordered by Rating.' ) ),
</ins><span class="cx" style="display: block; padding: 0 10px">                 );
</span><span class="cx" style="display: block; padding: 0 10px">        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span></span></pre></div>
<a id="trunksrcwpadminincludesclasswplisttablephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/includes/class-wp-list-table.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-wp-list-table.php       2023-06-21 21:30:26 UTC (rev 55970)
+++ trunk/src/wp-admin/includes/class-wp-list-table.php 2023-06-21 21:45:52 UTC (rev 55971)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1109,10 +1109,17 @@
</span><span class="cx" style="display: block; padding: 0 10px">         *
</span><span class="cx" style="display: block; padding: 0 10px">         * The format is:
</span><span class="cx" style="display: block; padding: 0 10px">         * - `'internal-name' => 'orderby'`
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+         * - `'internal-name' => array( 'orderby', bool, 'abbr', 'orderby-text', 'initially-sorted-column-order' )` -
</ins><span class="cx" style="display: block; padding: 0 10px">          * - `'internal-name' => array( 'orderby', 'asc' )` - The second element sets the initial sorting order.
</span><span class="cx" style="display: block; padding: 0 10px">         * - `'internal-name' => array( 'orderby', true )`  - The second element makes the initial order descending.
</span><span class="cx" style="display: block; padding: 0 10px">         *
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+         * In the second format, passing true as second parameter will make the initial
+        * sorting order be descending. Following parameters add a short column name to
+        * be used as 'abbr' attribute, a translatable string for the current sorting
+        * and the initial order for the initial sorted column, 'asc' or 'desc' (default: false).
+        *
</ins><span class="cx" style="display: block; padding: 0 10px">          * @since 3.1.0
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+         * @since 6.3.0 Added 'abbr', 'orderby-text' and 'initially-sorted-column-order'.
</ins><span class="cx" style="display: block; padding: 0 10px">          *
</span><span class="cx" style="display: block; padding: 0 10px">         * @return array
</span><span class="cx" style="display: block; padding: 0 10px">         */
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1253,9 +1260,22 @@
</span><span class="cx" style="display: block; padding: 0 10px">                        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">                        $data = (array) $data;
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                        // Descending initial sorting.
</ins><span class="cx" style="display: block; padding: 0 10px">                         if ( ! isset( $data[1] ) ) {
</span><span class="cx" style="display: block; padding: 0 10px">                                $data[1] = false;
</span><span class="cx" style="display: block; padding: 0 10px">                        }
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                        // Current sorting translatable string.
+                       if ( ! isset( $data[2] ) ) {
+                               $data[2] = '';
+                       }
+                       // Initial view sorted column and asc/desc order, default: false.
+                       if ( ! isset( $data[3] ) ) {
+                               $data[3] = false;
+                       }
+                       // Initial order for the initial sorted column, default: false.
+                       if ( ! isset( $data[4] ) ) {
+                               $data[4] = false;
+                       }
</ins><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">                        $sortable[ $id ] = $data;
</span><span class="cx" style="display: block; padding: 0 10px">                }
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1292,15 +1312,19 @@
</span><span class="cx" style="display: block; padding: 0 10px">                $current_url = set_url_scheme( 'http://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'] );
</span><span class="cx" style="display: block; padding: 0 10px">                $current_url = remove_query_arg( 'paged', $current_url );
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                // When users click on a column header to sort by other columns.
</ins><span class="cx" style="display: block; padding: 0 10px">                 if ( isset( $_GET['orderby'] ) ) {
</span><span class="cx" style="display: block; padding: 0 10px">                        $current_orderby = $_GET['orderby'];
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                        // In the initial view there's no orderby parameter.
</ins><span class="cx" style="display: block; padding: 0 10px">                 } else {
</span><span class="cx" style="display: block; padding: 0 10px">                        $current_orderby = '';
</span><span class="cx" style="display: block; padding: 0 10px">                }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                if ( isset( $_GET['order'] ) && 'desc' === $_GET['order'] ) {
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+         // Not in the initial view and descending order.
+               if ( isset( $_GET['order'] ) && 'desc' == $_GET['order'] ) {
</ins><span class="cx" style="display: block; padding: 0 10px">                         $current_order = 'desc';
</span><span class="cx" style="display: block; padding: 0 10px">                } else {
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                        // The initial view is not always 'asc' we'll take care of this below.
</ins><span class="cx" style="display: block; padding: 0 10px">                         $current_order = 'asc';
</span><span class="cx" style="display: block; padding: 0 10px">                }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1317,7 +1341,10 @@
</span><span class="cx" style="display: block; padding: 0 10px">                }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">                foreach ( $columns as $column_key => $column_display_name ) {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                        $class = array( 'manage-column', "column-$column_key" );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                 $class          = array( 'manage-column', "column-$column_key" );
+                       $aria_sort_attr = '';
+                       $abbr_attr      = '';
+                       $order_text     = '';
</ins><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">                        if ( in_array( $column_key, $hidden, true ) ) {
</span><span class="cx" style="display: block; padding: 0 10px">                                $class[] = 'hidden';
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1334,14 +1361,36 @@
</span><span class="cx" style="display: block; padding: 0 10px">                        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">                        if ( isset( $sortable[ $column_key ] ) ) {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                                list( $orderby, $desc_first ) = $sortable[ $column_key ];
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                         list( $orderby, $desc_first, $abbr, $orderby_text, $initial_order ) = $sortable[ $column_key ];
</ins><span class="cx" style="display: block; padding: 0 10px"> 
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                                /*
+                                * We're in the initial view and there's no $_GET['orderby'] then check if the
+                                * initial sorting information is set in the sortable columns and use that.
+                                */
+                               if ( '' === $current_orderby && $initial_order ) {
+                                       // Use the initially sorted column $orderby as current orderby.
+                                       $current_orderby = $orderby;
+                                       // Use the initially sorted column asc/desc order as initial order.
+                                       $current_order = $initial_order;
+                               }
+
+                               /*
+                                * True in the initial view when an initial orderby is set via get_sortable_columns()
+                                * and true in the sorted views when the actual $_GET['orderby'] is equal to $orderby.
+                                */
</ins><span class="cx" style="display: block; padding: 0 10px">                                 if ( $current_orderby === $orderby ) {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                                        $order = 'asc' === $current_order ? 'desc' : 'asc';
-
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                                 // The sorted column. The `aria-sort` attribute must be set only on the sorted column.
+                                       if ( 'asc' == $current_order ) {
+                                               $order          = 'desc';
+                                               $aria_sort_attr = ' aria-sort="ascending"';
+                                       } else {
+                                               $order          = 'asc';
+                                               $aria_sort_attr = ' aria-sort="descending"';
+                                       }
</ins><span class="cx" style="display: block; padding: 0 10px">                                         $class[] = 'sorted';
</span><span class="cx" style="display: block; padding: 0 10px">                                        $class[] = $current_order;
</span><span class="cx" style="display: block; padding: 0 10px">                                } else {
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                                        // The other sortable columns.
</ins><span class="cx" style="display: block; padding: 0 10px">                                         $order = strtolower( $desc_first );
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">                                        if ( ! in_array( $order, array( 'desc', 'asc' ), true ) ) {
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1348,15 +1397,17 @@
</span><span class="cx" style="display: block; padding: 0 10px">                                                $order = $desc_first ? 'desc' : 'asc';
</span><span class="cx" style="display: block; padding: 0 10px">                                        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                                        $class[] = 'sortable';
-                                       $class[] = 'desc' === $order ? 'asc' : 'desc';
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                                 $class[]    = 'sortable';
+                                       $class[]    = 'desc' === $order ? 'asc' : 'desc';
+                                       $order_text = 'asc' === $order ? __( 'Sort ascending.' ) : __( 'Sort descending.' );
</ins><span class="cx" style="display: block; padding: 0 10px">                                 }
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                                if ( '' !== $order_text ) {
+                                       $order_text = ' <span class="screen-reader-text">' . $order_text . '</span>';
+                               }
</ins><span class="cx" style="display: block; padding: 0 10px"> 
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                                $column_display_name = sprintf(
-                                       '<a href="%s"><span>%s</span><span class="sorting-indicator"></span></a>',
-                                       esc_url( add_query_arg( compact( 'orderby', 'order' ), $current_url ) ),
-                                       $column_display_name
-                               );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                         // Print an 'abbr' attribute if a value is provided via get_sortable_columns().
+                               $abbr_attr           = $abbr ? ' abbr="' . esc_attr( $abbr ) . '"' : '';
+                               $column_display_name = '<a href="' . esc_url( add_query_arg( compact( 'orderby', 'order' ), $current_url ) ) . '"><span>' . $column_display_name . '</span><span class="sorting-indicators"><span class="sorting-indicator asc" aria-hidden="true"></span><span class="sorting-indicator desc" aria-hidden="true"></span>' . $order_text . '</a>';
</ins><span class="cx" style="display: block; padding: 0 10px">                         }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">                        $tag   = ( 'cb' === $column_key ) ? 'td' : 'th';
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1367,11 +1418,77 @@
</span><span class="cx" style="display: block; padding: 0 10px">                                $class = "class='" . implode( ' ', $class ) . "'";
</span><span class="cx" style="display: block; padding: 0 10px">                        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                        echo "<$tag $scope $id $class>$column_display_name</$tag>";
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                 echo "<$tag $scope $id $class $aria_sort_attr $abbr_attr>$column_display_name</$tag>";
</ins><span class="cx" style="display: block; padding: 0 10px">                 }
</span><span class="cx" style="display: block; padding: 0 10px">        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">        /**
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+         * Print a table description with information about current sorting and order.
+        *
+        * For the table initial view, information about initial orderby and order
+        * should be provided via get_sortable_columns().
+        *
+        * @since 4.3.0
+        * @access public
+        */
+       public function print_table_description() {
+               list( $columns, $hidden, $sortable ) = $this->get_column_info();
+
+               if ( empty( $sortable ) ) {
+                       return;
+               }
+
+               // When users click on a column header to sort by other columns.
+               if ( isset( $_GET['orderby'] ) ) {
+                       $current_orderby = $_GET['orderby'];
+                       // In the initial view there's no orderby parameter.
+               } else {
+                       $current_orderby = '';
+               }
+
+               // Not in the initial view and descending order.
+               if ( isset( $_GET['order'] ) && 'desc' == $_GET['order'] ) {
+                       $current_order = 'desc';
+               } else {
+                       // The initial view is not always 'asc' we'll take care of this below.
+                       $current_order = 'asc';
+               }
+
+               foreach ( array_keys( $columns ) as $column_key ) {
+
+                       if ( isset( $sortable[ $column_key ] ) ) {
+
+                               list( $orderby, $desc_first, $abbr, $orderby_text, $initial_order ) = $sortable[ $column_key ];
+
+                               if ( ! is_string( $orderby_text ) || '' === $orderby_text ) {
+                                       return;
+                               }
+                               /*
+                                * We're in the initial view and there's no $_GET['orderby'] then check if the
+                                * initial sorting information is set in the sortable columns and use that.
+                                */
+                               if ( '' === $current_orderby && $initial_order ) {
+                                       // Use the initially sorted column $orderby as current orderby.
+                                       $current_orderby = $orderby;
+                                       // Use the initially sorted column asc/desc order as initial order.
+                                       $current_order = $initial_order;
+                               }
+
+                               /*
+                                * True in the initial view when an initial orderby is set via get_sortable_columns()
+                                * and true in the sorted views when the actual $_GET['orderby'] is equal to $orderby.
+                                */
+                               if ( $current_orderby == $orderby ) {
+                                       $order_text = 'asc' === $current_order ? __( 'Ascending.' ) : __( 'Descending.' );
+                                       echo '<caption  class="screen-reader-text">' . $orderby_text . ' ' . $order_text . '</p>';
+
+                                       return;
+                               }
+                       }
+               }
+       }
+
+       /**
</ins><span class="cx" style="display: block; padding: 0 10px">          * Displays the table.
</span><span class="cx" style="display: block; padding: 0 10px">         *
</span><span class="cx" style="display: block; padding: 0 10px">         * @since 3.1.0
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1384,6 +1501,7 @@
</span><span class="cx" style="display: block; padding: 0 10px">                $this->screen->render_screen_reader_content( 'heading_list' );
</span><span class="cx" style="display: block; padding: 0 10px">                ?>
</span><span class="cx" style="display: block; padding: 0 10px"> <table class="wp-list-table <?php echo implode( ' ', $this->get_table_classes() ); ?>">
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                <?php $this->print_table_description(); ?>
</ins><span class="cx" style="display: block; padding: 0 10px">         <thead>
</span><span class="cx" style="display: block; padding: 0 10px">        <tr>
</span><span class="cx" style="display: block; padding: 0 10px">                <?php $this->print_column_headers(); ?>
</span></span></pre></div>
<a id="trunksrcwpadminincludesclasswpmedialisttablephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/includes/class-wp-media-list-table.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-wp-media-list-table.php 2023-06-21 21:30:26 UTC (rev 55970)
+++ trunk/src/wp-admin/includes/class-wp-media-list-table.php   2023-06-21 21:45:52 UTC (rev 55971)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -389,11 +389,11 @@
</span><span class="cx" style="display: block; padding: 0 10px">         */
</span><span class="cx" style="display: block; padding: 0 10px">        protected function get_sortable_columns() {
</span><span class="cx" style="display: block; padding: 0 10px">                return array(
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                        'title'    => 'title',
-                       'author'   => 'author',
-                       'parent'   => 'parent',
-                       'comments' => 'comment_count',
-                       'date'     => array( 'date', true ),
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                 'title'    => array( 'title', false, _x( 'File', 'column name' ), __( 'Table ordered by File Name.' ) ),
+                       'author'   => array( 'author', false, __( 'Author' ), __( 'Table ordered by Author.' ) ),
+                       'parent'   => array( 'parent', false, _x( 'Uploaded to', 'column name' ), __( 'Table ordered by Uploaded To.' ) ),
+                       'comments' => array( 'comment_count', __( 'Comments' ), false, __( 'Table ordered by Comments.' ) ),
+                       'date'     => array( 'date', true, __( 'Date' ), __( 'Table ordered by Date.' ), 'desc' ),
</ins><span class="cx" style="display: block; padding: 0 10px">                 );
</span><span class="cx" style="display: block; padding: 0 10px">        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span></span></pre></div>
<a id="trunksrcwpadminincludesclasswpmssiteslisttablephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/includes/class-wp-ms-sites-list-table.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-wp-ms-sites-list-table.php      2023-06-21 21:30:26 UTC (rev 55970)
+++ trunk/src/wp-admin/includes/class-wp-ms-sites-list-table.php        2023-06-21 21:45:52 UTC (rev 55971)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -389,10 +389,19 @@
</span><span class="cx" style="display: block; padding: 0 10px">         * @return array
</span><span class="cx" style="display: block; padding: 0 10px">         */
</span><span class="cx" style="display: block; padding: 0 10px">        protected function get_sortable_columns() {
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
+               if ( is_subdomain_install() ) {
+                       $abbr = __( 'Domain' );
+                       $blogname_orderby_text = __( 'Table ordered by Site Domain Name.' );
+               } else {
+                       $abbr = __( 'Path' );
+                       $blogname_orderby_text = __( 'Table ordered by Site Path.' );
+               }
+
</ins><span class="cx" style="display: block; padding: 0 10px">                 return array(
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                        'blogname'    => 'blogname',
-                       'lastupdated' => 'lastupdated',
-                       'registered'  => 'blog_id',
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                 'blogname'    => array( 'blogname', false, $abbr, $blogname_orderby_text ),
+                       'lastupdated' => array( 'lastupdated', true, __( 'Last Updated' ), __( 'Table ordered by Last Updated.' ) ),
+                       'registered'  => array( 'blog_id', true, _x( 'Registered', 'site' ), __( 'Table ordered by Site Registered Date.' ), 'desc' ),
</ins><span class="cx" style="display: block; padding: 0 10px">                 );
</span><span class="cx" style="display: block; padding: 0 10px">        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span></span></pre></div>
<a id="trunksrcwpadminincludesclasswpmsthemeslisttablephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/includes/class-wp-ms-themes-list-table.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-wp-ms-themes-list-table.php     2023-06-21 21:30:26 UTC (rev 55970)
+++ trunk/src/wp-admin/includes/class-wp-ms-themes-list-table.php       2023-06-21 21:45:52 UTC (rev 55971)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -343,7 +343,7 @@
</span><span class="cx" style="display: block; padding: 0 10px">         */
</span><span class="cx" style="display: block; padding: 0 10px">        protected function get_sortable_columns() {
</span><span class="cx" style="display: block; padding: 0 10px">                return array(
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                        'name' => 'name',
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                 'name' => array( 'name', false, __( 'Theme' ), __( 'Table ordered by Theme Name.' ), 'asc' ),
</ins><span class="cx" style="display: block; padding: 0 10px">                 );
</span><span class="cx" style="display: block; padding: 0 10px">        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span></span></pre></div>
<a id="trunksrcwpadminincludesclasswpmsuserslisttablephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/includes/class-wp-ms-users-list-table.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-wp-ms-users-list-table.php      2023-06-21 21:30:26 UTC (rev 55970)
+++ trunk/src/wp-admin/includes/class-wp-ms-users-list-table.php        2023-06-21 21:45:52 UTC (rev 55971)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -212,10 +212,10 @@
</span><span class="cx" style="display: block; padding: 0 10px">         */
</span><span class="cx" style="display: block; padding: 0 10px">        protected function get_sortable_columns() {
</span><span class="cx" style="display: block; padding: 0 10px">                return array(
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                        'username'   => 'login',
-                       'name'       => 'name',
-                       'email'      => 'email',
-                       'registered' => 'id',
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                 'username'   => array( 'login', false, __( 'Username' ), __( 'Table ordered by Username.' ), 'asc' ),
+                       'name'       => array( 'name', false, __( 'Name' ), __( 'Table ordered by Name.' ) ),
+                       'email'      => array( 'email', false, __( 'E-mail' ), __( 'Table ordered by E-mail.' ) ),
+                       'registered' => array( 'id', false, _x( 'Registered', 'user' ), __( 'Table ordered by User Registered Date.' ) ),
</ins><span class="cx" style="display: block; padding: 0 10px">                 );
</span><span class="cx" style="display: block; padding: 0 10px">        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span></span></pre></div>
<a id="trunksrcwpadminincludesclasswppostslisttablephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/includes/class-wp-posts-list-table.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-wp-posts-list-table.php 2023-06-21 21:30:26 UTC (rev 55970)
+++ trunk/src/wp-admin/includes/class-wp-posts-list-table.php   2023-06-21 21:45:52 UTC (rev 55971)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -760,12 +760,28 @@
</span><span class="cx" style="display: block; padding: 0 10px">         * @return array
</span><span class="cx" style="display: block; padding: 0 10px">         */
</span><span class="cx" style="display: block; padding: 0 10px">        protected function get_sortable_columns() {
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                return array(
-                       'title'    => 'title',
-                       'parent'   => 'parent',
-                       'comments' => 'comment_count',
-                       'date'     => array( 'date', true ),
-               );
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
+               $post_type = $this->screen->post_type;
+
+               if ( 'page' === $post_type ) {
+                       $title_orderby_text = isset( $_GET['orderby'] ) ? __( 'Table ordered by Title.' ) : __( 'Table ordered by Hierarchical Menu Order and Title.' );
+                       $sortables = array(
+                               'title'    => array( 'title', false, __( 'Title' ), $title_orderby_text, 'asc' ),
+                               'parent'   => array( 'parent', false ),
+                               'comments' => array( 'comment_count', false, __( 'Comments' ), __( 'Table ordered by Comments.' ) ),
+                               'date'     => array( 'date', true, __( 'Date' ), __( 'Table ordered by Date.' ) ),
+                       );
+               } else {
+                       $sortables = array(
+                               'title'    => array( 'title', false, __( 'Title' ), __( 'Table ordered by Title.' ) ),
+                               'parent'   => array( 'parent', false ),
+                               'comments' => array( 'comment_count', false, __( 'Comments' ), __( 'Table ordered by Comments.' ) ),
+                               'date'     => array( 'date', true, __( 'Date' ), __( 'Table ordered by Date.' ), 'desc' ),
+                       );
+               }
+               // Custom Post Types: there's a filter for that, see get_column_info().
+
+               return $sortables;
</ins><span class="cx" style="display: block; padding: 0 10px">         }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">        /**
</span></span></pre></div>
<a id="trunksrcwpadminincludesclasswptermslisttablephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/includes/class-wp-terms-list-table.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-wp-terms-list-table.php 2023-06-21 21:30:26 UTC (rev 55970)
+++ trunk/src/wp-admin/includes/class-wp-terms-list-table.php   2023-06-21 21:45:52 UTC (rev 55971)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -208,12 +208,20 @@
</span><span class="cx" style="display: block; padding: 0 10px">         * @return array
</span><span class="cx" style="display: block; padding: 0 10px">         */
</span><span class="cx" style="display: block; padding: 0 10px">        protected function get_sortable_columns() {
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                $taxonomy = $this->screen->taxonomy;
+
+               if ( ! isset( $_GET['orderby'] ) && is_taxonomy_hierarchical( $taxonomy ) ) {
+                       $name_orderby_text = __( 'Table ordered hierarchically.' );
+               } else {
+                       $name_orderby_text = __( 'Table ordered by Name.' );
+               }
+
</ins><span class="cx" style="display: block; padding: 0 10px">                 return array(
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                        'name'        => 'name',
-                       'description' => 'description',
-                       'slug'        => 'slug',
-                       'posts'       => 'count',
-                       'links'       => 'count',
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                 'name'        => array( 'name', false, _x( 'Name', 'term name' ), $name_orderby_text, 'asc' ),
+                       'description' => array( 'description', false, __( 'Description' ), __( 'Table ordered by Description.' ) ),
+                       'slug'        => array( 'slug', false, __( 'Slug' ), __( 'Table ordered by Slug.' ) ),
+                       'posts'       => array( 'count', false, _x( 'Count', 'Number/count of items' ), __( 'Table ordered by Posts Count.' ) ),
+                       'links'       => array( 'count', false, __( 'Links' ), __( 'Table ordered by Links.' ) ),
</ins><span class="cx" style="display: block; padding: 0 10px">                 );
</span><span class="cx" style="display: block; padding: 0 10px">        }
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span></span></pre></div>
<a id="trunksrcwpadminincludesclasswpuserslisttablephp"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: trunk/src/wp-admin/includes/class-wp-users-list-table.php</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- trunk/src/wp-admin/includes/class-wp-users-list-table.php 2023-06-21 21:30:26 UTC (rev 55970)
+++ trunk/src/wp-admin/includes/class-wp-users-list-table.php   2023-06-21 21:45:52 UTC (rev 55971)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -393,8 +393,8 @@
</span><span class="cx" style="display: block; padding: 0 10px">         */
</span><span class="cx" style="display: block; padding: 0 10px">        protected function get_sortable_columns() {
</span><span class="cx" style="display: block; padding: 0 10px">                $columns = array(
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-                        'username' => 'login',
-                       'email'    => 'email',
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+                 'username' => array( 'login', false, __( 'Username' ), __( 'Table ordered by Username.' ), 'asc' ),
+                       'email'    => array( 'email', false, __( 'E-mail' ), __( 'Table ordered by E-mail.' ) ),
</ins><span class="cx" style="display: block; padding: 0 10px">                 );
</span><span class="cx" style="display: block; padding: 0 10px"> 
</span><span class="cx" style="display: block; padding: 0 10px">                return $columns;
</span></span></pre>
</div>
</div>

</body>
</html>