2
0
mirror of https://github.com/tenrok/bootstrap.git synced 2026-05-24 14:04:09 +03:00

Handle non-empty whitespace textContent in Tooltip trigger (#36588)

This commit is contained in:
Nathan Walters
2022-07-05 22:15:50 -07:00
committed by GitHub
parent 7d0b224df4
commit 3f324eed02
2 changed files with 20 additions and 1 deletions
+1 -1
View File
@@ -518,7 +518,7 @@ class Tooltip extends BaseComponent {
return
}
if (!this._element.getAttribute('aria-label') && !this._element.textContent) {
if (!this._element.getAttribute('aria-label') && !this._element.textContent.trim()) {
this._element.setAttribute('aria-label', title)
}