// ==UserScript== // @name Duolingo Pro BETA // @namespace Violentmonkey Scripts // @version 2.0-BETA-9.6.7 // @description Duolingo Auto Solver Tool - Working May 2024 // @author anonymoushackerIV (https://github.com/anonymoushackerIV) // @match https://*.duolingo.com/* // @grant none // @license MIT // @icon https://github.com/anonymoushackerIV/Duolingo-Pro-Assets/blob/main/images/Duolingo-Pro-Icon.png?raw=true // @downloadURL none // ==/UserScript== // MIT License // Copyright (c) 2023 anonymoushackerIV (https://github.com/anonymoushackerIV) // Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: // The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. function OMEGA() { let solvingIntervalId; let isAutoMode = false; let isSolving = false; let isTokenRunning = false; const debug = false; let findReactMainElementClass = '_3js2_'; let ASB969 = true; let duolingoProCurrentVersionShort = "2.0B9.6.7"; let duolingoProCurrentVersion = "2.0 BETA 9.6.7"; let duolingoProFormalCurrentVersion = "2.0BETA9.6.7"; let solveSpeed; if (isNaN(parseFloat(localStorage.getItem('duopro.autoSolveDelay')))) { solveSpeed = 0.8; localStorage.setItem('duopro.autoSolveDelay', solveSpeed); } else { solveSpeed = parseFloat(localStorage.getItem('duopro.autoSolveDelay')); } let autoSolverBoxRepeatAmount = 0; autoSolverBoxRepeatAmount = Number(sessionStorage.getItem('autoSolverBoxRepeatAmount')); let DLPsessionCompleteAmount = 0; if (!isNaN(Number(sessionStorage.getItem('duopro.autoSolveSessionCompleteAmount'))) && Number(sessionStorage.getItem('duopro.autoSolveSessionCompleteAmount')) !== null) { DLPsessionCompleteAmount = Number(sessionStorage.getItem('duopro.autoSolveSessionCompleteAmount')); } else { DLPsessionCompleteAmount = 0; } let duoproForeverTotalQuestions = 0; let duoproForeverTotalLessons = 0; try { let TATJxnLggmiGvbDm = localStorage.getItem("duopro.forever.userStatistics"); if (TATJxnLggmiGvbDm) { let BDxfDivqDbLuJooi = JSON.parse(localStorage.getItem("duopro.forever.userStatistics")); if (!isNaN(BDxfDivqDbLuJooi.question)) { duoproForeverTotalQuestions = BDxfDivqDbLuJooi.question; } if (!isNaN(BDxfDivqDbLuJooi.lesson)) { duoproForeverTotalLessons = BDxfDivqDbLuJooi.lesson; } } duoproForeverTotalQuestions = duoproForeverTotalQuestions || 0; duoproForeverTotalLessons = duoproForeverTotalLessons || 0; } catch (error) { console.log(error); } let ProBlockBannerOneVisible = false; if (JSON.parse(localStorage.getItem('ProBlockBannerOneVisible')) === null) { ProBlockBannerOneVisible = false; } else { ProBlockBannerOneVisible = JSON.parse(localStorage.getItem('ProBlockBannerOneVisible')); } let autoSolverBoxPracticeOnlyMode = true; let autoSolverBoxRepeatLessonMode = false; let autoSolverBoxPathMode = false; let autoSolverBoxListeningOnlyMode = false; let autoSolverBoxAutomatedSolvingActive = false; let autoSolverBoxVisibility = true; function AmsaXtiWnczmqqlr() { if (!sessionStorage.getItem('duopro.session.solvemode')) { sessionStorage.setItem('duopro.session.solvemode', JSON.stringify({ practicemode: true, lessonmode: false, pathmode: false, listeningmode: false, automatedsolving: false, boxvisibility: true })); } else { let sv = JSON.parse(sessionStorage.getItem('duopro.session.solvemode')); //[autoSolverBoxPracticeOnlyMode, autoSolverBoxRepeatLessonMode, autoSolverBoxPathMode, autoSolverBoxListeningOnlyMode, autoSolverBoxAutomatedSolvingActive, autoSolverBoxVisibility] = [sv.practicemode, sv.lessonmode, sv.pathmode, sv.listeningmode, sv.automatedsolving, sv.boxvisibility]; autoSolverBoxPracticeOnlyMode = sv.practicemode; autoSolverBoxRepeatLessonMode = sv.lessonmode; autoSolverBoxPathMode = sv.pathmode; autoSolverBoxListeningOnlyMode = sv.listeningmode; autoSolverBoxAutomatedSolvingActive = sv.automatedsolving; autoSolverBoxVisibility = sv.boxvisibility; } }; AmsaXtiWnczmqqlr(); function updateMode(n, v) { let sv = JSON.parse(sessionStorage.getItem('duopro.session.solvemode')); sv[n] = v; sessionStorage.setItem('duopro.session.solvemode', JSON.stringify(sv)); if (n === 'practicemode') autoSolverBoxPracticeOnlyMode = v; else if (n === 'lessonmode') autoSolverBoxRepeatLessonMode = v; else if (n === 'pathmode') autoSolverBoxPathMode = v; else if (n === 'listeningmode') autoSolverBoxListeningOnlyMode = v; else if (n === 'automatedsolving') autoSolverBoxAutomatedSolvingActive = v; else if (n === 'boxvisibility') autoSolverBoxVisibility = v; }; let DLPpromotionBubbleVisibility; if (JSON.parse(localStorage.getItem('DLP4Uz53cm6wjnOG7tY')) === null) { DLPpromotionBubbleVisibility = true; } else { DLPpromotionBubbleVisibility = JSON.parse(localStorage.getItem('DLP4Uz53cm6wjnOG7tY')); } let wasDuolingoProSettingsButtonOnePressed = false; // Duolingo Pro Settings Variables Start //moved here let AutoSolverSettingsShowPracticeOnlyModeForAutoSolverBox = true; let AutoSolverSettingsShowRepeatLessonModeForAutoSolverBox = true; let AutoSolverSettingsShowListeningOnlyModeForAutoSolverBox = true; //moved here let AutoSolverSettingsLowPerformanceMode = false; if (JSON.parse(localStorage.getItem('AutoSolverSettingsLowPerformanceMode')) === null) { AutoSolverSettingsLowPerformanceMode = false; // default } else { AutoSolverSettingsLowPerformanceMode = JSON.parse(localStorage.getItem('AutoSolverSettingsLowPerformanceMode')); } let DuolingoProSettingsProBlockMode = false; if (JSON.parse(localStorage.getItem('DuolingoProSettingsProBlockMode')) === null) { DuolingoProSettingsProBlockMode = false; // default } else { DuolingoProSettingsProBlockMode = JSON.parse(localStorage.getItem('DuolingoProSettingsProBlockMode')); if (!DuolingoProSettingsProBlockMode) { ProBlockBannerOneVisible = true; localStorage.setItem('ProBlockBannerOneVisible', ProBlockBannerOneVisible); } } let DuolingoProSettingsTurboSolveMode = false; if (JSON.parse(localStorage.getItem('DuolingoProSettingsTurboSolveMode')) === null) { DuolingoProSettingsTurboSolveMode = false; } else { DuolingoProSettingsTurboSolveMode = JSON.parse(localStorage.getItem('DuolingoProSettingsTurboSolveMode')); } let DuolingoProSettingsNeverEndMode = false; if (JSON.parse(localStorage.getItem('DuolingoProSettingsNeverEndMode')) === null) { DuolingoProSettingsNeverEndMode = false; } else { DuolingoProSettingsNeverEndMode = JSON.parse(localStorage.getItem('DuolingoProSettingsNeverEndMode')); } let DuolingoProShadeLessonsMode = true; if (JSON.parse(localStorage.getItem('DuolingoProShadeLessonsMode')) === null) { DuolingoProShadeLessonsMode = true; } else { DuolingoProShadeLessonsMode = JSON.parse(localStorage.getItem('DuolingoProShadeLessonsMode')); } let DuolingoProAntiStuckProtectionMode = true; if (JSON.parse(localStorage.getItem('DuolingoProAntiStuckProtectionMode')) === null) { DuolingoProAntiStuckProtectionMode = true; } else { DuolingoProAntiStuckProtectionMode = JSON.parse(localStorage.getItem('DuolingoProAntiStuckProtectionMode')); } let DuolingoProSettingsUpdateNotifications = true; if (JSON.parse(localStorage.getItem('DuolingoProSettingsUpdateNotifications')) === null) { DuolingoProSettingsUpdateNotifications = true; } else { DuolingoProSettingsUpdateNotifications = JSON.parse(localStorage.getItem('DuolingoProSettingsUpdateNotifications')); } let DuolingoProSettingsSolveIntervalValue = true; if (JSON.parse(localStorage.getItem('DuolingoProSettingsSolveIntervalValue')) === null) { DuolingoProSettingsSolveIntervalValue = true; } else { DuolingoProSettingsSolveIntervalValue = JSON.parse(localStorage.getItem('DuolingoProSettingsSolveIntervalValue')); } // Duolingo Pro Settings Variables End let duolingoProPythonanywhere = "https://duolingoprodb.pythonanywhere.com"; function DuolingoProRounded() { try { let DuolingoProRoundedCSS = ` @font-face { font-family: 'Duolingo Pro Rounded'; src: url(https://raw.githubusercontent.com/anonymoushackerIV/Duolingo-Pro-Assets/main/fonts/SF-Pro-Rounded-Bold.otf) format('opentype'); } `; let styleElement = document.createElement('style'); styleElement.type = 'text/css'; styleElement.appendChild(document.createTextNode(DuolingoProRoundedCSS)); document.head.appendChild(styleElement); } catch (error) { console.log(error); } } DuolingoProRounded(); function createButton(id, text, styleClass, eventHandlers) { const button = document.createElement('button'); button.id = id; button.innerText = text; button.className = styleClass; Object.keys(eventHandlers).forEach(event => { button.addEventListener(event, eventHandlers[event]); }); return button; } function addButtons() { if (window.location.pathname === '/learn' && document.querySelector('a[data-test="global-practice"]')) { return; } if (document.querySelector("#solveAllButton")) { return; } const original = document.querySelector('[data-test="player-next"]'); const storiesContinue = document.querySelector('[data-test="stories-player-continue"]'); const target = original || storiesContinue; if (!target) { const startButton = document.querySelector('[data-test="start-button"]'); if (!startButton) { return; } const solveAllButton = createButton("solveAllButton", "COMPLETE SKILL", "solve-all-btn", { 'click': () => { solving(true); setInterval(() => { const startButton = document.querySelector('[data-test="start-button"]'); if (startButton && startButton.innerText.startsWith("START")) { startButton.click(); } }, 1000); startButton.click(); } }); startButton.parentNode.appendChild(solveAllButton); } else { if (document.querySelector('._10vOG, ._2L_r0') !== null) { findReactMainElementClass = '_3FiYg'; document.querySelector('._10vOG, ._2L_r0').style.display = "flex"; document.querySelector('._10vOG, ._2L_r0').style.gap = "20px"; } else if (document.querySelector('._2sXnx') !== null) { findReactMainElementClass = '_3js2_'; document.querySelector('._2sXnx').style.display = "flex"; document.querySelector('._2sXnx').style.gap = "20px"; } else if (document.querySelector('.MYehf') !== null) { findReactMainElementClass = 'wqSzE'; document.querySelector('.MYehf').style.display = "flex"; document.querySelector('.MYehf').style.gap = "20px"; } const buttonsCSS = document.createElement('style'); buttonsCSS.innerHTML = ` .solve-btn { position: relative; min-width: 150px; font-size: 17px; border: none; border-bottom: 4px solid #2b70c9; border-radius: 16px; padding: 13px 16px; transition: filter .0s; font-weight: 700; letter-spacing: .8px; background: #1cb0f6; color: rgb(var(--color-snow)); cursor: pointer; } .pause-btn { position: relative; min-width: 100px; font-size: 17px; border: none; border-bottom: 4px solid #ff9600; border-radius: 16px; padding: 13px 16px; transition: filter .0s; font-weight: 700; letter-spacing: .8px; background: #ffc800; color: rgb(var(--color-snow)); cursor: pointer; } .auto-solver-btn:hover { filter: brightness(1.1); } .auto-solver-btn:active { border-bottom: 0px; margin-bottom: 4px; top: 4px; } `; document.head.appendChild(buttonsCSS); const solveCopy = createButton('solveAllButton', solvingIntervalId ? 'PAUSE SOLVE' : 'SOLVE ALL', 'auto-solver-btn solve-btn', { 'click': solving }); const pauseCopy = createButton('', 'SOLVE', 'auto-solver-btn pause-btn', { 'click': solve }); target.parentElement.appendChild(pauseCopy); target.parentElement.appendChild(solveCopy); } } setInterval(addButtons, 500); const DLPuniversalCSS = ` :root { --DLP-red: #FF3B30; --DLP-orange: #FF9500; --DLP-yellow: #FFCC00; --DLP-green: 52, 199, 89; --DLP-cyan: #5AC8FA; --DLP-blue: 0, 122, 255; --DLP-indigo: #5856D6; --DLP-purple: #AF52DE; --DLP-pink: 255, 45, 85; } .noSelect { user-select: none; -moz-user-select: none; -webkit-text-select: none; -webkit-user-select: none; } .DPLBoxStyleT1 { display: flex; width: 512px; max-height: 84%; gap: 8px; padding: 16px; justify-content: center; align-items: center; flex-direction: column; border-radius: 16px; border: 2px solid rgb(var(--color-swan)); background: rgb(var(--color-snow)); box-shadow: 0px 0px 16px 0px rgba(0, 0, 0, 0.10); transition: .2s; } .DPLBoxShadowStyleT1 { position: fixed; display: flex; width: 100%; height: 100vh; justify-content: center; align-items: center; flex-shrink: 0; background: rgba(0, 0, 0, 0.1); backdrop-filter: blur(8px); opacity: 0; transition: .2s; z-index: 128; top: 0px; bottom: 0px; right: 0px; left: 0px; } .VStack { display: flex; flex-direction: column; } .HStack { display: flex; flex-direction: row; } .selfFill { align-self: stretch; } .paragraphText { font-family: Duolingo Pro Rounded, 'din-round' !important; font-size: 16px; font-weight: 700; margin: 0; } .textFill { flex: 1 0 0; } .DPLPrimaryButtonStyleT1 { display: flex; height: 54px; padding: 16px; justify-content: center; align-items: center; gap: 8px; flex: 1 0 0; border-radius: 8px; border: 2px solid rgba(0, 0, 0, 0.20); border-bottom: 4px solid rgba(0, 0, 0, 0.20); background: rgb(var(--DLP-blue)); color: #fff; font-weight: 700; font-family: Duolingo Pro Rounded, 'din-round' !important; transition: .1s; cursor: pointer; } .DPLPrimaryButtonStyleT1:hover { filter: brightness(0.95); } .DPLPrimaryButtonStyleT1:active { filter: brightness(0.9); height: 52px; margin-top: 2px; border-bottom: 2px solid rgba(0, 0, 0, 0.20); } .DPLPrimaryButtonDisabledStyleT1 { display: flex; height: 52px; margin-top: 2px; padding: 16px; justify-content: center; align-items: center; gap: 8px; flex: 1 0 0; border-radius: 8px; border: 2px solid rgba(0, 0, 0, 0.20); opacity: 0.5; background: rgb(var(--DLP-blue)); color: #fff; font-weight: 700; font-family: Duolingo Pro Rounded, 'din-round' !important; transition: .1s; cursor: pointer; } .DPLSecondaryButtonStyleT1 { display: flex; height: 54px; padding: 16px; justify-content: center; align-items: center; gap: 8px; border-radius: 8px; border: 2px solid rgb(var(--DLP-blue), 0.1); border-bottom: 4px solid rgb(var(--DLP-blue), 0.1); background: rgb(var(--DLP-blue), 0.1); color: rgb(var(--DLP-blue)); font-weight: 700; font-family: Duolingo Pro Rounded, 'din-round' !important; transition: .1s; cursor: pointer; } .DPLSecondaryButtonStyleT1:hover { filter: brightness(0.95); } .DPLSecondaryButtonStyleT1:active { filter: brightness(0.9); height: 52px; margin-top: 2px; border-bottom: 2px solid rgb(var(--DLP-blue), 0.1); } .DLPSettingsToggleT1 { display: inline-flex; height: 48px; width: 64px; justify-content: flex-end; align-items: center; flex-shrink: 0; border-radius: 16px; cursor: pointer; } .DLPSettingsToggleT1B1 { display: flex; height: 32px; width: 32px; justify-content: center; align-items: center; border-radius: 8px; transition: .2s; } .DLPSettingsToggleT1:hover .DLPSettingsToggleT1B1 { filter: brightness(0.9); transform: scale(1.05); } .DLPSettingsToggleT1:active .DLPSettingsToggleT1B1 { filter: brightness(0.9); transform: scale(0.9); } .DLPSettingsToggleT1ON { border: 2px solid rgba(52, 199, 89, 0.1); background: rgba(var(--DLP-green), 0.1); } .DLPSettingsToggleT1ONB1 { border: 2px solid rgba(0, 0, 0, 0.1); background: rgba(var(--DLP-green)); margin-right: 6px; } .DLPSettingsToggleT1OFF { border: 2px solid rgba(255, 45, 85, 0.1); background: rgba(var(--DLP-pink), 0.1); } .DLPSettingsToggleT1OFFB1 { border: 2px solid rgba(0, 0, 0, 0.1); background: rgba(var(--DLP-pink)); margin-right: 22px; } .DLPSettingsToggleT2 { display: flex; width: 96px; height: 48px; align-items: center; flex-shrink: 0; border-radius: 16px; border: 2px solid rgba(0, 122, 255, 0.1); background: rgba(var(--DLP-blue), 0.1); cursor: pointer; } .DLPSettingsToggleT2B1 { display: flex; height: 32px; width: 32px; margin-left: 6px; justify-content: center; align-items: center; border-radius: 8px; border: 2px solid rgba(0, 0, 0, 0.1); background: rgba(var(--DLP-blue)); transition: .2s; } .DLPSettingsToggleT2:hover .DLPSettingsToggleT2B1 { filter: brightness(0.9); transform: scale(1.05); } .DLPSettingsToggleT2:active .DLPSettingsToggleT2B1 { filter: brightness(0.9); transform: scale(0.9); } .DLPSettingsToggleT2B1T1 { color: #FFF; text-align: center; font-size: 16px; font-weight: 700; font-family: Duolingo Pro Rounded, 'din-round' !important; } .DLPSettingsToggleT3 { display: flex; width: 48px; height: 48px; align-items: center; flex-shrink: 0; border-radius: 16px; border: 2px solid rgba(0, 122, 255, 0.1); background: rgba(var(--DLP-blue), 0.1); cursor: pointer; } .DLPSettingsToggleT3B1 { display: flex; height: 32px; width: 32px; margin-left: 6px; justify-content: center; align-items: center; border-radius: 8px; border: 2px solid rgba(0, 0, 0, 0.1); background: rgba(var(--DLP-blue)); transition: .2s; } .DLPSettingsToggleT3:hover .DLPSettingsToggleT3B1 { filter: brightness(0.9); transform: scale(1.05); } .DLPSettingsToggleT3:active .DLPSettingsToggleT3B1 { filter: brightness(0.9); transform: scale(0.9); } .DLPFeedbackTextFieldT1 { display: flex; width: 100%; padding: 16px; justify-content: center; align-items: flex-start; align-self: stretch; border-radius: 8px; border: 2px solid rgb(var(--color-eel), 0.1); background: rgba(var(--color-swan), 0.5); color: rgb(var(--color-eel)); font-size: 16px; font-weight: 700; font-family: Duolingo Pro Rounded, 'din-round' !important; transition: .2s; } .DLPFeedbackTextFieldT1::placeholder { font-weight: 700; color: rgb(var(--color-eel), 0.5); } .DLPFeedbackTextFieldT1:focus { border: 2px solid rgba(var(--DLP-blue)); } `; let injectedDLPuniversalCSS = null; function DLPuniversalCSSfunc() { try { if (!injectedDLPuniversalCSS) { injectedDLPuniversalCSS = document.createElement('style'); injectedDLPuniversalCSS.type = 'text/css'; injectedDLPuniversalCSS.innerHTML = DLPuniversalCSS; document.head.appendChild(injectedDLPuniversalCSS); } else { } } catch (error) { console.log(error); } } DLPuniversalCSSfunc(); const htmlContent = `

