HomePhabricator

HTMLRadioField: Do not automatically infuse our RadioSelectInputWidgets
f2a83fe4ac1cUnpublished

Authored by matmarex on Nov 16 2017, 4:14 PM.

Unpublished Commit · Learn More

Publishing Disabled: All publishing is disabled for this repository.

Description

HTMLRadioField: Do not automatically infuse our RadioSelectInputWidgets

This is really a workaround for an issue in a completely different place:
JS RadioSelectInputWidget internally uses <input type="hidden">
rather than real radio buttons, which does not work correctly with the
code in mediawiki.special.preferences.confirmClose.js. Ideally we would
change RadioSelectInputWidget to not do such weird things.

However, I think this is actually a good thing to do in general.
From the user's perspective, PHP RadioSelectInputWidget and JS
RadioSelectInputWidget look and behave the same, so there's no reason
to infuse and rebuild them.

This behavior was implemented in f50cee1375201a5d3fd76c0c262cfc7e66bd5d42
in which unfortunately I did not document the reason for it. For other
fields it makes obvious sense (the JS widgets have improvements like
autocompletion, or at least look "pretty"), but I have no idea why
I did it for this one.

Bug: T180643
Change-Id: I53e50f8cda39466b2396b374e642c154487888bb

Details

Committed
matmarexNov 16 2017, 4:33 PM
Parents
rMW9732ccc739b0: Merge "Hide empty OOUI FieldsetLayout headers"
Branches
Unknown
Tags
Unknown
References
refs/changes/61/391861/1
ChangeId
I53e50f8cda39466b2396b374e642c154487888bb