Skip to content

Commit ab088cb

Browse files
committed
rebuild pages at a879843
1 parent e6d4a57 commit ab088cb

File tree

4 files changed

+30
-21
lines changed

4 files changed

+30
-21
lines changed

doc/main.js

Lines changed: 24 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -806,23 +806,31 @@
806806
window.location = $('.srclink').attr('href');
807807
}
808808

809-
$("#expand-all").on("click", function() {
810-
$(".docblock").show();
811-
$(".toggle-label").hide();
812-
$(".toggle-wrapper").removeClass("collapsed");
813-
$(".collapse-toggle").children(".inner").html("-");
814-
});
815-
816-
$("#collapse-all").on("click", function() {
817-
$(".docblock").hide();
818-
$(".toggle-label").show();
819-
$(".toggle-wrapper").addClass("collapsed");
820-
$(".collapse-toggle").children(".inner").html("+");
809+
$("#toggle-all-docs").on("click", function() {
810+
var toggle = $("#toggle-all-docs");
811+
if (toggle.html() == "[-]") {
812+
toggle.html("[+]");
813+
toggle.attr("title", "expand all docs");
814+
$(".docblock").hide();
815+
$(".toggle-label").show();
816+
$(".toggle-wrapper").addClass("collapsed");
817+
$(".collapse-toggle").children(".inner").html("+");
818+
} else {
819+
toggle.html("[-]");
820+
toggle.attr("title", "collapse all docs");
821+
$(".docblock").show();
822+
$(".toggle-label").hide();
823+
$(".toggle-wrapper").removeClass("collapsed");
824+
$(".collapse-toggle").children(".inner").html("-");
825+
}
821826
});
822827

823828
$(document).on("click", ".collapse-toggle", function() {
824829
var toggle = $(this);
825830
var relatedDoc = toggle.parent().next();
831+
if (relatedDoc.is(".stability")) {
832+
relatedDoc = relatedDoc.next();
833+
}
826834
if (relatedDoc.is(".docblock")) {
827835
if (relatedDoc.is(":visible")) {
828836
relatedDoc.slideUp({duration:'fast', easing:'linear'});
@@ -843,9 +851,10 @@
843851
.html("[<span class='inner'>-</span>]");
844852

845853
$(".method").each(function() {
846-
if ($(this).next().is(".docblock")) {
847-
$(this).children().first().after(toggle.clone());
848-
}
854+
if ($(this).next().is(".docblock") ||
855+
($(this).next().is(".stability") && $(this).next().next().is(".docblock"))) {
856+
$(this).children().first().after(toggle.clone());
857+
}
849858
});
850859

851860
var mainToggle =

doc/r2d2_postgres/enum.Error.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@
4242

4343
<section id='main' class="content enum">
4444
<h1 class='fqn'><span class='in-band'>Enum <a href='index.html'>r2d2_postgres</a>::<wbr><a class='enum' href=''>Error</a></span><span class='out-of-band'><span id='render-detail'>
45-
<a id="collapse-all" href="#">[-]</a>&nbsp;<a id="expand-all" href="#">[+]</a>
46-
</span><a id='src-12' class='srclink' href='../src/r2d2_postgres/lib.rs.html#14-19'>[src]</a></span></h1>
45+
<a id="toggle-all-docs" href="#" title="collapse all docs">[-]</a>
46+
</span><a id='src-12' class='srclink' href='../src/r2d2_postgres/lib.rs.html#14-19' title='goto source code'>[src]</a></span></h1>
4747
<pre class='rust enum'>pub enum Error {
4848
Connect(<a class='enum' href='https://sfackler.github.io/rust-postgres/doc/postgres/error/enum.ConnectError.html' title='postgres::error::ConnectError'>ConnectError</a>),
4949
Other(<a class='enum' href='https://sfackler.github.io/rust-postgres/doc/postgres/error/enum.Error.html' title='postgres::error::Error'>Error</a>),

doc/r2d2_postgres/index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@
4242

4343
<section id='main' class="content mod">
4444
<h1 class='fqn'><span class='in-band'>Crate <a class='mod' href=''>r2d2_postgres</a></span><span class='out-of-band'><span id='render-detail'>
45-
<a id="collapse-all" href="#">[-]</a>&nbsp;<a id="expand-all" href="#">[+]</a>
46-
</span><a id='src-0' class='srclink' href='../src/r2d2_postgres/lib.rs.html#1-110'>[src]</a></span></h1>
45+
<a id="toggle-all-docs" href="#" title="collapse all docs">[-]</a>
46+
</span><a id='src-0' class='srclink' href='../src/r2d2_postgres/lib.rs.html#1-110' title='goto source code'>[src]</a></span></h1>
4747
<div class='docblock'><p>Postgres support for the <code>r2d2</code> connection pool.</p>
4848
</div><h2 id='structs' class='section-header'><a href="#structs">Structs</a></h2>
4949
<table>

doc/r2d2_postgres/struct.PostgresConnectionManager.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@
4242

4343
<section id='main' class="content struct">
4444
<h1 class='fqn'><span class='in-band'>Struct <a href='index.html'>r2d2_postgres</a>::<wbr><a class='struct' href=''>PostgresConnectionManager</a></span><span class='out-of-band'><span id='render-detail'>
45-
<a id="collapse-all" href="#">[-]</a>&nbsp;<a id="expand-all" href="#">[+]</a>
46-
</span><a id='src-171' class='srclink' href='../src/r2d2_postgres/lib.rs.html#76-79'>[src]</a></span></h1>
45+
<a id="toggle-all-docs" href="#" title="collapse all docs">[-]</a>
46+
</span><a id='src-171' class='srclink' href='../src/r2d2_postgres/lib.rs.html#76-79' title='goto source code'>[src]</a></span></h1>
4747
<pre class='rust struct'>pub struct PostgresConnectionManager {
4848
// some fields omitted
4949
}</pre><div class='docblock'><p>An <code>r2d2::ConnectionManager</code> for <code>postgres::Connection</code>s.</p>

0 commit comments

Comments
 (0)