// ==UserScript== // @name Panopto-Video-DL // @namespace www.pizidavi.altervista.org // @description Download video from Panopto // @icon https://www.panopto.com/wp-content/themes/panopto/library/images/favicons/favicon-96x96.png // @author pizidavi & Stini // @version 2.1 // @copyright 2021, PIZIDAVI // @license MIT // @homepageURL https://github.com/enricobragastini/Panopto-Video-DL // @match https://*.panopto.com/Panopto/Pages/Viewer.aspx?*id=* // @match https://*.panopto.com/Panopto/Pages/Embed.aspx?*id=* // @match https://*.panopto.eu/Panopto/Pages/Viewer.aspx?*id=* // @match https://*.panopto.eu/Panopto/Pages/Embed.aspx?*id=* // @grant none // @downloadURL none // ==/UserScript== (function(Panopto) { 'use strict'; if (location.pathname.includes('Viewer.aspx')) { const element = document.createElement('a'); element.id = 'downloadTabHeader'; element.classList = 'event-tab-header'; element.href = location.pathname.replace('Viewer.aspx', 'Embed.aspx') + '?id=' + new URLSearchParams(location.search).get('id'); element.target = '_blank'; element.style = 'position:absolute;bottom:40px;padding:5px 10px;cursor:pointer;'; element.innerHTML = 'Download
'; element.addEventListener('click', e => { if (localStorage.getItem('popup-viewed') == 'true') { return; } const div = document.createElement('div'); div.id = 'Panopto-Video-DL'; div.innerHTML = 'To download video follow these steps: