<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[23417] trunk: Refactor the Customizer accordion so that it can be used in other locations.</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg > ul, #logmsg > ol { margin-left: 0; margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://core.trac.wordpress.org/changeset/23417">23417</a></dd>
<dt>Author</dt> <dd>markjaquith</dd>
<dt>Date</dt> <dd>2013-02-14 22:58:04 +0000 (Thu, 14 Feb 2013)</dd>
</dl>

<h3>Log Message</h3>
<pre>Refactor the Customizer accordion so that it can be used in other locations.

fixes <a href="http://core.trac.wordpress.org/ticket/23449">#23449</a>. props lessbloat, aaroncampbell</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkwpadmincsscustomizecontrolsrtlcss">trunk/wp-admin/css/customize-controls-rtl.css</a></li>
<li><a href="#trunkwpadmincsscustomizecontrolscss">trunk/wp-admin/css/customize-controls.css</a></li>
<li><a href="#trunkwpadmincsswpadminrtlcss">trunk/wp-admin/css/wp-admin-rtl.css</a></li>
<li><a href="#trunkwpadmincsswpadmincss">trunk/wp-admin/css/wp-admin.css</a></li>
<li><a href="#trunkwpadmincustomizephp">trunk/wp-admin/customize.php</a></li>
<li><a href="#trunkwpadminjscustomizecontrolsjs">trunk/wp-admin/js/customize-controls.js</a></li>
<li><a href="#trunkwpincludesclasswpcustomizesectionphp">trunk/wp-includes/class-wp-customize-section.php</a></li>
<li><a href="#trunkwpincludesscriptloaderphp">trunk/wp-includes/script-loader.php</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkwpadminjsaccordionjs">trunk/wp-admin/js/accordion.js</a></li>
<li><a href="#trunkwpadminjsaccordionminjs">trunk/wp-admin/js/accordion.min.js</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkwpadmincsscustomizecontrolsrtlcss"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/css/customize-controls-rtl.css (23416 => 23417)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/css/customize-controls-rtl.css        2013-02-14 22:51:06 UTC (rev 23416)
+++ trunk/wp-admin/css/customize-controls-rtl.css        2013-02-14 22:58:04 UTC (rev 23417)
</span><span class="lines">@@ -1,11 +1,3 @@
</span><del>-.control-section .customize-section-title {
-        font-family: Tahoma, Arial, sans-serif;
-}
-.customize-section-title:after {
-        right: auto;
-        left: 20px;
-}
-
</del><span class="cx"> #customize-header-actions .button-primary {
</span><span class="cx">         float: left;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkwpadmincsscustomizecontrolscss"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/css/customize-controls.css (23416 => 23417)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/css/customize-controls.css        2013-02-14 22:51:06 UTC (rev 23416)
+++ trunk/wp-admin/css/customize-controls.css        2013-02-14 22:58:04 UTC (rev 23417)
</span><span class="lines">@@ -6,124 +6,7 @@
</span><span class="cx">         text-decoration: none;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section {
-        border-top: 1px solid #fff;
-        border-bottom: 1px solid #dfdfdf;
-        margin: 0;
-}
-
-.control-section.customize-section:hover,
-.control-section.customize-section.open {
-        border-top-color: #808080;
-}
-
-.control-section.customize-section:hover {
-        border-bottom-color: #6d6d6d;
-}
-
-.customize-section.open:hover {
-        border-bottom-color: #dfdfdf;
-}
-
-.customize-section:last-child {
-        box-shadow: 0 1px 0 0px #fff;
-}
-
-.customize-section-title {
-        margin: 0;
-        padding: 15px 20px;
-        position: relative;
-
-        cursor: pointer;
-
-        -webkit-user-select: none;
-        -moz-user-select: none;
-        user-select: none;
-}
-
-.customize-section-title:focus {
-        outline: none;
-}
-
-.cannot-expand .customize-section-title {
-        cursor: auto;
-}
-
-.customize-section-content {
-        display: none;
-        padding: 10px 20px 15px;
-        overflow: hidden;
-}
-
-.control-section .customize-section-title {
-        padding: 10px 20px;
-        font-size: 15px;
-        font-family: Georgia, &quot;Times New Roman&quot;, &quot;Bitstream Charter&quot;, Times, serif;
-        font-weight: normal;
-        text-shadow: 0 1px 0 #fff;
-        background: #f5f5f5;
-        background-image: -webkit-gradient(linear, left bottom, left top, from(#eee), to(#f5f5f5));
-        background-image: -webkit-linear-gradient(bottom, #eee, #f5f5f5);
-        background-image:    -moz-linear-gradient(bottom, #eee, #f5f5f5);
-        background-image:      -o-linear-gradient(bottom, #eee, #f5f5f5);
-        background-image: linear-gradient(to top, #eee, #f5f5f5);
-}
-
-.control-section:hover .customize-section-title,
-.control-section .customize-section-title:hover,
-.control-section.open .customize-section-title,
-.control-section .customize-section-title:focus {
-        color: #fff;
-        text-shadow: 0 -1px 0 #333;
-        background: #808080;
-        background-image: -webkit-gradient(linear, left bottom, left top, from(#6d6d6d), to(#808080));
-        background-image: -webkit-linear-gradient(bottom, #6d6d6d, #808080);
-        background-image:    -moz-linear-gradient(bottom, #6d6d6d, #808080);
-        background-image:      -o-linear-gradient(bottom, #6d6d6d, #808080);
-        background-image: linear-gradient(to top, #6d6d6d, #808080);
-}
-
-.control-section.open .customize-section-title {
-        border-bottom: 1px solid #6d6d6d;
-}
-
-.customize-section.open .customize-section-content {
-        display: block;
-        background: #fdfdfd;
-}
-
-.customize-section-title:after {
-        content: '';
-        width: 0;
-        height: 0;
-        border-color: #ccc transparent;
-        border-style: solid;
-        border-width: 6px 6px 0;
-        position: absolute;
-        top: 25px;
-        right: 20px;
-        z-index: 1;
-}
-
-.cannot-expand .customize-section-title:after {
-        display: none;
-}
-
-.customize-section-title:hover:after,
-.customize-section-title:focus:after {
-        border-color: #aaa transparent;
-}
-
-.control-section .customize-section-title:hover:after,
-.control-section .customize-section-title:focus:after {
-        border-color: #eee transparent;
-}
-
-.control-section .customize-section-title:after {
-        top: 15px;
-}
-
-#customize-info .customize-section-content {
</del><ins>+#customize-info .accordion-section-content {
</ins><span class="cx">         background: transparent;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -158,7 +41,7 @@
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> #customize-theme-controls &gt; ul,
</span><del>-#customize-theme-controls .customize-section-content {
</del><ins>+#customize-theme-controls .accordion-section-content {
</ins><span class="cx">         margin: 0;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -245,7 +128,7 @@
</span><span class="cx"> /*
</span><span class="cx">  * Dropdowns
</span><span class="cx">  */
</span><del>-.customize-section .dropdown {
</del><ins>+.accordion-section .dropdown {
</ins><span class="cx">         float: left;
</span><span class="cx">         display: block;
</span><span class="cx">         position: relative;
</span><span class="lines">@@ -255,7 +138,7 @@
</span><span class="cx">         border-radius: 3px;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .dropdown-content {
</del><ins>+.accordion-section .dropdown-content {
</ins><span class="cx">         overflow: hidden;
</span><span class="cx">         float: left;
</span><span class="cx">         min-width: 30px;
</span><span class="lines">@@ -301,12 +184,12 @@
</span><span class="cx">         z-index: 1;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .dropdown:hover .dropdown-content,
</del><ins>+.accordion-section .dropdown:hover .dropdown-content,
</ins><span class="cx"> .customize-control .dropdown:hover .dropdown-arrow {
</span><span class="cx">         border-color: #aaa;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .dropdown:hover .dropdown-arrow:after {
</del><ins>+.accordion-section .dropdown:hover .dropdown-arrow:after {
</ins><span class="cx">         border-color: #aaa transparent;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -341,7 +224,7 @@
</span><span class="cx">         border-color: rgba( 0, 0, 0, 0.25 );
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section input[type=&quot;text&quot;].color-picker-hex {
</del><ins>+.accordion-section input[type=&quot;text&quot;].color-picker-hex {
</ins><span class="cx">         width: 65px;
</span><span class="cx">         font-family: monospace;
</span><span class="cx">         text-align: center;
</span><span class="lines">@@ -349,10 +232,10 @@
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> /* The centered cursor overlaps the placeholder in webkit. Hide it when selected. */
</span><del>-.customize-section input[type=&quot;text&quot;].color-picker-hex:focus::-webkit-input-placeholder {
</del><ins>+.accordion-section input[type=&quot;text&quot;].color-picker-hex:focus::-webkit-input-placeholder {
</ins><span class="cx">         color: transparent;
</span><span class="cx"> }
</span><del>-.customize-section input[type=&quot;text&quot;].color-picker-hex:-moz-placeholder {
</del><ins>+.accordion-section input[type=&quot;text&quot;].color-picker-hex:-moz-placeholder {
</ins><span class="cx">         color: #999;
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -371,18 +254,18 @@
</span><span class="cx">         display: block;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .dropdown-content {
</del><ins>+.accordion-section .customize-control-image .dropdown-content {
</ins><span class="cx">         height: auto;
</span><span class="cx">         min-height: 24px;
</span><span class="cx">         min-width: 40px;
</span><span class="cx">         padding: 0;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .dropdown-status {
</del><ins>+.accordion-section .customize-control-image .dropdown-status {
</ins><span class="cx">         padding: 4px 5px;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .preview-thumbnail img {
</del><ins>+.accordion-section .customize-control-image .preview-thumbnail img {
</ins><span class="cx">         display: block;
</span><span class="cx">         width: 100%;
</span><span class="cx">         max-width: 122px;
</span><span class="lines">@@ -390,18 +273,18 @@
</span><span class="cx">         margin: 0 auto;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .actions {
</del><ins>+.accordion-section .customize-control-image .actions {
</ins><span class="cx">         text-align: right;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .library ul {
</del><ins>+.accordion-section .customize-control-image .library ul {
</ins><span class="cx">         border-bottom: 1px solid #dfdfdf;
</span><span class="cx">         float: left;
</span><span class="cx">         width: 100%;
</span><span class="cx">         margin: 10px 0 0;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .library li {
</del><ins>+.accordion-section .customize-control-image .library li {
</ins><span class="cx">         color: #999;
</span><span class="cx">         float: left;
</span><span class="cx">         padding: 3px 5px;
</span><span class="lines">@@ -411,7 +294,7 @@
</span><span class="cx">         border-width: 1px 1px 0 1px;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .library li.library-selected {
</del><ins>+.accordion-section .customize-control-image .library li.library-selected {
</ins><span class="cx">         margin-bottom: -1px;
</span><span class="cx">         padding-bottom: 4px;
</span><span class="cx"> 
</span><span class="lines">@@ -422,27 +305,27 @@
</span><span class="cx">         border-radius: 3px 3px 0 0 ;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .library-content {
</del><ins>+.accordion-section .customize-control-image .library-content {
</ins><span class="cx">         display: none;
</span><span class="cx">         width: 100%;
</span><span class="cx">         float: left;
</span><span class="cx">         padding: 10px 0;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .library-content.library-selected {
</del><ins>+.accordion-section .customize-control-image .library-content.library-selected {
</ins><span class="cx">         display: block;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .library .thumbnail {
</del><ins>+.accordion-section .customize-control-image .library .thumbnail {
</ins><span class="cx">         display: block;
</span><span class="cx">         width: 100%;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .library .thumbnail:hover img {
</del><ins>+.accordion-section .customize-control-image .library .thumbnail:hover img {
</ins><span class="cx">         border-color: #21759b;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-image .library .thumbnail img {
</del><ins>+.accordion-section .customize-control-image .library .thumbnail img {
</ins><span class="cx">         display: block;
</span><span class="cx">         max-width: 90%;
</span><span class="cx">         max-height: 80px;
</span><span class="lines">@@ -453,13 +336,13 @@
</span><span class="cx">         border: 1px solid #dfdfdf;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-upload .upload-fallback,
-.customize-section .customize-control-image .upload-fallback {
</del><ins>+.accordion-section .customize-control-upload .upload-fallback,
+.accordion-section .customize-control-image .upload-fallback {
</ins><span class="cx">         display: none;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-upload .upload-dropzone,
-.customize-section .customize-control-image .upload-dropzone {
</del><ins>+.accordion-section .customize-control-upload .upload-dropzone,
+.accordion-section .customize-control-image .upload-dropzone {
</ins><span class="cx">         display: none;
</span><span class="cx">         padding: 15px 10px;
</span><span class="cx">         border: 3px dashed #dfdfdf;
</span><span class="lines">@@ -470,8 +353,8 @@
</span><span class="cx">         cursor: default;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-upload .upload-dropzone.supports-drag-drop,
-.customize-section .customize-control-image .upload-dropzone.supports-drag-drop {
</del><ins>+.accordion-section .customize-control-upload .upload-dropzone.supports-drag-drop,
+.accordion-section .customize-control-image .upload-dropzone.supports-drag-drop {
</ins><span class="cx">         display: block;
</span><span class="cx">         -webkit-transition: border-color 0.1s;
</span><span class="cx">         -moz-transition:    border-color 0.1s;
</span><span class="lines">@@ -480,13 +363,13 @@
</span><span class="cx">         transition:         border-color 0.1s;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-upload .library ul li,
-.customize-section .customize-control-image .library ul li {
</del><ins>+.accordion-section .customize-control-upload .library ul li,
+.accordion-section .customize-control-image .library ul li {
</ins><span class="cx">         cursor: pointer;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-.customize-section .customize-control-upload .upload-dropzone.supports-drag-drop.drag-over,
-.customize-section .customize-control-image .upload-dropzone.supports-drag-drop.drag-over {
</del><ins>+.accordion-section .customize-control-upload .upload-dropzone.supports-drag-drop.drag-over,
+.accordion-section .customize-control-image .upload-dropzone.supports-drag-drop.drag-over {
</ins><span class="cx">         border-color: #83b4d8;
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkwpadmincsswpadminrtlcss"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/css/wp-admin-rtl.css (23416 => 23417)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/css/wp-admin-rtl.css        2013-02-14 22:51:06 UTC (rev 23416)
+++ trunk/wp-admin/css/wp-admin-rtl.css        2013-02-14 22:58:04 UTC (rev 23417)
</span><span class="lines">@@ -2534,6 +2534,15 @@
</span><span class="cx">         direction: ltr;
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+.control-section .accordion-section-title {
+        font-family: Tahoma, Arial, sans-serif;
+}
+
+.accordion-section-title:after {
+        right: auto;
+        left: 20px;
+}
+
</ins><span class="cx"> /**
</span><span class="cx">  * HiDPI Displays
</span><span class="cx">  */
</span></span></pre></div>
<a id="trunkwpadmincsswpadmincss"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/css/wp-admin.css (23416 => 23417)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/css/wp-admin.css        2013-02-14 22:51:06 UTC (rev 23416)
+++ trunk/wp-admin/css/wp-admin.css        2013-02-14 22:58:04 UTC (rev 23417)
</span><span class="lines">@@ -8277,6 +8277,121 @@
</span><span class="cx">         -ms-touch-action: none;
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+/* Accordion */
+
+.accordion-section {
+        border-top: 1px solid #fff;
+        border-bottom: 1px solid #dfdfdf;
+        margin: 0;
+}
+
+.accordion-section:last-child {
+        box-shadow: 0 1px 0 0px #fff;
+}
+
+.accordion-section.open .accordion-section-content {
+        display: block;
+        background: #fdfdfd;
+}
+
+.accordion-section.open:hover {
+        border-bottom-color: #dfdfdf;
+}
+
+.accordion-section-content {
+        display: none;
+        padding: 10px 20px 15px;
+        overflow: hidden;
+}
+
+.accordion-section-title {
+        margin: 0;
+        padding: 15px 20px;
+        position: relative;
+
+        cursor: pointer;
+
+        -webkit-user-select: none;
+        -moz-user-select: none;
+        user-select: none;
+}
+
+.accordion-section-title:after {
+        content: '';
+        width: 0;
+        height: 0;
+        border-color: #ccc transparent;
+        border-style: solid;
+        border-width: 6px 6px 0;
+        position: absolute;
+        top: 25px;
+        right: 20px;
+        z-index: 1;
+}
+
+.accordion-section-title:focus {
+        outline: none;
+}
+
+.accordion-section-title:hover:after,
+.accordion-section-title:focus:after {
+        border-color: #aaa transparent;
+}
+
+.cannot-expand .accordion-section-title {
+        cursor: auto;
+}
+
+.cannot-expand .accordion-section-title:after {
+        display: none;
+}
+
+.control-section .accordion-section-title {
+        padding: 10px 20px;
+        font-size: 15px;
+        font-family: Georgia, &quot;Times New Roman&quot;, &quot;Bitstream Charter&quot;, Times, serif;
+        font-weight: normal;
+        text-shadow: 0 1px 0 #fff;
+        background: #f5f5f5;
+        background-image: -webkit-gradient(linear, left bottom, left top, from(#eee), to(#f5f5f5));
+        background-image: -webkit-linear-gradient(bottom, #eee, #f5f5f5);
+        background-image:    -moz-linear-gradient(bottom, #eee, #f5f5f5);
+        background-image:      -o-linear-gradient(bottom, #eee, #f5f5f5);
+        background-image: linear-gradient(to top, #eee, #f5f5f5);
+}
+
+.control-section .accordion-section-title:after {
+        top: 15px;
+}
+
+.control-section .accordion-section-title:hover:after,
+.control-section .accordion-section-title:focus:after {
+        border-color: #eee transparent;
+}
+
+.control-section:hover .accordion-section-title,
+.control-section .accordion-section-title:hover,
+.control-section.open .accordion-section-title,
+.control-section .accordion-section-title:focus {
+        color: #fff;
+        text-shadow: 0 -1px 0 #333;
+        background: #808080;
+        background-image: -webkit-gradient(linear, left bottom, left top, from(#6d6d6d), to(#808080));
+        background-image: -webkit-linear-gradient(bottom, #6d6d6d, #808080);
+        background-image:    -moz-linear-gradient(bottom, #6d6d6d, #808080);
+        background-image:      -o-linear-gradient(bottom, #6d6d6d, #808080);
+        background-image: linear-gradient(to top, #6d6d6d, #808080);
+}
+
+.control-section.accordion-section:hover,
+.control-section.accordion-section.open {
+        border-top-color: #808080;
+}
+
+.control-section.open .accordion-section-title {
+        border-bottom: 1px solid #6d6d6d;
+}
+
</ins><span class="cx"> /* =Media Queries
</span><span class="cx"> -------------------------------------------------------------- */
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkwpadmincustomizephp"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/customize.php (23416 => 23417)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/customize.php        2013-02-14 22:51:06 UTC (rev 23416)
+++ trunk/wp-admin/customize.php        2013-02-14 22:58:04 UTC (rev 23417)
</span><span class="lines">@@ -36,6 +36,8 @@
</span><span class="cx"> wp_enqueue_script( 'customize-controls' );
</span><span class="cx"> wp_enqueue_style( 'customize-controls' );
</span><span class="cx"> 
</span><ins>+wp_enqueue_script( 'accordion' );
+
</ins><span class="cx"> do_action( 'customize_controls_enqueue_scripts' );
</span><span class="cx"> 
</span><span class="cx"> // Let's roll.
</span><span class="lines">@@ -89,15 +91,15 @@
</span><span class="cx">                 ?&gt;
</span><span class="cx"> 
</span><span class="cx">                 &lt;div class=&quot;wp-full-overlay-sidebar-content&quot; tabindex=&quot;-1&quot;&gt;
</span><del>-                        &lt;div id=&quot;customize-info&quot; class=&quot;customize-section&lt;?php if ( $cannot_expand ) echo ' cannot-expand'; ?&gt;&quot;&gt;
-                                &lt;div class=&quot;customize-section-title&quot; aria-label=&quot;&lt;?php esc_attr_e( 'Theme Customizer Options' ); ?&gt;&quot; tabindex=&quot;0&quot;&gt;
</del><ins>+                        &lt;div id=&quot;customize-info&quot; class=&quot;accordion-section&lt;?php if ( $cannot_expand ) echo ' cannot-expand'; ?&gt;&quot;&gt;
+                                &lt;div class=&quot;accordion-section-title&quot; aria-label=&quot;&lt;?php esc_attr_e( 'Theme Customizer Options' ); ?&gt;&quot; tabindex=&quot;0&quot;&gt;
</ins><span class="cx">                                         &lt;span class=&quot;preview-notice&quot;&gt;&lt;?php
</span><span class="cx">                                                 /* translators: %s is the theme name in the Customize/Live Preview pane */
</span><span class="cx">                                                 echo sprintf( __( 'You are previewing %s' ), '&lt;strong class=&quot;theme-name&quot;&gt;' . $wp_customize-&gt;theme()-&gt;display('Name') . '&lt;/strong&gt;' );
</span><span class="cx">                                         ?&gt;&lt;/span&gt;
</span><span class="cx">                                 &lt;/div&gt;
</span><span class="cx">                                 &lt;?php if ( ! $cannot_expand ) : ?&gt;
</span><del>-                                &lt;div class=&quot;customize-section-content&quot;&gt;
</del><ins>+                                &lt;div class=&quot;accordion-section-content&quot;&gt;
</ins><span class="cx">                                         &lt;?php if ( $screenshot ) : ?&gt;
</span><span class="cx">                                                 &lt;img class=&quot;theme-screenshot&quot; src=&quot;&lt;?php echo esc_url( $screenshot ); ?&gt;&quot; /&gt;
</span><span class="cx">                                         &lt;?php endif; ?&gt;
</span><span class="lines">@@ -109,7 +111,7 @@
</span><span class="cx">                                 &lt;?php endif; ?&gt;
</span><span class="cx">                         &lt;/div&gt;
</span><span class="cx"> 
</span><del>-                        &lt;div id=&quot;customize-theme-controls&quot;&gt;&lt;ul&gt;
</del><ins>+                        &lt;div id=&quot;customize-theme-controls&quot; class=&quot;accordion-container&quot;&gt;&lt;ul&gt;
</ins><span class="cx">                                 &lt;?php
</span><span class="cx">                                 foreach ( $wp_customize-&gt;sections() as $section )
</span><span class="cx">                                         $section-&gt;maybe_render();
</span></span></pre></div>
<a id="trunkwpadminjsaccordionjs"></a>
<div class="addfile"><h4>Added: trunk/wp-admin/js/accordion.js (0 => 23417)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/js/accordion.js                                (rev 0)
+++ trunk/wp-admin/js/accordion.js        2013-02-14 22:58:04 UTC (rev 23417)
</span><span class="lines">@@ -0,0 +1,51 @@
</span><ins>+jQuery(document).ready( function($) {
+        // Expand/Collapse
+        $('.accordion-section-title').on('click keydown', function( event ) {
+
+                if ( event.type === 'keydown' &amp;&amp;  13 !== event.which ) // enter
+                                return;
+
+                var clicked = $( this ).closest( '.accordion-section' );
+
+                if ( clicked.hasClass('cannot-expand') )
+                        return;
+
+                clicked.closest( '.accordion-container' ).find( '.accordion-section' ).not( clicked ).removeClass( 'open' );
+                clicked.toggleClass( 'open' );
+                event.preventDefault();
+        });
+});
+jQuery(document).ready( function($) {
+        // Expand/Collapse
+        $('.accordion-section-title').on('click keydown', function( event ) {
+
+                if ( event.type === 'keydown' &amp;&amp;  13 !== event.which ) // enter
+                                return;
+
+                var clicked = $( this ).closest( '.accordion-section' );
+
+                if ( clicked.hasClass('cannot-expand') )
+                        return;
+
+                clicked.closest( '.accordion-container' ).find( '.accordion-section' ).not( clicked ).removeClass( 'open' );
+                clicked.toggleClass( 'open' );
+                event.preventDefault();
+        });
+});
+jQuery(document).ready( function($) {
+        // Expand/Collapse
+        $('.accordion-section-title').on('click keydown', function( event ) {
+
+                if ( event.type === 'keydown' &amp;&amp;  13 !== event.which ) // enter
+                                return;
+
+                var clicked = $( this ).closest( '.accordion-section' );
+
+                if ( clicked.hasClass('cannot-expand') )
+                        return;
+
+                clicked.closest( '.accordion-container' ).find( '.accordion-section' ).not( clicked ).removeClass( 'open' );
+                clicked.toggleClass( 'open' );
+                event.preventDefault();
+        });
+});
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkwpadminjscustomizecontrolsjs"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/js/customize-controls.js (23416 => 23417)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/js/customize-controls.js        2013-02-14 22:51:06 UTC (rev 23416)
+++ trunk/wp-admin/js/customize-controls.js        2013-02-14 22:58:04 UTC (rev 23417)
</span><span class="lines">@@ -846,26 +846,6 @@
</span><span class="cx">                         api.state = state;
</span><span class="cx">                 }());
</span><span class="cx"> 
</span><del>-                // Temporary accordion code.
-                $('.customize-section-title').bind('click keydown', function( event ) {
-
-                        if ( event.type === 'keydown' &amp;&amp;  13 !== event.which ) // enter
-                                        return;
-
-                        var clicked = $( this ).parents( '.customize-section' );
-
-                        if ( clicked.hasClass('cannot-expand') )
-                                return;
-
-                        // Scroll up if on #customize-section-title_tagline
-                        if ('customize-section-title_tagline' === clicked.attr('id'))
-                                $('.wp-full-overlay-sidebar-content').scrollTop(0);
-
-                        $( '.customize-section' ).not( clicked ).removeClass( 'open' );
-                        clicked.toggleClass( 'open' );
-                        event.preventDefault();
-                });
-
</del><span class="cx">                 // Button bindings.
</span><span class="cx">                 $('#save').click( function( event ) {
</span><span class="cx">                         previewer.save();
</span></span></pre></div>
<a id="trunkwpincludesclasswpcustomizesectionphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/class-wp-customize-section.php (23416 => 23417)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/class-wp-customize-section.php        2013-02-14 22:51:06 UTC (rev 23416)
+++ trunk/wp-includes/class-wp-customize-section.php        2013-02-14 22:58:04 UTC (rev 23417)
</span><span class="lines">@@ -79,9 +79,9 @@
</span><span class="cx">          */
</span><span class="cx">         protected function render() {
</span><span class="cx">                 ?&gt;
</span><del>-                &lt;li id=&quot;customize-section-&lt;?php echo esc_attr( $this-&gt;id ); ?&gt;&quot; class=&quot;control-section customize-section&quot;&gt;
-                        &lt;h3 class=&quot;customize-section-title&quot; tabindex=&quot;0&quot; title=&quot;&lt;?php echo esc_attr( $this-&gt;description ); ?&gt;&quot;&gt;&lt;?php echo esc_html( $this-&gt;title ); ?&gt;&lt;/h3&gt;
-                        &lt;ul class=&quot;customize-section-content&quot;&gt;
</del><ins>+                &lt;li id=&quot;accordion-section-&lt;?php echo esc_attr( $this-&gt;id ); ?&gt;&quot; class=&quot;control-section accordion-section&quot;&gt;
+                        &lt;h3 class=&quot;accordion-section-title&quot; tabindex=&quot;0&quot; title=&quot;&lt;?php echo esc_attr( $this-&gt;description ); ?&gt;&quot;&gt;&lt;?php echo esc_html( $this-&gt;title ); ?&gt;&lt;/h3&gt;
+                        &lt;ul class=&quot;accordion-section-content&quot;&gt;
</ins><span class="cx">                                 &lt;?php
</span><span class="cx">                                 foreach ( $this-&gt;controls as $control )
</span><span class="cx">                                         $control-&gt;maybe_render();
</span></span></pre></div>
<a id="trunkwpincludesscriptloaderphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/script-loader.php (23416 => 23417)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/script-loader.php        2013-02-14 22:51:06 UTC (rev 23416)
+++ trunk/wp-includes/script-loader.php        2013-02-14 22:58:04 UTC (rev 23417)
</span><span class="lines">@@ -107,7 +107,7 @@
</span><span class="cx">         ) );
</span><span class="cx"> 
</span><span class="cx">         $scripts-&gt;add( 'autosave', &quot;/wp-includes/js/autosave$suffix.js&quot;, array('schedule', 'wp-ajax-response'), false, 1 );
</span><del>-        
</del><ins>+
</ins><span class="cx">         $scripts-&gt;add( 'heartbeat', &quot;/wp-includes/js/heartbeat$suffix.js&quot;, array('jquery'), false, 1 );
</span><span class="cx">         did_action( 'init' ) &amp;&amp; $scripts-&gt;localize( 'heartbeat', 'heartbeatSettings',
</span><span class="cx">                 apply_filters( 'heartbeat_settings', array() )
</span><span class="lines">@@ -331,6 +331,8 @@
</span><span class="cx">                 'allowedFiles' =&gt; __( 'Allowed Files' ),
</span><span class="cx">         ) );
</span><span class="cx"> 
</span><ins>+        $scripts-&gt;add( 'accordion', &quot;/wp-admin/js/accordion$suffix.js&quot;, array( 'jquery' ), false, 1 );
+
</ins><span class="cx">         $scripts-&gt;add( 'shortcode', &quot;/wp-includes/js/shortcode$suffix.js&quot;, array( 'underscore' ), false, 1 );
</span><span class="cx">         $scripts-&gt;add( 'media-models', &quot;/wp-includes/js/media-models$suffix.js&quot;, array( 'backbone', 'jquery' ), false, 1 );
</span><span class="cx">         did_action( 'init' ) &amp;&amp; $scripts-&gt;localize( 'media-models', '_wpMediaModelsL10n', array(
</span></span></pre>
</div>
</div>

</body>
</html>