From 1f5e126d29ca643567b3706c222ea515501d25df Mon Sep 17 00:00:00 2001 From: Dries Date: Fri, 1 Feb 2013 16:48:05 -0500 Subject: [PATCH] Issue #1852104 by sun, nod_, Cottser, swentel: #type details: Remove #collapsible property. --- core/includes/form.inc | 20 ++++++++----------- core/includes/install.core.inc | 4 ---- .../Drupal/Core/Database/Install/Tasks.php | 1 - .../Drupal/Core/FileTransfer/FileTransfer.php | 1 - core/misc/collapse.js | 2 +- core/misc/vertical-tabs.js | 2 +- core/modules/aggregator/aggregator.admin.inc | 1 - .../aggregator/aggregator.processor.inc | 3 +-- core/modules/book/book.module | 1 - core/modules/book/book.pages.inc | 2 -- core/modules/comment/comment.module | 2 -- .../Drupal/comment/CommentFormController.php | 1 - core/modules/contact/contact.module | 1 - core/modules/dblog/dblog.admin.inc | 2 -- .../Drupal/field/Plugin/views/field/Field.php | 1 - core/modules/field_ui/field_ui.admin.inc | 1 - .../lib/Drupal/field_ui/DisplayOverview.php | 1 - core/modules/language/language.admin.inc | 1 - core/modules/locale/locale.bulk.inc | 1 - core/modules/locale/locale.pages.inc | 1 - core/modules/menu/menu.module | 2 -- core/modules/node/content_types.inc | 4 ---- .../lib/Drupal/node/NodeFormController.php | 2 -- core/modules/node/node.module | 2 -- core/modules/overlay/overlay.module | 1 - core/modules/path/path.module | 1 - core/modules/simpletest/simpletest.pages.inc | 2 -- .../Drupal/system/Tests/Common/RenderTest.php | 5 +---- core/modules/system/system.admin.inc | 1 - core/modules/system/system.module | 6 ++---- .../modules/design_test/form/details.inc | 7 ------- .../modules/design_test/form/fieldset.inc | 5 ----- .../tests/modules/form_test/form_test.module | 2 -- .../Drupal/taxonomy/TermFormController.php | 1 - core/modules/translation/translation.module | 1 - .../EntityTranslationController.php | 2 -- core/modules/user/user.admin.inc | 9 --------- .../Drupal/views/Plugin/views/HandlerBase.php | 1 - .../Drupal/views/Plugin/views/PluginBase.php | 1 - .../Plugin/views/area/AreaPluginBase.php | 1 - .../views/argument/ArgumentPluginBase.php | 1 - .../Plugin/views/field/FieldPluginBase.php | 4 ---- .../views/Plugin/views/pager/SqlBase.php | 2 -- .../views/Plugin/views/row/RssFields.php | 1 - .../views/views_ui/css/views-admin.theme.css | 4 ++-- .../views_ui/ViewEditFormController.php | 1 - core/themes/seven/style.css | 2 +- core/update.php | 1 - 48 files changed, 17 insertions(+), 104 deletions(-) diff --git a/core/includes/form.inc b/core/includes/form.inc index 3684578f9f..830dc75517 100644 --- a/core/includes/form.inc +++ b/core/includes/form.inc @@ -1710,10 +1710,9 @@ function form_error(&$element, $message = '') { * can also be used to set additional properties or implement special logic * other than adding child elements: for example, for the 'details' element * type, one of the functions in this array is form_process_details(), which - * adds the attributes and JavaScript needed to make the details collapsible - * if the #collapsible property is set. The #process functions are called in - * preorder traversal, meaning they are called for the parent element first, - * then for the child elements. + * adds the attributes and JavaScript needed to make the details work in older + * browsers. The #process functions are called in preorder traversal, meaning + * they are called for the parent element first, then for the child elements. * - $element['#after_build']: An array of functions called after form_builder() * is done with its processing of the element. These are called in postorder * traversal, meaning they are called for the child elements first, then for @@ -2817,8 +2816,8 @@ function form_get_options($element, $key) { * @param $variables * An associative array containing: * - element: An associative array containing the properties of the element. - * Properties used: #attributes, #children, #collapsed, #collapsible, - * #description, #id, #title, #value. + * Properties used: #attributes, #children, #collapsed, #description, #id, + * #title, #value. * * @ingroup themeable */ @@ -2863,8 +2862,8 @@ function theme_fieldset($variables) { * @param $variables * An associative array containing: * - element: An associative array containing the properties of the element. - * Properties used: #attributes, #children, #collapsed, #collapsible, - * #description, #id, #title, #value. + * Properties used: #attributes, #children, #collapsed, #description, #id, + * #title, #value. * * @ingroup themeable */ @@ -3972,10 +3971,7 @@ function form_pre_render_details($element) { } // Collapsible details. - if (!empty($element['#collapsible'])) { - $element['#attached']['library'][] = array('system', 'drupal.collapse'); - $element['#attributes']['class'][] = 'collapsible'; - } + $element['#attached']['library'][] = array('system', 'drupal.collapse'); if (empty($element['#collapsed'])) { $element['#attributes']['open'] = 'open'; } diff --git a/core/includes/install.core.inc b/core/includes/install.core.inc index 8cc661f60d..41f96b0fdf 100644 --- a/core/includes/install.core.inc +++ b/core/includes/install.core.inc @@ -2189,7 +2189,6 @@ function _install_configure_form($form, &$form_state, &$install_state) { $form['site_information'] = array( '#type' => 'details', '#title' => st('Site information'), - '#collapsible' => FALSE, ); $form['site_information']['site_name'] = array( '#type' => 'textfield', @@ -2208,7 +2207,6 @@ function _install_configure_form($form, &$form_state, &$install_state) { $form['admin_account'] = array( '#type' => 'details', '#title' => st('Site maintenance account'), - '#collapsible' => FALSE, ); $form['admin_account']['account']['#tree'] = TRUE; @@ -2237,7 +2235,6 @@ function _install_configure_form($form, &$form_state, &$install_state) { $form['server_settings'] = array( '#type' => 'details', '#title' => st('Server settings'), - '#collapsible' => FALSE, ); $countries = country_get_list(); @@ -2264,7 +2261,6 @@ function _install_configure_form($form, &$form_state, &$install_state) { $form['update_notifications'] = array( '#type' => 'details', '#title' => st('Update notifications'), - '#collapsible' => FALSE, ); $form['update_notifications']['update_status_module'] = array( '#type' => 'checkboxes', diff --git a/core/lib/Drupal/Core/Database/Install/Tasks.php b/core/lib/Drupal/Core/Database/Install/Tasks.php index 2c8f00655c..ab1f771d2f 100644 --- a/core/lib/Drupal/Core/Database/Install/Tasks.php +++ b/core/lib/Drupal/Core/Database/Install/Tasks.php @@ -234,7 +234,6 @@ public function getFormOptions($database) { $form['advanced_options'] = array( '#type' => 'details', '#title' => st('Advanced options'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#description' => st("These options are only necessary for some sites. If you're not sure what you should enter here, leave the default settings or check with your hosting provider."), '#weight' => 10, diff --git a/core/lib/Drupal/Core/FileTransfer/FileTransfer.php b/core/lib/Drupal/Core/FileTransfer/FileTransfer.php index 72a6751a3f..823e17efb1 100644 --- a/core/lib/Drupal/Core/FileTransfer/FileTransfer.php +++ b/core/lib/Drupal/Core/FileTransfer/FileTransfer.php @@ -408,7 +408,6 @@ public function getSettingsForm() { $form['advanced'] = array( '#type' => 'details', '#title' => t('Advanced settings'), - '#collapsible' => TRUE, '#collapsed' => TRUE, ); $form['advanced']['hostname'] = array( diff --git a/core/misc/collapse.js b/core/misc/collapse.js index 3d99bcefef..77eb9ffb55 100644 --- a/core/misc/collapse.js +++ b/core/misc/collapse.js @@ -174,7 +174,7 @@ Drupal.behaviors.collapse = { if (isDetailsSupported) { return; } - var $collapsibleDetails = $(context).find('details.collapsible').once('collapse'); + var $collapsibleDetails = $(context).find('details').once('collapse'); if ($collapsibleDetails.length) { for (var i = 0; i < $collapsibleDetails.length; i++) { CollapsibleDetails.instances.push(new CollapsibleDetails($collapsibleDetails[i], settings.collapsibleDetails)); diff --git a/core/misc/vertical-tabs.js b/core/misc/vertical-tabs.js index 6d902e919a..a9450a8488 100644 --- a/core/misc/vertical-tabs.js +++ b/core/misc/vertical-tabs.js @@ -44,7 +44,7 @@ Drupal.behaviors.verticalTabs = { }); tab_list.append(vertical_tab.item); $this - .removeClass('collapsible collapsed') + .removeClass('collapsed') .attr('open', true) .addClass('vertical-tabs-pane') .data('verticalTab', vertical_tab); diff --git a/core/modules/aggregator/aggregator.admin.inc b/core/modules/aggregator/aggregator.admin.inc index 90b1f9ac5a..62cfe83a0b 100644 --- a/core/modules/aggregator/aggregator.admin.inc +++ b/core/modules/aggregator/aggregator.admin.inc @@ -413,7 +413,6 @@ function aggregator_admin_form($form, $form_state) { '#type' => 'details', '#title' => t('Basic configuration'), '#description' => t('For most aggregation tasks, the default settings are fine.'), - '#collapsible' => TRUE, '#collapsed' => FALSE, ); $form['basic_conf'] += $basic_conf; diff --git a/core/modules/aggregator/aggregator.processor.inc b/core/modules/aggregator/aggregator.processor.inc index c02654c8d0..54ae7a5e61 100644 --- a/core/modules/aggregator/aggregator.processor.inc +++ b/core/modules/aggregator/aggregator.processor.inc @@ -94,13 +94,12 @@ function aggregator_form_aggregator_admin_form_alter(&$form, $form_state) { $period = drupal_map_assoc(array(3600, 10800, 21600, 32400, 43200, 86400, 172800, 259200, 604800, 1209600, 2419200, 4838400, 9676800), 'format_interval'); $period[AGGREGATOR_CLEAR_NEVER] = t('Never'); - // Only wrap into a collapsible details if there is a basic configuration. + // Only wrap into details if there is a basic configuration. if (isset($form['basic_conf'])) { $form['modules']['aggregator'] = array( '#type' => 'details', '#title' => t('Default processor settings'), '#description' => $info['description'], - '#collapsible' => TRUE, '#collapsed' => !in_array('aggregator', $aggregator_processors), ); } diff --git a/core/modules/book/book.module b/core/modules/book/book.module index a46506e52a..653ba54d21 100644 --- a/core/modules/book/book.module +++ b/core/modules/book/book.module @@ -434,7 +434,6 @@ function _book_add_form_elements(&$form, &$form_state, Node $node) { '#type' => 'details', '#title' => t('Book outline'), '#weight' => 10, - '#collapsible' => TRUE, '#collapsed' => TRUE, '#group' => 'advanced', '#attributes' => array( diff --git a/core/modules/book/book.pages.inc b/core/modules/book/book.pages.inc index c03872f017..a971aa62b4 100644 --- a/core/modules/book/book.pages.inc +++ b/core/modules/book/book.pages.inc @@ -145,8 +145,6 @@ function book_outline_form($form, &$form_state, Node $node) { $form['#id'] = 'book-outline'; _book_add_form_elements($form, $form_state, $node); - $form['book']['#collapsible'] = FALSE; - $form['update'] = array( '#type' => 'submit', '#value' => $node->book['original_bid'] ? t('Update book outline') : t('Add to book outline'), diff --git a/core/modules/comment/comment.module b/core/modules/comment/comment.module index 17861896c7..14df5576d1 100644 --- a/core/modules/comment/comment.module +++ b/core/modules/comment/comment.module @@ -1017,7 +1017,6 @@ function comment_form_node_type_form_alter(&$form, $form_state) { $form['comment'] = array( '#type' => 'details', '#title' => t('Comment settings'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#group' => 'additional_settings', '#attributes' => array( @@ -1124,7 +1123,6 @@ function comment_form_node_form_alter(&$form, $form_state) { '#type' => 'details', '#access' => user_access('administer comments'), '#title' => t('Comment settings'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#group' => 'advanced', '#attributes' => array( diff --git a/core/modules/comment/lib/Drupal/comment/CommentFormController.php b/core/modules/comment/lib/Drupal/comment/CommentFormController.php index c0c0c32ccc..ff49681a71 100644 --- a/core/modules/comment/lib/Drupal/comment/CommentFormController.php +++ b/core/modules/comment/lib/Drupal/comment/CommentFormController.php @@ -53,7 +53,6 @@ public function form(array $form, array &$form_state, EntityInterface $comment) $form['author'] += array( '#type' => 'details', '#title' => t('Administration'), - '#collapsible' => TRUE, '#collapsed' => TRUE, ); } diff --git a/core/modules/contact/contact.module b/core/modules/contact/contact.module index 2686b80e4c..6e22fe7b58 100644 --- a/core/modules/contact/contact.module +++ b/core/modules/contact/contact.module @@ -335,7 +335,6 @@ function contact_form_user_profile_form_alter(&$form, &$form_state) { '#type' => 'details', '#title' => t('Contact settings'), '#weight' => 5, - '#collapsible' => TRUE, ); $account = $form_state['controller']->getEntity($form_state); $account_data = drupal_container()->get('user.data')->get('contact', $account->id(), 'enabled'); diff --git a/core/modules/dblog/dblog.admin.inc b/core/modules/dblog/dblog.admin.inc index d6b921a488..fd056c242a 100644 --- a/core/modules/dblog/dblog.admin.inc +++ b/core/modules/dblog/dblog.admin.inc @@ -320,7 +320,6 @@ function dblog_filter_form($form) { $form['filters'] = array( '#type' => 'details', '#title' => t('Filter log messages'), - '#collapsible' => TRUE, '#collapsed' => empty($_SESSION['dblog_overview_filter']), ); foreach ($filters as $key => $filter) { @@ -398,7 +397,6 @@ function dblog_clear_log_form($form) { '#type' => 'details', '#title' => t('Clear log messages'), '#description' => t('This will permanently remove the log messages from the database.'), - '#collapsible' => TRUE, '#collapsed' => TRUE, ); $form['dblog_clear']['clear'] = array( diff --git a/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php b/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php index 0477096e38..30836a33e2 100644 --- a/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php +++ b/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php @@ -467,7 +467,6 @@ function multiple_options_form(&$form, &$form_state) { $form['multiple_field_settings'] = array( '#type' => 'details', '#title' => t('Multiple field settings'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#weight' => 5, ); diff --git a/core/modules/field_ui/field_ui.admin.inc b/core/modules/field_ui/field_ui.admin.inc index 30cf795f9d..a9c18fc7c5 100644 --- a/core/modules/field_ui/field_ui.admin.inc +++ b/core/modules/field_ui/field_ui.admin.inc @@ -933,7 +933,6 @@ function field_ui_default_value_widget($field, $instance, &$form, &$form_state) $element = array( '#type' => 'details', '#title' => t('Default value'), - '#collapsible' => FALSE, '#tree' => TRUE, '#description' => t('The default value for this field, used when creating new content.'), // Stick to an empty 'parents' on this form in order not to breaks widgets diff --git a/core/modules/field_ui/lib/Drupal/field_ui/DisplayOverview.php b/core/modules/field_ui/lib/Drupal/field_ui/DisplayOverview.php index fe725cc437..4314fb47a5 100644 --- a/core/modules/field_ui/lib/Drupal/field_ui/DisplayOverview.php +++ b/core/modules/field_ui/lib/Drupal/field_ui/DisplayOverview.php @@ -352,7 +352,6 @@ public function form(array $form, array &$form_state) { $form['modes'] = array( '#type' => 'details', '#title' => t('Custom display settings'), - '#collapsible' => TRUE, '#collapsed' => TRUE, ); // Collect options and default values for the 'Custom display settings' diff --git a/core/modules/language/language.admin.inc b/core/modules/language/language.admin.inc index b078d2392d..6fd1fd6f2a 100644 --- a/core/modules/language/language.admin.inc +++ b/core/modules/language/language.admin.inc @@ -828,7 +828,6 @@ function language_negotiation_configure_browser_form($form, &$form_state) { $form['new_mapping'] = array( '#type' => 'details', '#title' => t('Add a new mapping'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#tree' => TRUE, ); diff --git a/core/modules/locale/locale.bulk.inc b/core/modules/locale/locale.bulk.inc index 5420ac921b..f49100bfd6 100644 --- a/core/modules/locale/locale.bulk.inc +++ b/core/modules/locale/locale.bulk.inc @@ -177,7 +177,6 @@ function locale_translate_export_form($form, &$form_state) { $form['content_options'] = array( '#type' => 'details', '#title' => t('Export options'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#tree' => TRUE, '#states' => array( diff --git a/core/modules/locale/locale.pages.inc b/core/modules/locale/locale.pages.inc index 125af8d6cf..dc76d4a9c1 100644 --- a/core/modules/locale/locale.pages.inc +++ b/core/modules/locale/locale.pages.inc @@ -169,7 +169,6 @@ function locale_translate_filter_form($form, &$form_state) { $form['filters'] = array( '#type' => 'details', '#title' => t('Filter translatable strings'), - '#collapsible' => TRUE, '#collapsed' => FALSE, ); foreach ($filters as $key => $filter) { diff --git a/core/modules/menu/menu.module b/core/modules/menu/menu.module index 3b17c22cea..09567cfb7e 100644 --- a/core/modules/menu/menu.module +++ b/core/modules/menu/menu.module @@ -571,7 +571,6 @@ function menu_form_node_form_alter(&$form, $form_state) { '#type' => 'details', '#title' => t('Menu settings'), '#access' => user_access('administer menu'), - '#collapsible' => TRUE, '#collapsed' => !$link['link_title'], '#group' => 'advanced', '#attached' => array( @@ -677,7 +676,6 @@ function menu_form_node_type_form_alter(&$form, $form_state) { $form['menu'] = array( '#type' => 'details', '#title' => t('Menu settings'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#attached' => array( 'library' => array(array('menu', 'drupal.menu.admin')), diff --git a/core/modules/node/content_types.inc b/core/modules/node/content_types.inc index c958f278f0..9d71ff082d 100644 --- a/core/modules/node/content_types.inc +++ b/core/modules/node/content_types.inc @@ -158,7 +158,6 @@ function node_type_form($form, &$form_state, $type = NULL) { $form['submission'] = array( '#type' => 'details', '#title' => t('Submission form settings'), - '#collapsible' => TRUE, '#group' => 'additional_settings', ); $form['submission']['title_label'] = array( @@ -193,7 +192,6 @@ function node_type_form($form, &$form_state, $type = NULL) { $form['workflow'] = array( '#type' => 'details', '#title' => t('Publishing options'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#group' => 'additional_settings', ); @@ -212,7 +210,6 @@ function node_type_form($form, &$form_state, $type = NULL) { $form['language'] = array( '#type' => 'details', '#title' => t('Language settings'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#group' => 'additional_settings', ); @@ -232,7 +229,6 @@ function node_type_form($form, &$form_state, $type = NULL) { $form['display'] = array( '#type' => 'details', '#title' => t('Display settings'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#group' => 'additional_settings', ); diff --git a/core/modules/node/lib/Drupal/node/NodeFormController.php b/core/modules/node/lib/Drupal/node/NodeFormController.php index 283a516569..c038d40313 100644 --- a/core/modules/node/lib/Drupal/node/NodeFormController.php +++ b/core/modules/node/lib/Drupal/node/NodeFormController.php @@ -199,7 +199,6 @@ public function form(array $form, array &$form_state, EntityInterface $node) { '#type' => 'details', '#access' => user_access('administer nodes'), '#title' => t('Authoring information'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#group' => 'advanced', '#attributes' => array( @@ -240,7 +239,6 @@ public function form(array $form, array &$form_state, EntityInterface $node) { '#type' => 'details', '#access' => user_access('administer nodes'), '#title' => t('Promotion options'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#group' => 'advanced', '#attributes' => array( diff --git a/core/modules/node/node.module b/core/modules/node/node.module index b64a1dcc3c..f2206a0885 100644 --- a/core/modules/node/node.module +++ b/core/modules/node/node.module @@ -2016,7 +2016,6 @@ function node_form_block_form_alter(&$form, &$form_state) { $form['visibility']['node_type'] = array( '#type' => 'details', '#title' => t('Content types'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#group' => 'visibility', '#weight' => 5, @@ -2346,7 +2345,6 @@ function node_form_search_form_alter(&$form, $form_state) { $form['advanced'] = array( '#type' => 'details', '#title' => t('Advanced search'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#attributes' => array('class' => array('search-advanced')), ); diff --git a/core/modules/overlay/overlay.module b/core/modules/overlay/overlay.module index 632d2703fb..383f08a5cd 100644 --- a/core/modules/overlay/overlay.module +++ b/core/modules/overlay/overlay.module @@ -92,7 +92,6 @@ function overlay_form_user_profile_form_alter(&$form, &$form_state) { '#type' => 'details', '#title' => t('Administrative overlay'), '#weight' => 4, - '#collapsible' => TRUE, ); $form['overlay_control']['overlay'] = array( '#type' => 'checkbox', diff --git a/core/modules/path/path.module b/core/modules/path/path.module index 7521deef3a..7d3fadd3c9 100644 --- a/core/modules/path/path.module +++ b/core/modules/path/path.module @@ -122,7 +122,6 @@ function path_form_node_form_alter(&$form, $form_state) { $form['path'] = array( '#type' => 'details', '#title' => t('URL path settings'), - '#collapsible' => TRUE, '#collapsed' => empty($path['alias']), '#group' => 'advanced', '#attributes' => array( diff --git a/core/modules/simpletest/simpletest.pages.inc b/core/modules/simpletest/simpletest.pages.inc index f1d55d80e3..7fe64d769d 100644 --- a/core/modules/simpletest/simpletest.pages.inc +++ b/core/modules/simpletest/simpletest.pages.inc @@ -242,7 +242,6 @@ function simpletest_result_form($form, &$form_state, $test_id) { '#type' => 'details', '#title' => $info['name'], '#description' => $info['description'], - '#collapsible' => TRUE, ); $form['result']['results'][$group]['summary'] = $summary; $group_summary = &$form['result']['results'][$group]['summary']; @@ -455,7 +454,6 @@ function simpletest_settings_form($form, &$form_state) { '#type' => 'details', '#title' => t('HTTP authentication'), '#description' => t('HTTP auth settings to be used by the SimpleTest browser during testing. Useful when the site requires basic HTTP authentication.'), - '#collapsible' => TRUE, '#collapsed' => TRUE, ); $form['httpauth']['simpletest_httpauth_method'] = array( diff --git a/core/modules/system/lib/Drupal/system/Tests/Common/RenderTest.php b/core/modules/system/lib/Drupal/system/Tests/Common/RenderTest.php index 485dc50b1f..8e053f982e 100644 --- a/core/modules/system/lib/Drupal/system/Tests/Common/RenderTest.php +++ b/core/modules/system/lib/Drupal/system/Tests/Common/RenderTest.php @@ -250,11 +250,8 @@ function testDrupalRenderFormElements() { $element = array( '#type' => 'details', '#title' => $this->randomName(), - '#collapsible' => TRUE, ); - $this->assertRenderedElement($element, '//details[contains(@class, :class)]', array( - ':class' => 'collapsible', - )); + $this->assertRenderedElement($element, '//details'); $element['item'] = array( '#type' => 'item', diff --git a/core/modules/system/system.admin.inc b/core/modules/system/system.admin.inc index 37a2bf23fb..e19372ecfb 100644 --- a/core/modules/system/system.admin.inc +++ b/core/modules/system/system.admin.inc @@ -917,7 +917,6 @@ function system_modules($form, $form_state = array()) { $form['modules'][$package] += array( '#type' => 'details', '#title' => t($package), - '#collapsible' => TRUE, '#theme' => 'system_modules_details', '#header' => array( array('data' => t('Enabled'), 'class' => array('checkbox')), diff --git a/core/modules/system/system.module b/core/modules/system/system.module index 24c0f9ff92..322e416829 100644 --- a/core/modules/system/system.module +++ b/core/modules/system/system.module @@ -548,7 +548,6 @@ function system_element_info() { '#theme_wrappers' => array('fieldset'), ); $types['details'] = array( - '#collapsible' => FALSE, '#collapsed' => FALSE, '#value' => NULL, '#process' => array('form_process_group', 'ajax_process_form'), @@ -1353,9 +1352,9 @@ function system_library_info() { ), ); - // Drupal's collapsible details. + // Collapsible details. $libraries['drupal.collapse'] = array( - 'title' => 'Drupal collapsible details', + 'title' => 'Collapsible details', 'version' => VERSION, 'js' => array( 'core/misc/collapse.js' => array('group' => JS_DEFAULT), @@ -2611,7 +2610,6 @@ function system_user_timezone(&$form, &$form_state) { '#type' => 'details', '#title' => t('Locale settings'), '#weight' => 6, - '#collapsible' => TRUE, ); $form['timezone']['timezone'] = array( '#type' => 'select', diff --git a/core/modules/system/tests/modules/design_test/form/details.inc b/core/modules/system/tests/modules/design_test/form/details.inc index 186945ff70..60d153a290 100644 --- a/core/modules/system/tests/modules/design_test/form/details.inc +++ b/core/modules/system/tests/modules/design_test/form/details.inc @@ -13,7 +13,6 @@ function design_test_form_details($form, &$form_state) { '#type' => 'details', '#title' => 'Collapsible details', '#description' => 'Details description', - '#collapsible' => TRUE, '#collapsed' => FALSE, '#states' => array( 'collapsed' => array( @@ -26,7 +25,6 @@ function design_test_form_details($form, &$form_state) { '#type' => 'details', '#title' => 'Collapsed details', '#description' => 'Details description', - '#collapsible' => TRUE, '#collapsed' => TRUE, ); $form['collapsed']['textfield'] = array( @@ -48,35 +46,30 @@ function design_test_form_details($form, &$form_state) { '#type' => 'details', '#title' => 'Details', '#description' => 'Details description', - '#collapsible' => TRUE, '#collapsed' => TRUE, ); $form['collapsed2']['collapsible'] = array( '#type' => 'details', '#title' => 'Collapsible details', '#description' => 'Details description', - '#collapsible' => TRUE, '#collapsed' => FALSE, ); $form['collapsed2']['collapsed'] = array( '#type' => 'details', '#title' => 'Collapsed details', '#description' => 'Details description', - '#collapsible' => TRUE, '#collapsed' => TRUE, ); $form['collapsed2']['regular'] = array( '#type' => 'details', '#title' => 'Details', '#description' => 'Details description', - '#collapsible' => FALSE, ); $form['regular'] = array( '#type' => 'details', '#title' => 'Details', '#description' => 'Details description', - '#collapsible' => FALSE, ); #$form['#attributes'] = array('class' => array('search-form')); diff --git a/core/modules/system/tests/modules/design_test/form/fieldset.inc b/core/modules/system/tests/modules/design_test/form/fieldset.inc index 4ab07fd012..f55bfe5b6e 100644 --- a/core/modules/system/tests/modules/design_test/form/fieldset.inc +++ b/core/modules/system/tests/modules/design_test/form/fieldset.inc @@ -19,7 +19,6 @@ function design_test_form_fieldset($form, &$form_state) { '#type' => 'details', '#title' => 'Collapsible details', '#description' => 'Details description', - '#collapsible' => TRUE, '#collapsed' => FALSE, ); $form['collapsible']['fieldset'] = array( @@ -43,10 +42,6 @@ function design_test_form_fieldset($form, &$form_state) { $form['collapsed']['#title'] = 'Collapsed details'; $form['collapsed']['#collapsed'] = TRUE; - $form['uncollapsible'] = $form['collapsible']; - $form['uncollapsible']['#title'] = 'Uncollapsible details'; - $form['uncollapsible']['#collapsible'] = FALSE; - $form['nested'] = $form['regular']; $form['nested']['#title'] = 'Parent fieldset'; $form['nested']['nested'] = $form['nested']; diff --git a/core/modules/system/tests/modules/form_test/form_test.module b/core/modules/system/tests/modules/form_test/form_test.module index 8e1992ce45..be55dcfc79 100644 --- a/core/modules/system/tests/modules/form_test/form_test.module +++ b/core/modules/system/tests/modules/form_test/form_test.module @@ -824,7 +824,6 @@ function _form_test_vertical_tabs_form($form, &$form_state) { $form['tab1'] = array( '#type' => 'details', '#title' => t('Tab 1'), - '#collapsible' => TRUE, '#group' => 'vertical_tabs', '#access' => user_access('access vertical_tab_test tabs') ); @@ -835,7 +834,6 @@ function _form_test_vertical_tabs_form($form, &$form_state) { $form['tab2'] = array( '#type' => 'details', '#title' => t('Tab 2'), - '#collapsible' => TRUE, '#group' => 'vertical_tabs', '#access' => user_access('access vertical_tab_test tabs') ); diff --git a/core/modules/taxonomy/lib/Drupal/taxonomy/TermFormController.php b/core/modules/taxonomy/lib/Drupal/taxonomy/TermFormController.php index e2b0b59629..3735ad6c70 100644 --- a/core/modules/taxonomy/lib/Drupal/taxonomy/TermFormController.php +++ b/core/modules/taxonomy/lib/Drupal/taxonomy/TermFormController.php @@ -53,7 +53,6 @@ public function form(array $form, array &$form_state, EntityInterface $term) { $form['relations'] = array( '#type' => 'details', '#title' => t('Relations'), - '#collapsible' => TRUE, '#collapsed' => ($vocabulary->hierarchy != TAXONOMY_HIERARCHY_MULTIPLE), '#weight' => 10, ); diff --git a/core/modules/translation/translation.module b/core/modules/translation/translation.module index 805b58fc01..a8641201f0 100644 --- a/core/modules/translation/translation.module +++ b/core/modules/translation/translation.module @@ -215,7 +215,6 @@ function translation_form_node_form_alter(&$form, &$form_state) { '#type' => 'details', '#title' => t('Translation settings'), '#access' => translation_user_can_translate_node($node), - '#collapsible' => TRUE, '#collapsed' => !$node->translate, '#tree' => TRUE, '#weight' => 30, diff --git a/core/modules/translation_entity/lib/Drupal/translation_entity/EntityTranslationController.php b/core/modules/translation_entity/lib/Drupal/translation_entity/EntityTranslationController.php index a76da8892e..1dcbc35fda 100644 --- a/core/modules/translation_entity/lib/Drupal/translation_entity/EntityTranslationController.php +++ b/core/modules/translation_entity/lib/Drupal/translation_entity/EntityTranslationController.php @@ -156,7 +156,6 @@ public function entityFormAlter(array &$form, array &$form_state, EntityInterfac $form['source_langcode'] = array( '#type' => 'details', '#title' => t('Source language: @language', array('@language' => $languages[$source_langcode]->name)), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#tree' => TRUE, '#weight' => -100, @@ -225,7 +224,6 @@ public function entityFormAlter(array &$form, array &$form_state, EntityInterfac $form['translation'] = array( '#type' => 'details', '#title' => t('Translation'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#tree' => TRUE, '#weight' => 10, diff --git a/core/modules/user/user.admin.inc b/core/modules/user/user.admin.inc index 4da13b818b..198bd9b983 100644 --- a/core/modules/user/user.admin.inc +++ b/core/modules/user/user.admin.inc @@ -400,7 +400,6 @@ function user_admin_settings($form, &$form_state) { $form['email_admin_created'] = array( '#type' => 'details', '#title' => t('Welcome (new user created by administrator)'), - '#collapsible' => TRUE, '#collapsed' => ($config->get('register') != USER_REGISTER_ADMINISTRATORS_ONLY), '#description' => t('Edit the welcome e-mail messages sent to new member accounts created by an administrator.') . ' ' . $email_token_help, '#group' => 'email', @@ -421,7 +420,6 @@ function user_admin_settings($form, &$form_state) { $form['email_pending_approval'] = array( '#type' => 'details', '#title' => t('Welcome (awaiting approval)'), - '#collapsible' => TRUE, '#collapsed' => ($config->get('register') != USER_REGISTER_VISITORS_ADMINISTRATIVE_APPROVAL), '#description' => t('Edit the welcome e-mail messages sent to new members upon registering, when administrative approval is required.') . ' ' . $email_token_help, '#group' => 'email', @@ -442,7 +440,6 @@ function user_admin_settings($form, &$form_state) { $form['email_pending_approval_admin'] = array( '#type' => 'details', '#title' => t('Admin (user awaiting approval)'), - '#collapsible' => TRUE, '#collapsed' => ($config->get('register') != USER_REGISTER_VISITORS_ADMINISTRATIVE_APPROVAL), '#description' => t('Edit the e-mail notifying the site administrator that there are new members awaiting administrative approval.') . ' ' . $email_token_help, '#group' => 'email', @@ -463,7 +460,6 @@ function user_admin_settings($form, &$form_state) { $form['email_no_approval_required'] = array( '#type' => 'details', '#title' => t('Welcome (no approval required)'), - '#collapsible' => TRUE, '#collapsed' => ($config->get('register') != USER_REGISTER_VISITORS), '#description' => t('Edit the welcome e-mail messages sent to new members upon registering, when no administrator approval is required.') . ' ' . $email_token_help, '#group' => 'email', @@ -484,7 +480,6 @@ function user_admin_settings($form, &$form_state) { $form['email_password_reset'] = array( '#type' => 'details', '#title' => t('Password recovery'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#description' => t('Edit the e-mail messages sent to users who request a new password.') . ' ' . $email_token_help, '#group' => 'email', @@ -506,7 +501,6 @@ function user_admin_settings($form, &$form_state) { $form['email_activated'] = array( '#type' => 'details', '#title' => t('Account activation'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#description' => t('Enable and edit e-mail messages sent to users upon account activation (when an administrator activates an account of a user who has already registered, on a site where administrative approval is required).') . ' ' . $email_token_help, '#group' => 'email', @@ -541,7 +535,6 @@ function user_admin_settings($form, &$form_state) { $form['email_blocked'] = array( '#type' => 'details', '#title' => t('Account blocked'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#description' => t('Enable and edit e-mail messages sent to users when their accounts are blocked.') . ' ' . $email_token_help, '#group' => 'email', @@ -576,7 +569,6 @@ function user_admin_settings($form, &$form_state) { $form['email_cancel_confirm'] = array( '#type' => 'details', '#title' => t('Account cancellation confirmation'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#description' => t('Edit the e-mail messages sent to users when they attempt to cancel their accounts.') . ' ' . $email_token_help, '#group' => 'email', @@ -597,7 +589,6 @@ function user_admin_settings($form, &$form_state) { $form['email_canceled'] = array( '#type' => 'details', '#title' => t('Account canceled'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#description' => t('Enable and edit e-mail messages sent to users when their accounts are canceled.') . ' ' . $email_token_help, '#group' => 'email', diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/HandlerBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/HandlerBase.php index ad0798b717..943090f29f 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/HandlerBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/HandlerBase.php @@ -291,7 +291,6 @@ public function buildOptionsForm(&$form, &$form_state) { $form['more'] = array( '#type' => 'details', '#title' => t('More'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#weight' => 150, ); diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/PluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/PluginBase.php index e6c255131d..34c4f12ddc 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/PluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/PluginBase.php @@ -309,7 +309,6 @@ public function globalTokenForm(&$form, &$form_state) { $form['global_tokens'] = array( '#type' => 'fieldset', '#title' => t('Available global token replacements'), - '#collapsible' => TRUE, '#collapsed' => TRUE, ); $form['global_tokens']['list'] = array( diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/area/AreaPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/area/AreaPluginBase.php index b860d0e8e4..fa394aeacd 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/area/AreaPluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/area/AreaPluginBase.php @@ -116,7 +116,6 @@ public function tokenForm(&$form, &$form_state) { $form['tokens'] = array( '#type' => 'details', '#title' => t('Replacement patterns'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#id' => 'edit-options-token-help', '#states' => array( diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/argument/ArgumentPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/argument/ArgumentPluginBase.php index e3af73a257..a7bd33e445 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/argument/ArgumentPluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/argument/ArgumentPluginBase.php @@ -192,7 +192,6 @@ public function buildOptionsForm(&$form, &$form_state) { $form['exception'] = array( '#type' => 'details', '#title' => t('Exceptions'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#fieldset' => 'no_argument', ); diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php index f72db81c43..5b684b3393 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php @@ -536,7 +536,6 @@ public function buildOptionsForm(&$form, &$form_state) { $form['style_settings'] = array( '#type' => 'details', '#title' => t('Style settings'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#weight' => 99, ); @@ -686,7 +685,6 @@ public function buildOptionsForm(&$form, &$form_state) { $form['alter'] = array( '#title' => t('Rewrite results'), '#type' => 'details', - '#collapsible' => TRUE, '#collapsed' => TRUE, '#weight' => 100, ); @@ -890,7 +888,6 @@ public function buildOptionsForm(&$form, &$form_state) { $form['alter']['help'] = array( '#type' => 'details', '#title' => t('Replacement patterns'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#value' => $output, '#states' => array( @@ -1037,7 +1034,6 @@ public function buildOptionsForm(&$form, &$form_state) { $form['empty_field_behavior'] = array( '#type' => 'details', '#title' => t('No results behavior'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#weight' => 100, ); diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/pager/SqlBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/pager/SqlBase.php index 5e5d9e830b..4f553e3a0f 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/pager/SqlBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/pager/SqlBase.php @@ -75,7 +75,6 @@ public function buildOptionsForm(&$form, &$form_state) { $form['tags'] = array( '#type' => 'details', - '#collapsible' => FALSE, '#collapsed' => FALSE, '#tree' => TRUE, '#title' => t('Pager link labels'), @@ -96,7 +95,6 @@ public function buildOptionsForm(&$form, &$form_state) { $form['expose'] = array( '#type' => 'details', - '#collapsible' => FALSE, '#collapsed' => FALSE, '#tree' => TRUE, '#title' => t('Exposed options'), diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/row/RssFields.php b/core/modules/views/lib/Drupal/views/Plugin/views/row/RssFields.php index c140305e29..b2348d9c1e 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/row/RssFields.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/row/RssFields.php @@ -92,7 +92,6 @@ public function buildOptionsForm(&$form, &$form_state) { $form['guid_field_options'] = array( '#type' => 'details', '#title' => t('GUID settings'), - '#collapsible' => FALSE, '#collapsed' => FALSE, ); $form['guid_field_options']['guid_field'] = array( diff --git a/core/modules/views/views_ui/css/views-admin.theme.css b/core/modules/views/views_ui/css/views-admin.theme.css index 8bf02e59b3..8248f34dda 100644 --- a/core/modules/views/views_ui/css/views-admin.theme.css +++ b/core/modules/views/views_ui/css/views-admin.theme.css @@ -390,7 +390,7 @@ td.group-title { * details need to be floated as well so that the margin above the details interacts with * the float edit option columns. */ -#edit-options .collapsible { +#edit-options details { float: left; width: 100%; } @@ -1061,7 +1061,7 @@ ul#views-display-menu-tabs li.add ul.action-list li{ float: left; } -#edit-options-exception.collapsible { +#edit-options-exception { float: right; width: 250px; margin-top: -2px; diff --git a/core/modules/views/views_ui/lib/Drupal/views_ui/ViewEditFormController.php b/core/modules/views/views_ui/lib/Drupal/views_ui/ViewEditFormController.php index 595113f321..a43d3ce8ba 100644 --- a/core/modules/views/views_ui/lib/Drupal/views_ui/ViewEditFormController.php +++ b/core/modules/views/views_ui/lib/Drupal/views_ui/ViewEditFormController.php @@ -478,7 +478,6 @@ public function getDisplayDetails($view, $display) { $build['columns']['third'] = array( '#type' => 'details', '#title' => t('Advanced'), - '#collapsible' => TRUE, '#collapsed' => TRUE, '#theme_wrappers' => array('details', 'container'), '#attributes' => array( diff --git a/core/themes/seven/style.css b/core/themes/seven/style.css index 376c130805..ecccad3eae 100644 --- a/core/themes/seven/style.css +++ b/core/themes/seven/style.css @@ -1453,7 +1453,7 @@ details.fieldset-no-legend { top: -1px; } -.views-ui-dialog details.collapsible:not(.collapsed) { +.views-ui-dialog details:not(.collapsed) { padding-top: 1.5em; } diff --git a/core/update.php b/core/update.php index 1f7ac5f25e..46d933baf1 100644 --- a/core/update.php +++ b/core/update.php @@ -70,7 +70,6 @@ function update_script_selection_form($form, &$form_state) { '#tree' => TRUE, '#type' => 'details', '#collapsed' => TRUE, - '#collapsible' => TRUE, ); // Ensure system.module's updates appear first. -- GitLab