Making WordPress.org

Changeset 4628


Ignore:
Timestamp:
01/12/2017 05:06:57 AM (7 years ago)
Author:
pento
Message:

Breathe: Bring a shiny new style to the handbook Chapters menu.

Props mapk, pento.
See #1825.

Location:
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-breathe
Files:
2 added
2 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-breathe/functions.php

    r4585 r4628  
    5050}
    5151add_action( 'wp_enqueue_scripts', __NAMESPACE__ . '\styles', 11 );
     52
     53function scripts() {
     54    wp_enqueue_script( 'wporg-breathe-chapters', get_stylesheet_directory_uri() . '/js/chapters.js', array( 'jquery' ), '20170112' );
     55}
     56add_action( 'wp_enqueue_scripts', __NAMESPACE__ . '\scripts', 11 );
    5257
    5358function inline_scripts() {
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-breathe/style.css

    r4607 r4628  
    807807/** Menu */
    808808
     809#secondary aside.widget_wporg_handbook_pages {
     810    font-size: 16px;
     811}
     812
    809813.widget_wporg_handbook_pages h1 {
    810814    font-size: 1.6em;
     
    813817}
    814818
    815 .menu-table-of-contents-container > ul {
    816     border-bottom: 1px solid #eee;
    817 }
    818 
    819 #secondary .menu-table-of-contents-container ul {
     819.menu-table-of-contents-container {
     820  font-size: 0.8em;
     821}
     822.menu-table-of-contents-container ul {
     823  margin-left: 0;
     824  padding-left: 0;
     825  list-style: none;
     826}
     827#secondary .menu-table-of-contents-container ul li {
     828  border-top: 1px solid #eee;
     829  padding: 0;
     830  position: relative;
     831}
     832#secondary .menu-table-of-contents-container ul ul {
    820833    margin-left: 0;
    821834}
    822 
    823 #secondary .menu-table-of-contents-container li {
    824     border-top: 1px solid #eee;
    825     padding: 0;
    826 }
    827 
     835.menu-table-of-contents-container ul li .expandable {
     836  display: flex;
     837  flex-direction: row-reverse;
     838  align-items: stretch;
     839  position: relative;
     840}
     841.menu-table-of-contents-container ul li .dashicons {
     842  position: absolute;
     843  cursor: pointer;
     844  border-left: 1px solid #eee;
     845  border-right: 1px solid #eee;
     846  padding: 8px;
     847  display: inline-block;
     848  width: auto;
     849  height: 100%;
     850  background-color: #fff;
     851}
     852.menu-table-of-contents-container ul li .dashicons:hover {
     853  color: #fff;
     854  background-color: #0073aa;
     855}
     856.menu-table-of-contents-container ul li.open > div > .dashicons {
     857  transform: rotate(180deg);
     858}
     859.menu-table-of-contents-container ul a {
     860  display: block;
     861  width: 100%;
     862  padding: 8px 40px 8px 8px;
     863  color: #23282d;
     864  text-decoration: none;
     865}
     866.menu-table-of-contents-container ul a:hover {
     867  color: #fff;
     868  background-color: #0073aa;
     869}
     870.menu-table-of-contents-container ul a.active {
     871  color: #fff !important;
     872  background-color: #0073aa;
     873}
     874.menu-table-of-contents-container > ul > li:last-child {
     875  border-bottom: 1px solid #eee;
     876}
     877.menu-table-of-contents-container > ul > li .children > li > a {
     878  padding-left: 13px;
     879}
     880.menu-table-of-contents-container > ul > li .children > li > ul > li > a {
     881  padding-left: 8px;
     882}
     883.menu-table-of-contents-container > ul > li > div > a, .menu-table-of-contents-container > ul > li > a {
     884  border-left: 5px solid transparent;
     885  transition: border-color 0.2s ease;
     886}
     887.menu-table-of-contents-container > ul > li.open > div > a {
     888  border-left: 5px solid #0073aa;
     889  color: #0073aa;
     890}
     891.menu-table-of-contents-container > ul > li.open > div > a:hover {
     892  color: #fff;
     893}
    828894.menu-table-of-contents-container > ul > li ul {
    829     background-color: #f6f6f6;
    830 }
    831 
    832 .menu-table-of-contents-container a {
    833     display: block;
    834     width: 100%;
    835     padding: 5px 0 5px 10px;
    836     color: #23282d;
    837 }
    838 
    839 .menu-table-of-contents-container .current-menu-item a {
    840     color: #191e23;
    841     font-weight: bold;
    842 }
    843 
     895  background-color: #f6f6f6;
     896}
     897.menu-table-of-contents-container > ul > li > ul > li > ul {
     898  padding-left: 16px;
     899  background-color: #fff;
     900}
     901.menu-table-of-contents-container > ul > li > ul > li > ul li {
     902  background-color: #f6f6f6;
     903}
    844904.menu-table-of-contents-container > ul > li > ul > li > ul a {
    845     border-left: 10px solid #d5d5d5;
    846     padding-left: 15px;
    847 }
    848 
    849 .menu-table-of-contents-container a:hover {
    850     color: #fff;
    851     background-color: #0073aa;
    852 }
    853 
    854 .menu-table-of-contents-container > ul > li > ul > li > ul a:hover {
    855     border-left: 0;
    856     padding-left: 25px;
    857 }
     905  border-left: 5px solid #d5d5d5;
     906}
     907.menu-table-of-contents-container > ul > li > ul > li > ul a:hover, .menu-table-of-contents-container > ul > li > ul > li > ul a.active {
     908  border-left: 5px solid #0073aa;
     909}
     910.menu-table-of-contents-container ul.default-open {
     911  display: block !important;
     912}
     913.menu-table-of-contents-container .children {
     914  overflow: hidden;
     915  display: none;
     916}
Note: See TracChangeset for help on using the changeset viewer.