diff options
author | friendica <info@friendica.com> | 2012-07-24 23:33:42 -0700 |
---|---|---|
committer | friendica <info@friendica.com> | 2012-07-24 23:33:42 -0700 |
commit | 2534075afe1b56396221a58a66051a3b7ae2f21d (patch) | |
tree | 913a91f13774fe6391ef285cfc6c958ddc4f059a /library/jquery.divgrow/jquery.divgrow-1.3.1.min.js | |
parent | 6911beca2f1d88a9e26c1dc110b2547a1b075951 (diff) | |
download | volse-hubzilla-2534075afe1b56396221a58a66051a3b7ae2f21d.tar.gz volse-hubzilla-2534075afe1b56396221a58a66051a3b7ae2f21d.tar.bz2 volse-hubzilla-2534075afe1b56396221a58a66051a3b7ae2f21d.zip |
see if this works for getting rid of scrollbars
Diffstat (limited to 'library/jquery.divgrow/jquery.divgrow-1.3.1.min.js')
-rw-r--r-- | library/jquery.divgrow/jquery.divgrow-1.3.1.min.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/library/jquery.divgrow/jquery.divgrow-1.3.1.min.js b/library/jquery.divgrow/jquery.divgrow-1.3.1.min.js new file mode 100644 index 000000000..fd08f7fa8 --- /dev/null +++ b/library/jquery.divgrow/jquery.divgrow-1.3.1.min.js @@ -0,0 +1 @@ +(function ($) { var divgrowid = 0; $.fn.divgrow = function (options) { var options = $.extend({}, { initialHeight: 100, moreText: "+ Show More", lessText: "- Show Less", speed: 1000, showBrackets: true }, options); return this.each(function () { divgrowid++; obj = $(this); var fullHeight = obj.height() + 10; obj.css('height', options.initialHeight).css('overflow', 'hidden'); if (options.showBrackets) { obj.after('<p class="divgrow-brackets">[…]</p><a href="#" class="divgrow-showmore' + " divgrow-obj-" + divgrowid + '"' + '></a>') } else { obj.after('<a href="#" class="divgrow-showmore' + " divgrow-obj-" + divgrowid + '"' + '></a>') } $("a.divgrow-showmore").html(options.moreText); $("." + "divgrow-obj-" + divgrowid).toggle(function () { $(this).prevAll("div:first").animate({ height: fullHeight + "px" }, options.speed, function () { if (options.showBrackets) { $(this).nextAll("p.divgrow-brackets:first").fadeOut() } $(this).nextAll("a.divgrow-showmore:first").html(options.lessText) }) }, function () { $(this).prevAll("div:first").stop(true, false).animate({ height: options.initialHeight }, options.speed, function () { if (options.showBrackets) { $(this).nextAll("p.divgrow-brackets:first").stop(true, false).fadeIn() } $(this).nextAll("a.divgrow-showmore:first").stop(true, false).html(options.moreText) }) }) }) } })(jQuery);
\ No newline at end of file |