Skip to content

Select doesn't work when wrapped in Label #494

Closed
@gleblebedev

Description

@gleblebedev

Documentation says:

A target element can be specified by providing an ID in the for attribute. Otherwise, when omitted, the label will target the first descending element which has one of the following tags: <button>, <input>, <textarea>, <progress>, or <select>.

But when select is wrapped in label the value doesn't change:

<label>
some label
	<select data-value="select_value">
		<option value="0">0</option>
		<option value="1">1</option>
		<option value="2">2</option>
		<option value="3">3</option>
	</select>
<label>

I've tried to debug and it seems that WidgetDropDown::ProcessEvent doesn't get callback on selected element.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions