JSFiddle - React, Tailwind, and code Playground

by Mateus Fernandes de Mello

HTML

CĂłdigo pra baixar as aulas com nome correto

JavaScript

javascript:
function create(htmlStr) {
    var frag = document.createDocumentFragment(),
        temp = document.createElement('div');
    temp.innerHTML = htmlStr;
    while (temp.firstChild) {
        frag.appendChild(temp.firstChild);
    }
    return frag;
}

url = document.getElementById("region-main").getElementsByTagName("a")[0].getAttribute('href');

name = document.getElementById("region-main").getElementsByTagName("h2")[0].innerHTML;

name = name.split("-")[1].trim().split('/').join('-');

url = url + 'output/aula-' + name + '.zip?download=zip';

var fragment = create('<a href="' + url + '" id="mlink" style="display:none">link</a>');

document.body.insertBefore(fragment, document.body.childNodes[0]);

alert('Aguarde a Adobe processar seu pedido!');

document.getElementById("mlink").click();