Closed (won't fix)
Project:
MaxLength
Version:
7.x-3.x-dev
Component:
User interface
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
28 Aug 2014 at 21:32 UTC
Updated:
26 Aug 2021 at 17:28 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
damienmckennaThat would be useful for integration with e.g. Metatag (#1918738: Character count on fields via Maxlength integration (D7)).
Comment #2
jeroentI created a simple initial patch for this. I added a new element to the form 'maxlength_js_limit'.
How to test? Add maxlength_js and maxlength_js_limit to your form element :
I add the 'maxlength_js_limit' as a data-attribute on the form element and in javascript, I check if this data-maxlength-js-limit attribute exists. When it exists, I set the enforce option to false.
What do you think? Any suggestions?
Comment #3
seanbSeems to work fine! +1
Comment #4
damienmckennaOne minuscule thing - the "if" statements should have a space after them for both files to match the Drupal coding standards.
Comment #5
jeroentAdded the code styling updates.
Comment #6
jeroentComment #7
weri commentedThis is related to #1841028: Add field setting "Do not restrict maxlength on writing"
Comment #8
damienmckenna@weri: The link you provided was to this issue, did you mean to link to a different one?
Comment #9
weri commentedThank you @DamienMcKenna for the hint!! I linked now the correct issue.
Comment #10
cedeweyWe are putting a feature freeze on the Drupal 7 version of the module, so I'm marking this Closed, won't fix. Thank you everyone for working on this issue. If you do want to maintain the Drupal 7 version, do reach out. We'd be happy to bring you on board as a maintainer.
Also, this is a feature that exists in the Drupal 8/9 version so I do encourage people to upgrade to Drupal 8/9 and enjoy this enhancement along with the many other benefits of the latest version of Drupal.