MDL-68167 lib: Fix label for autocomplete selection/suggestion box
authorShamim Rezaie <shamim@moodle.com>
Tue, 28 Jul 2020 16:45:30 +0000 (02:45 +1000)
committerShamim Rezaie <shamim@moodle.com>
Fri, 30 Oct 2020 05:08:40 +0000 (16:08 +1100)
commit7931148cbbee77a17c7f5f20a2d1c1c9b56d6d96
tree5e751b5448364d0c1439ca8da43530d0ebd7e4b5
parent1031836d89a4e96680af45089ff679e73e0070c7
MDL-68167 lib: Fix label for autocomplete selection/suggestion box

The content of the autocomplete selection div is purged by javascript
so we have to move its label outside of it. aria-labeledby is the way
to go.

Each time the suggestion box is expanded, autocomplete js renders the
autocomplete suggestions template. So the label cannot be outside the
suggestions ul.
lang/en/form.php
lib/templates/form_autocomplete_selection.mustache
lib/templates/form_autocomplete_suggestions.mustache
user/templates/local/participantsfilter/autocomplete_selection.mustache