We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 21ff272 + fe5ae6e commit 9e1f966Copy full SHA for 9e1f966
src/index.ts
@@ -313,7 +313,7 @@ function applyFromToolbar(event: Event) {
313
if (!(target instanceof Element)) return
314
const mdButton = target.closest('[data-md-button]')
315
if (!mdButton || mdButton.closest('markdown-toolbar') !== currentTarget) return
316
- const mdButtonStyle = target.getAttribute('data-md-button')
+ const mdButtonStyle = mdButton.getAttribute('data-md-button')
317
const style = manualStyles[mdButtonStyle as keyof typeof manualStyles]
318
if (!style) return
319
event.preventDefault()
0 commit comments