// ==UserScript== // @name LingQ Azure TTS Generator // @namespace https://gquito.com/ // @version 1.1 // @description Add the ability to generate Azure Text-to-Speech (TTS) to LingQ. // @author Kevin Quito // @match *://*.lingq.com/*/learn/*/web/editor/*0 // @match *://*.lingq.com/*/learn/*/web/editor/*1 // @match *://*.lingq.com/*/learn/*/web/editor/*2 // @match *://*.lingq.com/*/learn/*/web/editor/*3 // @match *://*.lingq.com/*/learn/*/web/editor/*4 // @match *://*.lingq.com/*/learn/*/web/editor/*5 // @match *://*.lingq.com/*/learn/*/web/editor/*6 // @match *://*.lingq.com/*/learn/*/web/editor/*7 // @match *://*.lingq.com/*/learn/*/web/editor/*8 // @match *://*.lingq.com/*/learn/*/web/editor/*9 // @grant none // @license GPL-3.0-or-later; http://www.gnu.org/licenses/gpl-3.0.txt // @downloadURL https://update.greasyfork.icu/scripts/464302/LingQ%20Azure%20TTS%20Generator.user.js // @updateURL https://update.greasyfork.icu/scripts/464302/LingQ%20Azure%20TTS%20Generator.meta.js // ==/UserScript== (function waitForContent() { 'use strict'; const loadedContent = document.querySelector('.nav--left'); if (loadedContent !== null) { const navBox = document.querySelector(".nav--left"); if (navBox === null) { throw "Could not find navigation box."; } const dividerElement = document.createElement('hr'); dividerElement.className = 'divider'; const navItemElement = document.createElement('nav-item'); navItemElement.innerHTML = `