diff --git a/core/lib/Drupal/Core/EventSubscriber/AcceptNegotiation406.php b/core/lib/Drupal/Core/EventSubscriber/AcceptNegotiation406.php index 72683e1..468ab9f 100644 --- a/core/lib/Drupal/Core/EventSubscriber/AcceptNegotiation406.php +++ b/core/lib/Drupal/Core/EventSubscriber/AcceptNegotiation406.php @@ -8,7 +8,6 @@ namespace Drupal\Core\EventSubscriber; use Symfony\Component\EventDispatcher\EventSubscriberInterface; -use Symfony\Component\HttpFoundation\JsonResponse; use Symfony\Component\HttpKernel\Event\GetResponseForControllerResultEvent; use Symfony\Component\HttpKernel\Exception\NotAcceptableHttpException; use Symfony\Component\HttpKernel\KernelEvents; diff --git a/core/lib/Drupal/Core/Render/Element/RenderElement.php b/core/lib/Drupal/Core/Render/Element/RenderElement.php index b9de164..87b9f02 100644 --- a/core/lib/Drupal/Core/Render/Element/RenderElement.php +++ b/core/lib/Drupal/Core/Render/Element/RenderElement.php @@ -7,7 +7,6 @@ namespace Drupal\Core\Render\Element; -use Drupal\Core\EventSubscriber\MainContentViewSubscriber; use Drupal\Core\Form\FormStateInterface; use Drupal\Core\Plugin\PluginBase; use Drupal\Core\Render\Element; @@ -241,7 +240,7 @@ public static function preRenderAjaxForm($element) { $settings += array( 'url' => isset($settings['callback']) ? Url::fromRoute('system.ajax') : NULL, 'options' => array(), - MainContentViewSubscriber::WRAPPER_ENVELOPE => 'ajax', + 'dialogType' => 'ajax', ); // @todo Legacy support. Remove in Drupal 8. diff --git a/core/modules/system/tests/modules/ajax_test/src/Controller/AjaxTestController.php b/core/modules/system/tests/modules/ajax_test/src/Controller/AjaxTestController.php index 364a36f..ff4859d 100644 --- a/core/modules/system/tests/modules/ajax_test/src/Controller/AjaxTestController.php +++ b/core/modules/system/tests/modules/ajax_test/src/Controller/AjaxTestController.php @@ -120,6 +120,7 @@ public function dialog() { '#url' => Url::fromRoute('ajax_test.dialog_contents'), '#attributes' => array( 'class' => array('use-ajax'), + 'data-dialog-type' => 'modal', ), );