Skip to content

Commit 841d0f2

Browse files
committed
Twenty Twenty-One: Fixes primary menu disappearing.
The primary menu was disappearing at 481px. This adjusts to resolve this. It was shown when adjust the browser window not in responsive design mode. Props stephenbrook, audrasjb, mukesh27, sabernhardt, poena, kristenfisher427, siliconforks, jwgoedert, joedolson. Fixes #52354. git-svn-id: https://develop.svn.wordpress.org/trunk@58142 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 1f09517 commit 841d0f2

File tree

6 files changed

+68
-68
lines changed

6 files changed

+68
-68
lines changed

src/wp-content/themes/twentytwentyone/assets/css/ie-editor.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ blockquote footer {
197197
font-size: 1rem;
198198
font-style: normal;
199199
}
200-
@media only screen and (max-width: 481px) {
200+
@media only screen and (max-width: 481.98px) {
201201

202202
blockquote {
203203
padding-left: 13px;
@@ -1577,7 +1577,7 @@ pre.wp-block-preformatted {
15771577
font-size: 2.5rem;
15781578
}
15791579
}
1580-
@media only screen and (max-width: 481px) {
1580+
@media only screen and (max-width: 481.98px) {
15811581

15821582
.wp-block-quote.is-large,
15831583
.wp-block-quote.is-style-large {

src/wp-content/themes/twentytwentyone/assets/css/ie.css

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1228,7 +1228,7 @@ blockquote footer {
12281228
font-size: 1rem;
12291229
font-style: normal;
12301230
}
1231-
@media only screen and (max-width: 481px) {
1231+
@media only screen and (max-width: 481.98px) {
12321232

12331233
blockquote {
12341234
padding-left: 13px;
@@ -2490,7 +2490,7 @@ h6,
24902490
max-width: 50%;
24912491
}
24922492
}
2493-
@media only screen and (max-width: 481px) {
2493+
@media only screen and (max-width: 481.98px) {
24942494

24952495
.entry-content > .wp-block-image > .alignleft,
24962496
.entry-content > .wp-block-image > .alignright {
@@ -3294,7 +3294,7 @@ pre.wp-block-preformatted {
32943294
color: #28303d;
32953295
font-size: 1.125rem;
32963296
}
3297-
@media only screen and (max-width: 481px) {
3297+
@media only screen and (max-width: 481.98px) {
32983298

32993299
.wp-block-quote.is-large,
33003300
.wp-block-quote.is-style-large {
@@ -4219,7 +4219,7 @@ table.wp-calendar-table caption {
42194219
}
42204220
}
42214221

4222-
@media only screen and (max-width: 481px) {
4222+
@media only screen and (max-width: 481.98px) {
42234223

42244224
.site-header.has-logo:not(.has-title-and-tagline).has-menu .site-logo {
42254225
position: absolute;
@@ -4291,7 +4291,7 @@ table.wp-calendar-table caption {
42914291
.no-widgets .site-footer {
42924292
margin-top: 180px;
42934293
}
4294-
@media only screen and (max-width: 481px) {
4294+
@media only screen and (max-width: 481.98px) {
42954295

42964296
.no-widgets .site-footer {
42974297
margin-top: 90px;
@@ -4522,7 +4522,7 @@ body:not(.single) .site-main > article:last-of-type .entry-footer {
45224522
.single .site-main > article > .entry-footer .tags-links {
45234523
display: block;
45244524
}
4525-
@media only screen and (max-width: 481px) {
4525+
@media only screen and (max-width: 481.98px) {
45264526

45274527
.single .site-main > article > .entry-footer,
45284528
.single .site-main > article > .entry-footer .full-size-link {
@@ -4941,7 +4941,7 @@ h1.page-title {
49414941
flex-basis: 0;
49424942
flex-grow: 1;
49434943
}
4944-
@media only screen and (max-width: 481px) {
4944+
@media only screen and (max-width: 481.98px) {
49454945

49464946
.comment-form .comment-form-author,
49474947
.comment-form .comment-form-email {
@@ -5002,7 +5002,7 @@ h1.page-title {
50025002
padding-top: 15px;
50035003
padding-bottom: 8px;
50045004
}
5005-
@media only screen and (max-width: 481px) {
5005+
@media only screen and (max-width: 481.98px) {
50065006

50075007
.menu-button-container {
50085008
display: flex;
@@ -5090,7 +5090,7 @@ h1.page-title {
50905090
transition: all 0.15s ease-in-out;
50915091
}
50925092
}
5093-
@media only screen and (max-width: 481px) {
5093+
@media only screen and (max-width: 481.98px) {
50945094

50955095
.primary-navigation > .primary-menu-container {
50965096
height: 100vh;
@@ -5142,7 +5142,7 @@ h1.page-title {
51425142
opacity: 1;
51435143
transform: translateY(0);
51445144
}
5145-
@media only screen and (max-width: 481px) {
5145+
@media only screen and (max-width: 481.98px) {
51465146

51475147
.primary-navigation-open .has-logo.has-title-and-tagline .primary-navigation > .primary-menu-container {
51485148
transform: translateX(0) translateY(0);
@@ -5186,7 +5186,7 @@ h1.page-title {
51865186
padding-left: 0;
51875187
position: relative;
51885188
}
5189-
@media only screen and (max-width: 481px) {
5189+
@media only screen and (max-width: 481.98px) {
51905190

51915191
.primary-navigation > div > .menu-wrapper {
51925192
padding-bottom: 100px;
@@ -5229,7 +5229,7 @@ h1.page-title {
52295229
.primary-navigation > div > .menu-wrapper .sub-menu-toggle:focus {
52305230
outline: 2px solid #28303d;
52315231
}
5232-
@media only screen and (max-width: 481px) {
5232+
@media only screen and (max-width: 481.98px) {
52335233

52345234
.primary-navigation > div > .menu-wrapper .sub-menu-toggle {
52355235
display: none;
@@ -5451,7 +5451,7 @@ h1.page-title {
54515451
padding: 0;
54525452
}
54535453
}
5454-
@media only screen and (max-width: 481px) {
5454+
@media only screen and (max-width: 481.98px) {
54555455

54565456
.primary-navigation .sub-menu .menu-item:last-child {
54575457
margin-bottom: 0;
@@ -5499,7 +5499,7 @@ h1.page-title {
54995499
display: inline-block;
55005500
}
55015501

5502-
@media only screen and (max-width: 481px) {
5502+
@media only screen and (max-width: 481.98px) {
55035503

55045504
.lock-scrolling .site {
55055505
position: fixed;
@@ -5796,7 +5796,7 @@ h1.page-title {
57965796
.comments-pagination .nav-links > *.prev {
57975797
margin-right: auto;
57985798
}
5799-
@media only screen and (max-width: 821px) {
5799+
@media only screen and (max-width: 821.98px) {
58005800

58015801
.pagination .nav-links,
58025802
.comments-pagination .nav-links {
@@ -5817,7 +5817,7 @@ h1.page-title {
58175817
flex: 0 1 auto;
58185818
}
58195819
}
5820-
@media only screen and (max-width: 481px) {
5820+
@media only screen and (max-width: 481.98px) {
58215821

58225822
.pagination .nav-short,
58235823
.comments-pagination .nav-short {
@@ -5861,7 +5861,7 @@ h1.page-title {
58615861
grid-template-columns: repeat(3, 1fr);
58625862
}
58635863
}
5864-
@media only screen and (max-width: 481px) {
5864+
@media only screen and (max-width: 481.98px) {
58655865

58665866
.widget-area {
58675867
margin-top: 90px;
@@ -6259,7 +6259,7 @@ footer {
62596259
.is-IE.is-dark-theme .primary-navigation > div > .menu-wrapper > li > .sub-menu li {
62606260
background: #000;
62616261
}
6262-
@media only screen and (max-width: 481px) {
6262+
@media only screen and (max-width: 481.98px) {
62636263

62646264
.is-IE.is-dark-theme.primary-navigation-open .primary-navigation > .primary-menu-container,
62656265
.is-IE.is-dark-theme.primary-navigation-open .menu-button-container {

src/wp-content/themes/twentytwentyone/assets/css/style-editor.css

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,7 @@ blockquote footer {
381381
font-size: var(--global--font-size-xs);
382382
font-style: var(--quote--font-style-cite);
383383
}
384-
@media only screen and (max-width: 481px) {
384+
@media only screen and (max-width: 481.98px) {
385385

386386
blockquote {
387387
padding-left: calc(0.5 * var(--global--spacing-horizontal));
@@ -1626,7 +1626,7 @@ pre.wp-block-preformatted {
16261626
line-height: var(--quote--line-height-large);
16271627
margin-right: 10px;
16281628
}
1629-
@media only screen and (max-width: 481px) {
1629+
@media only screen and (max-width: 481.98px) {
16301630

16311631
.wp-block-quote.is-large,
16321632
.wp-block-quote.is-style-large {
@@ -1649,7 +1649,7 @@ pre.wp-block-preformatted {
16491649
right: 0;
16501650
}
16511651
}
1652-
@media only screen and (max-width: 481px) {
1652+
@media only screen and (max-width: 481.98px) {
16531653

16541654
.wp-block-quote {
16551655
padding-left: calc(0.5 * var(--global--spacing-horizontal));

src/wp-content/themes/twentytwentyone/assets/sass/03-generic/breakpoints.scss

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ $breakpoint_xxl: 1024px;
1818
@mixin media( $res ) {
1919

2020
@if mobile-only == $res {
21-
@media only screen and (max-width: #{$breakpoint_sm - 1}) {
21+
@media only screen and (max-width: #{$breakpoint_sm - 0.02}) {
2222
@content;
2323
}
2424
}
@@ -30,7 +30,7 @@ $breakpoint_xxl: 1024px;
3030
}
3131

3232
@if tablet-only == $res {
33-
@media only screen and (max-width: #{$breakpoint_md - 1}) {
33+
@media only screen and (max-width: #{$breakpoint_md - 0.02}) {
3434
@content;
3535
}
3636
}
@@ -42,7 +42,7 @@ $breakpoint_xxl: 1024px;
4242
}
4343

4444
@if laptop-only == $res {
45-
@media only screen and (max-width: #{$breakpoint_lg - 1}) {
45+
@media only screen and (max-width: #{$breakpoint_lg - 0.02}) {
4646
@content;
4747
}
4848
}
@@ -54,7 +54,7 @@ $breakpoint_xxl: 1024px;
5454
}
5555

5656
@if desktop-only == $res {
57-
@media only screen and (max-width: #{$breakpoint_xl - 1}) {
57+
@media only screen and (max-width: #{$breakpoint_xl - 0.02}) {
5858
@content;
5959
}
6060
}
@@ -66,7 +66,7 @@ $breakpoint_xxl: 1024px;
6666
}
6767

6868
@if wide-only == $res {
69-
@media only screen and (max-width: #{$breakpoint_xxl - 1}) {
69+
@media only screen and (max-width: #{$breakpoint_xxl - 0.02}) {
7070
@content;
7171
}
7272
}

0 commit comments

Comments
 (0)