icon; ?> |
diff --git a/core/modules/forum/forum.module b/core/modules/forum/forum.module
index ca9bf7e..52d747a 100644
--- a/core/modules/forum/forum.module
+++ b/core/modules/forum/forum.module
@@ -1135,15 +1135,13 @@ function template_preprocess_forums(&$variables) {
*/
function template_preprocess_forum_list(&$variables) {
global $user;
- $row = 0;
+
// Sanitize each forum so that the template can safely print the data.
foreach ($variables['forums'] as $id => $forum) {
$variables['forums'][$id]->description = !empty($forum->description) ? filter_xss_admin($forum->description) : '';
$variables['forums'][$id]->link = url("forum/$forum->tid");
$variables['forums'][$id]->name = check_plain($forum->name);
$variables['forums'][$id]->is_container = !empty($forum->container);
- $variables['forums'][$id]->zebra = $row % 2 == 0 ? 'odd' : 'even';
- $row++;
$variables['forums'][$id]->new_text = '';
$variables['forums'][$id]->new_url = '';
@@ -1193,11 +1191,8 @@ function template_preprocess_forum_topic_list(&$variables) {
$variables['header'] = $header;
if (!empty($variables['topics'])) {
- $row = 0;
foreach ($variables['topics'] as $id => $topic) {
$variables['topics'][$id]->icon = theme('forum_icon', array('new_posts' => $topic->new, 'num_posts' => $topic->comment_count, 'comment_mode' => $topic->comment_mode, 'sticky' => $topic->sticky, 'first_new' => $topic->first_new));
- $variables['topics'][$id]->zebra = $row % 2 == 0 ? 'odd' : 'even';
- $row++;
// We keep the actual tid in forum table, if it's different from the
// current tid then it means the topic appears in two forums, one of
diff --git a/core/modules/image/image.admin.css b/core/modules/image/image.admin.css
index efe522f..cac31b3 100644
--- a/core/modules/image/image.admin.css
+++ b/core/modules/image/image.admin.css
@@ -1,4 +1,3 @@
-
/**
* Image style configuration pages.
*/
@@ -51,8 +50,7 @@ div.image-style-preview div.preview-image div.height span {
table.image-anchor {
width: auto;
}
-table.image-anchor tr.even,
-table.image-anchor tr.odd {
+table.image-anchor tr.zebra {
background: none;
}
table.image-anchor td {
diff --git a/core/modules/node/node.tpl.php b/core/modules/node/node.tpl.php
index c3db5ae..c56a74b 100644
--- a/core/modules/node/node.tpl.php
+++ b/core/modules/node/node.tpl.php
@@ -48,8 +48,6 @@
* - $created: Time the node was published formatted in Unix timestamp.
* - $classes_array: Array of html class attribute values. It is flattened
* into a string within the variable $classes.
- * - $zebra: Outputs either "even" or "odd". Useful for zebra striping in
- * teaser listings.
* - $id: Position of the node. Increments each time it's output.
*
* Node status variables:
diff --git a/core/modules/shortcut/shortcut.admin.js b/core/modules/shortcut/shortcut.admin.js
index dacae3e..04277df 100644
--- a/core/modules/shortcut/shortcut.admin.js
+++ b/core/modules/shortcut/shortcut.admin.js
@@ -16,14 +16,6 @@ Drupal.behaviors.shortcutDrag = {
slots = 0,
tableDrag = Drupal.tableDrag.shortcuts;
table.find('> tbody > tr, > tr')
- .filter(':visible')
- .filter(':odd').filter('.odd')
- .removeClass('odd').addClass('even')
- .end().end()
- .filter(':even').filter('.even')
- .removeClass('even').addClass('odd')
- .end().end()
- .end()
.filter('.shortcut-slot-empty').each(function(index) {
if ($(this).is(':visible')) {
visibleLength++;
@@ -86,18 +78,6 @@ Drupal.behaviors.shortcutDrag = {
var statusField = $rowElement.find('select.shortcut-status-select');
statusField.val(statusName);
};
-
- tableDrag.restripeTable = function () {
- // :even and :odd are reversed because jQuery counts from 0 and
- // we count from 1, so we're out of sync.
- // Match immediate children of the parent element to allow nesting.
- $(this.table).find('> tbody > tr:visible, > tr:visible')
- .filter(':odd').filter('.odd')
- .removeClass('odd').addClass('even')
- .end().end()
- .filter(':even').filter('.even')
- .removeClass('even').addClass('odd');
- };
}
}
};
diff --git a/core/modules/simpletest/lib/Drupal/simpletest/WebTestBase.php b/core/modules/simpletest/lib/Drupal/simpletest/WebTestBase.php
index f1a5f95..66a496d 100644
--- a/core/modules/simpletest/lib/Drupal/simpletest/WebTestBase.php
+++ b/core/modules/simpletest/lib/Drupal/simpletest/WebTestBase.php
@@ -1366,8 +1366,6 @@ abstract class WebTestBase extends TestBase {
break;
case 'data':
break;
- case 'restripe':
- break;
}
}
$content = $dom->saveHTML();
diff --git a/core/modules/simpletest/simpletest.css b/core/modules/simpletest/simpletest.css
index 86bd04b..d2e08ae 100644
--- a/core/modules/simpletest/simpletest.css
+++ b/core/modules/simpletest/simpletest.css
@@ -1,4 +1,3 @@
-
/* Test Table */
#simpletest-form-table th.select-all {
width: 1em;
@@ -46,28 +45,28 @@ div.simpletest-pass {
color: #981010;
}
-tr.simpletest-pass.odd {
+tr.simpletest-pass:nth-child(odd) {
background-color: #b6ffb6;
}
-tr.simpletest-pass.even {
+tr.simpletest-pass:nth-child(even) {
background-color: #9bff9b;
}
-tr.simpletest-fail.odd {
+tr.simpletest-fail:nth-child(odd) {
background-color: #ffc9c9;
}
-tr.simpletest-fail.even {
+tr.simpletest-fail:nth-child(even) {
background-color: #ffacac;
}
-tr.simpletest-exception.odd {
+tr.simpletest-exception:nth-child(odd) {
background-color: #f4ea71;
}
-tr.simpletest-exception.even {
+tr.simpletest-exception:nth-child(even) {
background-color: #f5e742;
}
-tr.simpletest-debug.odd {
+tr.simpletest-debug:nth-child(odd) {
background-color: #eee;
}
-tr.simpletest-debug.even {
+tr.simpletest-debug:nth-child(even) {
background-color: #fff;
}
diff --git a/core/modules/system/lib/Drupal/system/Tests/Ajax/CommandsTest.php b/core/modules/system/lib/Drupal/system/Tests/Ajax/CommandsTest.php
index 299b674..7deaf11 100644
--- a/core/modules/system/lib/Drupal/system/Tests/Ajax/CommandsTest.php
+++ b/core/modules/system/lib/Drupal/system/Tests/Ajax/CommandsTest.php
@@ -142,14 +142,6 @@ class CommandsTest extends AjaxTestBase {
);
$this->assertCommand($commands, $expected, "'remove' AJAX command issued with correct command and selector");
- // Tests the 'restripe' command.
- $commands = $this->drupalPostAJAX($form_path, $edit, array('op' => t("AJAX 'restripe' command")));
- $expected = array(
- 'command' => 'restripe',
- 'selector' => '#restripe_table',
- );
- $this->assertCommand($commands, $expected, "'restripe' AJAX command issued with correct selector");
-
// Tests the 'settings' command.
$commands = $this->drupalPostAJAX($form_path, $edit, array('op' => t("AJAX 'settings' command")));
$expected = array(
diff --git a/core/modules/system/lib/Drupal/system/Tests/Theme/FunctionsTest.php b/core/modules/system/lib/Drupal/system/Tests/Theme/FunctionsTest.php
index cb25c6f..dce500f 100644
--- a/core/modules/system/lib/Drupal/system/Tests/Theme/FunctionsTest.php
+++ b/core/modules/system/lib/Drupal/system/Tests/Theme/FunctionsTest.php
@@ -65,16 +65,16 @@ class FunctionsTest extends WebTestBase {
),
);
$inner = ' ';
- $inner .= '- c
';
- $inner .= '- d
';
+ $inner .= '- c
';
+ $inner .= '- d
';
$inner .= ' ';
$expected = ' ';
$expected .= ' Some title';
$expected .= ' ';
- $expected .= '- a
';
- $expected .= '- b' . $inner . '
';
- $expected .= '- e
';
+ $expected .= '- a
';
+ $expected .= '- b' . $inner . '
';
+ $expected .= '- e
';
$expected .= ' ';
$this->assertThemeOutput('item_list', $variables, $expected);
@@ -119,9 +119,9 @@ class FunctionsTest extends WebTestBase {
$expected_links = '';
$expected_links .= ' ';
// Verify that passing a string as heading works.
diff --git a/core/modules/system/lib/Drupal/system/Tests/Theme/TableTest.php b/core/modules/system/lib/Drupal/system/Tests/Theme/TableTest.php
index ef51f4e..0c44129 100644
--- a/core/modules/system/lib/Drupal/system/Tests/Theme/TableTest.php
+++ b/core/modules/system/lib/Drupal/system/Tests/Theme/TableTest.php
@@ -63,7 +63,7 @@ class TableTest extends WebTestBase {
),
);
$this->content = theme('table', array('header' => $header, 'rows' => array(), 'empty' => t('No strings available.')));
- $this->assertRaw(' No strings available. | ', t('Correct colspan was set on empty message.'));
+ $this->assertRaw(' No strings available. | ', t('Correct colspan was set on empty message.'));
$this->assertRaw('Header 1 | ', t('Table header was printed.'));
}
}
diff --git a/core/modules/system/system.admin-rtl.css b/core/modules/system/system.admin-rtl.css
index d7553b5..7c81f59 100644
--- a/core/modules/system/system.admin-rtl.css
+++ b/core/modules/system/system.admin-rtl.css
@@ -57,11 +57,11 @@ table.screenshot {
border-left: 1px solid #cdcdcd;
float: right;
}
-.theme-selector .operations li.last {
+.theme-selector .operations li:last-child {
border-left: none;
padding: 0 0.7em 0 0;
}
-.theme-selector .operations li.first {
+.theme-selector .operations li:first-child {
padding: 0 0 0 0.7em;
}
diff --git a/core/modules/system/system.admin.css b/core/modules/system/system.admin.css
index 957d3e0..1596721 100644
--- a/core/modules/system/system.admin.css
+++ b/core/modules/system/system.admin.css
@@ -222,11 +222,11 @@ table.screenshot {
list-style-type: none;
border-right: 1px solid #cdcdcd; /* LTR */
}
-.theme-selector .operations li.last {
+.theme-selector .operations li:last-child {
padding: 0 0 0 0.7em; /* LTR */
border-right: none; /* LTR */
}
-.theme-selector .operations li.first {
+.theme-selector .operations li:first-child {
padding: 0 0.7em 0 0; /* LTR */
}
#system-themes-admin-form {
diff --git a/core/modules/system/system.theme.css b/core/modules/system/system.theme.css
index d5f41e1..fb86b12 100644
--- a/core/modules/system/system.theme.css
+++ b/core/modules/system/system.theme.css
@@ -1,4 +1,3 @@
-
/**
* @file
* Basic styling for common markup.
@@ -30,8 +29,7 @@ th {
padding-right: 1em; /* LTR */
text-align: left; /* LTR */
}
-tr.even,
-tr.odd {
+tr.zebra {
background-color: #eee;
border-bottom: 1px solid #ccc;
padding: 0.1em 0.6em;
diff --git a/core/modules/system/tests/modules/ajax_forms_test/ajax_forms_test.module b/core/modules/system/tests/modules/ajax_forms_test/ajax_forms_test.module
index 6a95710..f8dcbb0 100644
--- a/core/modules/system/tests/modules/ajax_forms_test/ajax_forms_test.module
+++ b/core/modules/system/tests/modules/ajax_forms_test/ajax_forms_test.module
@@ -232,21 +232,6 @@ function ajax_forms_test_ajax_commands_form($form, &$form_state) {
'#suffix' => '',
);
- // Shows the Ajax 'restripe' command.
- $form['restripe_command_example'] = array(
- '#type' => 'submit',
- '#value' => t("AJAX 'restripe' command"),
- '#ajax' => array(
- 'callback' => 'ajax_forms_test_advanced_commands_restripe_callback',
- ),
- '#suffix' => '
-
- first row |
- second row |
-
- ',
- );
-
// Demonstrates the Ajax 'settings' command. The 'settings' command has
// nothing visual to "show", but it can be tested via SimpleTest and via
// Firebug.
@@ -392,15 +377,6 @@ function ajax_forms_test_advanced_commands_remove_callback($form, $form_state) {
}
/**
- * Ajax callback for 'restripe'.
- */
-function ajax_forms_test_advanced_commands_restripe_callback($form, $form_state) {
- $commands = array();
- $commands[] = ajax_command_restripe('#restripe_table');
- return array('#type' => 'ajax', '#commands' => $commands);
-}
-
-/**
* Ajax callback for 'settings'.
*/
function ajax_forms_test_advanced_commands_settings_callback($form, $form_state) {
diff --git a/core/modules/taxonomy/taxonomy-term.tpl.php b/core/modules/taxonomy/taxonomy-term.tpl.php
index b1ff20e..047b853 100644
--- a/core/modules/taxonomy/taxonomy-term.tpl.php
+++ b/core/modules/taxonomy/taxonomy-term.tpl.php
@@ -26,8 +26,6 @@
* - $page: Flag for the full page state.
* - $classes_array: Array of html class attribute values. It is flattened
* into a string within the variable $classes.
- * - $zebra: Outputs either "even" or "odd". Useful for zebra striping in
- * teaser listings.
* - $id: Position of the term. Increments each time it's output.
* - $is_front: Flags true when presented in the front page.
* - $logged_in: Flags true when the current user is a logged-in member.
diff --git a/core/modules/update/update.css b/core/modules/update/update.css
index cb20500..5206d8d 100644
--- a/core/modules/update/update.css
+++ b/core/modules/update/update.css
@@ -30,8 +30,7 @@
padding: 1em 1em .25em 1em;
}
-.update tr.even,
-.update tr.odd {
+.update tr.zebra {
border: none;
}
diff --git a/core/modules/user/user.css b/core/modules/user/user.css
index 866ee40..6e4e97f 100644
--- a/core/modules/user/user.css
+++ b/core/modules/user/user.css
@@ -1,12 +1,10 @@
-
#permissions td.module {
font-weight: bold;
}
#permissions td.permission {
padding-left: 1.5em; /* LTR */
}
-#permissions tr.odd .form-item,
-#permissions tr.even .form-item {
+#permissions tr.zebra .form-item {
white-space: normal;
}
#user-admin-settings fieldset .fieldset-description {
diff --git a/core/themes/bartik/css/style-rtl.css b/core/themes/bartik/css/style-rtl.css
index 90638eb..e47f77e 100644
--- a/core/themes/bartik/css/style-rtl.css
+++ b/core/themes/bartik/css/style-rtl.css
@@ -55,11 +55,11 @@ ul.tips {
margin-left: 2px;
margin-right: 0;
}
-.region-header #block-user-login .item-list li.last {
+.region-header #block-user-login .item-list li:last-child {
padding-left: 0;
padding-right: 0.5em;
}
-.region-header #block-user-login ul.openid-links li.last {
+.region-header #block-user-login ul.openid-links li:last-child {
padding-right: 0;
}
.region-header #user-login-form li.openid-link a,
@@ -176,11 +176,11 @@ a.button {
border-color: rgba(255, 255, 255, 0.15);
border-right: none;
}
-#footer li.first a {
+#footer li:first-child a {
padding-right: 0;
padding-left: 12px;
}
-#footer li.last a {
+#footer li:last-child a {
padding-left: 0;
padding-right: 12px;
border-left: none;
diff --git a/core/themes/bartik/css/style.css b/core/themes/bartik/css/style.css
index 72f776d..e419a9d 100644
--- a/core/themes/bartik/css/style.css
+++ b/core/themes/bartik/css/style.css
@@ -1,4 +1,3 @@
-
/* ---------- Overall Specifications ---------- */
body {
@@ -41,7 +40,7 @@ p {
del {
text-decoration: line-through;
}
-tr.odd {
+tr.zebra:nth-child(odd) {
background-color: #dddddd;
}
img {
@@ -210,12 +209,12 @@ tr th {
border-color: #555;
border-color: rgba(255, 255, 255, 0.18);
}
-tr.odd {
+tr.zebra:nth-child(odd) {
background: #e4e4e4;
background: rgba(0, 0, 0, 0.105);
}
tr,
-tr.even {
+tr.zebra:nth-child(even) {
background: #efefef;
background: rgba(0, 0, 0, 0.063);
}
@@ -371,7 +370,7 @@ h1#site-name {
text-decoration: none;
background: rgba(255, 255, 255, 0.15);
}
-.region-header .block-menu li.last a {
+.region-header .block-menu li:last-child a {
border-bottom: 0;
}
/* User Login block in the header region */
@@ -406,10 +405,10 @@ h1#site-name {
float: left; /* LTR */
padding: 3px 0 1px;
}
-.region-header #block-user-login .item-list li.last {
+.region-header #block-user-login .item-list li:last-child {
padding-left: 0.5em; /* LTR */
}
-.region-header #block-user-login ul.openid-links li.last {
+.region-header #block-user-login ul.openid-links li:last-child {
padding-left: 0; /* LTR */
}
.region-header #user-login-form li.openid-link a,
@@ -755,8 +754,7 @@ ul.links {
.sidebar tbody {
border: none;
}
-.sidebar tr.even,
-.sidebar tr.odd {
+.sidebar tr {
background: none;
border-bottom: 1px solid #d6d6d6;
}
@@ -782,7 +780,7 @@ ul.links {
border-bottom: 1px solid #dfdfdf;
line-height: 1.3;
}
-#triptych .block.last {
+#triptych .block:last-child {
border-bottom: none;
}
#triptych .block ul li,
@@ -919,17 +917,17 @@ ul.links {
border-right: 1px solid #555; /* LTR */
border-color: rgba(255, 255, 255, 0.15);
}
-#footer li.first a {
+#footer li:first-child a {
padding-left: 0; /* LTR */
}
-#footer li.last a {
+#footer li:last-child a {
padding-right: 0; /* LTR */
border-right: none; /* LTR */
}
-#footer-wrapper tr.odd {
+#footer-wrapper tr.zebra:nth-child(odd) {
background-color: transparent;
}
-#footer-wrapper tr.even {
+#footer-wrapper tr.zebra:nth-child(even) {
background-color: #2c2c2c;
background-color: rgba(0, 0, 0, 0.15);
}
diff --git a/core/themes/bartik/templates/node.tpl.php b/core/themes/bartik/templates/node.tpl.php
index 318197c..ac3216f 100644
--- a/core/themes/bartik/templates/node.tpl.php
+++ b/core/themes/bartik/templates/node.tpl.php
@@ -49,8 +49,6 @@
* - $created: Time the node was published formatted in Unix timestamp.
* - $classes_array: Array of html class attribute values. It is flattened
* into a string within the variable $classes.
- * - $zebra: Outputs either "even" or "odd". Useful for zebra striping in
- * teaser listings.
* - $id: Position of the node. Increments each time it's output.
*
* Node status variables:
diff --git a/core/themes/seven/reset.css b/core/themes/seven/reset.css
index de53f28..9f3e6b1 100644
--- a/core/themes/seven/reset.css
+++ b/core/themes/seven/reset.css
@@ -1,4 +1,3 @@
-
/**
* Reset CSS styles.
*
@@ -80,8 +79,7 @@ ul.links li,
/* Drupal: admin.css */
div.admin,
/* Drupal: system.css */
-tr.even,
-tr.odd,
+tr.zebra,
tr.drag,
tbody,
tbody th,
@@ -93,8 +91,7 @@ thead th,
.item-list ul li,
ol.task-list li.active,
.form-item,
-tr.odd .form-item,
-tr.even .form-item,
+tr.zebra .form-item,
.form-item .description,
.form-item label,
.form-item label.option,
diff --git a/core/themes/seven/style.css b/core/themes/seven/style.css
index 380aec8..67cbccc 100644
--- a/core/themes/seven/style.css
+++ b/core/themes/seven/style.css
@@ -1,4 +1,3 @@
-
/**
* Generic elements.
*/
@@ -442,14 +441,13 @@ table th {
border: 0;
color: #000;
}
-tr.even,
-tr.odd {
+tr.zebra {
border-width: 0 1px 0 1px;
border-style: solid;
border-color: #bebfb9;
background: #f3f4ee;
}
-tr.odd {
+tr.zebra:nth-child(odd) {
background: #fff;
}
tr.drag {
---|
|