diff --git a/src/index.js b/src/index.js index d882452..ba2c1e0 100644 --- a/src/index.js +++ b/src/index.js @@ -4,7 +4,6 @@ export async function initialize() { /* Listen for messages from the background script */ chrome.runtime.onMessage.addListener((message, sendResponse) => { if (message.type === "navigation") { - sendResponse({ status: "ok" }); appendAccessibilityInfo(); } }); diff --git a/src/utils.js b/src/utils.js index 627050e..6619042 100644 --- a/src/utils.js +++ b/src/utils.js @@ -28,7 +28,9 @@ export function appendAccessibilityInfo() { ".github-a11y-heading-prefix, .github-a11y-img-caption" ).length > 0) return - commentBody.querySelectorAll("img").forEach(function (image) { + [...commentBody.querySelectorAll("img")] + .filter(el => !el.closest('animated-image')) + .forEach(function (image) { const parentNodeName = image.parentElement.nodeName; if (parentNodeName === "A" || parentNodeName === "P") { const parent = image.closest("a") || image.closest("p");