// ==UserScript== // @name 为Alist生成m3u播放列表文件 // @namespace createM3UforAlist.whatGUI // @version 2024-08-27 // @description 为alist中的音视频文件生成并上传或下载一个m3u播放列表文件,脚本编写过程由肉人辅助AI完成 // @author whatGUI // @match http://*/* // @match https://*/* // @grant GM_setClipboard // @icon https://alist.nn.ci/favicon.ico // @license MIT // @downloadURL none // ==/UserScript== (function () { "use strict"; addButton(); })(); function addButton() { let buttonLock = false; const buttonDiv = document.createElement("div"); const style = document.createElement("style"); // 设置 CSS 规则 style.textContent = ` .toolbar-ex { position: fixed; right: 65px; bottom: 20px; } .toolbar-ex-icon { width: 2rem; height: 2rem; color: #ff8718; padding: 4px; border-radius: 0.5rem; cursor: pointer; margin-top: 0.25rem; } .toolbar-ex-icon:hover { color: #ffffff; background-color: #ff8718; } .m3u-method-menu { position: absolute; bottom: calc( 32px + 0.25rem); right: 0; transition: height 0.2s ease-out; height: 0; overflow: hidden; } `; // 将