(function ($) {
    $.expandingTextarea = $.extend({
        autoInitialize: true,
        initialSelector: "textarea.expanding"
    }, $.expandingTextarea || {});
    
    var cloneCSSProperties = [
        'lineHeight', 'textDecoration', 'letterSpacing',
        'fontSize', 'fontFamily', 'fontStyle', 
        'fontWeight', 'textTransform', 'textAlign', 
        'direction', 'wordSpacing', 'fontSizeAdjust', 
        'whiteSpace', 'wordWrap', 
        'borderLeftWidth', 'borderRightWidth',
        'borderTopWidth','borderBottomWidth',
        'paddingLeft', 'paddingRight',
        'paddingTop','paddingBottom',
        'marginLeft', 'marginRight',
        'marginTop','marginBottom',
        'boxSizing', 'webkitBoxSizing', 'mozBoxSizing', 'msBoxSizing'
    ];
    
    var textareaCSS = {
        position: "absolute",
        height: "100%",
        resize: "none"
    };
    
    var preCSS = {
        visibility: "hidden",
        border: "0 solid"
    };
    
    var containerCSS = {
        position: "relative"
    };
    
    function resize() {
        $(this).closest('.expandingText').find("div").text(this.value + ' ');
    }
    
    $.fn.expandingTextarea = function(o) {
        
        if (o === "resize") {
            return this.trigger("input.expanding");
        }
        
        if (o === "destroy") {
            this.filter(".expanding-init").removeClass('expanding-init').each(function() {
                var textarea = $(this);
                var container = textarea.closest('.expandingText');
                
                textarea
                    .insertBefore(container)
                    .attr('style', textarea.data('originalStyle') || '')
                    .removeData('originalStyle');
                
                container.remove();
            });
            
            return this;
        }
        
        this.filter("textarea").not(".expanding-init").each(function() {
            var textarea = $(this).addClass("expanding-init");
            
            
            textarea.wrap("<div class='expandingText'></div>");
            textarea.after("<pre class='textareaClone'><div></div></pre>");
            
            var container = textarea.parent().css(containerCSS);
            var pre = container.find("pre").css(preCSS);
            
            // Store the original styles for destroying
            textarea.data('originalStyle', textarea.attr('style'));
            
            textarea.css(textareaCSS);
            
            $.each(cloneCSSProperties, function(i, p) {
                var val = textarea.css(p);
                
                // Only set if different to prevent overriding percentage css
                // values
                if (pre.css(p) !== val) {
                    pre.css(p, val);
                }
            });
            
            textarea.bind("input.expanding propertychange.expanding", resize);
            resize.apply(this);
        });
        
        return this;
    };
    
    $(function () {
        if ($.expandingTextarea.autoInitialize) {
            $($.expandingTextarea.initialSelector).expandingTextarea();
        }
    });
    
})(jQuery);

@@ -1665,29 +1665,32 @@
 a.data('
-originalS
+expanding-s
 tyle
+s
 ') %7C%7C ''
@@ -1724,29 +1724,32 @@
 veData('
-originalS
+expanding-s
 tyle
+s
 ');%0A    
@@ -2375,16 +2375,23 @@
 stroying
+ later.
 %0A       
@@ -2414,21 +2414,24 @@
 ta('
-originalS
+expanding-s
 tyle
+s
 ', t
@@ -2454,29 +2454,16 @@
 yle'));%0A
-            %0A
         

namespace the data name