Expand textareas to fit content
Texpand class provides a way to expand textareas to fit it's contents. It is possible to provide minimal or maximal values to restrict possible textarea dimensions
Contents
Download
Example codes
<!DOCTYPE html> <html> <head> </head> <body> <textarea id='expand'></textarea> <script type="text/javascript" src="./texpand.packed.js" ></script> <script type="text/javascript"> var te = new texpand("expand"); </script> </body> </html>
Live Examples
This textarea will expand, when you'll write something in it
Examples in action
Method list
Constructor
| Method name | new texpand(id, config); |
| Description | Create expandable textarea |
| Input parameters | string or HTML element id - id of textarea or textarea element itself json config - Json structure with configuration properties
|
| Example input | var ta = new texpand("expandable",
{
minWidth: 100,
maxWidth: "auto",
minHeight: 30,
maxHeight: "auto"
}); |
Latest changes
None for nowYou may also be interested in:
Powered by BlogAlike.com










