mirror of
https://github.com/moodle/moodle.git
synced 2025-08-06 01:16:44 +02:00
MDL-31976 Accessbility: Action icons on course page do not need title attributes
This commit is contained in:
parent
a3ab18c735
commit
aad982aa24
5 changed files with 22 additions and 27 deletions
|
@ -550,6 +550,10 @@ class pix_icon implements renderable {
|
|||
}
|
||||
if (!isset($this->attributes['title'])) {
|
||||
$this->attributes['title'] = $this->attributes['alt'];
|
||||
} else if (empty($this->attributes['title'])) {
|
||||
// Remove the title attribute if empty, we probably want to use the parent node's title
|
||||
// and some browsers might overwrite it with an empty title.
|
||||
unset($this->attributes['title']);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue