diff --git a/core/includes/common.inc b/core/includes/common.inc index e768bf4..e6ae994 100644 --- a/core/includes/common.inc +++ b/core/includes/common.inc @@ -1346,9 +1346,9 @@ function l($text, $path, array $options = array()) { // The query parameters of an active link are equal to the current parameters. && ($variables['options']['query'] == $active['query']); - // Add the "active" class if appropriate. + // Add the "is-active" class if appropriate. if ($variables['url_is_active']) { - $variables['options']['attributes']['class'][] = 'active'; + $variables['options']['attributes']['class'][] = 'is-active'; } // Remove all HTML and PHP tags from a tooltip, calling expensive strip_tags() diff --git a/core/includes/menu.inc b/core/includes/menu.inc index 94d0e57..e509e98 100644 --- a/core/includes/menu.inc +++ b/core/includes/menu.inc @@ -1109,7 +1109,7 @@ function menu_tree_output($tree) { // trees, so if the current path is a local task, and this link is its // tab root, then we have to set the class manually. if ($data['link']['href'] == $router_item['tab_root_href'] && $data['link']['href'] != current_path()) { - $data['link']['localized_options']['attributes']['class'][] = 'active'; + $data['link']['localized_options']['attributes']['class'][] = 'is-active'; } // Allow menu-specific theme overrides. @@ -1695,7 +1695,7 @@ function theme_menu_local_task($variables) { $link_text = t('!local-task-title!active', array('!local-task-title' => $link['title'], '!active' => $active)); } - return '' . l($link_text, $link['href'], $link['localized_options']) . ''; + return '' . l($link_text, $link['href'], $link['localized_options']) . ''; } /** @@ -1895,7 +1895,7 @@ function menu_navigation_links($menu_name, $level = 0) { // menu trees, so if the current path is a local task, and this link is // its tab root, then we have to set the class manually. if ($item['link']['href'] == $router_item['tab_root_href'] && $item['link']['href'] != current_path()) { - $l['attributes']['class'][] = 'active'; + $l['attributes']['class'][] = 'is-active'; } // Keyed with the unique mlid to generate classes in theme_links(). $links['menu-' . $item['link']['mlid'] . $class] = $l; @@ -2008,7 +2008,7 @@ function menu_local_tasks($level = 0) { // would not be marked as active, since l() only compares the href // with current_path(). if ($link['href'] != current_path()) { - $link['localized_options']['attributes']['class'][] = 'active'; + $link['localized_options']['attributes']['class'][] = 'is-active'; } $tabs_current[$link['href']] = array( '#theme' => 'menu_local_task', @@ -2085,7 +2085,7 @@ function menu_local_tasks($level = 0) { // links to its parent, l() will not mark it as active, as it only // compares the link's href to current_path(). if ($link['href'] != current_path()) { - $link['localized_options']['attributes']['class'][] = 'active'; + $link['localized_options']['attributes']['class'][] = 'is-active'; } $tabs_current[$link['href']] = array( '#theme' => 'menu_local_task', diff --git a/core/includes/tablesort.inc b/core/includes/tablesort.inc index c42b1f4..da0bb46 100644 --- a/core/includes/tablesort.inc +++ b/core/includes/tablesort.inc @@ -48,7 +48,7 @@ function tablesort_header($cell, $header, $ts) { // http://www.w3.org/TR/wai-aria/states_and_properties#aria-sort $cell['aria-sort'] = ($ts['sort'] == 'asc') ? 'ascending' : 'descending'; $ts['sort'] = (($ts['sort'] == 'asc') ? 'desc' : 'asc'); - $cell['class'][] = 'active'; + $cell['class'][] = 'is-active'; $image = theme('tablesort_indicator', array('style' => $ts['sort'])); } else { @@ -83,10 +83,10 @@ function tablesort_header($cell, $header, $ts) { function tablesort_cell($cell, $header, $ts, $i) { if (isset($header[$i]['data']) && $header[$i]['data'] == $ts['name'] && !empty($header[$i]['field'])) { if (is_array($cell)) { - $cell['class'][] = 'active'; + $cell['class'][] = 'is-active'; } else { - $cell = array('data' => $cell, 'class' => array('active')); + $cell = array('data' => $cell, 'class' => array('is-active')); } } return $cell; diff --git a/core/includes/theme.inc b/core/includes/theme.inc index f1e0861..a6c2d7f 100644 --- a/core/includes/theme.inc +++ b/core/includes/theme.inc @@ -1737,7 +1737,7 @@ function theme_links($variables) { $is_current_path = ($link['href'] == current_path() || ($link['href'] == '' && drupal_is_front_page())); $is_current_language = (empty($link['language']) || $link['language']->id == $language_url->id); if ($is_current_path && $is_current_language) { - $class[] = 'active'; + $class[] = 'is-active'; } // @todo Reconcile Views usage of 'ajax' as a boolean with the rest of // core's usage of it as an array. diff --git a/core/includes/theme.maintenance.inc b/core/includes/theme.maintenance.inc index de519a2..5e27bdf 100644 --- a/core/includes/theme.maintenance.inc +++ b/core/includes/theme.maintenance.inc @@ -135,7 +135,7 @@ function theme_task_list($variables) { foreach ($items as $k => $item) { if ($active == $k) { - $class = 'active'; + $class = 'is-active'; $status = '(' . t('active') . ')'; $done = FALSE; } diff --git a/core/modules/contextual/contextual.toolbar.js b/core/modules/contextual/contextual.toolbar.js index ecd19d92..f121881 100644 --- a/core/modules/contextual/contextual.toolbar.js +++ b/core/modules/contextual/contextual.toolbar.js @@ -152,7 +152,7 @@ Drupal.contextualToolbar = { // Render the visibility. this.$el.toggleClass('hidden', !this.model.get('isVisible')); // Render the state. - this.$el.find('button').toggleClass('active', !this.model.get('isViewing')); + this.$el.find('button').toggleClass('is-active', !this.model.get('isViewing')); return this; }, diff --git a/core/modules/contextual/css/contextual.toolbar.css b/core/modules/contextual/css/contextual.toolbar.css index b4fcd1f..ec0b60b 100644 --- a/core/modules/contextual/css/contextual.toolbar.css +++ b/core/modules/contextual/css/contextual.toolbar.css @@ -30,7 +30,7 @@ .js[dir=rtl] .toolbar .bar .contextual-toolbar-tab button { padding-right: 1.3333em; } -.js .toolbar .bar .contextual-toolbar-tab button.active { +.js .toolbar .bar .contextual-toolbar-tab button.is-active { background-image:-moz-linear-gradient(rgb(78,159,234) 0%,rgb(69,132,221) 100%); background-image:-webkit-gradient(linear,color-stop(0, rgb(78,159,234)),color-stop(1, rgb(69,132,221))); background-image: -webkit-linear-gradient(top, rgb(78,159,234) 0%, rgb(69,132,221) 100%); diff --git a/core/modules/dblog/css/dblog.module.css b/core/modules/dblog/css/dblog.module.css index 66ce59a..4858b45 100644 --- a/core/modules/dblog/css/dblog.module.css +++ b/core/modules/dblog/css/dblog.module.css @@ -17,22 +17,22 @@ padding: 3ex 0 0; vertical-align: top; } -.dblog-user.odd .active { +.dblog-user.odd .is-active { background: #ddf; } -.dblog-user.even .active { +.dblog-user.even .is-active { background: #cce; } -.dblog-error.odd .active { +.dblog-error.odd .is-active { background: #ffc9c9; } -.dblog-error.even .active { +.dblog-error.even .is-active { background: #eeb9b9; } -.dblog-warning.odd .active { +.dblog-warning.odd .is-active { background: #fffdca; } -.dblog-warning.even .active { +.dblog-warning.even .is-active { background: #eeedbd; } .admin-dblog .icon { diff --git a/core/modules/image/lib/Drupal/image/Tests/ImageFieldDisplayTest.php b/core/modules/image/lib/Drupal/image/Tests/ImageFieldDisplayTest.php index c0f0cfd..f52fedb 100644 --- a/core/modules/image/lib/Drupal/image/Tests/ImageFieldDisplayTest.php +++ b/core/modules/image/lib/Drupal/image/Tests/ImageFieldDisplayTest.php @@ -100,7 +100,7 @@ function _testImageFieldFormatters($scheme) { $display_options['settings']['image_link'] = 'content'; $display->setComponent($field_name, $display_options) ->save(); - $default_output = l(theme('image', $image_info), 'node/' . $nid, array('html' => TRUE, 'attributes' => array('class' => 'active'))); + $default_output = l(theme('image', $image_info), 'node/' . $nid, array('html' => TRUE, 'attributes' => array('class' => 'is-active'))); $this->drupalGet('node/' . $nid); $this->assertRaw($default_output, 'Image linked to content formatter displaying correctly on full node view.'); diff --git a/core/modules/language/lib/Drupal/language/Tests/LanguageSwitchingTest.php b/core/modules/language/lib/Drupal/language/Tests/LanguageSwitchingTest.php index 6265660..de634b0 100644 --- a/core/modules/language/lib/Drupal/language/Tests/LanguageSwitchingTest.php +++ b/core/modules/language/lib/Drupal/language/Tests/LanguageSwitchingTest.php @@ -62,32 +62,32 @@ function testLanguageBlock() { // Assert that only the current language is marked as active. list($language_switcher) = $this->xpath('//div[@id=:id]/div[contains(@class, "content")]', array(':id' => 'block-test-language-block')); $links = array( - 'active' => array(), + 'is-active' => array(), 'inactive' => array(), ); $anchors = array( - 'active' => array(), + 'is-active' => array(), 'inactive' => array(), ); foreach ($language_switcher->ul->li as $link) { $classes = explode(" ", (string) $link['class']); list($langcode) = array_intersect($classes, array('en', 'fr')); - if (in_array('active', $classes)) { - $links['active'][] = $langcode; + if (in_array('is-active', $classes)) { + $links['is-active'][] = $langcode; } else { $links['inactive'][] = $langcode; } $anchor_classes = explode(" ", (string) $link->a['class']); - if (in_array('active', $anchor_classes)) { - $anchors['active'][] = $langcode; + if (in_array('is-active', $anchor_classes)) { + $anchors['is-active'][] = $langcode; } else { $anchors['inactive'][] = $langcode; } } - $this->assertIdentical($links, array('active' => array('en'), 'inactive' => array('fr')), 'Only the current language list item is marked as active on the language switcher block.'); - $this->assertIdentical($anchors, array('active' => array('en'), 'inactive' => array('fr')), 'Only the current language anchor is marked as active on the language switcher block.'); + $this->assertIdentical($links, array('is-active' => array('en'), 'inactive' => array('fr')), 'Only the current language list item is marked as active on the language switcher block.'); + $this->assertIdentical($anchors, array('is-active' => array('en'), 'inactive' => array('fr')), 'Only the current language anchor is marked as active on the language switcher block.'); } /** @@ -112,17 +112,17 @@ function testLanguageLinkActiveClass() { // Language code 'none' link should be active. $langcode = 'none'; - $links = $this->xpath('//a[@id = :id and contains(@class, :class)]', array(':id' => 'no_lang_link', ':class' => 'active')); + $links = $this->xpath('//a[@id = :id and contains(@class, :class)]', array(':id' => 'no_lang_link', ':class' => 'is-active')); $this->assertTrue(isset($links[0]), t('A link generated by :function to the current :language page with langcode :langcode is marked active.', array(':function' => $function_name, ':language' => $current_language, ':langcode' => $langcode))); // Language code 'en' link should be active. $langcode = 'en'; - $links = $this->xpath('//a[@id = :id and contains(@class, :class)]', array(':id' => 'en_link', ':class' => 'active')); + $links = $this->xpath('//a[@id = :id and contains(@class, :class)]', array(':id' => 'en_link', ':class' => 'is-active')); $this->assertTrue(isset($links[0]), t('A link generated by :function to the current :language page with langcode :langcode is marked active.', array(':function' => $function_name, ':language' => $current_language, ':langcode' => $langcode))); // Language code 'fr' link should not be active. $langcode = 'fr'; - $links = $this->xpath('//a[@id = :id and not(contains(@class, :class))]', array(':id' => 'fr_link', ':class' => 'active')); + $links = $this->xpath('//a[@id = :id and not(contains(@class, :class))]', array(':id' => 'fr_link', ':class' => 'is-active')); $this->assertTrue(isset($links[0]), t('A link generated by :function to the current :language page with langcode :langcode is NOT marked active.', array(':function' => $function_name, ':language' => $current_language, ':langcode' => $langcode))); // Test links generated by l() on a French page. @@ -131,17 +131,17 @@ function testLanguageLinkActiveClass() { // Language code 'none' link should be active. $langcode = 'none'; - $links = $this->xpath('//a[@id = :id and contains(@class, :class)]', array(':id' => 'no_lang_link', ':class' => 'active')); + $links = $this->xpath('//a[@id = :id and contains(@class, :class)]', array(':id' => 'no_lang_link', ':class' => 'is-active')); $this->assertTrue(isset($links[0]), t('A link generated by :function to the current :language page with langcode :langcode is marked active.', array(':function' => $function_name, ':language' => $current_language, ':langcode' => $langcode))); // Language code 'en' link should not be active. $langcode = 'en'; - $links = $this->xpath('//a[@id = :id and not(contains(@class, :class))]', array(':id' => 'en_link', ':class' => 'active')); + $links = $this->xpath('//a[@id = :id and not(contains(@class, :class))]', array(':id' => 'en_link', ':class' => 'is-active')); $this->assertTrue(isset($links[0]), t('A link generated by :function to the current :language page with langcode :langcode is NOT marked active.', array(':function' => $function_name, ':language' => $current_language, ':langcode' => $langcode))); // Language code 'fr' link should be active. $langcode = 'fr'; - $links = $this->xpath('//a[@id = :id and contains(@class, :class)]', array(':id' => 'fr_link', ':class' => 'active')); + $links = $this->xpath('//a[@id = :id and contains(@class, :class)]', array(':id' => 'fr_link', ':class' => 'is-active')); $this->assertTrue(isset($links[0]), t('A link generated by :function to the current :language page with langcode :langcode is marked active.', array(':function' => $function_name, ':language' => $current_language, ':langcode' => $langcode))); } diff --git a/core/modules/language/lib/Drupal/language/Tests/LanguageUILanguageNegotiationTest.php b/core/modules/language/lib/Drupal/language/Tests/LanguageUILanguageNegotiationTest.php index 555c198..ab116da 100644 --- a/core/modules/language/lib/Drupal/language/Tests/LanguageUILanguageNegotiationTest.php +++ b/core/modules/language/lib/Drupal/language/Tests/LanguageUILanguageNegotiationTest.php @@ -419,7 +419,7 @@ function testUrlLanguageFallback() { // Check that the language switcher active link matches the given browser // language. $args = array(':id' => 'block-test-language-block', ':url' => base_path() . $GLOBALS['script_path'] . $langcode_browser_fallback); - $fields = $this->xpath('//div[@id=:id]//a[@class="language-link active" and starts-with(@href, :url)]', $args); + $fields = $this->xpath('//div[@id=:id]//a[@class="language-link is-active" and starts-with(@href, :url)]', $args); $this->assertTrue($fields[0] == $languages[$langcode_browser_fallback]->name, 'The browser language is the URL active language'); // Check that URLs are rewritten using the given browser language. diff --git a/core/modules/overlay/css/overlay-child.css b/core/modules/overlay/css/overlay-child.css index 6fe068d..fa78927 100644 --- a/core/modules/overlay/css/overlay-child.css +++ b/core/modules/overlay/css/overlay-child.css @@ -125,10 +125,10 @@ html[dir=rtl] { padding: 0 14px; text-decoration: none; } -#overlay-tabs li.active a, -#overlay-tabs li.active a.active, -#overlay-tabs li.active a:active, -#overlay-tabs li.active a:visited { +#overlay-tabs li.is-active a, +#overlay-tabs li.is-active a.is-active, +#overlay-tabs li.is-active a:active, +#overlay-tabs li.is-active a:visited { background-color: #fff; margin-bottom: 0; padding-bottom: 2px; @@ -137,8 +137,8 @@ html[dir=rtl] { #overlay-tabs li a:hover { color: #fff; } -#overlay-tabs li.active a:focus, -#overlay-tabs li.active a:hover { +#overlay-tabs li.is-active a:focus, +#overlay-tabs li.is-active a:hover { color: #000; } diff --git a/core/modules/overlay/overlay-child.js b/core/modules/overlay/overlay-child.js index cd7cdee..0fe2572 100644 --- a/core/modules/overlay/overlay-child.js +++ b/core/modules/overlay/overlay-child.js @@ -157,8 +157,8 @@ Drupal.overlayChild.behaviors.tabs = function (context, settings) { $('#overlay-tabs > li > a').bind('click.drupal-overlay', function () { var active_tab = Drupal.t('(active tab)'); - $tabsLinks.parent().siblings().removeClass('active').find('visually-hidden:contains(' + active_tab + ')').appendTo(this); - $(this).parent().addClass('active'); + $tabsLinks.parent().siblings().removeClass('is-active').find('visually-hidden:contains(' + active_tab + ')').appendTo(this); + $(this).parent().addClass('is-active'); }); }; diff --git a/core/modules/overlay/overlay-parent.js b/core/modules/overlay/overlay-parent.js index 4f45299..e3c093f 100644 --- a/core/modules/overlay/overlay-parent.js +++ b/core/modules/overlay/overlay-parent.js @@ -793,7 +793,7 @@ Drupal.overlay.resetActiveClass = function(activePath) { $('#toolbar-administration') .find('a[href]') // Remove active class from all links in displaced elements. - .removeClass('active') + .removeClass('is-active') // Add active class to links that match activePath. .each(function () { var linkDomain = this.protocol + this.hostname; @@ -802,7 +802,7 @@ Drupal.overlay.resetActiveClass = function(activePath) { // A link matches if it is part of the active trail of activePath, except // for frontpage links. if (linkDomain === windowDomain && (activePath + '/').indexOf(linkPath + '/') === 0 && (linkPath !== '' || activePath === '')) { - $(this).addClass('active'); + $(this).addClass('is-active'); } }); }; diff --git a/core/modules/shortcut/css/shortcut.theme.css b/core/modules/shortcut/css/shortcut.theme.css index df5a6e8..f224bb5 100644 --- a/core/modules/shortcut/css/shortcut.theme.css +++ b/core/modules/shortcut/css/shortcut.theme.css @@ -10,7 +10,7 @@ background-image: url(../images/shortcut.png); } .icon-shortcut:active:before, -.icon-shortcut.active:before { +.icon-shortcut.is-active:before { background-image: url(../images/shortcut-active.png); } .toolbar .tray.horizontal.shortcuts .menu { diff --git a/core/modules/system/css/system.theme.css b/core/modules/system/css/system.theme.css index 4fb073f..d66dfca 100644 --- a/core/modules/system/css/system.theme.css +++ b/core/modules/system/css/system.theme.css @@ -65,10 +65,10 @@ caption { /** * Markup generated by theme_tablesort_indicator(). */ -th.active img { +th.is-active img { display: inline; } -td.active { +td.is-active { background-color: #ddd; } @@ -368,7 +368,7 @@ ul.menu li { padding-top: 0.2em; margin: 0; } -ul.menu a.active { +ul.menu a.is-active { color: #000; } @@ -434,7 +434,7 @@ ul.tabs { padding: 0.2em 1em; text-decoration: none; } -.tabs a.active { +.tabs a.is-active { background-color: #eee; } .tabs a:focus, diff --git a/core/modules/system/lib/Drupal/system/Tests/Menu/MenuTestBase.php b/core/modules/system/lib/Drupal/system/Tests/Menu/MenuTestBase.php index 7d23727..ea30827 100644 --- a/core/modules/system/lib/Drupal/system/Tests/Menu/MenuTestBase.php +++ b/core/modules/system/lib/Drupal/system/Tests/Menu/MenuTestBase.php @@ -118,7 +118,7 @@ protected function assertMenuActiveTrail($tree, $last_active) { $xpath .= 'li[contains(@class, :class-trail)]/a[contains(@href, :href) ' . $xpath_last_active . 'and contains(text(), :title)]'; $args = array( ':class-trail' => 'active-trail', - ':class-active' => 'active', + ':class-active' => 'is-active', ':href' => url($active_link_path), ':title' => $active_link_title, ); diff --git a/core/modules/system/lib/Drupal/system/Tests/Pager/PagerTest.php b/core/modules/system/lib/Drupal/system/Tests/Pager/PagerTest.php index bb27fa0..3798974 100644 --- a/core/modules/system/lib/Drupal/system/Tests/Pager/PagerTest.php +++ b/core/modules/system/lib/Drupal/system/Tests/Pager/PagerTest.php @@ -105,7 +105,7 @@ protected function assertPagerItems($current_page) { $this->assertNoClass($element, 'pager-current', "Item for page $page has no .pager-current class."); $this->assertClass($element, 'pager-item', "Item for page $page has .pager-item class."); $this->assertTrue($element->a, "Link to page $page found."); - $this->assertNoClass($element->a, 'active', "Link to page $page is not active."); + $this->assertNoClass($element->a, 'is-active', "Link to page $page is not active."); } unset($elements[--$page]); } @@ -116,22 +116,22 @@ protected function assertPagerItems($current_page) { if (isset($first)) { $this->assertClass($first, 'pager-first', 'Item for first page has .pager-first class.'); $this->assertTrue($first->a, 'Link to first page found.'); - $this->assertNoClass($first->a, 'active', 'Link to first page is not active.'); + $this->assertNoClass($first->a, 'is-active', 'Link to first page is not active.'); } if (isset($previous)) { $this->assertClass($previous, 'pager-previous', 'Item for first page has .pager-previous class.'); $this->assertTrue($previous->a, 'Link to previous page found.'); - $this->assertNoClass($previous->a, 'active', 'Link to previous page is not active.'); + $this->assertNoClass($previous->a, 'is-active', 'Link to previous page is not active.'); } if (isset($next)) { $this->assertClass($next, 'pager-next', 'Item for next page has .pager-next class.'); $this->assertTrue($next->a, 'Link to next page found.'); - $this->assertNoClass($next->a, 'active', 'Link to next page is not active.'); + $this->assertNoClass($next->a, 'is-active', 'Link to next page is not active.'); } if (isset($last)) { $this->assertClass($last, 'pager-last', 'Item for last page has .pager-last class.'); $this->assertTrue($last->a, 'Link to last page found.'); - $this->assertNoClass($last->a, 'active', 'Link to last page is not active.'); + $this->assertNoClass($last->a, 'is-active', 'Link to last page is not active.'); } } 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 d8505bc..e9392a6 100644 --- a/core/modules/system/lib/Drupal/system/Tests/Theme/FunctionsTest.php +++ b/core/modules/system/lib/Drupal/system/Tests/Theme/FunctionsTest.php @@ -165,7 +165,7 @@ function testLinks() { $expected_links .= ''; // Verify that passing a string as heading works. @@ -197,7 +197,7 @@ function testLinks() { $expected_links .= ''; $expected = $expected_heading . $expected_links; $this->assertThemeOutput('links', $variables, $expected); diff --git a/core/modules/toolbar/css/toolbar.icons.css b/core/modules/toolbar/css/toolbar.icons.css index dc457ca..5d9144a 100644 --- a/core/modules/toolbar/css/toolbar.icons.css +++ b/core/modules/toolbar/css/toolbar.icons.css @@ -63,14 +63,14 @@ background-image: url("../images/icon-home.png"); } .icon-home:active:before, -.icon-home.active:before { +.icon-home.is-active:before { background-image: url("../images/icon-home-active.png"); } .icon-menu:before { background-image: url("../images/icon-menu.png"); } .icon-menu:active:before, -.icon-menu.active:before { +.icon-menu.is-active:before { background-image: url("../images/icon-menu-active.png"); } @@ -81,56 +81,56 @@ background-image: url("../images/icon-content.png"); } .icon-content:active:before, -.icon-content.active:before { +.icon-content.is-active:before { background-image: url("../images/icon-content-active.png"); } .icon-structure:before { background-image: url("../images/icon-structure.png"); } .icon-structure:active:before, -.icon-structure.active:before { +.icon-structure.is-active:before { background-image: url("../images/icon-structure-active.png"); } .icon-appearance:before { background-image: url("../images/icon-appearance.png"); } .icon-appearance:active:before, -.icon-appearance.active:before { +.icon-appearance.is-active:before { background-image: url("../images/icon-appearance-active.png"); } .icon-people:before { background-image: url("../images/icon-people.png"); } .icon-people:active:before, -.icon-people.active:before { +.icon-people.is-active:before { background-image: url("../images/icon-people-active.png"); } .icon-extend:before { background-image: url("../images/icon-extend.png"); } .icon-extend:active:before, -.icon-extend.active:before { +.icon-extend.is-active:before { background-image: url("../images/icon-extend-active.png"); } .icon-configuration:before { background-image: url("../images/icon-configuration.png"); } .icon-configuration:active:before, -.icon-configuration.active:before { +.icon-configuration.is-active:before { background-image: url("../images/icon-configuration-active.png"); } .icon-reports:before { background-image: url("../images/icon-reports.png"); } .icon-reports:active:before, -.icon-reports.active:before { +.icon-reports.is-active:before { background-image: url("../images/icon-reports-active.png"); } .icon-help:before { background-image: url("../images/icon-help.png"); } .icon-help:active:before, -.icon-help.active:before { +.icon-help.is-active:before { background-image: url("../images/icon-help-active.png"); } diff --git a/core/modules/toolbar/css/toolbar.menu.css b/core/modules/toolbar/css/toolbar.menu.css index 39f214d..646ed95 100644 --- a/core/modules/toolbar/css/toolbar.menu.css +++ b/core/modules/toolbar/css/toolbar.menu.css @@ -28,7 +28,7 @@ margin-right: 0; } .toolbar .tray .active-trail > .box a, -.toolbar .tray a.active { +.toolbar .tray a.is-active { color: #000; font-weight: bold; } diff --git a/core/modules/toolbar/css/toolbar.module.css b/core/modules/toolbar/css/toolbar.module.css index be20fdc..9b44b1d 100644 --- a/core/modules/toolbar/css/toolbar.module.css +++ b/core/modules/toolbar/css/toolbar.module.css @@ -173,26 +173,26 @@ html.js[dir=rtl] .toolbar { top: 0; z-index: -1; } -.toolbar .tray.active { +.toolbar .tray.is-active { display: block; } -.toolbar .horizontal.active { +.toolbar .horizontal.is-active { height: auto; } -.toolbar .vertical.active, -.toolbar .vertical.active > .lining { +.toolbar .vertical.is-active, +.toolbar .vertical.is-active > .lining { bottom: 0; left: 0; /* LTR */ top: 0; } -[dir=rtl] .toolbar .vertical.active, -[dir=rtl] .toolbar .vertical.active > .lining { +[dir=rtl] .toolbar .vertical.is-active, +[dir=rtl] .toolbar .vertical.is-active > .lining { left: auto; right: 0; } /* Make vertical toolbar tray scroll with page for touch devices. */ -.touch .toolbar .vertical.active, -.touch .toolbar .vertical.active > .lining { +.touch .toolbar .vertical.is-active, +.touch .toolbar .vertical.is-active > .lining { bottom: auto; top: auto; } @@ -216,11 +216,11 @@ html.js[dir=rtl] .toolbar { width: 240px; width: 15rem; } - .toolbar .vertical.active > .lining:before { + .toolbar .vertical.is-active > .lining:before { display: block; left: -1px; /* LTR */ } - [dir=rtl] .toolbar .vertical.active > .lining:before { + [dir=rtl] .toolbar .vertical.is-active > .lining:before { left: auto; right: -1px; } diff --git a/core/modules/toolbar/css/toolbar.theme.css b/core/modules/toolbar/css/toolbar.theme.css index 4407211..d93be42 100644 --- a/core/modules/toolbar/css/toolbar.theme.css +++ b/core/modules/toolbar/css/toolbar.theme.css @@ -45,7 +45,7 @@ background-image: linear-gradient(rgba(255, 255, 255, 0.125) 20%, transparent 200%); text-decoration: none; } -.toolbar .bar .tab > a.active { +.toolbar .bar .tab > a.is-active { background-image: -webkit-linear-gradient(rgba(255, 255, 255, 0.25) 20%, transparent 200%); background-image: linear-gradient(rgba(255, 255, 255, 0.25) 20%, transparent 200%); } @@ -94,7 +94,7 @@ } .toolbar .tray a:hover, .toolbar .tray a:active, -.toolbar .tray a.active { +.toolbar .tray a.is-active { color: #000; } .toolbar .horizontal .menu { diff --git a/core/modules/toolbar/js/toolbar.js b/core/modules/toolbar/js/toolbar.js index 3e12b55..a6c72fb 100644 --- a/core/modules/toolbar/js/toolbar.js +++ b/core/modules/toolbar/js/toolbar.js @@ -133,11 +133,11 @@ Drupal.toolbar.toggleTray = function (event) { var $tab = $(event.target); var name = $tab.attr('data-toolbar-tray'); // Activate the selected tab and associated tray. - var $activateTray = $toolbar.find('[data-toolbar-tray="' + name + '"].tray').toggleClass('active'); + var $activateTray = $toolbar.find('[data-toolbar-tray="' + name + '"].tray').toggleClass('is-active'); if ($activateTray.length) { event.preventDefault(); event.stopPropagation(); - $tab.toggleClass('active'); + $tab.toggleClass('is-active'); // Toggle aria-pressed. var value = $tab.prop('aria-pressed'); $tab.prop('aria-pressed', (value === 'false') ? 'true' : 'false'); @@ -147,7 +147,7 @@ Drupal.toolbar.toggleTray = function (event) { '@state': (value === 'true') ? strings.closed : strings.opened })); // Store the active tab name or remove the setting. - if ($tab.hasClass('active')) { + if ($tab.hasClass('is-active')) { localStorage.setItem('Drupal.toolbar.activeTab', JSON.stringify(name)); } else { @@ -156,10 +156,10 @@ Drupal.toolbar.toggleTray = function (event) { // Disable non-selected tabs and trays. $toolbar.find('.bar .trigger') .not($tab) - .removeClass('active') + .removeClass('is-active') // Set aria-pressed to false. .prop('aria-pressed', false); - $toolbar.find('.tray').not($activateTray).removeClass('active'); + $toolbar.find('.tray').not($activateTray).removeClass('is-active'); } // Update the page and toolbar dimension indicators. updatePeripherals(); @@ -202,9 +202,9 @@ Drupal.toolbar.setTrayWidth = function () { // Remove the left offset from the trays. $toolbar.find('.tray').removeAttr('data-offset-' + edge + ' data-offset-top'); // If an active vertical tray exists, mark it as an offset element. - $toolbar.find('.tray.vertical.active').attr('data-offset-' + edge, ''); + $toolbar.find('.tray.vertical.is-active').attr('data-offset-' + edge, ''); // If an active horizontal tray exists, mark it as an offset element. - $toolbar.find('.tray.horizontal.active').attr('data-offset-top', ''); + $toolbar.find('.tray.horizontal.is-active').attr('data-offset-top', ''); // Trigger a recalculation of viewport displacing elements. Drupal.displace(); }; @@ -264,7 +264,7 @@ function changeOrientation (newOrientation, isLock) { * Mark up the body tag to reflect the current state of the toolbar. */ function setBodyState () { - var $activeTray = $trays.filter('.active'); + var $activeTray = $trays.filter('.is-active'); $('body') .toggleClass('toolbar-tray-open', !!$activeTray.length) .toggleClass('toolbar-vertical', (!!$activeTray.length && orientation === 'vertical')) diff --git a/core/modules/toolbar/js/toolbar.menu.js b/core/modules/toolbar/js/toolbar.menu.js index 3c32c50..2083b5f 100644 --- a/core/modules/toolbar/js/toolbar.menu.js +++ b/core/modules/toolbar/js/toolbar.menu.js @@ -123,7 +123,7 @@ var activeItem = drupalSettings.basePath + drupalSettings.currentPath; activeItem = location.pathname; } if (activeItem) { - var $activeItem = $menu.find('a[href="' + activeItem + '"]').addClass('active'); + var $activeItem = $menu.find('a[href="' + activeItem + '"]').addClass('is-active'); var $activeTrail = $activeItem.parentsUntil('.root', 'li').addClass('active-trail'); toggleList($activeTrail, true); } diff --git a/core/modules/tour/css/tour.module.css b/core/modules/tour/css/tour.module.css index 12467dc..3585dc1 100644 --- a/core/modules/tour/css/tour.module.css +++ b/core/modules/tour/css/tour.module.css @@ -16,7 +16,7 @@ color: #fff; font-weight: bold; } -.js .toolbar .tour-toolbar-tab button.active { +.js .toolbar .tour-toolbar-tab button.is-active { background-image: -webkit-linear-gradient(rgba(255, 255, 255, 0.25) 20%, transparent 200%); background-image: linear-gradient(rgba(255, 255, 255, 0.25) 20%, transparent 200%); } diff --git a/core/modules/tour/js/tour.js b/core/modules/tour/js/tour.js index 611b225..710e3fe 100644 --- a/core/modules/tour/js/tour.js +++ b/core/modules/tour/js/tour.js @@ -101,7 +101,7 @@ Drupal.tour.views.ToggleTourView = Backbone.View.extend({ // Render the state. var isActive = this.model.get('isActive'); this.$el.find('button') - .toggleClass('active', isActive) + .toggleClass('is-active', isActive) .prop('aria-pressed', isActive); return this; }, diff --git a/core/modules/user/css/user.module.css b/core/modules/user/css/user.module.css index 24cd259..a009a3b 100644 --- a/core/modules/user/css/user.module.css +++ b/core/modules/user/css/user.module.css @@ -114,6 +114,6 @@ div.password-suggestions ul { background-image: url(../images/icon-user.png); } .icon-user:active:before, -.icon-user.active:before { +.icon-user.is-active:before { background-image: url(../images/icon-user-active.png); } diff --git a/core/modules/views/lib/Drupal/views/Tests/Plugin/DisplayPageWebTest.php b/core/modules/views/lib/Drupal/views/Tests/Plugin/DisplayPageWebTest.php index 4ea268a..7ac9206 100644 --- a/core/modules/views/lib/Drupal/views/Tests/Plugin/DisplayPageWebTest.php +++ b/core/modules/views/lib/Drupal/views/Tests/Plugin/DisplayPageWebTest.php @@ -77,7 +77,7 @@ public function testPageDisplayMenu() { $this->assertResponse(200); $element = $this->xpath('//ul[contains(@class, :ul_class)]//a[contains(@class, :a_class)]', array( ':ul_class' => 'tabs primary', - ':a_class' => 'active', + ':a_class' => 'is-active', )); $this->assertEqual((string) $element[0], t('Test default tab')); $this->assertTitle(t('Test default page | Drupal')); @@ -89,7 +89,7 @@ public function testPageDisplayMenu() { $this->assertResponse(200); $element = $this->xpath('//ul[contains(@class, :ul_class)]//a[contains(@class, :a_class)]', array( ':ul_class' => 'tabs primary', - ':a_class' => 'active', + ':a_class' => 'is-active', )); $this->assertEqual((string) $element[0], t('Test local tab')); $this->assertTitle(t('Test local page | Drupal')); diff --git a/core/modules/views/views.theme.inc b/core/modules/views/views.theme.inc index 444633b..8de8bdd 100644 --- a/core/modules/views/views.theme.inc +++ b/core/modules/views/views.theme.inc @@ -420,7 +420,7 @@ function template_preprocess_views_view_summary(&$vars) { $vars['rows'][$id]->count = intval($row->{$argument->count_alias}); $vars['row_classes'][$id] = array(); if (isset($active_urls[$vars['rows'][$id]->url])) { - $vars['row_classes'][$id]['class'][] = 'active'; + $vars['row_classes'][$id]['class'][] = 'is-active'; } $vars['row_classes'][$id] = new Attribute($vars['row_classes'][$id]); } @@ -484,7 +484,7 @@ function template_preprocess_views_view_summary_unformatted(&$vars) { $vars['rows'][$id]->count = intval($row->{$argument->count_alias}); $vars['row_classes'][$id] = array(); if (isset($active_urls[$vars['rows'][$id]->url])) { - $vars['row_classes'][$id]['class'][] = 'active'; + $vars['row_classes'][$id]['class'][] = 'is-active'; } $vars['row_classes'][$id] = new Attribute($vars['row_classes'][$id]); } @@ -539,7 +539,7 @@ function template_preprocess_views_view_table(&$vars) { // what the CSS classes should be. $vars['fields'][$field] = drupal_clean_css_identifier($field); if ($active == $field) { - $vars['fields'][$field] .= ' active'; + $vars['fields'][$field] .= ' is-active'; } // render the header labels diff --git a/core/modules/views_ui/config/tour.tour.views-ui.yml b/core/modules/views_ui/config/tour.tour.views-ui.yml index 6f2ca9d..45137be 100644 --- a/core/modules/views_ui/config/tour.tour.views-ui.yml +++ b/core/modules/views_ui/config/tour.tour.views-ui.yml @@ -12,7 +12,7 @@ tips: body: This is the active display in the view. When there are multiple displays, one link for each display is shown and you can switch displays simply by clicking on the display link. weight: "2" attributes: - data-class: views-display-top li.active + data-class: views-display-top li.is-active views-ui-displays: id: views-ui-displays plugin: text diff --git a/core/modules/views_ui/css/views_ui.admin.theme.css b/core/modules/views_ui/css/views_ui.admin.theme.css index 22f8c4a..b868979 100644 --- a/core/modules/views_ui/css/views_ui.admin.theme.css +++ b/core/modules/views_ui/css/views_ui.admin.theme.css @@ -490,7 +490,7 @@ ul#views-display-menu-tabs li.add ul.action-list li{ /** * Display a red border if the display doesn't validate. */ -.views-displays ul.secondary li.active a.active.error, +.views-displays ul.secondary li.is-active a.is-active.error, .views-displays .secondary a.error { border: 2px solid #ed541d; padding: 1px 6px; @@ -505,8 +505,8 @@ ul#views-display-menu-tabs li.add ul.action-list li{ } .views-displays ul.secondary li a:hover, -.views-displays ul.secondary li.active a, -.views-displays ul.secondary li.active a.active { +.views-displays ul.secondary li.is-active a, +.views-displays ul.secondary li.is-active a.is-active { background-color: #555; color: #fff; } diff --git a/core/themes/bartik/color/preview.css b/core/themes/bartik/color/preview.css index 805ce79..4aeb95f 100644 --- a/core/themes/bartik/color/preview.css +++ b/core/themes/bartik/color/preview.css @@ -69,7 +69,7 @@ background: #b3b3b3; background: rgba(255, 255, 255, 1); } -#preview-main-menu-links li a.active { +#preview-main-menu-links li a.is-active { border-bottom: none; } #preview-main-menu-links li { diff --git a/core/themes/bartik/css/colors.css b/core/themes/bartik/css/colors.css index 96f3877..0ab991f 100644 --- a/core/themes/bartik/css/colors.css +++ b/core/themes/bartik/css/colors.css @@ -9,14 +9,14 @@ body.overlay { } #page, #main-wrapper, -#main-menu-links li a.active, -#main-menu-links li.active-trail a { +#main-menu-links li a.is-active, +#main-menu-links li.is-active-trail a { background: #ffffff; } -.tabs ul.primary li a.active { +.tabs ul.primary li a.is-active { background-color: #ffffff; } -.tabs ul.primary li.active a { +.tabs ul.primary li.is-active a { background-color: #ffffff; border-bottom: 1px solid #ffffff; } @@ -53,7 +53,7 @@ a:active, } .region-header, .region-header a, -.region-header li a.active, +.region-header li a.is-active, #name-and-slogan, #name-and-slogan a, #secondary-menu-links li a { diff --git a/core/themes/bartik/css/style.css b/core/themes/bartik/css/style.css index 8e679b6..40d9f58 100644 --- a/core/themes/bartik/css/style.css +++ b/core/themes/bartik/css/style.css @@ -570,7 +570,7 @@ h1#site-name { background: #b3b3b3; background: rgba(255, 255, 255, 1); } -#main-menu-links li a.active { +#main-menu-links li a.is-active { border-bottom: none; } @@ -1118,7 +1118,7 @@ div.tabs { float: right; zoom: 1; } -.tabs ul.primary li.active a { +.tabs ul.primary li.is-active a { border-bottom: 1px solid #ffffff; } .tabs ul.primary li a { @@ -1138,7 +1138,7 @@ div.tabs { border-top-left-radius: 6px; border-top-right-radius: 6px; } -.tabs ul.primary li.active a { +.tabs ul.primary li.is-active a { background-color: #ffffff; border: 1px solid #bbb; border-bottom: 1px solid #fff; @@ -1177,7 +1177,7 @@ div.tabs { padding: 0.25em 0.5em; text-decoration: none; } -.tabs ul.secondary li a.active { +.tabs ul.secondary li a.is-active { background: #f2f2f2; border-bottom: none; border-radius: 5px; @@ -1869,7 +1869,7 @@ div.admin-panel .description { padding: 0.7em 0.8em; } .featured #main-menu-links li a:active, - .featured #main-menu-links li a.active { + .featured #main-menu-links li a.is-active { background: #f0f0f0; background: rgba(240, 240, 240, 1.0); } diff --git a/core/themes/seven/install-page.css b/core/themes/seven/install-page.css index 69cfcbc..2831c44 100644 --- a/core/themes/seven/install-page.css +++ b/core/themes/seven/install-page.css @@ -119,12 +119,12 @@ body.install-page #page-title { [dir="rtl"] .install-task-list li { padding: 0.5em 20px 0.5em 1em; } -.install-task-list li.active { +.install-task-list li.is-active { background: #ebeae4; position: relative; font-weight: normal; } -.install-task-list li.active:after { +.install-task-list li.is-active:after { left: 100%; /* LTR */ border: solid transparent; border-color: rgba(235, 234, 228, 0); @@ -138,7 +138,7 @@ body.install-page #page-title { top: 50%; margin-top: -17px; } -[dir="rtl"] .install-task-list li.active:after { +[dir="rtl"] .install-task-list li.is-active:after { left: auto; right: 100%; border-left-color: transparent; diff --git a/core/themes/seven/js/mobile.install.js b/core/themes/seven/js/mobile.install.js index 6ee8934..3083f58 100644 --- a/core/themes/seven/js/mobile.install.js +++ b/core/themes/seven/js/mobile.install.js @@ -4,7 +4,7 @@ function findActiveStep (steps) { for (var i = 0; i < steps.length; i++) { - if (steps[i].className === 'active') { + if (steps[i].className === 'is-active') { return i + 1; } } diff --git a/core/themes/seven/style.css b/core/themes/seven/style.css index 2556bf0..62df561 100644 --- a/core/themes/seven/style.css +++ b/core/themes/seven/style.css @@ -279,11 +279,11 @@ ul.primary li { float: right; } ul.primary li a:link, -ul.primary li a.active, +ul.primary li a.is-active, ul.primary li a:active, ul.primary li a:visited, ul.primary li a:hover, -ul.primary li.active a { +ul.primary li.is-active a { display: block; float: left; /* LTR */ padding: 0.615em 18px; @@ -296,24 +296,24 @@ ul.primary li.active a { border-radius: 8px 8px 0 0; } [dir=rtl] ul.primary li a:link, -[dir=rtl] ul.primary li a.active, +[dir=rtl] ul.primary li a.is-active, [dir=rtl] ul.primary li a:active, [dir=rtl] ul.primary li a:visited, [dir=rtl] ul.primary li a:hover, -[dir=rtl] ul.primary li.active a { +[dir=rtl] ul.primary li.is-active a { float: right; } -ul.primary li.active a, -ul.primary li.active a.active, -ul.primary li.active a:active, -ul.primary li.active a:visited { +ul.primary li.is-active a, +ul.primary li.is-active a.is-active, +ul.primary li.is-active a:active, +ul.primary li.is-active a:visited { background-color: #fff; border-color: #c9cac4; } ul.primary li a:hover { color: #fff; } -ul.primary li.active a:hover { +ul.primary li.is-active a:hover { color: #000; } .tabs-secondary { @@ -344,14 +344,14 @@ ul.secondary li a { } ul.secondary li a, ul.secondary li a:hover, -ul.secondary li.active a, -ul.secondary li.active a.active { +ul.secondary li.is-active a, +ul.secondary li.is-active a.is-active { padding: 2px 10px; border-radius: 7px; } ul.secondary li a:hover, -ul.secondary li.active a, -ul.secondary li.active a.active { +ul.secondary li.is-active a, +ul.secondary li.is-active a.is-active { color: #fff; background: #666; } @@ -392,11 +392,11 @@ ul.secondary li.active a.active { white-space: nowrap; } .touch ul.primary li a:link, - .touch ul.primary li a.active, + .touch ul.primary li a.is-active, .touch ul.primary li a:active, .touch ul.primary li a:visited, .touch ul.primary li a:hover, - .touch ul.primary li.active a { + .touch ul.primary li.is-active a { -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; @@ -524,25 +524,25 @@ table th { border-color: #bebfb9; padding: 3px 10px; } -table th.active { +table th.is-active { background: #bdbeb9; } table th a { display: block; position: relative; } -table th.active a { +table th.is-active a { padding: 0 25px 0 0; /* LTR */ } -[dir=rtl] table th.active a { +[dir=rtl] table th.is-active a { padding: 0 0 0 25px; } -table th.active img { +table th.is-active img { position: absolute; top: 3px; right: 3px; /* LTR */ } -[dir=rtl] table th.active img { +[dir=rtl] table th.is-active img { left: 3px; right: auto; } @@ -552,13 +552,13 @@ table th.active img { table th.select-all { width: 1px; } -table td.active { +table td.is-active { background: #e9e9dd; } -table tr.odd td.active { +table tr.odd td.is-active { background: #f3f4ee; } -table tr.selected td.active, +table tr.selected td.is-active, table tr.selected td { background: #ffc; border-color: #eeb; @@ -1055,12 +1055,12 @@ body.in-maintenance #logo { [dir=rtl] .task-list li { padding: 0.5em 20px 0.5em 1em; } -.task-list li.active { +.task-list li.is-active { background: transparent url(images/task-item.png) no-repeat 3px 50%; /* LTR */ padding: 0.5em 1em 0.5em 20px; /* LTR */ color: #000; } -[dir=rtl] .task-list li.active { +[dir=rtl] .task-list li.is-active { background: transparent url(images/task-item-rtl.png) no-repeat right 50%; padding: 0.5em 20px 0.5em 1em; } @@ -1354,8 +1354,8 @@ details.fieldset-no-legend { } .views-displays ul.secondary li a, -.views-displays ul.secondary li.active a, -.views-displays ul.secondary li.active a.active { +.views-displays ul.secondary li.is-active a, +.views-displays ul.secondary li.is-active a.is-active { padding: 2px 7px 3px; } @@ -1363,8 +1363,8 @@ details.fieldset-no-legend { color: #0074bd; } -.views-displays ul.secondary li.active a, -.views-displays ul.secondary li.active a.active { +.views-displays ul.secondary li.is-active a, +.views-displays ul.secondary li.is-active a.is-active { border: 1px solid transparent; }