Bug fix: Update textarea and input elements to properly handle the maxlength attribute. Includes unit tests to test functionality. Addresses issue #49