Hide

Feedback

Settings

Issues & Fixes

Duolingo Pro

2.0 BETA 9.6.7

How many lessons would you like to AutoSolve?

0
Practice Only Mode
Repeat Lesson Mode
Listening Only Mode (Super)

Turn off all to use Path Mode

`; const cssContent = ` .AutoSolverBoxFirst { display: inline-flex; flex-direction: column; align-items: flex-end; gap: 8px; position: fixed; bottom: 24px; right: 24px; z-index: 2; } .AutoSolverBoxBackground { display: flex; padding: 16px; flex-direction: column; justify-content: center; align-items: center; gap: 8px; border-radius: 16px; border: 2px solid rgb(var(--color-swan)); background: rgb(var(--color-snow), 0.84); backdrop-filter: blur(32px); width: 320px; opacity: 0; transition: .5s; overflow: hidden; } .AutoSolverBoxLayers { display: flex; width: 100%; flex-direction: column; justify-content: center; align-items: center; gap: 8px; transition: .5s; } .AutoSolverBoxAlertSectionOne { display: flex; width: 100%; flex-direction: column; align-items: flex-start; gap: 8px; } .AutoSolverBoxAlertSectionOneSystemSection { display: flex; align-items: flex-start; gap: 8px; align-self: stretch; } .AutoSolverBoxAlertOneBox { display: flex; align-items: center; gap: 8px; align-self: stretch; padding: 8px; border-radius: 8px; height: 40px; cursor: pointer; transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); } .AutoSolverBoxAlertOneBox:hover { filter: brightness(0.9); transform: scale(1.05); } .AutoSolverBoxAlertOneBox:active { filter: brightness(0.8); transform: scale(0.9); } .AutoSolverBoxAlertOneBoxTextOne { font-weight: 700; font-size: 16px; flex: 1 0 0; margin: 0px; user-select: none; -moz-user-select: none; -webkit-text-select: none; -webkit-user-select: none; } .AutoSolverBoxSectionThreeBox { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; height: 100%; width: 100%; } .AutoSolverBoxTitleSectionOne { display: flex; justify-content: space-between; align-items: center; align-self: stretch; padding-bottom: 8px; padding: 0px; } .AutoSolverBoxTitleSectionOneBETATagOne { display: flex; height: 36px; padding-right: 8px; padding-left: 8px; flex-direction: column; justify-content: center; align-items: center; border-radius: 8px; background: #FF2D55; border: 2px solid rgba(0, 0, 0, 0.20); } .AutoSolverBoxTitleSectionOneBETATagOneTextOne { color: #FFF; font-style: normal; font-weight: 700; line-height: normal; margin-top: 0px; margin-bottom: 0px; font-size: 16px; cursor: default; } .AutoSolverBoxSectionThreeBoxSectionOne { height: 100%; width: 100%; display: flex; justify-content: center; align-items: center; gap: 8px } .AutoSolverBoxRepeatAmountButton { position: relative; display: flex; width: 48px; height: 48px; flex-direction: column; justify-content: center; align-items: center; gap: 8px; flex-shrink: 0; border-radius: 8px; cursor: pointer; transition: all .1s, opacity .2s; text-align: center; font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; } .AutoSolverBoxRepeatAmountButton:hover { filter: brightness(0.95); } .AutoSolverBoxRepeatAmountButton:active { margin-top: 2px; height: 46px; filter: brightness(0.9); } .AutoSolverBoxRepeatAmountButtonActive { border: 2px solid rgba(0, 0, 0, 0.20); border-bottom: 4px solid rgba(0, 0, 0, 0.20); background: #007AFF; color: #FFF; } .AutoSolverBoxRepeatAmountButtonActive:hover { } .AutoSolverBoxRepeatAmountButtonActive:active { border-bottom: 2px solid rgba(0, 0, 0, 0.20); } .AutoSolverBoxRepeatAmountButtonDeactive { height: 46px; margin-top: 2px; border: 2px solid rgba(0, 0, 0, 0.20); background: #007AFF; opacity: 0.5; cursor: not-allowed; color: #FFF; } .AutoSolverBoxRepeatAmountButtonDeactive:hover { } .AutoSolverBoxRepeatAmountButtonDeactive:active { } .AutoSolverBoxRepeatAmountButtonOff { border: 2px solid rgb(var(--color-swan)); border-bottom: 4px solid rgb(var(--color-swan)); background: rgb(var(--color-snow)); color: rgb(var(--color-eel)); } .AutoSolverBoxRepeatAmountButtonOff:hover { } .AutoSolverBoxRepeatAmountButtonOff:active { border-bottom: 2px solid rgb(var(--color-swan)); } .AutoSolverBoxRepeatNumberDisplay { position: relative; text-align: center; display: inline-flex; height: 48px; width: 100%; padding: 16px; justify-content: center; align-items: center; gap: 8px; border-radius: 8px; border: 2px solid rgb(var(--color-eel), 0.2); background: rgb(var(--color-swan), 0.8); text-align: center; transition: all .2s, font-size .0s; z-index: 2; } .AutoSolverBoxSectionThreeBoxSectionTwo { height: 100%; width: 100%; display: flex; justify-content: center; align-items: center; gap: 8px; } `; let DVfkMxsABjstoaGw = `

You've Been Banned

You’ve been banned from using Duolingo Pro because of

All features of Duolingo Pro are disabled, except basic functions such as Solve buttons in lessons.

How can I fix this?

`; let VBvArqbjKNjukomQ = null; function szdfgvhbjnk() { let VRFATlhSBsIqitsa = false; if (JSON.parse(localStorage.getItem('PkvEOSJlElvFWWOGmNxshSsPShkkZwmM')) === null) { VRFATlhSBsIqitsa = false; } else { VRFATlhSBsIqitsa = JSON.parse(localStorage.getItem('PkvEOSJlElvFWWOGmNxshSsPShkkZwmM')); localStorage.setItem('PkvEOSJlElvFWWOGmNxshSsPShkkZwmM', VRFATlhSBsIqitsa); } if (VRFATlhSBsIqitsa) { try { document.querySelector('.AutoSolverBoxLayers').remove(); VBvArqbjKNjukomQ = document.createElement('div'); VBvArqbjKNjukomQ.innerHTML = DVfkMxsABjstoaGw; document.querySelector('.AutoSolverBoxBackground').appendChild(VBvArqbjKNjukomQ); } catch (error) {} } async function updateWarningsFromURL(url, currentVersion) { try { const response = await fetch(url); if (!response.ok) { //throw new Error('Network response was not ok'); } const data = await response.json(); const versionData = data[currentVersion]; if (versionData) { try { document.querySelector('.AutoSolverBoxLayers').remove(); VBvArqbjKNjukomQ = document.createElement('div'); VBvArqbjKNjukomQ.innerHTML = DVfkMxsABjstoaGw; document.querySelector('.AutoSolverBoxBackground').appendChild(VBvArqbjKNjukomQ); } catch (error) {} autoSolverBoxRepeatAmount = 0; VRFATlhSBsIqitsa = true; localStorage.setItem('PkvEOSJlElvFWWOGmNxshSsPShkkZwmM', VRFATlhSBsIqitsa); for (const warningKey in versionData) { if (warningKey === 'expiration') { if (warningKey === 'never' || warningKey === 'forever' || warningKey === '') { } } else if (warningKey === 'reason') { document.querySelector('#MHUXHhvVrJjRMuOe').textContent = "You’ve been banned from using Duolingo Pro because of " + versionData[warningKey] + "."; } else if (warningKey === 'rebuttal') { document.querySelector('#ACuvpqwPRPwTYTHRID').addEventListener('click', () => { window.open(versionData[warningKey], '_blank'); }); } } } else { // cleanassbitch } } catch (error) { console.log(`Error getting data #1: ${error.message}`); } } updateWarningsFromURL('https://raw.githubusercontent.com/anonymoushackerIV/Duolingo-Pro-Assets/main/resources/security-1.json', String(randomValue)); } let injectedContainer = null; let injectedStyleElement = null; function injectContent() { if (window.location.pathname === '/learn' || window.location.pathname === '/practice-hub') { if (!injectedContainer) { injectedContainer = document.createElement('div'); injectedContainer.innerHTML = htmlContent; document.body.appendChild(injectedContainer); injectedStyleElement = document.createElement('style'); injectedStyleElement.type = 'text/css'; injectedStyleElement.innerHTML = cssContent; document.head.appendChild(injectedStyleElement); initializeDuolingoProSystemButtons(); checkForUpdatesVersion(); try { let AutoSolverBoxSectionThreeBoxSectionTwoIDOneForHiding = document.querySelector('#AutoSolverBoxSectionThreeBoxSectionTwoIDOne'); let AutoSolverBoxSectionThreeBoxSectionTwoIDTwoForHiding = document.querySelector('#AutoSolverBoxSectionThreeBoxSectionTwoIDTwo'); let AutoSolverBoxSectionThreeBoxSectionTwoIDThreeForHiding = document.querySelector('#AutoSolverBoxSectionThreeBoxSectionTwoIDThree'); const AutoSolverBoxBackgroundForHiding = document.querySelector('.AutoSolverBoxBackground'); if (autoSolverBoxVisibility) { initializeAutoSolverBoxButtonInteractiveness(); something(); if (!AutoSolverSettingsShowPracticeOnlyModeForAutoSolverBox) { AutoSolverBoxSectionThreeBoxSectionTwoIDOneForHiding.remove(); } if (!AutoSolverSettingsShowRepeatLessonModeForAutoSolverBox) { AutoSolverBoxSectionThreeBoxSectionTwoIDTwoForHiding.remove(); } if (!AutoSolverSettingsShowListeningOnlyModeForAutoSolverBox) { AutoSolverBoxSectionThreeBoxSectionTwoIDThreeForHiding.remove(); } } else { console.log('error 5'); } } catch(error) { } } } else { if (injectedContainer) { document.body.removeChild(injectedContainer); document.head.removeChild(injectedStyleElement); injectedContainer = null; injectedStyleElement = null; } } } setInterval(injectContent, 100); function initializeDuolingoProSystemButtons() { const DuolingoProSettingsButtonOne = document.querySelector('#DuolingoProSettingsButtonOne'); DuolingoProSettingsButtonOne.addEventListener('click', () => { wasDuolingoProSettingsButtonOnePressed = true; }); const SendFeedbackButton = document.querySelector('#SendFeedbackButtonOne'); SendFeedbackButton.addEventListener('click', () => { SendFeedBackBox(true); }); const SeeCurrentIssuesButton = document.querySelector('#DPSeeAllCurrentIssuesButtonABButtonID'); SeeCurrentIssuesButton.addEventListener('click', () => { CurrentIssuesPopUpFunction(true); }); let _32a = false; let fornow1a; const HideAutoSolverBoxButtonOne = document.querySelector('#HideAutoSolverBoxButtonOneID'); const AutoSolverBoxBackground = document.querySelector('.AutoSolverBoxBackground'); if (autoSolverBoxVisibility) { AutoSolverBoxBackground.style.opacity = '1'; document.querySelector('#HideAutoSolverBoxButtonOneTextOneID').textContent = 'Hide'; document.querySelector('#HideAutoSolverBoxButtonOneIconOneID').style.display = 'none'; document.querySelector('#HideAutoSolverBoxButtonOneIconTwoID').style.display = ''; } else if (!autoSolverBoxVisibility) { fornow1a = document.querySelector('.AutoSolverBoxBackground').offsetHeight; document.querySelector('#HideAutoSolverBoxButtonOneTextOneID').textContent = 'Show'; document.querySelector('#HideAutoSolverBoxButtonOneIconOneID').style.display = ''; document.querySelector('#HideAutoSolverBoxButtonOneIconTwoID').style.display = 'none'; AutoSolverBoxBackground.style.opacity = '0'; fornow1a = document.querySelector('.AutoSolverBoxBackground').offsetHeight; AutoSolverBoxBackground.style.height = '0px'; _32a = true; } HideAutoSolverBoxButtonOne.addEventListener('click', () => { if (autoSolverBoxVisibility) { document.querySelector('#HideAutoSolverBoxButtonOneTextOneID').textContent = 'Show'; HideAutoSolverBoxButtonOne.style.marginBottom = '0px'; document.querySelector('#HideAutoSolverBoxButtonOneIconOneID').style.display = ''; document.querySelector('#HideAutoSolverBoxButtonOneIconTwoID').style.display = 'none'; autoSolverBoxVisibility = false; updateMode('boxvisibility', autoSolverBoxVisibility); document.querySelector('.AutoSolverBoxLayers').style.transform = 'scaleY(1.0)'; AutoSolverBoxBackground.style.filter = 'blur(0)'; fornow1a = document.querySelector('.AutoSolverBoxBackground').offsetHeight; AutoSolverBoxBackground.style.height = `${fornow1a}px`; setTimeout(function() { AutoSolverBoxBackground.style.height = '0px'; AutoSolverBoxBackground.style.opacity = '0'; document.querySelector('.AutoSolverBoxLayers').style.transform = 'scaleY(0)'; AutoSolverBoxBackground.style.filter = 'blur(16px)'; setTimeout(function() { }, 500); }, 50); } else if (!autoSolverBoxVisibility) { document.querySelector('#HideAutoSolverBoxButtonOneTextOneID').textContent = 'Hide'; HideAutoSolverBoxButtonOne.style.marginBottom = ''; document.querySelector('#HideAutoSolverBoxButtonOneIconOneID').style.display = 'none'; document.querySelector('#HideAutoSolverBoxButtonOneIconTwoID').style.display = ''; autoSolverBoxVisibility = true; updateMode('boxvisibility', autoSolverBoxVisibility); document.querySelector('.AutoSolverBoxLayers').style.transform = 'scaleY(0)'; AutoSolverBoxBackground.style.filter = 'blur(16px)'; setTimeout(function() { AutoSolverBoxBackground.style.height = `${fornow1a}px`; AutoSolverBoxBackground.style.opacity = '1'; document.querySelector('.AutoSolverBoxLayers').style.transform = 'scaleY(1.0)'; AutoSolverBoxBackground.style.filter = 'blur(0)'; setTimeout(function() { AutoSolverBoxBackground.style.height = ''; }, 500); }, 10); if (_32a) { something(); initializeAutoSolverBoxButtonInteractiveness(); _32a = false; } } }); } function something() { let AutoSolverBoxRepeatStartButton = document.querySelector('#DPASBsB1'); if (autoSolverBoxRepeatAmount > 0 || DuolingoProSettingsNeverEndMode) { AutoSolverBoxRepeatStartButton.classList.add('AutoSolverBoxRepeatAmountButtonActive'); try { AutoSolverBoxRepeatStartButton.classList.remove('AutoSolverBoxRepeatAmountButtonDeactive'); } catch (error) {} } else { AutoSolverBoxRepeatStartButton.classList.add('AutoSolverBoxRepeatAmountButtonDeactive'); try { AutoSolverBoxRepeatStartButton.classList.remove('AutoSolverBoxRepeatAmountButtonActive'); } catch (error) {} } } let PkJiQETebALNWeLt = 0; function initializeAutoSolverBoxButtonInteractiveness() { const AutoSolverBoxNumberDisplayID = document.querySelector('#AutoSolverBoxNumberDisplayID'); const AutoSolverBoxRepeatNumberDownButton = document.querySelector('#DPASBadB1'); const AutoSolverBoxRepeatNumberUpButton = document.querySelector('#DPASBauB1'); const AutoSolverBoxForeverModeButton = document.querySelector('#DPASBfmB1'); const AutoSolverBoxXPModeButton = document.querySelector('#DLPIDxpMB1ID1'); const AutoSolverBoxRepeatStartButton = document.querySelector('#DPASBsB1'); DPABaBsFunc1(); AutoSolverBoxNumberDisplayID.textContent = autoSolverBoxRepeatAmount; AutoSolverBoxForeverModeButtonUpdateFunc(); something(); function DPABaBsFunc1() { const AutoSolverBoxRepeatNumberDownButton = document.querySelector('#DPASBadB1'); const AutoSolverBoxRepeatNumberUpButton = document.querySelector('#DPASBauB1'); if (autoSolverBoxRepeatAmount === 0 || autoSolverBoxRepeatAmount < 0) { AutoSolverBoxRepeatNumberDownButton.classList.add('AutoSolverBoxRepeatAmountButtonDeactive'); try { AutoSolverBoxRepeatNumberDownButton.classList.remove('AutoSolverBoxRepeatAmountButtonActive'); } catch (error) {} } else { AutoSolverBoxRepeatNumberDownButton.classList.add('AutoSolverBoxRepeatAmountButtonActive'); try { AutoSolverBoxRepeatNumberDownButton.classList.remove('AutoSolverBoxRepeatAmountButtonDeactive'); } catch (error) {} } if (autoSolverBoxRepeatAmount === 99999 || autoSolverBoxRepeatAmount > 99999) { AutoSolverBoxRepeatNumberUpButton.classList.add('AutoSolverBoxRepeatAmountButtonDeactive'); try { AutoSolverBoxRepeatNumberUpButton.classList.remove('AutoSolverBoxRepeatAmountButtonActive'); } catch (error) {} } else { AutoSolverBoxRepeatNumberUpButton.classList.add('AutoSolverBoxRepeatAmountButtonActive'); try { AutoSolverBoxRepeatNumberUpButton.classList.remove('AutoSolverBoxRepeatAmountButtonDeactive'); } catch (error) {} } } function AutoSolverBoxForeverModeButtonUpdateFunc() { if (false) { AutoSolverBoxXPModeButton.classList.add('AutoSolverBoxRepeatAmountButtonActive'); try { AutoSolverBoxXPModeButton.classList.remove('AutoSolverBoxRepeatAmountButtonOff'); } catch (error) {} } else { AutoSolverBoxXPModeButton.classList.add('AutoSolverBoxRepeatAmountButtonOff'); try { AutoSolverBoxXPModeButton.classList.remove('AutoSolverBoxRepeatAmountButtonActive'); } catch (error) {} } if (DuolingoProSettingsNeverEndMode) { AutoSolverBoxForeverModeButton.classList.add('AutoSolverBoxRepeatAmountButtonActive'); try { AutoSolverBoxForeverModeButton.classList.remove('AutoSolverBoxRepeatAmountButtonOff'); } catch (error) {} AutoSolverBoxNumberDisplayID.style.marginLeft = '-56px'; AutoSolverBoxNumberDisplayID.style.marginRight = '-56px'; AutoSolverBoxRepeatNumberDownButton.style.opacity = '0'; //AutoSolverBoxRepeatNumberDownButton.style.filter = 'blur(4px)'; AutoSolverBoxRepeatNumberUpButton.style.opacity = '0'; //AutoSolverBoxRepeatNumberUpButton.style.filter = 'blur(4px)'; AutoSolverBoxNumberDisplayID.textContent = "∞"; AutoSolverBoxNumberDisplayID.style.fontSize = '20px'; } else { AutoSolverBoxForeverModeButton.classList.add('AutoSolverBoxRepeatAmountButtonOff'); try { AutoSolverBoxForeverModeButton.classList.remove('AutoSolverBoxRepeatAmountButtonActive'); } catch (error) {} AutoSolverBoxNumberDisplayID.style.marginLeft = ''; AutoSolverBoxNumberDisplayID.style.marginRight = ''; AutoSolverBoxRepeatNumberDownButton.style.opacity = ''; //AutoSolverBoxRepeatNumberDownButton.style.filter = ''; AutoSolverBoxRepeatNumberUpButton.style.opacity = ''; //AutoSolverBoxRepeatNumberUpButton.style.filter = ''; AutoSolverBoxNumberDisplayID.textContent = autoSolverBoxRepeatAmount; AutoSolverBoxNumberDisplayID.style.fontSize = ''; } } if (DuolingoProSettingsNeverEndMode) { AutoSolverBoxNumberDisplayID.textContent = "∞"; AutoSolverBoxNumberDisplayID.style.fontSize = '20px'; } AutoSolverBoxForeverModeButton.addEventListener('click', () => { DuolingoProSettingsNeverEndMode = !DuolingoProSettingsNeverEndMode; localStorage.setItem('DuolingoProSettingsNeverEndMode', DuolingoProSettingsNeverEndMode); AutoSolverBoxForeverModeButtonUpdateFunc(); something(); }); AutoSolverBoxRepeatNumberDownButton.addEventListener('click', () => { if (!DuolingoProSettingsNeverEndMode) { if (autoSolverBoxRepeatAmount > 0) { autoSolverBoxRepeatAmount--; } else if (autoSolverBoxRepeatAmount <= 0) { autoSolverBoxRepeatAmount = 0; } AutoSolverBoxNumberDisplayID.textContent = autoSolverBoxRepeatAmount; sessionStorage.setItem('autoSolverBoxRepeatAmount', autoSolverBoxRepeatAmount); DPABaBsFunc1(); } else { } something(); }); AutoSolverBoxRepeatNumberUpButton.addEventListener('click', () => { if (!DuolingoProSettingsNeverEndMode) { if (autoSolverBoxRepeatAmount !== 99999) { autoSolverBoxRepeatAmount++; } else if (autoSolverBoxRepeatAmount >= 99999) { autoSolverBoxRepeatAmount = 99999; } AutoSolverBoxNumberDisplayID.textContent = autoSolverBoxRepeatAmount; sessionStorage.setItem('autoSolverBoxRepeatAmount', autoSolverBoxRepeatAmount); DPABaBsFunc1(); } else { } something(); }); if (autoSolverBoxRepeatAmount === 0 && !DuolingoProSettingsNeverEndMode) { autoSolverBoxAutomatedSolvingActive = false; updateMode('automatedsolving', autoSolverBoxAutomatedSolvingActive); AutoSolverBoxRepeatStartButton.textContent = 'START'; } if (autoSolverBoxAutomatedSolvingActive === true) { AutoSolverBoxRepeatStartButton.textContent = 'STOP'; AutoSolverBoxRepeatStartButtonActions(); } try { AutoSolverBoxRepeatStartButton.addEventListener('click', () => { if (autoSolverBoxRepeatAmount > 0 || DuolingoProSettingsNeverEndMode) { AutoSolverBoxRepeatStartButton.textContent = AutoSolverBoxRepeatStartButton.textContent === 'START' ? 'STOP' : 'START'; autoSolverBoxAutomatedSolvingActive = !autoSolverBoxAutomatedSolvingActive; updateMode('automatedsolving', autoSolverBoxAutomatedSolvingActive); } AutoSolverBoxRepeatStartButtonActions(); }); } catch(error) { } try { const AutoSolverBoxToggleT1ID1 = document.querySelector('#AutoSolverBoxToggleT1ID1'); const AutoSolverBoxToggleT1ID2 = document.querySelector('#AutoSolverBoxToggleT1ID2'); const AutoSolverBoxToggleT1ID3 = document.querySelector('#AutoSolverBoxToggleT1ID3'); AutoSolverBoxToggleT1ID1.addEventListener('click', () => { if (autoSolverBoxPracticeOnlyMode) { autoSolverBoxPracticeOnlyMode = !autoSolverBoxPracticeOnlyMode; updateMode('practicemode', autoSolverBoxPracticeOnlyMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID1, autoSolverBoxPracticeOnlyMode); } else if (!autoSolverBoxPracticeOnlyMode) { autoSolverBoxPracticeOnlyMode = !autoSolverBoxPracticeOnlyMode; autoSolverBoxRepeatLessonMode = !autoSolverBoxPracticeOnlyMode; autoSolverBoxListeningOnlyMode = !autoSolverBoxPracticeOnlyMode; updateMode('practicemode', autoSolverBoxPracticeOnlyMode); updateMode('lessonmode', autoSolverBoxRepeatLessonMode); updateMode('listeningmode', autoSolverBoxListeningOnlyMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID1, autoSolverBoxPracticeOnlyMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID2, autoSolverBoxRepeatLessonMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID3, autoSolverBoxListeningOnlyMode); } }); AutoSolverBoxToggleT1ID2.addEventListener('click', () => { if (autoSolverBoxRepeatLessonMode) { autoSolverBoxRepeatLessonMode = !autoSolverBoxRepeatLessonMode; updateMode('lessonmode', autoSolverBoxRepeatLessonMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID2, autoSolverBoxRepeatLessonMode); } else if (!autoSolverBoxRepeatLessonMode) { autoSolverBoxRepeatLessonMode = !autoSolverBoxRepeatLessonMode; autoSolverBoxPracticeOnlyMode = !autoSolverBoxRepeatLessonMode; autoSolverBoxListeningOnlyMode = !autoSolverBoxRepeatLessonMode; updateMode('practicemode', autoSolverBoxPracticeOnlyMode); updateMode('lessonmode', autoSolverBoxRepeatLessonMode); updateMode('listeningmode', autoSolverBoxListeningOnlyMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID1, autoSolverBoxPracticeOnlyMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID2, autoSolverBoxRepeatLessonMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID3, autoSolverBoxListeningOnlyMode); } }); AutoSolverBoxToggleT1ID3.addEventListener('click', () => { if (autoSolverBoxListeningOnlyMode) { autoSolverBoxListeningOnlyMode = !autoSolverBoxListeningOnlyMode; updateMode('listeningmode', autoSolverBoxListeningOnlyMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID3, autoSolverBoxListeningOnlyMode); } else { autoSolverBoxListeningOnlyMode = !autoSolverBoxListeningOnlyMode; autoSolverBoxPracticeOnlyMode = !autoSolverBoxListeningOnlyMode; autoSolverBoxRepeatLessonMode = !autoSolverBoxListeningOnlyMode; updateMode('practicemode', autoSolverBoxPracticeOnlyMode); updateMode('lessonmode', autoSolverBoxRepeatLessonMode); updateMode('listeningmode', autoSolverBoxListeningOnlyMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID1, autoSolverBoxPracticeOnlyMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID2, autoSolverBoxRepeatLessonMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID3, autoSolverBoxListeningOnlyMode); } }); updateAutoSolverToggles(AutoSolverBoxToggleT1ID1, autoSolverBoxPracticeOnlyMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID2, autoSolverBoxRepeatLessonMode); updateAutoSolverToggles(AutoSolverBoxToggleT1ID3, autoSolverBoxListeningOnlyMode); } catch(error) { } function updateAutoSolverToggles(element, variable) { let smthElement = element; let smthElementB = smthElement.querySelector(".DLPSettingsToggleT1B1"); let smthElementBI1 = smthElement.querySelector(".DLPSettingsToggleT1B1I1"); let smthElementBI2 = smthElement.querySelector(".DLPSettingsToggleT1B1I2"); function idk() { if (variable === false) { smthElement.classList.add("DLPSettingsToggleT1OFF"); smthElement.classList.remove("DLPSettingsToggleT1ON"); smthElementB.classList.add("DLPSettingsToggleT1OFFB1"); smthElementB.classList.remove("DLPSettingsToggleT1ONB1"); smthElementBI1.style.transform = 'scale(0)'; setTimeout(function() { smthElementBI1.style.display = "none"; smthElementBI2.style.display = ""; smthElementBI2.style.transform = 'scale(1)'; }, 100); } else if (variable === true) { smthElement.classList.add("DLPSettingsToggleT1ON"); smthElement.classList.remove("DLPSettingsToggleT1OFF"); smthElementB.classList.add("DLPSettingsToggleT1ONB1"); smthElementB.classList.remove("DLPSettingsToggleT1OFFB1"); smthElementBI2.style.transform = 'scale(0)'; setTimeout(function() { smthElementBI2.style.display = "none"; smthElementBI1.style.display = ""; smthElementBI1.style.transform = 'scale(1)'; }, 100); } else { console.log("error #1"); } }; idk(); } } function AutoSolverBoxRepeatStartButtonActions() { if (autoSolverBoxRepeatAmount > 0 || DuolingoProSettingsNeverEndMode) { pKVKQrfVcqrLWnpH(); } }; function pKVKQrfVcqrLWnpH() { if (PkJiQETebALNWeLt <= 20) { try { if (document.readyState === 'complete') { setTimeout(function() { PjYdVpmxDsskMlRs(); }, 2000); } else { setTimeout(function() { pKVKQrfVcqrLWnpH(); PkJiQETebALNWeLt++; }, 100); } } catch (error) { setTimeout(function() { PjYdVpmxDsskMlRs(); }, 2000); } } else { PjYdVpmxDsskMlRs(); } }; function PjYdVpmxDsskMlRs() { try { const imageUrl = 'https://d35aaqx5ub95lt.cloudfront.net/images/path/09f977a3e299d1418fde0fd053de0beb.svg'; const images = document.querySelectorAll('.TI9Is'); if (!images.length) { XyEOALuaeQicpGHW(); } else { let imagesProcessed = 0; let chestFound = false; images.forEach(image => { if (image.src === imageUrl) { image.click(); chestFound = true; setTimeout(function() { XyEOALuaeQicpGHW(); }, 2000); } imagesProcessed++; if (imagesProcessed >= images.length && !chestFound) { XyEOALuaeQicpGHW(); } }); } } catch (error) { XyEOALuaeQicpGHW(); } }; function XyEOALuaeQicpGHW() { if ((DuolingoProSettingsNeverEndMode || autoSolverBoxRepeatAmount > 0) && autoSolverBoxAutomatedSolvingActive) { if (autoSolverBoxPracticeOnlyMode) { window.location.href = "https://duolingo.com/practice"; } else if (autoSolverBoxRepeatLessonMode) { window.location.href = "https://duolingo.com/lesson/unit/1/level/1"; } else if (autoSolverBoxListeningOnlyMode) { window.location.href = "https://duolingo.com/practice-hub/listening-practice"; } else { window.location.href = "https://duolingo.com/lesson"; } } }; function checkURLForAutoSolverBox() { if (window.location.pathname === '/practice-hub/listening-practice' || window.location.pathname.includes('/lesson') || window.location.pathname === '/practice') { let jfgsdodhgsf = document.querySelector('#solveAllButton'); if (jfgsdodhgsf) { if (autoSolverBoxAutomatedSolvingActive === true) { solving(); } } else { setTimeout(function() { checkURLForAutoSolverBox(); }, 100); } } else { } } checkURLForAutoSolverBox(); injectContent(); let DuolingoSiderbarPaddingThingFunctionRepeatTimes = 20; let DuolingoProBoxHeightForSidebarPadding; function DuolingoHomeSidebarAddPaddingFunction() { if (window.location.pathname === '/learn' || window.location.pathname === '/practice-hub') { DuolingoProBoxHeightForSidebarPadding = document.querySelector('.AutoSolverBoxFirst'); try { const DuolingoSiderbarPaddingThing = document.querySelector('.Fc0NK'); DuolingoSiderbarPaddingThing.style.paddingBottom = String(String(DuolingoProBoxHeightForSidebarPadding.offsetHeight += 8) + 'px'); // or 574px if an 8px gap preferred } catch(error) { } } } setInterval(DuolingoHomeSidebarAddPaddingFunction, 100); function DuolingoRemoveLearnAds() { // if (window.location.pathname === '/learn' || window.location.pathname === '/shop') { try { const DuolingoRemoveLearnAdsElementOne = document.querySelector('._3bfsh'); DuolingoRemoveLearnAdsElementOne.remove(); } catch(error) { } // } } const RemovedByDuolingoProOneHTML = `

Ads Blocked by Duolingo Pro

HIDE

These ads were removed with ProBlock by Duolingo Pro.

`; const RemovedByDuolingoProOneCSS = ` .BlockedByDuolingoProBoxBackground { display: flex; width: 100%; padding: 16px; flex-direction: column; justify-content: center; align-items: center; gap: 4px; flex-shrink: 0; border-radius: 16px; border: 2px solid rgb(var(--color-swan)); background: rgb(var(--color-snow)); } .BlockedByDuolingoProBoxSectionOne { display: flex; align-items: center; gap: 8px; align-self: stretch; } .BlockedByDuolingoProBoxSectionOneTextOne { flex: 1 0 0; color: rgb(var(--color-eel)); font-size: 18px; font-weight: 700; margin: 0px; cursor: default; } .BlockedByDuolingoProBoxSectionOneTextTwo { color: var(--web-ui_button-color,rgb(var(--color-macaw))); font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; margin: 0px; cursor: pointer; transition: .1s; user-select: none; -moz-user-select: none; -webkit-text-select: none; -webkit-user-select: none; } .BlockedByDuolingoProBoxSectionOneTextTwo:hover { filter: brightness(1.1); } .BlockedByDuolingoProBoxSectionOneTextTwo:active { filter: brightness(1.2); } .BlockedByDuolingoProBoxSectionTwoTextOne { align-self: stretch; color: rgb(var(--color-hare)); font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; margin: 0px; cursor: default; } `; let injectedRemovedByDuolingoProOneElement = null; let injectedRemovedByDuolingoProOneStyle = null; function iforgot() { try { let targetDiv = document.querySelector('.Fc0NK'); if (targetDiv) { if (ProBlockBannerOneVisible) { if (!injectedRemovedByDuolingoProOneElement) { injectedRemovedByDuolingoProOneStyle = document.createElement('style'); injectedRemovedByDuolingoProOneStyle.type = 'text/css'; injectedRemovedByDuolingoProOneStyle.innerHTML = RemovedByDuolingoProOneCSS; document.head.appendChild(injectedRemovedByDuolingoProOneStyle); injectedRemovedByDuolingoProOneElement = document.createElement('div'); injectedRemovedByDuolingoProOneElement.innerHTML = RemovedByDuolingoProOneHTML; targetDiv.appendChild(injectedRemovedByDuolingoProOneElement); } else { let BlockedByDuolingoProBoxSectionOneTextTwoElement = document.querySelector('.BlockedByDuolingoProBoxSectionOneTextTwo'); let BlockedByDuolingoProBoxBackgroundElement = document.querySelector('.BlockedByDuolingoProBoxBackground'); BlockedByDuolingoProBoxSectionOneTextTwoElement.addEventListener('click', () => { ProBlockBannerOneVisible = false; localStorage.setItem("ProBlockBannerOneVisible", ProBlockBannerOneVisible); BlockedByDuolingoProBoxBackgroundElement.remove(); }); if (document.querySelector('.BlockedByDuolingoProBoxBackground')) { } else { injectedRemovedByDuolingoProOneElement = null; injectedRemovedByDuolingoProOneStyle = null; } } } } else { console.error("Target div with class 'Fc0NK' not found."); } } catch(error) {} } //if (DuolingoProSettingsProBlockMode) { // setInterval(iforgot, 100); // setInterval(DuolingoRemoveLearnAds, 100); //} const SendFeedbackBoxHTML = `

Send Feedback for Duolingo Pro

Join our new Discord community, give feedback faster

Our new Discord server is a great place to give feedback, as well as get up-to-date with the newest updates. Join here

Choose Feedback Type

Bug Report

Suggestion

Upload Photo - Optional

Email - Optional, can help us reach back

`; const SendFeedbackBoxCSS = ` .DuolingoProFeedbackBoxPromotionLinkPurple { color: rgba(88, 101, 242, 0.50); text-decoration-line: underline; transition: .1s; } .DuolingoProFeedbackBoxPromotionLinkPurple:hover { color: #5865F2; } .loldonttouchthisbit { display: flex; height: 54px; width: 100%; align-items: center; /*flex: 1 0 0;*/ border-radius: 8px; padding: 14px; cursor: pointer; transition: .1s; font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; overflow: hidden; } #SendFeedbackFileUploadButtonIDOne { border: 2px solid rgb(var(--color-swan)); border-bottom: 4px solid rgb(var(--color-swan)); background: rgb(var(--color-snow)); color: rgb(var(--color-eel)); } #SendFeedbackFileUploadButtonIDOne:hover { filter: brightness(0.95); } #SendFeedbackFileUploadButtonIDOne:active { height: 52px; border-bottom: 2px solid rgb(var(--color-swan)); filter: brightness(0.9); margin-top: 2px; } #SendFeedbackFileUploadButtonIDOne::file-selector-button { display: none; } #SendFeedbackFileUploadButtonIDTwo { border: 2px solid rgba(0, 0, 0, 0.20); border-bottom: 4px solid rgba(0, 0, 0, 0.20); background: #007AFF; color: rgb(241, 247, 251); } #SendFeedbackFileUploadButtonIDTwo:hover { filter: brightness(0.95); } #SendFeedbackFileUploadButtonIDTwo:active { height: 52px; border-bottom: 2px solid rgba(0, 0, 0, 0.20); filter: brightness(0.9); margin-top: 2px; } #SendFeedbackFileUploadButtonIDTwo::file-selector-button { display: none; } .SendFeebackBoxLayers { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 8px; width: 100%; } .SendFeebackBoxSectionOneTextOne { color: rgb(var(--color-eel)); font-size: 24px; font-style: normal; font-weight: 700; line-height: normal; margin-top: 0px; margin-bottom: 0px; height: 32px; cursor: default; } .SendFeebackBoxSectionThree { display: flex; width: 100%; flex-direction: column; justify-content: center; color: rgb(var(--color-eel)); font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; cursor: default; margin-top: 0px; margin-bottom: 0px; height: 32px; } .SendFeebackBoxSectionFourButtonOneBackground { display: flex; height: 54px; align-items: center; flex: 1 0 0; border-radius: 8px; border: 2px solid rgb(var(--color-swan)); border-bottom: 4px solid rgb(var(--color-swan)); background: rgb(var(--color-snow)); cursor: pointer; transition: .1s; } .SendFeebackBoxSectionFourButtonOneBackground:hover { filter: brightness(0.95); } .SendFeebackBoxSectionFourButtonOneBackground:active { height: 52px; border-bottom: 2px solid rgb(var(--color-swan)); filter: brightness(0.9); margin-top: 2px; } .SendFeebackBoxSectionFourButtonOneIconOneBox { display: flex; width: 48px; height: 48px; justify-content: center; align-items: center; } .SendFeebackBoxSectionFourButtonOneIconOne { appearance: none; width: 20px; height: 20px; flex-shrink: 0; margin-right: 16px; margin-left: 16px; border-radius: 20px; border: 4px solid rgb(var(--color-swan), 0.4); background: rgb(var(--color-swan), 0.2); opacity: 100% !important; cursor: pointer; } .SendFeebackBoxSectionFourButtonOneIconTwoBox { display: flex; width: 48px; height: 48px; justify-content: center; align-items: center; } .SendFeebackBoxSectionFourButtonOneIconTwo { display: flex; width: 16px; height: 16px; flex-direction: column; justify-content: center; align-items: center; color: rgba(255, 45, 85, 0.00); text-align: center; font-size: 15px; font-style: normal; font-weight: 700; line-height: normal; fill: #FF2D55; } .SendFeebackBoxSectionSix { display: flex; height: 54px; align-items: center; align-self: stretch; flex: 1 0 0; border-radius: 8px; border: 2px solid rgba(0, 0, 0, 0.20); border-bottom: 4px solid rgba(0, 0, 0, 0.20); background: #007AFF; cursor: pointer; transition: .1s; } .SendFeebackBoxSectionSix:hover { filter: brightness(0.95); } .SendFeebackBoxSectionSix:active { height: 52px; border-bottom: 2px solid rgba(0, 0, 0, 0.20); filter: brightness(0.9); margin-top: 2px; } .SendFeebackBoxSectionSixIconOneBox { display: flex; width: 48px; height: 48px; justify-content: center; align-items: center; } .SendFeebackBoxSectionSixIconOne { width: 20px; height: 20px; flex-shrink: 0; border-radius: 20px; border: 4px solid rgb(241, 247, 251, 0.40); background: rgb(241, 247, 251, 0.40); } .SendFeebackBoxSectionSixTextOne { flex: 1 0 0; color: rgb(241, 247, 251); font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; user-select: none; -moz-user-select: none; -webkit-text-select: none; -webkit-user-select: none; } .SendFeebackBoxSectionSixIconTwoBox { display: flex; width: 48px; height: 48px; justify-content: center; align-items: center; } .SendFeebackBoxSectionSixIconTwo { display: flex; width: 16px; height: 16px; flex-direction: column; justify-content: center; align-items: center; fill: rgb(241, 247, 251); text-align: center; line-height: normal; } .SendFeebackBoxSectionSeven { // height: 48px; height: 56px; align-self: stretch; border-radius: 8px; position: relative; cursor: not-allowed !important; } .SendFeebackBoxSectionSevenBoxOne { flex-shrink: 0; display: flex; gap: 32px; align-items: center; height: 54px; /* set the height */ overflow: hidden; /* clip any overflowing content */ border-radius: 8px; pointer-events: none; } .SendFeebackBoxSectionSevenBoxOneBoxOne { width: 16px; height: 100px; transform: rotate(45deg); flex-shrink: 0; background: rgb(var(--color-eel), 0.1); } .SendFeebackBoxSectionSevenBoxTwo { display: flex; height: 54px; align-items: center; align-self: stretch; flex: 1 0 0; position: absolute; width: 100%; border-radius: 8px; border: 2px solid rgb(var(--color-swan)); border-bottom: 4px solid rgb(var(--color-swan)); background: rgb(var(--color-snow)); // cursor: pointer; transition: .1s; } .SendFeebackBoxSectionSevenBoxTwo:hover { filter: brightness(0.95); } .SendFeebackBoxSectionSevenBoxTwo:active { border-bottom: 4px solid rgb(var(--color-swan)); filter: brightness(0.95); } .SendFeebackBoxSectionSevenBoxTwoIconOneBox { display: flex; width: 48px; height: 48px; justify-content: center; align-items: center; } .SendFeebackBoxSectionSevenBoxTwoIconOne { width: 20px; height: 20px; flex-shrink: 0; border-radius: 20px; border: 4px solid rgb(var(--color-swan), 0.4); background: rgb(var(--color-swan), 0.2); } .SendFeebackBoxSectionSevenBoxTwoTextOne { flex: 1 0 0; color: rgb(var(--color-swan)); font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; margin-top: 0px; margin-bottom: 0px; user-select: none; -moz-user-select: none; -webkit-text-select: none; -webkit-user-select: none; } .SendFeebackBoxSectionSevenBoxTwoIconTwoBox { display: flex; width: 48px; height: 48px; justify-content: center; align-items: center; } .SendFeebackBoxSectionSevenBoxTwoIconTwo { display: flex; width: 16px; height: 16px; flex-direction: column; justify-content: center; align-items: center; text-align: center; line-height: normal; fill: rgb(var(--color-swan)); } .SendFeedbackBoxSectionEight { display: flex; justify-content: center; align-items: center; gap: 8px; align-self: stretch; } .SendFeebackBoxSectionEightTextOne { display: flex; flex-direction: column; justify-content: center; flex: 1 0 0; align-self: stretch; color: #FFF; text-align: center; font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; user-select: none; -moz-user-select: none; -webkit-text-select: none; -webkit-user-select: none; } `; let randomValue; let randomValueInText; function setRandomValue() { if (Boolean(localStorage.getItem("RandomValue")) === false) { randomValue = Math.floor(Math.random() * 10000000000); randomValueInText = String(randomValue); // Prepend zeros to the string until it is 10 digits long while (randomValueInText.length < 10) { randomValueInText = "0" + randomValueInText; } localStorage.setItem("RandomValue", randomValueInText); console.log("Generated ID: ", randomValue); } else { randomValue = localStorage.getItem("RandomValue"); szdfgvhbjnk(); } } setRandomValue(); let fileInput; let injectedSendFeedBackBoxElement = null; let injectedSendFeedBackBoxStyle = null; let isSendFeebackBoxSectionEightSendButtonEnabled = false; let SendFeedbackTextAreaValue; let emailContactValue; let idktype = 'Bug Report'; let sendFeedbackStatus = 'none'; function SendFeedBackBox(visibility) { if (visibility === true) { if (!injectedSendFeedBackBoxElement) { // Creating a container for the overlay injectedSendFeedBackBoxElement = document.createElement('div'); injectedSendFeedBackBoxElement.innerHTML = SendFeedbackBoxHTML; document.body.appendChild(injectedSendFeedBackBoxElement); // Creating a style tag for CSS injectedSendFeedBackBoxStyle = document.createElement('style'); injectedSendFeedBackBoxStyle.type = 'text/css'; injectedSendFeedBackBoxStyle.innerHTML = SendFeedbackBoxCSS; document.head.appendChild(injectedSendFeedBackBoxStyle); let poijhugjfhd = setInterval(SendFeedbackTextAreaStuff, 100); let SendFeedbackWholeDiv = document.querySelector('#SendFeebackBoxShadow'); let SendFeedbackBoxDiv = document.querySelector('#SendFeebackBoxBackground'); setTimeout(function() { SendFeedbackWholeDiv.style.opacity = '1'; //SendFeedbackBoxDiv.style.transform = 'scale(1)'; }, 50); fileInput = document.querySelector('.loldonttouchthisbit'); fileInput.addEventListener('change', function() { if (fileInput.files.length > 0) { fileInput.setAttribute('id', 'SendFeedbackFileUploadButtonIDTwo'); } else { fileInput.setAttribute('id', 'SendFeedbackFileUploadButtonIDOne'); } }); const SendFeedbackCloseButton = document.querySelector('#SendFeebackBoxSectionOneCancelBoxBackground'); SendFeedbackCloseButton.addEventListener('click', () => { SendFeedBackBox(false); clearInterval(poijhugjfhd); }); const TextAreaOneOne = document.getElementById('SendFeebackBoxSectionTwoID'); const TextAreaTwoOne = document.getElementById('DLPFeedbackTextField2'); // Set the value of the textarea to the variable const bugRadio = document.getElementById('SendFeebackTypeButtonOne'); const suggestionRadio = document.getElementById('SendFeebackTypeButtonTwo'); bugRadio.addEventListener('mousedown', () => { if (idktype === 'Bug Report') { bugRadio.style.border = '2px solid rgba(0, 0, 0, 0.20)'; bugRadio.style.borderBottom = '2px solid rgba(0, 0, 0, 0.20)'; } else { bugRadio.style.border = '2px solid rgb(var(--color-swan))'; bugRadio.style.borderBottom = '2px solid rgb(var(--color-swan))'; } }); bugRadio.addEventListener('mouseup', () => { idktype = 'Bug Report'; updateDuolingoProSendFeedbackButtons(bugRadio, idktype); }); suggestionRadio.addEventListener('mousedown', () => { if (idktype === 'Suggestion') { suggestionRadio.style.border = '2px solid rgba(0, 0, 0, 0.20)'; suggestionRadio.style.borderBottom = '2px solid rgba(0, 0, 0, 0.20)'; } else { suggestionRadio.style.border = '2px solid rgb(var(--color-swan))'; suggestionRadio.style.borderBottom = '2px solid rgb(var(--color-swan))'; } }); suggestionRadio.addEventListener('mouseup', () => { idktype = 'Suggestion'; updateDuolingoProSendFeedbackButtonsTwo(bugRadio, idktype); }); addEventListener('mouseup', () => { updateDuolingoProSendFeedbackButtons(bugRadio, idktype); updateDuolingoProSendFeedbackButtonsTwo(suggestionRadio, idktype); }); updateDuolingoProSendFeedbackButtons(bugRadio, idktype); updateDuolingoProSendFeedbackButtonsTwo(suggestionRadio, idktype); const SendFeebackBoxSectionTwo = document.querySelector('.SendFeebackBoxSectionTwo'); let _283b = false; const SendFeebackBoxSectionEightSendButton = document.querySelector('#SendFeebackBoxSectionEightSendButton'); SendFeebackBoxSectionEightSendButton.addEventListener('click', () => { if (isSendFeebackBoxSectionEightSendButtonEnabled && !_283b) { _283b = true; SendFeedbackTextAreaValue = TextAreaOneOne.value; emailContactValue = TextAreaTwoOne.value; sendFeedbackServer(SendFeedbackTextAreaValue, idktype, emailContactValue); sendFeedbackStatus = 'trying'; function checkFlag() { if (sendFeedbackStatus === 'trying') { SendFeebackBoxSectionEightSendButton.textContent = 'SENDING'; setTimeout(function() { checkFlag(); }, 100); } else if (sendFeedbackStatus === 'true') { SendFeebackBoxSectionEightSendButton.textContent = 'SUCCESSFULLY SENT'; setTimeout(function() { location.reload(); }, 2000); } else if (sendFeedbackStatus === 'error') { SendFeebackBoxSectionEightSendButton.textContent = 'ERROR SENDING'; SendFeebackBoxSectionEightSendButton.style.background = '#FF2D55'; SendFeebackBoxSectionEightSendButton.style.border = '2px solid rgba(0, 0, 0, 0.20)'; SendFeebackBoxSectionEightSendButton.style.borderBottom = '4px solid rgba(0, 0, 0, 0.20)'; setTimeout(function() { SendFeebackBoxSectionEightSendButton.textContent = 'TRY AGAIN'; }, 2000); setTimeout(function() { SendFeebackBoxSectionEightSendButton.textContent = 'SEND'; SendFeebackBoxSectionEightSendButton.style.background = ''; SendFeebackBoxSectionEightSendButton.style.border = ''; SendFeebackBoxSectionEightSendButton.style.borderBottom = ''; _283b = false; }, 4000); sendFeedbackStatus = 'empty'; } else if (sendFeedbackStatus === 'empty') { setTimeout(function() { checkFlag(); _283b = false; }, 100); } } checkFlag(); } }); function updateDuolingoProSendFeedbackButtons(element, value) { let textElement = element.querySelector('#SendFeebackBoxSectionFourButtonOneTextOne'); let iconElement = element.querySelector('.SendFeebackBoxSectionFourButtonOneIconOne'); if (value === 'Bug Report') { element.style.background = '#FF2D55'; element.style.border = '2px solid rgba(0, 0, 0, 0.20)'; element.style.borderBottom = '4px solid rgba(0, 0, 0, 0.20)'; textElement.style.color = 'rgb(241, 247, 251)'; iconElement.style.border = '4px solid rgb(241, 247, 251, 0.40)'; iconElement.style.background = 'rgb(241, 247, 251, 0.40)'; } else { element.style.background = 'rgb(var(--color-snow))'; element.style.border = '2px solid rgb(var(--color-swan))'; element.style.borderBottom = '4px solid rgb(var(--color-swan))'; textElement.style.color = 'rgb(var(--color-eel), 0.4)'; iconElement.style.border = '4px solid rgb(var(--color-swan))'; iconElement.style.background = 'rgb(var(--color-swan), 0.4)'; } } function updateDuolingoProSendFeedbackButtonsTwo(element, value) { let textElement = element.querySelector('#SendFeebackBoxSectionFourButtonOneTextOne'); let iconElement = element.querySelector('.SendFeebackBoxSectionFourButtonOneIconOne'); if (value === 'Suggestion') { element.style.background = '#34C759'; element.style.border = '2px solid rgba(0, 0, 0, 0.20)'; element.style.borderBottom = '4px solid rgba(0, 0, 0, 0.20)'; textElement.style.color = 'rgb(241, 247, 251)'; iconElement.style.border = '4px solid rgb(241, 247, 251, 0.40)'; iconElement.style.background = 'rgb(241, 247, 251, 0.40)'; } else { element.style.background = 'rgb(var(--color-snow))'; element.style.border = '2px solid rgb(var(--color-swan))'; element.style.borderBottom = '4px solid rgb(var(--color-swan))'; textElement.style.color = 'rgb(var(--color-eel), 0.4)'; iconElement.style.border = '4px solid rgb(var(--color-swan))'; iconElement.style.background = 'rgb(var(--color-swan), 0.4)'; } } } } else if (visibility === false) { if (injectedSendFeedBackBoxElement) { let SendFeedbackWholeDiv = document.querySelector('#SendFeebackBoxShadow'); let SendFeedbackBoxDiv = document.querySelector('#SendFeebackBoxBackground'); setTimeout(function() { SendFeedbackWholeDiv.style.opacity = '0'; //SendFeedbackBoxDiv.style.transform = 'scale(0.8)'; }, 50); setTimeout(function() { document.body.removeChild(injectedSendFeedBackBoxElement); document.head.removeChild(injectedSendFeedBackBoxStyle); injectedSendFeedBackBoxElement = null; injectedSendFeedBackBoxStyle = null; }, 500); } } } function SendFeedbackTextAreaStuff() { try { const SendFeebackBoxSectionEightSendButton = document.querySelector('#SendFeebackBoxSectionEightSendButton'); const SendFeebackBoxSectionTwo = document.querySelector('#SendFeebackBoxSectionTwoID'); function disableHoverOne() { SendFeebackBoxSectionEightSendButton.style.marginTop = ''; SendFeebackBoxSectionEightSendButton.style.height = ''; SendFeebackBoxSectionEightSendButton.style.border = ''; SendFeebackBoxSectionEightSendButton.style.borderBottom = ''; } function enableHoverOne() { SendFeebackBoxSectionEightSendButton.style.marginTop = '2px'; SendFeebackBoxSectionEightSendButton.style.height = '52px'; SendFeebackBoxSectionEightSendButton.style.border = '2px solid rgb(var(--color-eel), 0.2)'; SendFeebackBoxSectionEightSendButton.style.borderBottom = '2px solid rgb(var(--color-eel), 0.2)'; } if (SendFeebackBoxSectionTwo.value.trim().length > 16) { SendFeebackBoxSectionEightSendButton.style.opacity = '100%'; SendFeebackBoxSectionEightSendButton.style.cursor = 'pointer'; isSendFeebackBoxSectionEightSendButtonEnabled = true; } else { SendFeebackBoxSectionEightSendButton.style.opacity = '0.5'; SendFeebackBoxSectionEightSendButton.style.cursor = 'not-allowed'; isSendFeebackBoxSectionEightSendButtonEnabled = false; } if (isSendFeebackBoxSectionEightSendButtonEnabled) { //disableHoverOne(); } else { //enableHoverOne(); } } catch (error) { } } const DuolingoProSettingsBoxHTML = `

Settings

2.0 BETA 9.6.7

BETA

Shade

Duolingo Pro adds a view on top of your lesson to hide what AutoSolver is doing behind.

BETA

Question Solve Delay

Adjust how many seconds it takes for each question to get solved. A lower number will solve faster, and a higher number will solve slower. Use a higher number if your computer is slow or AutoSolver answers incorrectly. Continue clicking on the toggle to enter custom timing.

0.6

BETA

AntiStuck

In a case where Duolingo Pro fails to answer a question, AntiStuck will send an anomosus fail report, which can be used by our developers to fix AutoSolve for that type of question, and also reload the lesson, in hopes of not encountering the same question in the next lesson.

RECOMMENDED IF YOU HAVE LESS THAN 8GB OF RAM

Memory Saver

Memory Saver gradually loads Duolingo Pro onto Duolingo, helping with memory management. If you're encountering lag or crashes with Duolingo Pro, try turning this mode ON. Please note, using an incompatible browser or having a very slow internet connection may result further complications.

DISABLED UNTIL NEXT MONTH

Manually Check for an Update

Duolingo Pro automatically performs periodic checks for updates. Alternatively, you can manually check for updates too.

Your Time with Duolingo Pro

Questions Solved:

0

Lessons Solved:

0

XP Gained:

0

Contributors & Libraries

anonymoushackerIV, Eclipse, ByThon1, surebrec, SicariusBlack, fakeduo, JxxIT

`; const DuolingoProSettingsBoxCSS = ` .DuolingoProSettingsBoxLayers { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; align-self: stretch; overflow-y: auto; padding: 16px 0 16px 0; margin-right: -16px; padding-right: 16px; } .DuolingoProSettingsBoxSectionOne { display: flex; height: 36px; justify-content: space-between; align-items: center; align-self: stretch; } .DuolingoProSettingsBoxSectionOneBoxOne { display: flex; //width: 98px; height: 36px; flex-direction: column; justify-content: center; align-items: center; border-radius: 8px; border: 2px solid rgba(0, 0, 0, 0.20); background: #FF2D55; padding-left: 8px; padding-right: 8px; } .DuolingoProSettingsBoxSectionOneBoxOneTextOne { color: #FFF; font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; margin: 0px; cursor: default; } .DuolingoProSettingsBoxSectionTwo { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; align-self: stretch; } .DuolingoProSettingsBoxSectionTwoBoxOne { display: flex; align-items: center; gap: 16px; align-self: stretch; } .DuolingoProSettingsBoxSectionTwoBoxOneBoxOne { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; flex: 1 0 0; } .DuolingoProSettingsBoxSectionTwoBoxOneBoxOneTextOne { align-self: stretch; color: rgb(var(--color-eel)); font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; margin: 0px; cursor: default; } .DuolingoProSettingsBoxSectionTwoBoxOneBoxOneTextTwo { align-self: stretch; color: rgb(var(--color-hare)); font-size: 14px; font-style: normal; font-weight: 700; line-height: normal; margin: 0px; cursor: default; } .DuolingoProSettingsBoxSectionTwoBoxOneBoxOneTextThree { align-self: stretch; font-size: 14px; font-style: normal; font-weight: 700; line-height: normal; margin: 0px; cursor: default; } .DuolingoProSettingsBoxSectionThree { display: flex; align-items: flex-start; gap: 8px; align-self: stretch; } .DuolingoProSettingsBoxContributorsLink { color: rgba(0, 122, 255, 0.50); text-decoration-line: underline; transition: .1s; } .DuolingoProSettingsBoxContributorsLink:hover { color: #007AFF; } `; let injectedDuolingoProSettingsBoxElement = null; let injectedDuolingoProSettingsBoxStyle = null; function injectDuolingoProSettingsBox() { if (wasDuolingoProSettingsButtonOnePressed === true) { if (!injectedDuolingoProSettingsBoxElement) { injectedDuolingoProSettingsBoxElement = document.createElement('div'); injectedDuolingoProSettingsBoxElement.innerHTML = DuolingoProSettingsBoxHTML; document.body.appendChild(injectedDuolingoProSettingsBoxElement); injectedDuolingoProSettingsBoxStyle = document.createElement('style'); injectedDuolingoProSettingsBoxStyle.type = 'text/css'; injectedDuolingoProSettingsBoxStyle.innerHTML = DuolingoProSettingsBoxCSS; document.head.appendChild(injectedDuolingoProSettingsBoxStyle); let DuolingoProSettingsBoxWholeDiv = document.querySelector('#DuolingoProSettingsBoxShadow'); setTimeout(function() { DuolingoProSettingsBoxWholeDiv.style.opacity = '1'; }, 50); const DuolingoProSettingsBoxCancelButton = document.querySelector('#DuolingoProSettingsBoxCancelButton'); DuolingoProSettingsBoxCancelButton.addEventListener('click', () => { let DuolingoProSettingsBoxWholeDiv = document.querySelector('#DuolingoProSettingsBoxShadow'); setTimeout(function() { DuolingoProSettingsBoxWholeDiv.style.opacity = '0'; }, 50); setTimeout(function() { wasDuolingoProSettingsButtonOnePressed = false; //AutoSolverSettingsShowPracticeOnlyModeForAutoSolverBox = JSON.parse(localStorage.getItem('AutoSolverSettingsShowPracticeOnlyModeForAutoSolverBox')); //AutoSolverSettingsShowRepeatLessonModeForAutoSolverBox = JSON.parse(localStorage.getItem('AutoSolverSettingsShowRepeatLessonModeForAutoSolverBox')); AutoSolverSettingsLowPerformanceMode = JSON.parse(localStorage.getItem('AutoSolverSettingsLowPerformanceMode')); solveSpeed = parseFloat(localStorage.getItem('duopro.autoSolveDelay')); }, 500); }); const DuolingoProSettingsBoxSaveButton = document.querySelector('#DuolingoProSettingsBoxSaveButton'); DuolingoProSettingsBoxSaveButton.addEventListener('click', () => { //if (JSON.parse(localStorage.getItem('AutoSolverSettingsLowPerformanceMode')) !== AutoSolverSettingsLowPerformanceMode) { // settingsStuff("Duolingo Pro Low Performance Mode", AutoSolverSettingsLowPerformanceMode ? 'ON' : 'OFF'); //} //if (JSON.parse(localStorage.getItem('DuolingoProSettingsProBlockMode')) !== DuolingoProSettingsProBlockMode) { // settingsStuff("Duolingo Pro ProBlock", DuolingoProSettingsProBlockMode ? 'ON' : 'OFF'); //} //if (JSON.parse(localStorage.getItem('DuolingoProShadeLessonsMode')) !== DuolingoProShadeLessonsMode) { // settingsStuff("Duolingo Pro Shade Mode", DuolingoProShadeLessonsMode ? 'ON' : 'OFF'); //} //if (JSON.parse(localStorage.getItem('DuolingoProAntiStuckProtectionMode')) !== DuolingoProAntiStuckProtectionMode) { // settingsStuff("Duolingo Pro AntiStuck Protection", DuolingoProAntiStuckProtectionMode ? 'ON' : 'OFF'); //} if (parseFloat(localStorage.getItem('duopro.autoSolveDelay')) !== solveSpeed) { } localStorage.setItem('duopro.autoSolveDelay', solveSpeed); localStorage.setItem('DuolingoProShadeLessonsMode', DuolingoProShadeLessonsMode); //localStorage.setItem('AutoSolverSettingsLowPerformanceMode', AutoSolverSettingsLowPerformanceMode); //localStorage.setItem('DuolingoProSettingsProBlockMode', DuolingoProSettingsProBlockMode); //localStorage.setItem('DuolingoProShadeLessonsMode', DuolingoProShadeLessonsMode); localStorage.setItem('DuolingoProAntiStuckProtectionMode', DuolingoProAntiStuckProtectionMode); localStorage.setItem('DLPOMEGA', DLPOMEGA); DuolingoProSettingsBoxSaveButton.textContent = 'SAVING AND RELOADING'; setTimeout(function() { //wasDuolingoProSettingsButtonOnePressed = false; location.reload(); }, 2000); }); document.querySelector('#eASGBnBrCZmjwbBq').textContent = String(duoproForeverTotalQuestions); document.querySelector('#WuLExbHJuqjJkLpE').textContent = String(duoproForeverTotalLessons); const DuolingoProSettingsBoxToggleT1ID1 = document.querySelector('#DuolingoProSettingsBoxToggleT1ID1'); DuolingoProSettingsBoxToggleT1ID1.addEventListener('click', () => { DuolingoProShadeLessonsMode = !DuolingoProShadeLessonsMode; updateDuolingoProSettingsToggle(1, DuolingoProSettingsBoxToggleT1ID1, DuolingoProShadeLessonsMode); }); const DuolingoProSettingsBoxToggleT2ID2 = document.querySelector('#DuolingoProSettingsBoxToggleT2ID2'); DuolingoProSettingsBoxToggleT2ID2.addEventListener('click', () => { if (solveSpeed === 0.6) { solveSpeed = 0.7; updateDuolingoProSettingsToggle(2, DuolingoProSettingsBoxToggleT2ID2, solveSpeed); } else if (solveSpeed === 0.7) { solveSpeed = 0.8; updateDuolingoProSettingsToggle(2, DuolingoProSettingsBoxToggleT2ID2, solveSpeed); } else if (solveSpeed === 0.8) { solveSpeed = 0.9; updateDuolingoProSettingsToggle(2, DuolingoProSettingsBoxToggleT2ID2, solveSpeed); } else if (solveSpeed === 0.9) { updateDuolingoProSettingsToggle(2, DuolingoProSettingsBoxToggleT2ID2, "Custom"); setTimeout(function() { ObywJEgHfSkHSgDTFunction(); }, 100); } else { solveSpeed = 0.6; updateDuolingoProSettingsToggle(2, DuolingoProSettingsBoxToggleT2ID2, solveSpeed); } }); const DuolingoProSettingsBoxToggleT1ID2 = document.querySelector('#DuolingoProSettingsBoxToggleT1ID2'); DuolingoProSettingsBoxToggleT1ID2.addEventListener('click', () => { DuolingoProAntiStuckProtectionMode = !DuolingoProAntiStuckProtectionMode; updateDuolingoProSettingsToggle(1, DuolingoProSettingsBoxToggleT1ID2, DuolingoProAntiStuckProtectionMode); }); const DuolingoProSettingsBoxToggleT1ID3 = document.querySelector('#DuolingoProSettingsBoxToggleT1ID3'); DuolingoProSettingsBoxToggleT1ID3.addEventListener('click', () => { DLPOMEGA = !DLPOMEGA; updateDuolingoProSettingsToggle(1, DuolingoProSettingsBoxToggleT1ID3, DLPOMEGA); }); const DuolingoProSettingsBoxToggleT3ID1 = document.querySelector('#DLPSettingsToggleT3ID3'); DuolingoProSettingsBoxToggleT1ID2.addEventListener('click', () => { //DuolingoProAntiStuckProtectionMode = !DuolingoProAntiStuckProtectionMode; //updateDuolingoProSettingsToggle(1, DuolingoProSettingsBoxToggleT1ID2, DuolingoProAntiStuckProtectionMode); }); function slideEventForT22() { var startX = null; var startY = null; var pressed = false; document.addEventListener('mousedown', function(event) { if (event.target.classList.contains('DLPSettingsToggleRmElement')) { startX = event.clientX; startY = event.clientY; pressed = true; } }); document.addEventListener('mouseup', function(event) { if (pressed) { let currentX = event.clientX; let currentY = event.clientY; pressed = false; if (Math.abs(currentX - startX) > 20 || Math.abs(currentY - startY) > 20) { notificationCall("Try clicking instead of swiping", "Click on the toggle instead of swiping."); } } }); } slideEventForT22(); function updateDuolingoProSettingsToggleAll() { updateDuolingoProSettingsToggle(1, DuolingoProSettingsBoxToggleT1ID1, DuolingoProShadeLessonsMode); updateDuolingoProSettingsToggle(2, DuolingoProSettingsBoxToggleT2ID2, solveSpeed); updateDuolingoProSettingsToggle(1, DuolingoProSettingsBoxToggleT1ID2, DuolingoProAntiStuckProtectionMode); updateDuolingoProSettingsToggle(1, DuolingoProSettingsBoxToggleT1ID3, DLPOMEGA); } updateDuolingoProSettingsToggleAll(); } } else { if (injectedDuolingoProSettingsBoxElement) { document.body.removeChild(injectedDuolingoProSettingsBoxElement); document.head.removeChild(injectedDuolingoProSettingsBoxStyle); injectedDuolingoProSettingsBoxElement = null; injectedDuolingoProSettingsBoxStyle = null; } } } setInterval(injectDuolingoProSettingsBox, 100); function updateDuolingoProSettingsToggle(id, element, variable) { if (id === 1) { let smthElement = element; let smthElementB = smthElement.querySelector(".DLPSettingsToggleT1B1"); let smthElementBI1 = smthElement.querySelector(".DLPSettingsToggleT1B1I1"); let smthElementBI2 = smthElement.querySelector(".DLPSettingsToggleT1B1I2"); if (variable === false) { smthElement.classList.add("DLPSettingsToggleT1OFF"); smthElement.classList.remove("DLPSettingsToggleT1ON"); smthElementB.classList.add("DLPSettingsToggleT1OFFB1"); smthElementB.classList.remove("DLPSettingsToggleT1ONB1"); smthElementBI1.style.transform = 'scale(0)'; setTimeout(function() { smthElementBI1.style.display = "none"; smthElementBI2.style.display = ""; smthElementBI2.style.transform = 'scale(1)'; }, 100); } else if (variable === true) { smthElement.classList.add("DLPSettingsToggleT1ON"); smthElement.classList.remove("DLPSettingsToggleT1OFF"); smthElementB.classList.add("DLPSettingsToggleT1ONB1"); smthElementB.classList.remove("DLPSettingsToggleT1OFFB1"); smthElementBI2.style.transform = 'scale(0)'; setTimeout(function() { smthElementBI2.style.display = "none"; smthElementBI1.style.display = ""; smthElementBI1.style.transform = 'scale(1)'; }, 100); } else { console.log("error #11"); } } else if (id === 2) { let elementTB = element.querySelector(".DLPSettingsToggleT2B1"); let elementTBT = element.querySelector(".DLPSettingsToggleT2B1T1"); if (variable === 0.6) { elementTB.style.marginLeft = "6px"; elementTBT.textContent = "0.6"; elementTB.style.width = ""; } else if (variable === 0.7) { elementTB.style.marginLeft = "22px"; elementTBT.textContent = "0.7"; } else if (variable === 0.8) { elementTB.style.marginLeft = "38px"; elementTBT.textContent = "0.8"; } else if (variable === 0.9) { elementTB.style.marginLeft = "54px"; elementTBT.textContent = "0.9"; } else if (variable === "Custom") { elementTB.style.marginLeft = "6px"; elementTB.style.width = "80px"; elementTBT.textContent = "Custom"; } else { elementTB.style.marginLeft = "6px"; elementTB.style.width = "80px"; elementTBT.textContent = String(variable); } } else if (id === 3) { } } const ObywJEgHfSkHSgDT = `

Custom Solve Delay

`; let ObywJEgHfSkHSgDTElement = null; function ObywJEgHfSkHSgDTFunction() { try { if (!ObywJEgHfSkHSgDTElement) { document.body.insertAdjacentHTML('beforeend', ObywJEgHfSkHSgDT); ObywJEgHfSkHSgDTElement = ObywJEgHfSkHSgDT; let ooSOIuzdgFhWQnMF = document.querySelector("#DLPSettingsBoxCustomSolveDelayBoxOneID") setTimeout(function() { ooSOIuzdgFhWQnMF.style.opacity = "1"; }, 50); let dyYWhDVQJASxSpEt = document.querySelector('#DLPSettingsBoxCustomSolveDelayBoxOneCancelButtonID'); let WFJpVXqPJOKtwFRX = document.querySelector('#DLPSettingsBoxCustomSolveDelayBoxOneSaveButtonID'); dyYWhDVQJASxSpEt.addEventListener('click', () => { solveSpeed = 0.6; const DuolingoProSettingsBoxToggleT2ID2 = document.querySelector('#DuolingoProSettingsBoxToggleT2ID2'); updateDuolingoProSettingsToggle(2, DuolingoProSettingsBoxToggleT2ID2, solveSpeed); setTimeout(function() { ooSOIuzdgFhWQnMF.style.opacity = '0'; }, 50); ObywJEgHfSkHSgDTElement = null; ooSOIuzdgFhWQnMF.remove(); }); WFJpVXqPJOKtwFRX.addEventListener('click', () => { let inputValue = document.getElementById('DLPSettingsBoxCustomSolveDelayBoxOneInputID').value.trim(); let regex = /^[0-9]+(\.[0-9]+)?$/; if (regex.test(inputValue) && inputValue >= 0.6 && inputValue <= 30) { solveSpeed = parseFloat(inputValue).toFixed(1); const DuolingoProSettingsBoxToggleT2ID2 = document.querySelector('#DuolingoProSettingsBoxToggleT2ID2'); updateDuolingoProSettingsToggle(2, DuolingoProSettingsBoxToggleT2ID2, solveSpeed); setTimeout(function() { ooSOIuzdgFhWQnMF.style.opacity = '0'; }, 50); ObywJEgHfSkHSgDTElement = null; ooSOIuzdgFhWQnMF.remove(); } else { notificationCall("Invalid Number", "Make sure to enter a number between 0.6 and 30, with no other text or spaces. "); //alert('Input is invalid. Please enter a number between 0.6 and 30 with no more than 1 decimal.'); } }); } } catch(error) {} } let downloadStuffVar = 'none'; let updateStuffVar = 'none'; if (String(localStorage.getItem('duolingoProLastInstalledVersion')) === null || String(localStorage.getItem('duolingoProLastInstalledVersion')) === "null") { downloadStuffVar = 'trying'; setTimeout(function() { versionServerStuff('download', duolingoProCurrentVersion); checkFlagTwo(); }, 2000); function checkFlagTwo() { if (downloadStuffVar === 'trying') { setTimeout(function() { checkFlagTwo(); }, 100); } else if (downloadStuffVar === 'true') { localStorage.setItem('duolingoProLastInstalledVersion', duolingoProCurrentVersion); } else if (downloadStuffVar === 'error') { setTimeout(function() { versionServerStuff('download', duolingoProCurrentVersion); checkFlagTwo(); }, 1000); } else if (downloadStuffVar === 'empty') { notificationCall("Duolingo Pro Encountered An Error", "Duolingo Pro error #0001"); } } } else if (String(localStorage.getItem('duolingoProLastInstalledVersion')) !== duolingoProCurrentVersion) { updateStuffVar = 'trying'; DLPpromotionBubbleVisibility = true; localStorage.setItem('DLP4Uz53cm6wjnOG7tY', "true"); setTimeout(function() { versionServerStuff('update', duolingoProCurrentVersion, String(localStorage.getItem('duolingoProLastInstalledVersion'))); checkFlagThree(); }, 2000); function checkFlagThree() { if (updateStuffVar === 'trying') { setTimeout(function() { checkFlagThree(); }, 100); } else if (updateStuffVar === 'true') { localStorage.setItem('duolingoProLastInstalledVersion', duolingoProCurrentVersion); } else if (updateStuffVar === 'error') { setTimeout(function() { versionServerStuff('update', duolingoProCurrentVersion, String(localStorage.getItem('duolingoProLastInstalledVersion'))); checkFlagThree(); }, 1000); } else if (updateStuffVar === 'empty') { notificationCall("Duolingo Pro Encountered An Error", "Duolingo Pro error #0002"); } } } let screenWidth = screen.width; function BegMobileSupport() { try { screenWidth = screen.width; if (Number(localStorage.getItem('screenWidthDuolingoPro')) === null || isNaN(Number(localStorage.getItem('screenWidthDuolingoPro'))) || Number(localStorage.getItem('screenWidthDuolingoPro')) === 0) { localStorage.setItem('screenWidthDuolingoPro', screenWidth); setTimeout(function() { BegMobileSupport(); }, 1000); } else if (Number(localStorage.getItem('screenWidthDuolingoPro')) !== screenWidth) { localStorage.setItem('screenWidthDuolingoPro', screenWidth); setTimeout(function() { BegMobileSupport(); }, 1000); } else { setTimeout(function() { BegMobileSupport(); }, 1000); } } catch (error) { } } BegMobileSupport(); function MidMobileSupport() { try { screenWidth = screen.width; const boxFirst = document.querySelector('.AutoSolverBoxFirst'); if (screenWidth < 700) { boxFirst.style.marginBottom = '64px'; } else { boxFirst.style.marginBottom = ''; } } catch (error) { } } setInterval(MidMobileSupport, 1000); const DuolingoProShadeHTML = `

Duolingo Pro is working hard

AntiStuck Protection is active

END LESSON
SHOW LESSON
`; const DuolingoProShadeCSS = ` .BlockBoxOne { position: fixed; top: 0px; bottom: 0px; right: 0px; left: 0px; width: 100%; height: 100vh; background: rgb(var(--color-snow)); justify-content: center; align-items: center; align-self: stretch; display: flex; z-index: 512; } .BlockBoxOneSectionOne { width: 100%; height: 100%; flex-direction: column; justify-content: center; align-items: center; gap: 8px; display: inline-flex; } .BlockBoxOneSectionOneTextOne { color: rgb(var(--color-eel)); text-align: center; font-size: 32px; font-style: normal; font-weight: 700; line-height: normal; margin: 0px; } .BlockBoxOneSectionOneTextTwo { align-self: stretch; color: rgb(var(--color-hare)); text-align: center; font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; margin: 0px; } .BlockBoxOneSectionTwo { display: flex; justify-content: center; align-items: center; gap: 8px; align-self: stretch; position: fixed; bottom: 16px; width: 500px; } .BlockBoxOneSectionTwoBoxOne { display: flex; height: 54px; padding: 0px 16px; justify-content: center; align-items: center; gap: 10px; flex: 1 0 0; border-radius: 8px; border: 2px solid rgba(0, 0, 0, 0.20); border-bottom: 4px solid rgba(0, 0, 0, 0.20); background: #FF2D55; color: #FFF; text-align: center; font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; cursor: pointer; transition: .1s; } .BlockBoxOneSectionTwoBoxOne:hover { filter: brightness(0.95); } .BlockBoxOneSectionTwoBoxOne:active { filter: brightness(0.9); height: 52px; margin-top: 2px; border: 2px solid rgba(0, 0, 0, 0.20); } .BlockBoxOneSectionTwoBoxTwo { display: flex; height: 54px; padding: 0px 16px; justify-content: center; align-items: center; gap: 10px; flex: 1 0 0; border-radius: 8px; border: 2px solid rgba(0, 0, 0, 0.20); border-bottom: 4px solid rgba(0, 0, 0, 0.20); background: rgb(var(--color-hare), 0.5); color: rgb(var(--color-eel)); text-align: center; font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; cursor: pointer; transition: .1s; } .BlockBoxOneSectionTwoBoxTwo:hover { filter: brightness(0.95); } .BlockBoxOneSectionTwoBoxTwo:active { filter: brightness(0.9); height: 52px; margin-top: 2px; border: 2px solid rgba(0, 0, 0, 0.20); } `; let injectedDuolingoProShadeElement = null; let injectedDuolingoProShadeStyle = null; function injectDuolingoProShade() { if (window.location.pathname.includes('/lesson') && autoSolverBoxAutomatedSolvingActive && DuolingoProShadeLessonsMode) { if (!injectedDuolingoProShadeElement) { injectedDuolingoProShadeElement = document.createElement('div'); injectedDuolingoProShadeElement.innerHTML = DuolingoProShadeHTML; document.body.appendChild(injectedDuolingoProShadeElement); injectedDuolingoProShadeStyle = document.createElement('style'); injectedDuolingoProShadeStyle.type = 'text/css'; injectedDuolingoProShadeStyle.innerHTML = DuolingoProShadeCSS; document.head.appendChild(injectedDuolingoProShadeStyle); const DuolingoProShadeEndLessonButton = document.querySelector('.BlockBoxOneSectionTwoBoxOne'); const DuolingoProShadeShowLessonButton = document.querySelector('.BlockBoxOneSectionTwoBoxTwo'); DuolingoProShadeEndLessonButton.addEventListener('click', () => { window.location.href = "https://duolingo.com/learn"; DuolingoProShadeEndLessonButton.textContent = 'ENDING LESSON' }); const DuolingoProShadeDivBox = document.querySelector('.BlockBoxOne'); DuolingoProShadeShowLessonButton.addEventListener('mouseover', () => { DuolingoProShadeDivBox.style.transition = '0.4s'; DuolingoProShadeDivBox.style.opacity = '0.8'; }); DuolingoProShadeShowLessonButton.addEventListener('mouseleave', () => { if (DuolingoProShadeDivBox.style.opacity === '0') { } else { DuolingoProShadeDivBox.style.opacity = ''; } }); DuolingoProShadeShowLessonButton.addEventListener('click', () => { DuolingoProShadeDivBox.style.opacity = '0'; DuolingoProShadeDivBox.style.pointerEvents = 'none'; }); } } else { if (injectedDuolingoProShadeElement) { document.body.removeChild(injectedDuolingoProShadeElement); document.head.removeChild(injectedDuolingoProShadeStyle); injectedDuolingoProShadeElement = null; injectedDuolingoProShadeStyle = null; } } } setInterval(injectDuolingoProShade, 100); let duolingoProCurrentNewVersion; function checkForUpdatesVersion() { async function updateWarningsFromURL(url, currentVersion) { try { const response = await fetch(url); if (!response.ok) { //throw new Error('Network response was not ok'); } const data = await response.json(); const versionData = data[currentVersion]; if (versionData) { for (const warningKey in versionData) { if (warningKey === 'status') { if (versionData[warningKey] !== "latest") { UpdateAvailableAutoSolverBoxAlertFunction(); } } } } else { console.log(`Warnings not found for Duolingo Pro ${duolingoProFormalCurrentVersion}, this version may be deprecated.`); UpdateAvailableAutoSolverBoxAlertFunction(); } } catch (error) { console.log(`Error getting data #2: ${error.message}`); } } updateWarningsFromURL('https://raw.githubusercontent.com/anonymoushackerIV/Duolingo-Pro-Assets/main/resources/issues-and-fixes.json', duolingoProFormalCurrentVersion); } const DuolingoProNotificationBoxHTML = `

Title

DISMISS

Description

`; const DuolingoProNotificationBoxCSS = ` .BlockedByDuolingoProBoxBackground { position: fixed; display: flex; width: 368px !important; padding: 16px; flex-direction: column; justify-content: center; align-items: center; gap: 4px; flex-shrink: 0; border-radius: 16px; border: 2px solid rgb(var(--color-swan)); background: rgb(var(--color-snow), 0.84); backdrop-filter: blur(16px); z-index: 2048; opacity: 1; transition: opacity .2s; left: 24px; top: calc(100%); /* Initially, it's hidden below the viewport */ transition: top 0.5s cubic-bezier(0.16, 1, 0.32, 1); /* Add a transition for the 'top' property */ } .BlockedByDuolingoProBoxSectionOne { display: flex; align-items: center; gap: 8px; align-self: stretch; } .BlockedByDuolingoProBoxSectionOneTextOne { flex: 1 0 0; color: rgb(var(--color-eel)); font-size: 18px; font-weight: 700; margin: 0px; cursor: default; } .BlockedByDuolingoProBoxSectionOneTextTwo { color: #007AFF; font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; margin: 0px; cursor: pointer; transition: .1s; } .BlockedByDuolingoProBoxSectionOneTextTwo:hover { filter: brightness(0.9); } .BlockedByDuolingoProBoxSectionOneTextTwo:active { filter: brightness(0.8); } .BlockedByDuolingoProBoxSectionTwoTextOne { align-self: stretch; color: rgb(var(--color-eel), 0.6); font-size: 16px; font-style: normal; font-weight: 700; line-height: normal; margin: 0px; cursor: default; } `; let injectedDuolingoProNotificationBoxElement = null; let injectedDuolingoProNotificationBoxStyle = null; let DuolingoProNotificationOneVar = false; function injectDuolingoProNotificationBox() { if (!injectedDuolingoProNotificationBoxElement) { injectedDuolingoProNotificationBoxElement = document.createElement('div'); injectedDuolingoProNotificationBoxElement.innerHTML = DuolingoProNotificationBoxHTML; document.body.appendChild(injectedDuolingoProNotificationBoxElement); injectedDuolingoProNotificationBoxStyle = document.createElement('style'); injectedDuolingoProNotificationBoxStyle.type = 'text/css'; injectedDuolingoProNotificationBoxStyle.innerHTML = DuolingoProNotificationBoxCSS; document.head.appendChild(injectedDuolingoProNotificationBoxStyle); } } setInterval(injectDuolingoProNotificationBox, 100); function notificationCall(title, description) { if (!DuolingoProNotificationOneVar) { notificationPopOne("", "", false); setTimeout(function() { notificationPopOne(title, description, true); DuolingoProNotificationOneVar = true; }, 600); } else if (DuolingoProNotificationOneVar) { notificationPopOne("", "", false); DuolingoProNotificationOneVar = false; setTimeout(function() { notificationPopOne(title, description, true); DuolingoProNotificationOneVar = false; }, 600); } } function notificationPopOne(title, description, value) { let DuolingoProNotificationOne = document.querySelector('#DuolingoProNotificationBackgroundOneID'); let DuolingoProNotificationOneTitle = document.querySelector('#DuolingoProNotificationTitleOneID'); let DuolingoProNotificationOneDescription = document.querySelector('#DuolingoProNotificationDescriptionOneID'); let DuolingoProNotificationOneHideButton = document.querySelector('#DuolingoProNotificationHideButtonOneID'); DuolingoProNotificationOneTitle.textContent = title; DuolingoProNotificationOneDescription.textContent = description; let DuolingoProNotificationOneHeight = DuolingoProNotificationOne.getBoundingClientRect().height; if (value) { DuolingoProNotificationOne.style.top = `calc(100% - ${DuolingoProNotificationOneHeight + 24}px)`; } else { DuolingoProNotificationOne.style.top = `calc(100%)`; } DuolingoProNotificationOneHideButton.addEventListener('click', () => { DuolingoProNotificationOne.style.top = `calc(100%)`; DuolingoProNotificationOneVar = false; }); } let DuolingoProShortSessionID; if (Number(sessionStorage.getItem('DuolingoProShortSessionID')) === null || Number(sessionStorage.getItem('DuolingoProShortSessionID')) === 0 || Number(sessionStorage.getItem('DuolingoProShortSessionID')) === NaN) { DuolingoProShortSessionID = Math.floor(Math.random() * (9999 - 1 + 1)) + 1; sessionStorage.setItem('DuolingoProShortSessionID', DuolingoProShortSessionID); } else { DuolingoProShortSessionID = Number(sessionStorage.getItem('DuolingoProShortSessionID')); //sessionStorage will be deleted after the tab is closed } const asdgfhjklHTML = `
null
`; let asdgfhjklElement = null; let smythr; function asdgfhjklElementFunctionInj() { if (!asdgfhjklElement) { // Creating a container for the overlay document.body.insertAdjacentHTML('beforeend', asdgfhjklHTML); asdgfhjklElement = asdgfhjklHTML; smythr = document.querySelector('#dshuigf'); smythr.style.opacity = '0'; } } setInterval(asdgfhjklElementFunctionInj, 100); function refreshactivatorThingDPHDJfunction() { let dfsuhf = document.querySelectorAll('.activatorThingDPHDJ'); dfsuhf.forEach(dfsuhfO => { dfsuhfO.addEventListener('mouseover', () => { fhduishfu(true, dfsuhfO.getAttribute('aria-label')); }); }); dfsuhf.forEach(dfsuhfO => { dfsuhfO.addEventListener('mouseleave', () => { fhduishfu(false); }); }); } setInterval(refreshactivatorThingDPHDJfunction, 200); function fhduishfu(state, message) { if (state) { smythr.textContent = message; smythr.style.opacity = '1'; } else { smythr.style.opacity = '0'; } } const UpdateAvailableAutoSolverBoxAlertHTML = `

Update Available

`; let UpdateAvailableAutoSolverBoxAlertElement = null; function UpdateAvailableAutoSolverBoxAlertFunction() { try { let targetDiv = document.querySelector('.AutoSolverBoxAlertSectionOne'); if (targetDiv) { if (!UpdateAvailableAutoSolverBoxAlertElement) { targetDiv.insertAdjacentHTML('beforeend', UpdateAvailableAutoSolverBoxAlertHTML); let dhsofadsuh = document.querySelector('#AutoSolverBoxAlertOneBoxIDUpdate'); dhsofadsuh.addEventListener('click', () => { UpdateAvailablePopUpFunction(true); }); } } } catch(error) {} } const UpdateAvailablePopUpHTML = `

An Update is Available

A newer version of Duolingo Pro is now available for download.

MANUALLY UPDATE
OK
`; const UpdateAvailablePopUpCSS = ` .BPUDPUB1 { position: relative; width: 544px; height: 544px; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 10px; box-sizing: border-box; border-radius: 16px; border: 2px solid rgba(0, 0, 0, 0.10); background: #FFF; background: url("https://assets.univer.se/69263e2d-23c8-4c60-b47c-3797fe76e72d?auto=compress") 546px 546px; /*background-size: cover;*/ /*background-clip: padding-box;*/ } .BPUDPUL1 { display: inline-flex; flex-direction: column; justify-content: center; align-items: center; gap: 4px; padding: 16px; } .BPUDPUL1T1 { color: #FFF; text-align: center; font-weight: 700; margin: 0px; } .BPUDPUB1BN1 { display: flex; width: 256px; height: 54px; flex-direction: column; justify-content: center; align-items: center; border-radius: 8px; border: 2px solid rgba(0, 0, 0, 0.20); border-bottom: 4px solid rgba(0, 0, 0, 0.20); background: #FFF; color: #000; font-size: 16px; font-weight: 700; margin: 0px; cursor: pointer; transition: .1s; } .BPUDPUB1BN1:hover { filter: brightness(0.95); } .BPUDPUB1BN1:active { filter: brightness(0.9); height: 52px; margin-top: 2px; border-bottom: 2px solid rgba(0, 0, 0, 0.20); } `; let UpdateAvailablePopUpStyle = null; function UpdateAvailablePopUpFunction(status) { try { if (status) { UpdateAvailablePopUpStyle = document.createElement('style'); UpdateAvailablePopUpStyle.type = 'text/css'; UpdateAvailablePopUpStyle.innerHTML = UpdateAvailablePopUpCSS; document.head.appendChild(UpdateAvailablePopUpStyle); document.body.insertAdjacentHTML('beforeend', UpdateAvailablePopUpHTML); setTimeout(function() { let smthdfshfb = document.querySelector('#DPUDPUshadowThing'); smthdfshfb.style.opacity = '1'; }, 50); let smfuerhguf = document.querySelector('#BPUDPUB1BN1DS'); smfuerhguf.addEventListener('click', () => { UpdateAvailablePopUpFunction(false); }); } else { let smthdfshfb = document.querySelector('#DPUDPUshadowThing'); smthdfshfb.style.opacity = '0'; setTimeout(function() { smthdfshfb.remove(); //UpdateAvailablePopUpElement = null; UpdateAvailablePopUpStyle = null; }, 200); } } catch(error) {} } const DPAutoServerButtonMainMenuHTML = `

AutoServer

`; const DPAutoServerButtonMainMenuCSS = ` .DPAutoServerButtonMainMenu { display: flex; box-sizing: border-box; justify-content: center; align-items: center; gap: 16px; flex-shrink: 0; border-radius: 12px; cursor: pointer; } .DPAutoServerButtonMainMenu:hover { background: rgba(0, 122, 255, 0.10); } .DPAutoServerButtonMainMenu:active { filter: brightness(.9); } .DPAutoServerButtonMainMenuMedium { width: 56px; height: 52px; padding: 8px; } .DPAutoServerButtonMainMenu:hover .DPAutoServerElementsMenu { visibility: visible !important; } .DPAutoServerButtonMainMenuLarge { width: 222px; height: 52px; padding: 16px 16px 16px 17px; } `; let DPAutoServerButtonMainMenuElement = null; let DPAutoServerButtonMainMenuStyle = null; function DPAutoServerButtonMainMenuFunction() { if (ASB969) { try { let targetDiv = document.querySelector('._1ZKwW'); if (targetDiv && !document.querySelector('.DPAutoServerButtonMainMenu')) { DPAutoServerButtonMainMenuStyle = document.createElement('style'); DPAutoServerButtonMainMenuStyle.type = 'text/css'; DPAutoServerButtonMainMenuStyle.innerHTML = DPAutoServerButtonMainMenuCSS; document.head.appendChild(DPAutoServerButtonMainMenuStyle); let targetDivLast = document.querySelector('[data-test="profile-tab"]'); if (targetDiv && targetDivLast) { targetDiv.lastChild.insertAdjacentHTML('beforebegin', DPAutoServerButtonMainMenuHTML); let otherTargetDiv = document.querySelector('.DPAutoServerButtonMainMenu'); otherTargetDiv.addEventListener('click', () => { notificationCall("AutoServer is under construction", "AutoServer is currently under construction. We'll let you know when it's available. Join our Discord server to learn more & be the first few people to use it discord.gg/r8xQ7K59Mt"); }); if (targetDiv.offsetWidth === 56) { otherTargetDiv.classList.add('DPAutoServerButtonMainMenuMedium'); document.querySelectorAll('.DPAutoServerElementsMenu').forEach(function(element) { element.remove(); }); fdhuf(); function fdhuf() { if (targetDiv.offsetWidth !== 56) { otherTargetDiv.remove(); DPAutoServerButtonMainMenuFunction(); } else { setTimeout(function() { fdhuf(); }, 100); } } } else { otherTargetDiv.classList.add('DPAutoServerButtonMainMenuLarge'); urhef(); function urhef() { if (targetDiv.offsetWidth !== 222) { otherTargetDiv.remove(); DPAutoServerButtonMainMenuFunction(); } else { setTimeout(function() { urhef(); }, 100); } } } } } } catch(error) {} } } setInterval(DPAutoServerButtonMainMenuFunction, 100); const DuolingoProCounterOneHTML = `

AntiStuck OFF

Feedback

`; const DuolingoProCounterOneCSS = ` .vCIrKKxykXwXyUza { border: 2px solid rgb(var(--color-swan)); height: 40px; width: auto; padding: 0 12px; gap: 8px; display: inline-flex; justify-content: center; align-items: center; flex-wrap: nowrap; border-radius: 32px; background: rgb(var(--color-snow), 0.84); box-shadow: 0px 0px 16px 0px rgba(0, 0, 0, 0.08); backdrop-filter: blur(16px); overflow: hidden; transition: all 0.4s cubic-bezier(0.16, 1, 0.32, 1); cursor: pointer; } .vCIrKKxykXwXyUza:hover { scale: 1.05; } .vCIrKKxykXwXyUza:active { scale: 0.85; } .vCIrKKxykXwXyUza svg { flex-shrink: 0; } .vCIrKKxykXwXyUza-Text { color: rgb(var(--color-eel)); font-size: 16px; font-weight: 700; white-space: nowrap; margin: 0; } `; let injectedDuolingoProCounterOneElement = null; let injectedDuolingoProCounterOneStyle = null; function DuolingoProCounterOneFunction() { if ((window.location.pathname.includes('/lesson') || window.location.pathname.includes('/practice')) && autoSolverBoxAutomatedSolvingActive) { if (!injectedDuolingoProCounterOneElement) { injectedDuolingoProCounterOneStyle = document.createElement('style'); injectedDuolingoProCounterOneStyle.type = 'text/css'; injectedDuolingoProCounterOneStyle.innerHTML = DuolingoProCounterOneCSS; document.head.appendChild(injectedDuolingoProCounterOneStyle); document.body.insertAdjacentHTML('beforeend', DuolingoProCounterOneHTML); injectedDuolingoProCounterOneElement = DuolingoProCounterOneHTML; let fgOFCULKfxUUvNjw1 = document.querySelector('#DLPTB1e1ID'); let fgOFCULKfxUUvNjw2 = document.querySelector('#DLPTB1e2ID'); let fgOFCULKfxUUvNjw3 = document.querySelector('#DLPTB1e3ID'); let UqgpktnVnpDIrSaY = document.querySelector('#DLPTB1eC1ID'); let UqgpktnVnpDIrSaY1 = document.querySelector('#DLPTB1eC1i1ID'); let theBarVisibility = false; function hideKDOS(noAnimation) { fgOFCULKfxUUvNjw2.style.width = fgOFCULKfxUUvNjw2.offsetWidth + "px"; fgOFCULKfxUUvNjw3.style.width = fgOFCULKfxUUvNjw3.offsetWidth + "px"; fgOFCULKfxUUvNjw2.style.width = "0px"; fgOFCULKfxUUvNjw3.style.width = "0px"; fgOFCULKfxUUvNjw2.style.padding = "0"; fgOFCULKfxUUvNjw3.style.padding = "0"; fgOFCULKfxUUvNjw2.style.filter = "blur(8px)"; fgOFCULKfxUUvNjw3.style.filter = "blur(8px)"; fgOFCULKfxUUvNjw2.style.margin = "0 -4px"; fgOFCULKfxUUvNjw3.style.margin = "0 -4px"; fgOFCULKfxUUvNjw2.style.opacity = "0"; fgOFCULKfxUUvNjw3.style.opacity = "0"; if (!noAnimation) { setTimeout(function() { fgOFCULKfxUUvNjw2.style.display = "none"; fgOFCULKfxUUvNjw3.style.display = "none"; }, 400); } else { fgOFCULKfxUUvNjw2.style.display = "none"; fgOFCULKfxUUvNjw3.style.display = "none"; } } function showKDOS() { EAWoMwEP(); fgOFCULKfxUUvNjw2.style.display = ""; fgOFCULKfxUUvNjw3.style.display = ""; fgOFCULKfxUUvNjw2.style.width = ""; fgOFCULKfxUUvNjw3.style.width = ""; fgOFCULKfxUUvNjw2.style.padding = ""; fgOFCULKfxUUvNjw3.style.padding = ""; let remember0009 = (fgOFCULKfxUUvNjw2.offsetWidth - 0) + "px"; let remember0010 = (fgOFCULKfxUUvNjw3.offsetWidth - 0) + "px"; fgOFCULKfxUUvNjw2.style.width = "0px"; fgOFCULKfxUUvNjw3.style.width = "0px"; requestAnimationFrame(function() { fgOFCULKfxUUvNjw2.style.width = remember0009; fgOFCULKfxUUvNjw2.style.padding = ""; fgOFCULKfxUUvNjw2.style.filter = ""; fgOFCULKfxUUvNjw2.style.opacity = ""; fgOFCULKfxUUvNjw2.style.margin = ""; fgOFCULKfxUUvNjw3.style.width = remember0010; fgOFCULKfxUUvNjw3.style.padding = ""; fgOFCULKfxUUvNjw3.style.filter = ""; fgOFCULKfxUUvNjw3.style.opacity = ""; fgOFCULKfxUUvNjw3.style.margin = ""; }); } hideKDOS(true); UqgpktnVnpDIrSaY.addEventListener('click', () => { if (theBarVisibility) { UqgpktnVnpDIrSaY1.style.transform = "rotate(0deg)"; theBarVisibility = false; hideKDOS(); } else { UqgpktnVnpDIrSaY1.style.transform = "rotate(180deg)"; theBarVisibility = true; showKDOS(); } }); fgOFCULKfxUUvNjw2.addEventListener('click', () => { DuolingoProAntiStuckProtectionMode = !DuolingoProAntiStuckProtectionMode; localStorage.setItem('DuolingoProAntiStuckProtectionMode', DuolingoProAntiStuckProtectionMode); EAWoMwEP(); let remember013 = fgOFCULKfxUUvNjw2.offsetWidth; fgOFCULKfxUUvNjw2.style.width = ''; let remember014 = fgOFCULKfxUUvNjw2.offsetWidth; fgOFCULKfxUUvNjw2.style.width = remember013 + 'px'; requestAnimationFrame(function() { fgOFCULKfxUUvNjw2.style.width = remember014 + 'px'; }); }); fgOFCULKfxUUvNjw3.addEventListener('click', () => { solving("stop"); SendFeedBackBox(true); }); } let cLsYCmdd = document.querySelector('#DLPTB1e2t2ID'); function EAWoMwEP() { if (DuolingoProAntiStuckProtectionMode) { cLsYCmdd.style.color = '#007AFF'; cLsYCmdd.textContent = 'ON'; } else { cLsYCmdd.style.color = '#FF2D55'; cLsYCmdd.textContent = 'OFF'; } } function aQklgZktoyzqdZpz(typeSingular, typePLural) { if (DLPsessionCompleteAmount === 0) { if (DLPCE258) { DLPCE258.style.display = 'none'; } } else if (DLPsessionCompleteAmount === 1) { DLPCE258.style.display = ''; DLPCE258i.textContent = String(DLPsessionCompleteAmount) + " " + typeSingular + " Solved"; } else { DLPCE258.style.display = ''; DLPCE258i.textContent = String(DLPsessionCompleteAmount) + " " + typePLural + " Solved"; } } let DLPCE728 = document.querySelector('#DLPTB1e1t1ID'); let DLPCE728i = document.querySelector('#DLPTB1e1i1ID'); let DLPCE258 = document.querySelector('#DLPTB1e4ID'); let DLPCE258i = document.querySelector('#DLPTB1e4t1ID'); if (DuolingoProSettingsNeverEndMode) { DLPCE728i.style.display = ''; DLPCE728.textContent = 'Infinity'; if (window.location.pathname === '/practice') { aQklgZktoyzqdZpz("Practice", "Practices"); } else { aQklgZktoyzqdZpz("Lesson", "Lessons"); } } else if (window.location.pathname === '/practice') { aQklgZktoyzqdZpz("Practice", "Practices"); if (autoSolverBoxRepeatAmount === 1) { DLPCE728.textContent = 'Last Practice'; } else if (autoSolverBoxRepeatAmount === 0) { DLPCE728.textContent = 'Finishing Up'; } else if (autoSolverBoxRepeatAmount) { DLPCE728.textContent = String(autoSolverBoxRepeatAmount + ' Practices Left'); } } else { aQklgZktoyzqdZpz("Lesson", "Lessons"); if (autoSolverBoxRepeatAmount === 1) { DLPCE728.textContent = 'Last Lesson'; } else if (autoSolverBoxRepeatAmount === 0) { DLPCE728.textContent = 'Finishing Up'; } else if (autoSolverBoxRepeatAmount) { DLPCE728.textContent = String(autoSolverBoxRepeatAmount + ' Lessons Left'); } } } else { if (injectedDuolingoProCounterOneElement) { let DuolingoProShadeStatusOne = document.querySelector('#DLPTBL1ID'); if (DuolingoProShadeStatusOne) { DuolingoProShadeStatusOne.remove(); } injectedDuolingoProCounterOneElement = null; } } } setInterval(DuolingoProCounterOneFunction, 500); const CurrentIssuesPopUpHTML = `

Issues & Fixes

Loading...

LEARN MORE
OK
`; const CurrentIssuesPopUpCSS = ` .DPIPUB1 { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 8px; width: 100%; } .DPIPUL1 { display: flex; justify-content: space-between; align-items: center; align-self: stretch; } .DPIPUL1T1 { color: rgb(var(--color-eel)); font-size: 24px; font-weight: 700; margin: 0px; } .DPIPUL1T2 { color: rgb(var(--color-eel), .4); font-size: 16px; font-weight: 700; margin: 0px; } .DPIPUL2 { display: flex; width: 100%; flex-direction: column; justify-content: center; align-items: flex-start; gap: 16px; } .DPIPUL2TI1 { display: flex; align-items: center; gap: 8px; align-self: stretch; } .DPIPUL2TI1T1 { flex: 1 0 0; font-size: 16px; font-weight: 700; margin: 0px; } .DPIPUL2TI1T1R { color: #FF2D55; } .DPIPUL2TI1T1O { color: #FF9500; } .DPIPUL2TI1T1B { color: rgb(var(--color-eel)); } .DPIPUL2TI1T1G { color: #34C759; } .DPIPUL2TI2 { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 8px; align-self: stretch; } .DPIPUL2TI2TG1 { display: flex; height: 8px; padding-right: 0px; align-items: center; flex: 1 0 0; border-radius: 8px; background: rgb(var(--color-swan)); } .DPIPUL2TI2TG1TG1 { display: flex; height: 8px; width: 60%; border-radius: 8px; background: linear-gradient(117deg, #34C759 16.66%, #007AFF 50%, #AF52DE 83.34%); } .DPIPUL3B1 { display: flex; height: 54px; flex-direction: column; justify-content: center; align-items: center; flex: 1 0 0; border-radius: 8px; border: 2px solid rgb(var(--color-swan)); border-bottom: 4px solid rgb(var(--color-swan)); background: rgb(var(--color-snow)); color: rgb(var(--color-eel)); font-size: 16px; font-weight: 700; cursor: pointer; transition: .1s; } .DPIPUL3B1:hover { filter: brightness(0.95); } .DPIPUL3B1:active { filter: brightness(0.9); margin-top: 2px; height: 52px; border-bottom: 2px solid rgb(var(--color-swan)); } `; let CurrentIssuesPopUpElement = null; let CurrentIssuesPopUpStyle = null; function CurrentIssuesPopUpFunction(status) { try { if (status) { CurrentIssuesPopUpStyle = document.createElement('style'); CurrentIssuesPopUpStyle.type = 'text/css'; CurrentIssuesPopUpStyle.innerHTML = CurrentIssuesPopUpCSS; document.head.appendChild(CurrentIssuesPopUpStyle); document.body.insertAdjacentHTML('beforeend', CurrentIssuesPopUpHTML); setTimeout(function() { let djhsafjkds = document.querySelector('#SeeActiveIssuesBoxShadow'); djhsafjkds.style.opacity = '1'; }, 50); let gfhdsfjdsh = document.querySelector('#DPIPUL3BDissmissID'); gfhdsfjdsh.addEventListener('click', () => { CurrentIssuesPopUpFunction(false); }); let dhbGkaCU = document.querySelector('#DPIPUL3BLearnMoreID'); dhbGkaCU.addEventListener('click', () => { window.open("discord.gg/r8xQ7K59Mt", "_blank"); }); let HighWarningComponent1 = `

Warning Title

`; let MediumWarningComponent1 = `

Warning Title

`; let LowWarningComponent1 = `

Warning Title

`; let FixedWarningComponent1 = `

Warning Title

`; function createWarningElement(warning) { let htmlContent = ''; switch (warning['warning-level']) { case 'high': htmlContent = HighWarningComponent1; break; case 'medium': htmlContent = MediumWarningComponent1; break; case 'low': htmlContent = LowWarningComponent1; break; case 'fixed': htmlContent = FixedWarningComponent1; break; default: //htmlContent = `

${warning['warning-title']}

`; break; } htmlContent = htmlContent.replace('Warning Title', warning['warning-title']); document.querySelector('.DPIPUL2').insertAdjacentHTML('beforeend', htmlContent); } let NextUpdateTrackerComponent1 = `

Next Update Tracker

`; async function updateWarningsFromURL(url, currentVersion) { try { const response = await fetch(url); if (!response.ok) { throw new Error('Network response was not ok'); } const data = await response.json(); const versionData = data[currentVersion]; const lastUpdated = versionData['last-updated']; let syvxYxgE; if (versionData) { for (const warningKey in versionData) { if (warningKey !== 'status' && warningKey !== 'last-updated' && warningKey !== 'next-update') { createWarningElement(versionData[warningKey]); } else if (warningKey === 'status') { let shfueowifj = versionData[warningKey]; } else if (warningKey === 'next-update') { syvxYxgE = String(versionData[warningKey]); console.log(syvxYxgE); } } document.querySelector('#DPIPUL1T2DATE').textContent = "Last Updated: " + String(lastUpdated); document.querySelector('.DPIPUL2').insertAdjacentHTML('beforeend', NextUpdateTrackerComponent1); document.querySelector('.DPIPUL2TI2TG1TG1').style.width = syvxYxgE; if (syvxYxgE === "100%") { document.querySelector('#TUEZQYXDAhmVUfZf').style.fill = "#34C759"; } } else { alert(`Warnings not found for Duolingo Pro ${duolingoProFormalCurrentVersion}, this version may be deprecated. `); } } catch (error) { console.log(`Error getting data #3: ${error.message}`); } } updateWarningsFromURL('https://raw.githubusercontent.com/anonymoushackerIV/Duolingo-Pro-Assets/main/resources/issues-and-fixes.json', duolingoProFormalCurrentVersion); } else { let djhsafjkds = document.querySelector('#SeeActiveIssuesBoxShadow'); djhsafjkds.style.opacity = '0'; setTimeout(function() { djhsafjkds.remove(); CurrentIssuesPopUpElement = null; CurrentIssuesPopUpStyle = null; }, 200); } } catch(error) {} } function hgfem() { let currentTz = Intl.DateTimeFormat().resolvedOptions().timeZone; // Get the current timezone let currentDate = new Date(); // Get the current date in the current timezone console.log('Current date in ' + currentTz + ': ' + currentDate.toString()); let estDate = currentDate.toLocaleDateString("en-US", {timeZone: "America/New_York"}); // Convert the current date to EST and get only the date part console.log('Current date in EST: ' + estDate); } let EGxjxpyyQVICYLlt = `

`; let lXTUDhsszBlpOzyG = ` .gFyuyoyv { display: flex; width: 222px; padding: 16px; flex-direction: column; justify-content: center; align-items: center; gap: 4px; box-sizing: border-box; border-radius: 16px; border: 2px solid rgba(0, 0, 0, 0.10); background: #000; cursor: pointer; overflow: hidden; position: fixed; bottom: 16px; left: -154px; z-index: 2; transition: scale .4s, background .8s, left .4s, box-shadow .4s, opacity .4s, filter .4s; } .gFyuyoyv:hover { box-shadow: 0px 0px 16px 0px rgba(0, 0, 0, 0.2); scale: 1.05; } .gFyuyoyv:active { box-shadow: none; scale: .95; } .closeIcon094:hover { fill: rgba(255, 255, 255, 1); box-shadow: 0px 0px 16px 0px rgba(0, 0, 0, 0.2); scale: 1.2; } .closeIcon094:active { box-shadow: none; scale: .9; } .fiaks { align-self: stretch; color: #FFF; font-size: 20px; font-weight: 700; margin: 0; transition: .4s; } .lkfds { align-self: stretch; color: rgba(255, 255, 255, 0.75); font-size: 16px; font-weight: 700; margin: 0; height: 0; opacity: 0; transition: .4s; } .qjids { display: flex; padding-top: 4px; justify-content: center; align-items: center; gap: 4px; } .iohft { height: 8px; border-radius: 4px; background: rgba(255, 255, 255, 0.50); backdrop-filter: blur(4px); transition: 1s; } .fheks { height: 8px; border-radius: 4px; background: rgba(255, 255, 255, 0.50); backdrop-filter: blur(4px); transition: width 8s, opacity 1s; } `; let EGxjxpyyQVICYLltElement = null; let lXTUDhsszBlpOzyGStyle = null; function cBcutPZB() { try { if (!document.querySelector('.gFyuyoyv')) { if (!lXTUDhsszBlpOzyGStyle) { lXTUDhsszBlpOzyGStyle = document.createElement('style'); lXTUDhsszBlpOzyGStyle.type = 'text/css'; lXTUDhsszBlpOzyGStyle.innerHTML = lXTUDhsszBlpOzyG; document.head.appendChild(lXTUDhsszBlpOzyGStyle); document.body.insertAdjacentHTML('beforeend', EGxjxpyyQVICYLlt); } function eipwofa() { if (document.querySelector('._3bTT7')) { try { document.querySelector('.gFyuyoyv').style.display = ''; } catch (error) {} } else { try { document.querySelector('.gFyuyoyv').style.display = 'none'; } catch (error) {} } } setInterval(eipwofa, 1000); let djwodElement = document.querySelector('.gFyuyoyv'); let smallView = false; if (window.innerWidth < 1160) { smallView = true; } else { smallView = false; } // let EdIozuiv = true; let isPaused = false; let currentNumber = 1; let isHoveringCloseButton094 = false; let currentURL = ""; document.querySelector('.closeIcon094').addEventListener('mouseover', function() { isHoveringCloseButton094 = true; }); document.querySelector('.closeIcon094').addEventListener('mouseout', function() { setTimeout(function() { isHoveringCloseButton094 = false; }, 800); }); document.querySelector('.closeIcon094').addEventListener('click', function() { localStorage.setItem('DLP4Uz53cm6wjnOG7tY', "false"); DLPpromotionBubbleVisibility = false; djwodElement.style.scale = "0.8"; djwodElement.style.filter = "blur(16px)"; djwodElement.style.opacity = "0"; notificationCall("Promotions Hidden", "Duolingo Pro promotions are hidden until the next update. "); }); djwodElement.addEventListener("click", function() { if (!isHoveringCloseButton094) { window.open(BubbleResult.bubbles[currentNumber - 1].link, '_blank'); } else { } }); let isTransitionTime832 = false; let sjidhf = document.querySelector(".fiaks"); let ifdhsi = document.querySelector(".lkfds"); let OuCoTKrL = document.querySelector('.OuCoTKrL'); sjidhf.textContent = BubbleResult.bubbles[0].title.text; ifdhsi.textContent = BubbleResult.bubbles[0].description.text; sjidhf.style.opacity = "1"; sjidhf.style.filter = "blur(0px)"; sjidhf.style.height = BubbleResult.bubbles[0].title.height; djwodElement.style.background = BubbleResult.bubbles[0].background; OuCoTKrL.insertAdjacentHTML('afterbegin', BubbleResult.bubbles[0].icon); OuCoTKrL.style.filter = "blur(0px)"; OuCoTKrL.style.opacity = "1"; document.querySelector(".gFyuyoyv").style.background = BubbleResult.bubbles[0].background; if (!smallView) { djwodElement.style.left = "16px"; } djwodElement.addEventListener("mouseover", function() { let fgijgElement = document.querySelector(".fiaks"); let lkfdsElement = document.querySelector(".lkfds"); if (smallView) { djwodElement.style.left = "16px"; } tddfnj(); function tddfnj() { if (!isTransitionTime832) { lkfdsElement.style.height = BubbleResult.bubbles[currentNumber - 1].description.height; lkfdsElement.style.opacity = "1"; lkfdsElement.style.filter = "blur(0px)"; fgijgElement.style.height = BubbleResult.bubbles[currentNumber - 1].title.height; fgijgElement.style.opacity = "1"; fgijgElement.style.filter = "blur(0px)"; } else { setTimeout(function() { tddfnj(); }, 50); } } isPaused = true; }); djwodElement.addEventListener("mouseout", function() { let lkfdsElement = document.getElementsByClassName("lkfds")[0]; if (smallView) { djwodElement.style.left = "-154px"; } lkfdsElement.style.height = "0px"; lkfdsElement.style.opacity = "0"; lkfdsElement.style.filter = "blur(8px)"; isPaused = false; }); function injectElements(amount) { for (let i = 1; i <= amount; i++) { let outerDiv = document.createElement('div'); outerDiv.id = 'jfei' + i; outerDiv.className = 'iohft'; outerDiv.style.width = '8px'; let innerDiv = document.createElement('div'); innerDiv.className = 'fheks'; innerDiv.style.width = '8px'; innerDiv.style.background = '#FFF'; innerDiv.style.opacity = '0'; outerDiv.appendChild(innerDiv); document.querySelector('.qjids').appendChild(outerDiv); } } function disdf(total) { let numbersList = []; let jfei1Element = document.getElementById("jfei" + String(currentNumber)); jfei1Element.style.width = "32px"; let jfei1fheksElement = jfei1Element.getElementsByClassName("fheks")[0]; jfei1fheksElement.style.width = "8px"; jfei1fheksElement.style.opacity = "1"; for (let i = 1; i <= total; i++) { if (i !== currentNumber) { numbersList.push(i); } } numbersList.forEach(function(num) { let element = document.getElementById("jfei" + String(num)); if (element) { //console.log("Element found for ID:", "jfei" + String(num)); element.style.width = "8px"; } }); setTimeout(function() { jfei1fheksElement.style.width = "100%"; }, 50); document.querySelector(".gFyuyoyv").style.background = BubbleResult.bubbles[currentNumber - 1].background; ifhji(); function ifhji() { setTimeout(function() { sjidhf.textContent = BubbleResult.bubbles[currentNumber - 1].title.text; ifdhsi.textContent = BubbleResult.bubbles[currentNumber - 1].description.text; sjidhf.style.opacity = "1"; sjidhf.style.filter = "blur(0px)"; sjidhf.style.height = BubbleResult.bubbles[currentNumber - 1].title.height; if (!EdIozuiv) { document.querySelector('.OuCoTKrL .dihafk').remove(); document.querySelector('.OuCoTKrL').insertAdjacentHTML('afterbegin', BubbleResult.bubbles[currentNumber - 1].icon); //requestAnimationFrame(function() { setTimeout(function() { document.querySelector('.OuCoTKrL').style.filter = "blur(0px)"; document.querySelector('.OuCoTKrL').style.opacity = "1"; }, 0); //}); } EdIozuiv = false; if (isPaused) { ifdhsi.style.opacity = "1"; ifdhsi.style.filter = "blur(0px)"; ifdhsi.style.height = BubbleResult.bubbles[currentNumber - 1].description.height; } }, 400); setTimeout(function() { isTransitionTime832 = false; }, 800); } setTimeout(function() { isTransitionTime832 = true; if (currentNumber < total) { currentNumber = currentNumber + 1; disdf(bubbleTotal); } else if (currentNumber === total) { currentNumber = 1; disdf(bubbleTotal); } jfei1fheksElement.style.width = "8px"; jfei1fheksElement.style.opacity = "0"; sjidhf.style.opacity = "0"; sjidhf.style.filter = "blur(8px)"; sjidhf.style.height = "0px"; ifdhsi.style.opacity = "0"; ifdhsi.style.filter = "blur(8px)"; ifdhsi.style.height = "0px"; document.querySelector('.OuCoTKrL').style.filter = "blur(8px)"; document.querySelector('.OuCoTKrL').style.opacity = "0"; }, 8050); } injectElements(bubbleTotal); disdf(bubbleTotal); } else { } } catch (error) { console.log(error); } } let bubbleTotal; let BubbleResult; async function fetchDatacBcutPZB(url) { try { const response = await fetch(url); if (!response.ok) { throw new Error('Network response was not ok'); } else { const data = await response.json(); bubbleTotal = parseInt(data["bubble-total"]); const bubbleList = []; for (let i = 1; i <= bubbleTotal; i++) { const bubbleKey = `bubble-${i}`; const bubbleInfo = { icon: data[bubbleKey].icon, title: { text: data[bubbleKey].title["title-text"], color: data[bubbleKey].title["title-color"], height: data[bubbleKey].title["title-height"] }, description: { text: data[bubbleKey].description["description-text"], color: data[bubbleKey].description["description-color"], height: data[bubbleKey].description["description-height"] }, background: data[bubbleKey].background, border: data[bubbleKey].border, link: data[bubbleKey].link }; bubbleList.push(bubbleInfo); } BubbleResult = { bubbleTotal, bubbles: bubbleList }; cBcutPZB(); } } catch (error) { console.log(`Error getting data #4: ${error.message}`); } } async function sTvtBAMVJoWFodPG() { if (DLPpromotionBubbleVisibility && document.querySelector('._1ZKwW')) { await fetchDatacBcutPZB("https://raw.githubusercontent.com/anonymoushackerIV/Duolingo-Pro-Assets/main/resources/promotion-bubble.json"); } } setInterval(sTvtBAMVJoWFodPG, 1000); function updateSolveButtonText(text) { document.getElementById("solveAllButton").innerText = text; } function solving(value) { if (value === "start") { isAutoMode = true; updateSolveButtonText(isAutoMode ? "PAUSE SOLVE" : "SOLVE ALL"); solvingIntervalId = isAutoMode ? setInterval(solve, solveSpeed * 1000) : clearInterval(solvingIntervalId); } else if (value === "stop") { isAutoMode = false; updateSolveButtonText(isAutoMode ? "PAUSE SOLVE" : "SOLVE ALL"); solvingIntervalId = isAutoMode ? setInterval(solve, solveSpeed * 1000) : clearInterval(solvingIntervalId); } else { isAutoMode = !isAutoMode; updateSolveButtonText(isAutoMode ? "PAUSE SOLVE" : "SOLVE ALL"); solvingIntervalId = isAutoMode ? setInterval(solve, solveSpeed * 1000) : clearInterval(solvingIntervalId); } } let hcwNIIOdaQqCZRDL = false; function solve() { const practiceAgain = document.querySelector('[data-test="player-practice-again"]'); const sessionCompleteSlide = document.querySelector('[data-test="session-complete-slide"]'); let ejfkLLtg = document.querySelector('[data-test="practice-hub-ad-no-thanks-button"]'); if (ejfkLLtg) { ejfkLLtg.click(); } let xJiRCXrz = document.querySelector('.vpDIE'); if (xJiRCXrz) { xJiRCXrz.click(); } let LwLkdRDp = document.querySelector('[data-test="plus-no-thanks"]'); if (LwLkdRDp) { LwLkdRDp.click(); } let ortgyuha = document.querySelector('._1N-oo._36Vd3._16r-S._1ZBYz._23KDq._1S2uf.HakPM'); if (ortgyuha) { ortgyuha.click(); } let iohuygty = document.querySelector('._8AMBh._2vfJy._3Qy5R._28UWu._3h0lA._1S2uf._1E9sc'); if (iohuygty) { iohuygty.click(); } if ((practiceAgain !== null || sessionCompleteSlide !== null) && isAutoMode && autoSolverBoxAutomatedSolvingActive) { if (!DuolingoProSettingsNeverEndMode && !hcwNIIOdaQqCZRDL) { hcwNIIOdaQqCZRDL = true; autoSolverBoxRepeatAmount--; sessionStorage.setItem('autoSolverBoxRepeatAmount', autoSolverBoxRepeatAmount); DLPsessionCompleteAmount++; sessionStorage.setItem('duopro.autoSolveSessionCompleteAmount', DLPsessionCompleteAmount); mainSolveStatistics('lesson'); } if ((autoSolverBoxRepeatAmount > 0 || DuolingoProSettingsNeverEndMode) && practiceAgain !== null) { practiceAgain.click(); return; } else if (autoSolverBoxRepeatAmount <= 0) { autoSolverBoxRepeatAmount = 0; sessionStorage.setItem('autoSolverBoxRepeatAmount', autoSolverBoxRepeatAmount); window.location.href = "https://duolingo.com"; } } try { window.sol = findReact(document.getElementsByClassName(findReactMainElementClass)[0]).props.currentChallenge; } catch { //let next = document.querySelector('[data-test="player-next"]'); //if (next) { // next.click(); //} //return; } //if (!window.sol) { // return; //} let challengeType = determineChallengeType(); if (challengeType === 'error') { nextClickFunc(); } else if (challengeType) { if (debug) { document.getElementById("solveAllButton").innerText = challengeType; } handleChallenge(challengeType); nextClickFunc(); } else { nextClickFunc(); } } let zXIArDomWMPkmTVf = 0; let GtPzsoCcLnDAVvjb; let SciiOTPybxFAimRW = false; function nextClickFunc() { setTimeout(function() { try { let nextButton = document.querySelector('[data-test="player-next"]'); if (nextButton) { let nextButtonAriaValue = nextButton.getAttribute('aria-disabled'); if (nextButtonAriaValue === 'true') { if (document.querySelectorAll('._35QY2._3jIlr.f2zGP._18W4a.xtPuL').length > 0) { } else { if (DuolingoProAntiStuckProtectionMode) { console.log('The next button is disabled.'); zXIArDomWMPkmTVf++; //for (let i = 0; i < 50; i++) { // setTimeout(function() { //if (document.querySelector('[data-test="player-next"]').getAttribute('aria-disabled') === 'true') { //} else if (document.querySelector('[data-test="player-next"]').getAttribute('aria-disabled') === 'false') { // if (document.querySelector('[data-test="player-next"]').getAttribute('aria-disabled') === 'false') { // zXIArDomWMPkmTVf = 0; // } else { // zXIArDomWMPkmTVf = 0; // } // }, 2); //} //if (solveSpeed <= 2) { // zXIArDomWMPkmTVf++; //} else if (solveSpeed <= 3) { // setTimeout(function() { // nextClickFunc("test"); // }, 1000); //} } } if (zXIArDomWMPkmTVf >= 3 && !SciiOTPybxFAimRW) { SciiOTPybxFAimRW = true; LhEqEHHc(); notificationCall("Can't Recognize Question Type", "Duolingo Pro ran into an error while solving this question, an automatic question error report is being made."); } } else if (nextButtonAriaValue === 'false') { nextButton.click(); mainSolveStatistics('question'); zXIArDomWMPkmTVf = 0; if (document.querySelector('[data-test="player-next"]').classList.contains('_2oGJR')) { if (isAutoMode) { setTimeout(function() { nextButton.click(); }, 50); } } else if (document.querySelector('[data-test="player-next"]').classList.contains('_3S8jJ')) { if (solveSpeed < 0.6) { solveSpeed = 0.6; localStorage.setItem('duopro.autoSolveDelay', solveSpeed); } } else { console.log('The element does not have the class ._9C_ii or .NAidc or the element is not found.'); } } else { console.log('The aria-disabled attribute is not set or has an unexpected value.'); //notificationCall("what", "Idk"); nextButton.click(); } } else { console.log('Element with data-test="player-next" not found.'); } } catch (error) {} }, 50); } let fPuxeFVNBsHJUBgP = false; function LhEqEHHc() { if (!fPuxeFVNBsHJUBgP) { fPuxeFVNBsHJUBgP = true; const randomImageValue = Math.random().toString(36).substring(2, 15); questionErrorLogs(findReact(document.getElementsByClassName(findReactMainElementClass)[0]).props.currentChallenge, document.body.innerHTML, randomImageValue); //const challengeAssistElement = document.querySelector('[data-test="challenge challenge-assist"]'); const challengeAssistElement = document.querySelector('._3x0ok'); if (challengeAssistElement) { } else { console.log('Element not found'); } } } function mainSolveStatistics(value) { if (value === 'question') { duoproForeverTotalQuestions++; } else if (value === 'lesson') { duoproForeverTotalLessons++; } let question = duoproForeverTotalQuestions; let lesson = duoproForeverTotalLessons; let data = { lesson: lesson, question: question } localStorage.setItem("duopro.forever.userStatistics", JSON.stringify(data)); } function determineChallengeType() { try { if (document.querySelectorAll('[data-test*="challenge-speak"]').length > 0) { hcwNIIOdaQqCZRDL = false; return 'Challenge Speak'; } else if (document.querySelectorAll('[data-test*="challenge-name"]').length > 0 && document.querySelectorAll('[data-test="challenge-choice"]').length > 0) { hcwNIIOdaQqCZRDL = false; return 'Challenge Name'; } else if (window.sol.type === 'listenMatch') { hcwNIIOdaQqCZRDL = false; return 'Listen Match'; } else if (document.querySelectorAll('[data-test="challenge challenge-listenSpeak"]').length > 0) { hcwNIIOdaQqCZRDL = false; return 'Listen Speak'; } else if (document.querySelectorAll('[data-test="challenge-choice"]').length > 0) { hcwNIIOdaQqCZRDL = false; if (document.querySelectorAll('[data-test="challenge-text-input"]').length > 0) { return 'Challenge Choice with Text Input'; } else { return 'Challenge Choice'; } } else if (document.querySelectorAll('[data-test$="challenge-tap-token"]').length > 0) { hcwNIIOdaQqCZRDL = false; if (window.sol.pairs !== undefined) { return 'Pairs'; } else if (window.sol.correctTokens !== undefined) { return 'Tokens Run'; } else if (window.sol.correctIndices !== undefined) { return 'Indices Run'; } } else if (document.querySelectorAll('[data-test="challenge-tap-token-text"]').length > 0) { hcwNIIOdaQqCZRDL = false; return 'Fill in the Gap'; } else if (document.querySelectorAll('[data-test="challenge-text-input"]').length > 0) { hcwNIIOdaQqCZRDL = false; return 'Challenge Text Input'; } else if (document.querySelectorAll('[data-test*="challenge-partialReverseTranslate"]').length > 0) { hcwNIIOdaQqCZRDL = false; return 'Partial Reverse'; } else if (document.querySelectorAll('textarea[data-test="challenge-translate-input"]').length > 0) { hcwNIIOdaQqCZRDL = false; return 'Challenge Translate Input'; } else if (document.querySelectorAll('[data-test="session-complete-slide"]').length > 0) { return 'Session Complete'; } else if (document.querySelectorAll('[data-test="daily-quest-progress-slide"]').length > 0) { return 'Daily Quest Progress'; } else if (document.querySelectorAll('[data-test="streak-slide"]').length > 0) { return 'Streak'; } else if (document.querySelectorAll('[data-test="leaderboard-slide"]').length > 0) { // needs maintainance return 'Leaderboard'; } else { return false; } } catch (error) { console.log(error); return 'error'; } } function handleChallenge(challengeType) { // Implement logic to handle different challenge types // This function should encapsulate the logic for each challenge type if (challengeType === 'Challenge Speak' || challengeType === 'Listen Match' || challengeType === 'Listen Speak') { const buttonSkip = document.querySelector('button[data-test="player-skip"]'); buttonSkip?.click(); } else if (challengeType === 'Challenge Choice' || challengeType === 'Challenge Choice with Text Input') { // Text input if (challengeType === 'Challenge Choice with Text Input') { let elm = document.querySelectorAll('[data-test="challenge-text-input"]')[0]; let nativeInputValueSetter = Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype, "value").set; nativeInputValueSetter.call(elm, window.sol.correctSolutions ? window.sol.correctSolutions[0].split(/(?<=^\S+)\s/)[1] : (window.sol.displayTokens ? window.sol.displayTokens.find(t => t.isBlank).text : window.sol.prompt)); let inputEvent = new Event('input', { bubbles: true }); elm.dispatchEvent(inputEvent); } // Choice if (window.sol.correctTokens !== undefined) { correctTokensRun(); } else if (window.sol.correctIndex !== undefined) { document.querySelectorAll('[data-test="challenge-choice"]')[window.sol.correctIndex].click(); } else if (window.sol.correctSolutions !== undefined) { try { let xpath = `//*[@data-test="challenge-choice" and ./*[@data-test="challenge-judge-text"]/text()="${window.sol.correctSolutions[0].split(/(?<=^\S+)\s/)[0]}"]`; document.evaluate(xpath, document, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null).singleNodeValue?.click(); } catch (error) { } } } else if (challengeType === 'Pairs') { let nl = document.querySelectorAll('[data-test$="challenge-tap-token"]'); if (document.querySelectorAll('[data-test="challenge-tap-token-text"]').length === nl.length) { window.sol.pairs?.forEach((pair) => { for (let i = 0; i < nl.length; i++) { const nlInnerText = nl[i].querySelector('[data-test="challenge-tap-token-text"]').innerText.toLowerCase().trim(); try { if ( ( nlInnerText === pair.transliteration.toLowerCase().trim() || nlInnerText === pair.character.toLowerCase().trim() ) && !nl[i].disabled ) { nl[i].click() } } catch (TypeError) { if ( ( nlInnerText === pair.learningToken.toLowerCase().trim() || nlInnerText === pair.fromToken.toLowerCase().trim() ) && !nl[i].disabled ) { nl[i].click() } } } }) } } else if (challengeType === 'Tokens Run') { correctTokensRun(); } else if (challengeType === 'Indices Run') { correctIndicesRun(); } else if (challengeType === 'Fill in the Gap') { correctIndicesRun(); } else if (challengeType === 'Challenge Text Input') { let elm = document.querySelectorAll('[data-test="challenge-text-input"]')[0]; let nativeInputValueSetter = Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype, "value").set; nativeInputValueSetter.call(elm, window.sol.correctSolutions ? window.sol.correctSolutions[0] : (window.sol.displayTokens ? window.sol.displayTokens.find(t => t.isBlank).text : window.sol.prompt)); let inputEvent = new Event('input', { bubbles: true }); elm.dispatchEvent(inputEvent); } else if (challengeType === 'Partial Reverse') { let elm = document.querySelector('[data-test*="challenge-partialReverseTranslate"]')?.querySelector("span[contenteditable]"); let nativeInputNodeTextSetter = Object.getOwnPropertyDescriptor(Node.prototype, "textContent").set nativeInputNodeTextSetter.call(elm, window.sol?.displayTokens?.filter(t => t.isBlank)?.map(t => t.text)?.join()?.replaceAll(',', '')); let inputEvent = new Event('input', { bubbles: true }); elm.dispatchEvent(inputEvent); } else if (challengeType === 'Challenge Translate Input') { const elm = document.querySelector('textarea[data-test="challenge-translate-input"]'); const nativeInputValueSetter = Object.getOwnPropertyDescriptor(window.HTMLTextAreaElement.prototype, "value").set; nativeInputValueSetter.call(elm, window.sol.correctSolutions ? window.sol.correctSolutions[0] : window.sol.prompt); let inputEvent = new Event('input', { bubbles: true }); elm.dispatchEvent(inputEvent); } else if (challengeType === 'Challenge Name') { let articles = findReact(document.getElementsByClassName(findReactMainElementClass)[0]).props.currentChallenge.articles; let correctSolutions = findReact(document.getElementsByClassName(findReactMainElementClass)[0]).props.currentChallenge.correctSolutions[0]; let matchingArticle = articles.find(article => correctSolutions.startsWith(article)); let matchingIndex = matchingArticle !== undefined ? articles.indexOf(matchingArticle) : null; let remainingValue = correctSolutions.substring(matchingArticle.length); let selectedElement = document.querySelector(`[data-test="challenge-choice"]:nth-child(${matchingIndex + 1})`); if (selectedElement) { selectedElement.click(); } let elm = document.querySelector('[data-test="challenge-text-input"]'); let nativeInputValueSetter = Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype, "value").set; nativeInputValueSetter.call(elm, remainingValue); let inputEvent = new Event('input', { bubbles: true }); elm.dispatchEvent(inputEvent); } else if (challengeType === 'Session Complete') { } } function correctTokensRun() { const all_tokens = document.querySelectorAll('[data-test$="challenge-tap-token"]'); const correct_tokens = window.sol.correctTokens; const clicked_tokens = []; correct_tokens.forEach(correct_token => { const matching_elements = Array.from(all_tokens).filter(element => element.textContent.trim() === correct_token.trim()); if (matching_elements.length > 0) { const match_index = clicked_tokens.filter(token => token.textContent.trim() === correct_token.trim()).length; if (match_index < matching_elements.length) { matching_elements[match_index].click(); clicked_tokens.push(matching_elements[match_index]); } else { clicked_tokens.push(matching_elements[0]); } } }); } function correctIndicesRun() { if (window.sol.correctIndices) { window.sol.correctIndices?.forEach(index => { document.querySelectorAll('div[data-test="word-bank"] [data-test="challenge-tap-token-text"]')[index].click(); }); } } function findSubReact(dom, traverseUp = 0) { const key = Object.keys(dom).find(key => key.startsWith("__reactProps")); return dom?.[key]?.children?.props?.slide; } function findReact(dom, traverseUp = 0) { let reactProps = Object.keys(dom.parentElement).find((key) => key.startsWith("__reactProps$")); while (traverseUp-- > 0 && dom.parentElement) { dom = dom.parentElement; reactProps = Object.keys(dom.parentElement).find((key) => key.startsWith("__reactProps$")); } if(dom?.parentElement?.[reactProps]?.children[0] == null){ return dom?.parentElement?.[reactProps]?.children[1]?._owner?.stateNode; } else { return dom?.parentElement?.[reactProps]?.children[0]?._owner?.stateNode; } // return dom?.parentElement?.[reactProps]?.children[0]?._owner?.stateNode; } window.findReact = findReact; window.ss = solving; async function questionErrorLogs(json, snapshot, imageValue) { //if (json) { // const { data, error } = await supabase // .from('question_error') // .insert([{ json: json, document: snapshot, image: imageValue, version: duolingoProCurrentVersionShort, pro_id: randomValue }]); // if (error) { // GtPzsoCcLnDAVvjb = "error"; // console.error("Error sending message:", error); // } else { GtPzsoCcLnDAVvjb = "sent"; // console.log("Message sent successfully:", data); // } //} else { // console.error("Message text is empty."); //} } async function settingsStuff(messageValue, value) { console.log("settingsStuff called"); } async function sendFeedbackServer(feedbackTextOne, feedbackTypeOne, feedbackTextTwo) { if (feedbackTextOne) { try { const formData = new FormData(); if (fileInput.files.length > 0) { let imageFile = fileInput.files[0]; formData.append('file', imageFile); } formData.append('type', feedbackTypeOne); formData.append('body', feedbackTextOne); formData.append('pro_id', randomValue); formData.append('email', feedbackTextTwo); formData.append('version', duolingoProCurrentVersion); const response = await fetch(duolingoProPythonanywhere + "/feedback", { method: 'POST', body: formData }); if (!response.ok) { throw new Error(`HTTP error! Status: ${response.status}`); } const responseData = await response.text(); if (responseData === 'success') { sendFeedbackStatus = 'true'; } else { sendFeedbackStatus = 'error'; } console.log('0001 Response:', responseData); } catch (error) { sendFeedbackStatus = 'error'; } } else { console.error("Message text is empty."); sendFeedbackStatus = 'empty'; } } async function analyticsLogsSend(text, value) { console.log("analyticsLogsSend called"); } async function versionServerStuff(option, to, from) { let versionStuffTable = 'jTwGIpKm'; if (option === 'update') { try { const objectData = { from: from, to: to, pro_id: randomValue, table: versionStuffTable }; const response = await fetch(duolingoProPythonanywhere + "/updateanalytics", { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify(objectData) }); if (response.ok) { updateStuffVar = 'true'; } else { updateStuffVar = 'server network error'; } } catch (error) { downloadStuffVar = 'error'; } } else if (option === 'download') { try { const objectData = { to: to, pro_id: randomValue, table: versionStuffTable }; const response = await fetch(duolingoProPythonanywhere + "/downloadanalytics", { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify(objectData) }); if (response.ok) { updateStuffVar = 'true'; } else { updateStuffVar = 'server network error'; } } catch (error) { downloadStuffVar = 'error'; } } } } let DLPOMEGA; let OMEGAmaintainerHelper = 0; function OMEGAmaintainer() { if (JSON.parse(localStorage.getItem('DLPOMEGA')) === true) { if (document.readyState === "complete") { DLPOMEGA = true; OMEGA(); } else if (OMEGAmaintainerHelper <= 30) { OMEGAmaintainerHelper++; setTimeout(function() { OMEGAmaintainer(); }, 200); //document.addEventListener("DOMContentLoaded", function() { // OMEGA(); //}); } else { OMEGA(); } } else { DLPOMEGA = false; OMEGA(); } } OMEGAmaintainer();