From e61b7862335b3bf30f66adcd3d42ea2e574c7488 Mon Sep 17 00:00:00 2001 From: xjm <xjm@65776.no-reply.drupal.org> Date: Wed, 16 Oct 2019 15:50:54 -0500 Subject: [PATCH] Issue #3086369 by zrpnr, lauriii, Wim Leers: Deprecate matchMedia --- core/core.libraries.yml | 2 ++ core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php | 2 ++ 2 files changed, 4 insertions(+) diff --git a/core/core.libraries.yml b/core/core.libraries.yml index ecdeaa5164ae..e973b51b36d6 100644 --- a/core/core.libraries.yml +++ b/core/core.libraries.yml @@ -889,6 +889,7 @@ matchmedia: gpl-compatible: true js: assets/vendor/matchMedia/matchMedia.min.js: { minified: true } + deprecated: &matchmedia_deprecated The "%library_id%" asset library is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. See https://www.drupal.org/node/3086653 matchmedia.addListener: version: *matchmedia_version @@ -897,6 +898,7 @@ matchmedia.addListener: assets/vendor/matchMedia/matchMedia.addListener.min.js: { minified: true } dependencies: - core/matchmedia + deprecated: *matchmedia_deprecated modernizr: # Block the page from being loaded until Modernizr is initialized. diff --git a/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php b/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php index 5299822ffa1e..1d5d4b9ec4a6 100644 --- a/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php +++ b/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php @@ -143,6 +143,8 @@ public static function getSkippedDeprecations() { // @todo Remove in https://www.drupal.org/project/drupal/issues/3082655 'Drupal\Tests\BrowserTestBase::$defaultTheme is required in drupal:9.0.0 when using an install profile that does not set a default theme. See https://www.drupal.org/node/2352949, which includes recommendations on which theme to use.', 'The "core/html5shiv" asset library is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. See https://www.drupal.org/node/3086383', + 'The "core/matchmedia" asset library is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. See https://www.drupal.org/node/3086653', + 'The "core/matchmedia.addListener" asset library is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. See https://www.drupal.org/node/3086653', ]; } -- GitLab