diff --git a/core/core.libraries.yml b/core/core.libraries.yml index 1a188ec2f1d72f7fe92271da701f4c8d14e3eab3..f0fb2c4fe6cc6f97885aaf961c70c4efd426f5ec 100644 --- a/core/core.libraries.yml +++ b/core/core.libraries.yml @@ -798,6 +798,7 @@ modernizr: version: "3.11.7" js: assets/vendor/modernizr/modernizr.min.js: { preprocess: 0, weight: -21, minified: true } + deprecated: The %library_id% asset library is deprecated in Drupal 10.1.0 and will be removed in Drupal 11.0.0. See https://www.drupal.org/node/3333253 normalize: remote: https://github.com/necolas/normalize.css diff --git a/core/lib/Drupal/Core/Render/theme.api.php b/core/lib/Drupal/Core/Render/theme.api.php index 5c57841f4a7a69274d84ebc0a427165a3153e8fa..c98ab3e4ed7e8d8a644d89ebdd5a28e18714c1ff 100644 --- a/core/lib/Drupal/Core/Render/theme.api.php +++ b/core/lib/Drupal/Core/Render/theme.api.php @@ -164,8 +164,8 @@ * $variables['#attached'] @endcode, e.g.: * @code * function THEME_preprocess_menu_local_action(array &$variables) { - * // We require Modernizr's touch test for button styling. - * $variables['#attached']['library'][] = 'core/modernizr'; + * // We require touch events detection for button styling. + * $variables['#attached']['library'][] = 'core/drupal.touchevents-test'; * } * @endcode * diff --git a/core/misc/cspell/dictionary.txt b/core/misc/cspell/dictionary.txt index 1d502548c095d2d08f90684c0403906ed12d4cc8..3a3ab28b9ca5a0d814e66b3964673ef9db1bea0c 100644 --- a/core/misc/cspell/dictionary.txt +++ b/core/misc/cspell/dictionary.txt @@ -712,7 +712,6 @@ mocktails mocky moderatable modernizr -modernizr's modulenarrow mojito montag diff --git a/core/themes/claro/claro.libraries.yml b/core/themes/claro/claro.libraries.yml index 3a66b925320b30033bb40219b4bc46eb34d0ed79..ec413eef3ae08495a4410112007deeb95e65ac58 100644 --- a/core/themes/claro/claro.libraries.yml +++ b/core/themes/claro/claro.libraries.yml @@ -71,12 +71,10 @@ global-styling: # such as inputs, action links, buttons, dropbuttons. For usability and # accessibility reasons, we keep target sizes big enough on touch screen # devices (by not making these elements smaller than their default size). - # Modernizr was used for recognizing whether user is using a touch device or - # not. This allows conditionally rendering small variation of the control - # elements on non-touch devices. Modernizr's touch detection has since been - # replaced by core/drupal.touchevents-test. - # In some cases, such as when rendering links, it is hard recognize when - # this detection should be attached, therefore it is always attached. + # This library allows conditionally rendering small variations of the + # control elements on non-touch devices. In some cases, such as when + # rendering links, it is hard to recognize when this detection should be + # attached, therefore it is always attached. - core/drupal.touchevents-test node-form: diff --git a/core/themes/claro/templates/details.html.twig b/core/themes/claro/templates/details.html.twig index dfd58d4985926df8b337094651c9873b645dd27f..1256f86e6b27a6b37aa2c57e3aa0a52d56a22128 100644 --- a/core/themes/claro/templates/details.html.twig +++ b/core/themes/claro/templates/details.html.twig @@ -19,11 +19,6 @@ * @see claro_preprocess_details() */ #} -{# - Prefix 'details' class to avoid collision with Modernizr. - - @todo Remove prefix after https://www.drupal.org/node/2981732 has been solved. -#} {% set classes = [ 'claro-details', diff --git a/core/themes/claro/templates/navigation/details--vertical-tabs.html.twig b/core/themes/claro/templates/navigation/details--vertical-tabs.html.twig index ba0d82325689927a8dd204bfb7e54c444f126125..46328cb10f2c6633515f5d0eb5ef1e54541006a7 100644 --- a/core/themes/claro/templates/navigation/details--vertical-tabs.html.twig +++ b/core/themes/claro/templates/navigation/details--vertical-tabs.html.twig @@ -20,11 +20,6 @@ * @see claro_preprocess_details() */ #} -{# - Prefix 'details' class to avoid collision with Modernizr. - - @todo Remove prefix after https://www.drupal.org/node/2981732 has been solved. -#} {% set classes = [ 'claro-details', diff --git a/core/themes/olivero/templates/form/details.html.twig b/core/themes/olivero/templates/form/details.html.twig index c526d63e6ebe2bdeab610cbeef90ba37777e3491..c7a7f9c416a2f17f6bfc56f5f754daf3a0496752 100644 --- a/core/themes/olivero/templates/form/details.html.twig +++ b/core/themes/olivero/templates/form/details.html.twig @@ -16,11 +16,6 @@ * @see olivero_preprocess_details() */ #} -{# - Prefix 'details' class to avoid collision with Modernizr. - - @todo Remove prefix after https://www.drupal.org/node/2981732 has been solved. -#} {% set classes = [ 'olivero-details',