jenkins-bot has submitted this change and it was merged. Change subject: TextInputWidget: Allow maxLength of 0 in JS (matching PHP) ......................................................................
TextInputWidget: Allow maxLength of 0 in JS (matching PHP) While it's silly, the HTML specs permits it, and we need to be consistent one way or the other. http://www.w3.org/TR/html5/forms.html#attr-fe-maxlength Change-Id: I321310113dca413562885549c9b2fae206163dc6 --- M src/widgets/TextInputWidget.js 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Ricordisamoa: Looks good to me, but someone else must approve Krinkle: Looks good to me, approved Jforrester: Looks good to me, approved jenkins-bot: Verified diff --git a/src/widgets/TextInputWidget.js b/src/widgets/TextInputWidget.js index 6b2df7b..2d3ee3a 100644 --- a/src/widgets/TextInputWidget.js +++ b/src/widgets/TextInputWidget.js @@ -77,7 +77,7 @@ if ( config.placeholder ) { this.$input.attr( 'placeholder', config.placeholder ); } - if ( config.maxLength ) { + if ( config.maxLength !== undefined ) { this.$input.attr( 'maxlength', config.maxLength ); } if ( config.autofocus ) { -- To view, visit https://gerrit.wikimedia.org/r/190943 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I321310113dca413562885549c9b2fae206163dc6 Gerrit-PatchSet: 4 Gerrit-Project: oojs/ui Gerrit-Branch: master Gerrit-Owner: Bartosz DziewoĆski <matma....@gmail.com> Gerrit-Reviewer: Jforrester <jforres...@wikimedia.org> Gerrit-Reviewer: Krinkle <krinklem...@gmail.com> Gerrit-Reviewer: Ricordisamoa <ricordisa...@openmailbox.org> Gerrit-Reviewer: jenkins-bot <> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits