Textarea
A multi-line text input component with optional auto-resize functionality. Supports both form builder mode (with Rails form objects) and standalone usage. Includes label, hint text, error states, and character count display.
Preview & Code
_textarea.html.erb
███
████████ █████████ █████████
█████ ████ ████ ████████
███ █████████ ██████ █████ ██ ███ ██
███ ██████ ██████████████████████ █████ ██ ██████████ ██████ █████ ██ ████████████ ████ ██
██ ███ ██
██████████ ██████
███ ██████ ██████████████████████ █████ ██████████ ████████████ ██████ ████ ████████████ ███████████ ███ ██
textarea_controller.js
██████ █ ██████████ █ ████ ████████████████████
██████ ███████ █████ ███████ ██████████ █
██████ ███████ █ █████████ ██████████
██████ ██████ █ █
██████████ ███████
███████████ █ █████ ████████ ████████ █████ █
█
█████████ █
textarea_component.rb
█ ██████████████████████ ████
█████ █████████████████ █ ███████████████████
███████████ ██████ ███████████ ██████ ███████ ███████ ██████ █████████████
██████ ████████████ █████████████ ██████████ ██████████ ██████
███ ███████████
█████ ████
██████████ ████
█████ ████
textarea_component.html.erb
████ ██████████████ ███ ████████████████████ ████████████████ ███
██ ██ ███████████████ ██
██████ ████████ ████████ ███ ██████████ █████████████ ████
███ ██████ ██
██ ██ █████████ ██
█████ ███████████████████ ████████████████
██ ███ ██
████████
██ ███ ██
textarea_controller.js
██████ █ ██████████ █ ████ ████████████████████
██████ ███████ █████ ███████ ██████████ █
██████ ███████ █ █████████ ██████████
██████ ██████ █ █
██████████ ███████
███████████ █ █████ ████████ ████████ █████ █
█
█████████ █
Changelog
- Initial release with form builder and standalone modes
- Auto-resize functionality via Stimulus controller
- Character count display with max_length option
- Dark mode support
Get Full Access
Unlock the source code for this component and all others. One-time payment for lifetime access.
Get Access Now