Commit: e9757923797c251bc1a26dd5302a6d1160f4444f

Author: gwoo | Date: 2010-03-08 17:20:40 -0800
fixing up source display from bad merge
diff --git a/views/browser/view.html.php b/views/browser/view.html.php index d8e6594..1dcde38 100644 --- a/views/browser/view.html.php +++ b/views/browser/view.html.php @@ -118,7 +118,7 @@ $this->title($namespace); <?php // Method source ?> <?php if (isset($object['source'])) { ?> <pre class="source-code"> - <code><?php echo $object['source']; ?></code> + <code class="php"><?php echo $object['source']; ?></code> </pre> <button class="source-toggle">Show source</button> <?php } ?> diff --git a/views/layouts/default.html.php b/views/layouts/default.html.php index 86c944c..345b33c 100644 --- a/views/layouts/default.html.php +++ b/views/layouts/default.html.php @@ -63,13 +63,12 @@ $(".markdown").each(function () { $(this).html(converter.makeHtml($.trim($(this).text()))); }); - - $('pre code').hide(); + $('pre.source-code').hide(); $('.source-toggle').bind('click', function() { - visible = $('pre code').is(':visible'); + visible = $('pre.source-code').is(':visible'); $(this).text((visible ? 'Show' : 'Hide') + ' source'); - visible ? $('pre code').slideUp() : $('pre code').slideDown(); + visible ? $('pre.source-code').slideUp() : $('pre.source-code').slideDown(); }); hljs.initHighlightingOnLoad(); });