Skip to content

Commit 64b1daf

Browse files
committed
Fix a11y-click-events-have-key-events requirements
1 parent fc86be5 commit 64b1daf

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/routes/+page.svelte

+3-2
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@
9292
const setPartials = event => {
9393
const { value: selected } = event.target as HTMLInputElement
9494
95+
9596
if (selected === 'harmonics') {
9697
setHarmonics()
9798
} else {
@@ -115,11 +116,11 @@
115116
<div class="grid justify-end items-center pt-1 pr-2">
116117
<button>
117118
{#if view === 'instrument'}
118-
<div class="tooltip" data-tip="Show Info" on:click={showInfo}>
119+
<div class="tooltip" data-tip="Show Info" on:click={showInfo} on:keydown={showInfo}>
119120
<img src="information.svg" alt="Show information" />
120121
</div>
121122
{:else}
122-
<div on:click={hideInfo} class="pb-1">
123+
<div on:click={hideInfo} on:keydown={hideInfo} class="pb-1">
123124
<img src="close.svg" alt="Hide information" />
124125
</div>
125126
{/if}

0 commit comments

Comments
 (0)