From 55f0a18c02a28ff119f40db7de1e29729b35f615 Mon Sep 17 00:00:00 2001 From: Ian Belanger Date: Fri, 12 Jun 2020 15:09:35 +0000 Subject: [PATCH] Bundled Themes: Twenty Nineteen long submenu item titles do not wrap. Fixes the issue of long submenu item titles that do not wrap by adding a `max-width: 20rem;` and removing `white-space: nowrap;`. Props kjellr, mukesh27, mohsinrasool, samful. Fixes #45866. git-svn-id: https://develop.svn.wordpress.org/trunk@48032 602fd350-edb4-49c9-b593-d223f7449a82 --- .../twentynineteen/sass/navigation/_menu-main-navigation.scss | 2 +- src/wp-content/themes/twentynineteen/style.css | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wp-content/themes/twentynineteen/sass/navigation/_menu-main-navigation.scss b/src/wp-content/themes/twentynineteen/sass/navigation/_menu-main-navigation.scss index 4bbd9cff52..502fdf627e 100644 --- a/src/wp-content/themes/twentynineteen/sass/navigation/_menu-main-navigation.scss +++ b/src/wp-content/themes/twentynineteen/sass/navigation/_menu-main-navigation.scss @@ -205,7 +205,7 @@ line-height: $font__line-height-heading; text-shadow: none; padding: calc( .5 * #{$size__spacing-unit} ) calc( 24px + #{$size__spacing-unit} ) calc( .5 * #{$size__spacing-unit} ) $size__spacing-unit; - white-space: nowrap; + max-width: #{20 * $size__spacing-unit}; &:hover, &:focus { diff --git a/src/wp-content/themes/twentynineteen/style.css b/src/wp-content/themes/twentynineteen/style.css index 982ea90b39..296f506d1e 100644 --- a/src/wp-content/themes/twentynineteen/style.css +++ b/src/wp-content/themes/twentynineteen/style.css @@ -2958,7 +2958,7 @@ body.page .main-navigation { line-height: 1.2; text-shadow: none; padding: calc( .5 * 1rem) calc( 24px + 1rem) calc( .5 * 1rem) 1rem; - white-space: nowrap; + max-width: 20rem; } .main-navigation .sub-menu > li > a:hover, .main-navigation .sub-menu > li > a:focus,