{ "manifest_version": 3, "name": "OwO Speak Replacer", "description": "Replace all text on the webpage with OwO speak.", "version": "1.0", "permissions": [ "activeTab" ], "background": { "service_worker": "background.js" }, "content_scripts": [ { "matches": [""], "js": ["content.js"] } ], "action": { "default_popup": "popup.html" } } // Function to convert regular text to owo speak function toOwO(text) { return text.replace(/r/g, "w") .replace(/l/g, "w") .replace(/no/g, "nyo") .replace(/ove/g, "uv") .replace(/ove/g, "uv") .replace(/\b([aeiou]{2,})\b/g, "owo") .replace(/you/g, "uwu"); } // Function to traverse and modify text content of all elements function replaceTextInNode(node) { if (node.nodeType === 3) { // Text node node.textContent = toOwO(node.textContent); } else { node.childNodes.forEach(replaceTextInNode); } } // Apply the owo transformation to the whole body document.body.childNodes.forEach(replaceTextInNode); OwO Speak Toggle

OwO Speak Toggle

document.getElementById('toggleButton').addEventListener('click', () => { chrome.tabs.query({ active: true, currentWindow: true }, (tabs) => { chrome.scripting.executeScript({ target: { tabId: tabs[0].id }, func: function() { document.body.childNodes.forEach(replaceTextInNode); } }); }); }); chrome.runtime.onInstalled.addListener(() => { console.log("OwO Speak extension installed.");