diff --git a/core/includes/theme.inc b/core/includes/theme.inc index d811f4d..c9bee2d 100644 --- a/core/includes/theme.inc +++ b/core/includes/theme.inc @@ -2335,6 +2335,8 @@ function drupal_common_theme() { ), 'task_list' => array( 'variables' => array('items' => NULL, 'active' => NULL, 'variant' => NULL), + 'template' => 'task-list', + 'includes' => array('core/includes/theme.maintenance.inc'), ), 'authorize_message' => array( 'variables' => array('message' => NULL, 'success' => TRUE), diff --git a/core/includes/theme.maintenance.inc b/core/includes/theme.maintenance.inc index 2ceec4a..4d53a78 100644 --- a/core/includes/theme.maintenance.inc +++ b/core/includes/theme.maintenance.inc @@ -7,6 +7,7 @@ use Drupal\Component\Utility\Unicode; use Drupal\Core\Site\Settings; +use Drupal\Core\Template\Attribute; /** * Sets up the theming system for maintenance page. @@ -104,43 +105,37 @@ function _drupal_maintenance_theme() { } /** - * Returns HTML for a list of maintenance tasks to perform. + * Prepares variables for maintenance task list templates. * - * @param $variables + * Default template: task-list.html.twig. + * + * @param array $variables * An associative array containing: * - items: An associative array of maintenance tasks. * It's the caller's responsibility to ensure this array's items contain no * dangerous HTML such as SCRIPT tags. * - active: The key for the currently active maintenance task. - * - * @ingroup themeable */ -function theme_task_list($variables) { +function template_preprocess_task_list(&$variables) { $items = $variables['items']; $active = $variables['active']; $done = isset($items[$active]) || $active == NULL; - $output = '