diff --git wordpress.org/public_html/wp-content/themes/pub/wporg-developer/js/chapters.js wordpress.org/public_html/wp-content/themes/pub/wporg-developer/js/chapters.js
index 5284df090..ea574fef9 100644
|
|
|
1 | 1 | // Mobile Subnav open/close |
2 | | jQuery(document).ready(function() { |
| 2 | jQuery( document ).ready( function () { |
3 | 3 | |
4 | 4 | jQuery( document ).on( 'click', '.code-tab', function ( e ) { |
5 | 5 | var $tab = jQuery( e.target ); |
… |
… |
jQuery(document).ready(function() { |
12 | 12 | $tab.parent().find( '.is-active, .' + lang ).toggleClass( 'is-active' ); |
13 | 13 | } ); |
14 | 14 | |
15 | | var tocContainer = jQuery( 'div[class*="-table-of-contents-container"]').first(); |
| 15 | var tocContainer = jQuery( 'div[class*="-table-of-contents-container"]' ).first(); |
16 | 16 | |
17 | 17 | if ( 0 === tocContainer.length ) { |
18 | 18 | return; |
19 | 19 | } |
20 | 20 | |
21 | 21 | // Add our expandable button |
22 | | tocContainer.find( '> ul > .menu-item-has-children > a' ) |
| 22 | tocContainer.find( '> ul .menu-item-has-children > a' ) |
23 | 23 | .wrap( '<div class="expandable"></div>' ) |
24 | 24 | .after( '<button class="dashicons dashicons-arrow-down-alt2" aria-expanded="false"></button>' ); |
25 | 25 | |
26 | | // Invisibly open all of the submenus |
27 | | jQuery( '.menu-item-has-children > ul ul' ).addClass( 'default-open' ); |
| 26 | // Invisibly hide all of the submenus |
| 27 | jQuery( '.menu-item-has-children > ul ul' ).hide(); |
28 | 28 | |
29 | 29 | // Open the current menu |
30 | 30 | tocContainer.find( '.current-menu-item a' ).first() |
31 | 31 | .addClass( 'active' ) |
32 | 32 | .parents( '.menu-item-has-children' ) |
33 | | .toggleClass( 'open' ) |
| 33 | .toggleClass( 'open' ) |
34 | 34 | .find( '> div > .dashicons' ) |
35 | | .attr( 'aria-expanded', true ); |
36 | | |
| 35 | .attr( 'aria-expanded', true ); |
| 36 | |
| 37 | // Open the current submenu |
| 38 | $secondary_menu = tocContainer.find( '.current-menu-item > ul' ); |
| 39 | console.log( $secondary_menu.length ); |
| 40 | if ( $secondary_menu.length ) { |
| 41 | $secondary_menu.show(); |
| 42 | } else { |
| 43 | tocContainer.find( '.current-menu-item' ).parents( 'ul' ).show(); |
| 44 | } |
37 | 45 | // Or if wrapped in a div.expandable |
38 | | jQuery( '.menu-item-has-children > div > .dashicons' ).click( function() { |
| 46 | jQuery( '.menu-item-has-children > div > .dashicons' ).click( function () { |
39 | 47 | var menuToggle = jQuery( this ).closest( '.menu-item-has-children' ); |
40 | 48 | |
41 | 49 | jQuery( this ).parent().siblings( '.sub-menu' ).length |
diff --git wordpress.org/public_html/wp-content/themes/pub/wporg-developer/scss/main.scss wordpress.org/public_html/wp-content/themes/pub/wporg-developer/scss/main.scss
index dcce75998..2c65e6db9 100644
|
|
|
545 | 545 | width: 640px; |
546 | 546 | margin: 0 auto; |
547 | 547 | } |
548 | | |
| 548 | |
549 | 549 | } |
550 | 550 | .color.section { |
551 | 551 | color: #fff; |
… |
… |
|
736 | 736 | padding-top: 0; |
737 | 737 | } |
738 | 738 | |
739 | | div#inner-search { |
740 | | background-color: #666; |
741 | | margin-bottom: 1em; |
742 | | padding-top: 2px; |
743 | | .section.search-section { |
| 739 | div#inner-search { |
| 740 | background-color: #666; |
| 741 | margin-bottom: 1em; |
| 742 | padding-top: 2px; |
| 743 | .section.search-section { |
| 744 | color: #ffffff; |
| 745 | } |
| 746 | div#inner-search-icon-container { |
| 747 | margin: 0 auto; |
| 748 | max-width: 60em; |
| 749 | cursor: pointer; |
| 750 | div#inner-search-icon { |
| 751 | background-color: #666; |
744 | 752 | color: #ffffff; |
745 | | } |
746 | | div#inner-search-icon-container { |
747 | | margin: 0 auto; |
748 | | max-width: 60em; |
749 | | cursor: pointer; |
750 | | div#inner-search-icon { |
751 | | background-color: #666; |
752 | | color: #ffffff; |
753 | | text-align: center; |
754 | | margin-right: 26px; |
755 | | margin-left: 4px; |
756 | | float: right; |
757 | | padding: 5px; |
758 | | -webkit-border-bottom-right-radius: 5px; |
759 | | -webkit-border-bottom-left-radius: 5px; |
760 | | -moz-border-radius-bottomright: 5px; |
761 | | -moz-border-radius-bottomleft: 5px; |
762 | | border-bottom-right-radius: 5px; |
763 | | border-bottom-left-radius: 5px; |
764 | | .dashicons-search { |
765 | | height: auto; |
766 | | width: auto; |
767 | | &:before { |
768 | | font-size: 36px; |
769 | | line-height: 36px; |
770 | | } |
| 753 | text-align: center; |
| 754 | margin-right: 26px; |
| 755 | margin-left: 4px; |
| 756 | float: right; |
| 757 | padding: 5px; |
| 758 | -webkit-border-bottom-right-radius: 5px; |
| 759 | -webkit-border-bottom-left-radius: 5px; |
| 760 | -moz-border-radius-bottomright: 5px; |
| 761 | -moz-border-radius-bottomleft: 5px; |
| 762 | border-bottom-right-radius: 5px; |
| 763 | border-bottom-left-radius: 5px; |
| 764 | .dashicons-search { |
| 765 | height: auto; |
| 766 | width: auto; |
| 767 | &:before { |
| 768 | font-size: 36px; |
| 769 | line-height: 36px; |
771 | 770 | } |
772 | 771 | } |
773 | 772 | } |
774 | 773 | } |
| 774 | } |
775 | 775 | |
776 | 776 | .archive-filter-form { |
777 | 777 | margin: 5rem 0; |
… |
… |
|
1282 | 1282 | .comment-list li.depth-1, |
1283 | 1283 | #comment-preview { |
1284 | 1284 | border: 1px solid #dfdfdf; |
1285 | | border-radius: 2px; |
| 1285 | border-radius: 2px; |
1286 | 1286 | width: 100%; |
1287 | 1287 | } |
1288 | 1288 | |
… |
… |
|
1696 | 1696 | a { |
1697 | 1697 | font-size: 68.6646px; |
1698 | 1698 | font-size: 6.86646rem; |
1699 | | |
| 1699 | |
1700 | 1700 | @media (max-width: 500px) { |
1701 | 1701 | font-size: 50px; |
1702 | 1702 | font-size: 5rem; |
… |
… |
div[class*="-table-of-contents-container"] { |
2131 | 2131 | display: block; |
2132 | 2132 | } |
2133 | 2133 | .current-menu-ancestor:not(.open) .expandable .dashicons:not(:focus), |
2134 | | .current-menu-item .expandable .dashicons:not(:focus) { |
| 2134 | .current-menu-item > .expandable .dashicons:not(:focus) { |
2135 | 2135 | background: #fff; |
2136 | 2136 | color: #0073aa; |
2137 | 2137 | } |
diff --git wordpress.org/public_html/wp-content/themes/pub/wporg-developer/stylesheets/main.css wordpress.org/public_html/wp-content/themes/pub/wporg-developer/stylesheets/main.css
index 8f460c7d9..96d97e19e 100644
|
|
div[class*="-table-of-contents-container"] .current-menu-ancestor ul { |
2517 | 2517 | } |
2518 | 2518 | |
2519 | 2519 | div[class*="-table-of-contents-container"] .current-menu-ancestor:not(.open) .expandable .dashicons:not(:focus), |
2520 | | div[class*="-table-of-contents-container"] .current-menu-item .expandable .dashicons:not(:focus) { |
| 2520 | div[class*="-table-of-contents-container"] .current-menu-item > .expandable .dashicons:not(:focus) { |
2521 | 2521 | background: #fff; |
2522 | 2522 | color: #0073aa; |
2523 | 2523 | } |