v0.15.5
This commit is contained in:
parent
e10b975eeb
commit
7cb8cd227e
|
@ -5,7 +5,7 @@
|
||||||
// @supportURL https://github.com/Xmader/musescore-downloader/issues
|
// @supportURL https://github.com/Xmader/musescore-downloader/issues
|
||||||
// @updateURL https://msdl.librescore.org/install.user.js
|
// @updateURL https://msdl.librescore.org/install.user.js
|
||||||
// @downloadURL https://msdl.librescore.org/install.user.js
|
// @downloadURL https://msdl.librescore.org/install.user.js
|
||||||
// @version 0.15.4
|
// @version 0.15.5
|
||||||
// @description download sheet music from musescore.com for free, no login or Musescore Pro required | 免登录、免 Musescore Pro,免费下载 musescore.com 上的曲谱
|
// @description download sheet music from musescore.com for free, no login or Musescore Pro required | 免登录、免 Musescore Pro,免费下载 musescore.com 上的曲谱
|
||||||
// @author Xmader
|
// @author Xmader
|
||||||
// @match https://musescore.com/*/*
|
// @match https://musescore.com/*/*
|
||||||
|
@ -26354,6 +26354,7 @@ Please pipe the document into a Node stream.\
|
||||||
}
|
}
|
||||||
})();
|
})();
|
||||||
const IPNS_KEY = 'QmSdXtvzC8v8iTTZuj5cVmiugnzbR1QATYRcGix4bBsioP';
|
const IPNS_KEY = 'QmSdXtvzC8v8iTTZuj5cVmiugnzbR1QATYRcGix4bBsioP';
|
||||||
|
const RADIX = 20;
|
||||||
const scoreinfo = {
|
const scoreinfo = {
|
||||||
get playerdata() {
|
get playerdata() {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
|
@ -26369,6 +26370,10 @@ Please pipe the document into a Node stream.\
|
||||||
return +m[1];
|
return +m[1];
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
get idLastDigit() {
|
||||||
|
const idStr = (+this.id).toString(RADIX);
|
||||||
|
return parseInt(idStr[idStr.length - 1], RADIX);
|
||||||
|
},
|
||||||
get title() {
|
get title() {
|
||||||
try {
|
try {
|
||||||
return this.playerdata.title;
|
return this.playerdata.title;
|
||||||
|
@ -26403,7 +26408,7 @@ Please pipe the document into a Node stream.\
|
||||||
return origin + pathname.split('/').slice(0, -1).join('/') + '/';
|
return origin + pathname.split('/').slice(0, -1).join('/') + '/';
|
||||||
},
|
},
|
||||||
get msczIpfsRef() {
|
get msczIpfsRef() {
|
||||||
return `/ipns/${IPNS_KEY}/${this.id}.mscz`;
|
return `/ipns/${IPNS_KEY}/${this.idLastDigit}/${this.id}.mscz`;
|
||||||
},
|
},
|
||||||
get msczCidUrl() {
|
get msczCidUrl() {
|
||||||
return `https://ipfs.infura.io:5001/api/v0/dag/resolve?arg=${this.msczIpfsRef}`;
|
return `https://ipfs.infura.io:5001/api/v0/dag/resolve?arg=${this.msczIpfsRef}`;
|
||||||
|
@ -26559,7 +26564,7 @@ Please pipe the document into a Node stream.\
|
||||||
})();
|
})();
|
||||||
|
|
||||||
/* eslint-disable no-extend-native */
|
/* eslint-disable no-extend-native */
|
||||||
let AUTH_MODULE_ID;
|
let authModuleId;
|
||||||
const AUTH_FN = '+3],22,-1044525330)';
|
const AUTH_FN = '+3],22,-1044525330)';
|
||||||
const MAGIC_ARG_INDEX = 1;
|
const MAGIC_ARG_INDEX = 1;
|
||||||
/**
|
/**
|
||||||
|
@ -26570,14 +26575,16 @@ Please pipe the document into a Node stream.\
|
||||||
webpackGlobalOverride(ALL, (n, r, t) => {
|
webpackGlobalOverride(ALL, (n, r, t) => {
|
||||||
const fn = n.exports;
|
const fn = n.exports;
|
||||||
if (typeof fn === 'function' && fn.toString().includes(AUTH_FN)) {
|
if (typeof fn === 'function' && fn.toString().includes(AUTH_FN)) {
|
||||||
AUTH_MODULE_ID = n.i;
|
if (!authModuleId && n.i) {
|
||||||
n.exports = (...args) => {
|
authModuleId = n.i;
|
||||||
if (magic instanceof Promise) {
|
n.exports = (...args) => {
|
||||||
magic = args[MAGIC_ARG_INDEX];
|
if (magic instanceof Promise) {
|
||||||
resolve(magic);
|
magic = args[MAGIC_ARG_INDEX];
|
||||||
}
|
resolve(magic);
|
||||||
return fn(...args);
|
}
|
||||||
};
|
return fn(...args);
|
||||||
|
};
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
@ -26592,7 +26599,7 @@ Please pipe the document into a Node stream.\
|
||||||
magic = yield magic;
|
magic = yield magic;
|
||||||
}
|
}
|
||||||
const str = String(scoreinfo.id) + type + String(index);
|
const str = String(scoreinfo.id) + type + String(index);
|
||||||
const fn = webpackHook(AUTH_MODULE_ID);
|
const fn = webpackHook(authModuleId);
|
||||||
return fn(str, magic);
|
return fn(str, magic);
|
||||||
});
|
});
|
||||||
const getFileUrl = (type, index = 0) => __awaiter(void 0, void 0, void 0, function* () {
|
const getFileUrl = (type, index = 0) => __awaiter(void 0, void 0, void 0, function* () {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "musescore-downloader",
|
"name": "musescore-downloader",
|
||||||
"version": "0.15.4",
|
"version": "0.15.5",
|
||||||
"lockfileVersion": 1,
|
"lockfileVersion": 1,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "musescore-downloader",
|
"name": "musescore-downloader",
|
||||||
"version": "0.15.4",
|
"version": "0.15.5",
|
||||||
"description": "download sheet music from musescore.com for free, no login or Musescore Pro required | 免登录、免 Musescore Pro,免费下载 musescore.com 上的曲谱",
|
"description": "download sheet music from musescore.com for free, no login or Musescore Pro required | 免登录、免 Musescore Pro,免费下载 musescore.com 上的曲谱",
|
||||||
"main": "dist/main.js",
|
"main": "dist/main.js",
|
||||||
"repository": {
|
"repository": {
|
||||||
|
|
Loading…
Reference in New Issue