This repository has been archived on 2025-02-01. You can view files and clone it, but cannot push or open issues or pull requests.
reprapfirmware-dc42/SD-image/www/js/jquery.textarea_autosize.min.js
David Crocker 8d99d640b8 Version 1.09x-beta3
Merged in chrishamm's changes to Network, PrintMonitor, and his support
for firmware updates from SD card
Fixed print monitor issue that threw out the layer count and time
estimates when there was an initial extruder priming move in the start
gcode
2016-03-11 18:03:41 +00:00

1 line
661 B
JavaScript

!function(t,e,i,n){function h(e,i){this.element=e,this.$element=t(e),this.init()}var s="textareaAutoSize",o="plugin_"+s,l=function(t){return t.replace(/\s/g,"").length>0};h.prototype={init:function(){var i=(this.$element.outerHeight(),parseInt(this.$element.css("paddingBottom"))+parseInt(this.$element.css("paddingTop"))||0);l(this.element.value)&&this.$element.height(this.element.scrollHeight-i),this.$element.on("input keyup",function(n){var h=t(e),s=h.scrollTop();t(this).height(0).height(this.scrollHeight-i),h.scrollTop(s)})}},t.fn[s]=function(e){return this.each(function(){t.data(this,o)||t.data(this,o,new h(this,e))}),this}}(jQuery,window,document);