fix(frontend): make icon tooltips work again

This commit is contained in:
sam 2023-09-13 15:41:01 +02:00
parent dd9c9c442c
commit 636ee7369d
No known key found for this signature in database
GPG key ID: B4EF20DDE721CAA1

View file

@ -15,9 +15,11 @@
$: currentPreference =
status in mergedPreferences ? mergedPreferences[status] : defaultPreferences.missing;
let iconElement: HTMLElement;
let iconElement: HTMLSpanElement;
</script>
<Icon aria-hidden name={currentPreference.icon} class={className} />
<span bind:this={iconElement} aria-hidden>
<Icon name={currentPreference.icon} class={className} />
</span>
<span class="visually-hidden">{currentPreference.tooltip}:</span>
<Tooltip aria-hidden target={iconElement} placement="top">{currentPreference.tooltip}</Tooltip>