User tests: Successful: Unsuccessful:
Change made last month in a subform
field broke subform support when there is a joomla.form.field.radio.switcher
(and most likely joomla.form.field.radio.buttons
) layout set on the field. The result is Uncaught TypeError like this
In short, the script is looking for a radio
class in element parents. Where the script itself works fine, the switcher
and buttons
layout for the radio field lacks the radio
class on a fieldset.
Added radio
class to joomla.form.field.radio.switcher
and joomla.form.field.radio.buttons
layouts.
Add this field XML to any of the core modules like (eg mod_banners
) and try to add new row in this field:
<field name="fields" type="subform"
multiple="true"
label="Fields"
>
<form>
<field name="checkboxes"
type="checkboxes"
label="Checkboxes"
>
<option value="0">JNO</option>
<option value="1">JYES</option>
</field>
<field name="radio"
type="radio"
label="Radio"
layout="joomla.form.field.radio.switcher"
>
<option value="0">JNO</option>
<option value="1">JYES</option>
</field>
</form>
</field>
Uncaught TypeError: can't access property "nodeName", b is null
New row in a subform is added
Please select:
Documentation link for docs.joomla.org:
No documentation changes for docs.joomla.org needed
Pull Request link for manual.joomla.org:
No documentation changes for manual.joomla.org needed
Status | New | ⇒ | Pending |
Category | ⇒ | Layout |
@Fedik @richard67 #43804 Will fix it too so no need to waste time on testing. Was searching for the ticket before creating PR but could not find it.
Status | Pending | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2024-08-06 09:47:03 |
Closed_By | ⇒ | artur-stepien | |
Labels |
Added:
PR-5.1-dev
|
@artur-stepien Thanks for checking.
@artur-stepien Is it the same issue as reported with issue #43800 ? If so, there is a PR already: #43804 . To me it seems to be the same issue but that PR and yours here solve it in different ways. Could you check the other PR?