ManeraKai 2024-08-17 09:13:58 +03:00
parent 5a503e9e20
commit e96ac0c310
No known key found for this signature in database
GPG Key ID: 5ABC31FFD562E337
2 changed files with 17 additions and 1 deletions

View File

@ -565,6 +565,15 @@ function rewrite(url, frontend, randomInstance) {
return `${randomInstance}${url.pathname}${url.search}`
}
case "ytify": {
if (url.pathname.startsWith('/watch')) return `${randomInstance}/?s=${encodeURIComponent(url.searchParams.get('v'))}`
const channelReg = /\/channel\/([^\/]+)/.exec(url.pathname)
if (channelReg) return `${randomInstance}/list?channel=${channelReg[1]}`
if (url.pathname.startsWith('/playlist')) return `${randomInstance}/list?playlists=${encodeURIComponent(url.searchParams.get('list'))}`
return `${randomInstance}${url.pathname}${url.search}`
}
case "piped":
case "pipedMaterial":
case "cloudtube":
@ -818,7 +827,8 @@ const defaultInstances = {
freetar: ["https://freetar.de"],
ratAintTieba: ["https://rat.fis.land"],
shoelace: ["https://shoelace.mint.lgbt"],
skunkyArt: ["https://skunky.bloat.cat/"],
skunkyArt: ["https://skunky.bloat.cat"],
ytify: ["https://ytify.netlify.app"],
}
function initDefaults() {

View File

@ -125,6 +125,12 @@
"embeddable": false,
"instanceList": true,
"url": "https://github.com/ViewTube/viewtube"
},
"ytify": {
"name": "ytify",
"embeddable": false,
"instanceList": true,
"url": "https://github.com/n-ce/ytify/"
}
},
"targets": [