0733bdcbe2
优化 substore 脚本逻辑,移除 peiqian-rename.js 和 yuetong-rename.js 中对 _subName 的硬编码判断,使其更适合在单条订阅中复用。 同时在 rename.js 中新增流媒体文案清理规则,并同步更新 README.md 文档,说明各脚本在单订阅与整合订阅中的最佳实践建议。
21 lines
524 B
JavaScript
21 lines
524 B
JavaScript
/**
|
|
* YueTong 专用节点清理脚本
|
|
* 负责去掉“悦·”品牌前缀、钻石等装饰,以及压短 AI 解锁文案。
|
|
*/
|
|
function operator(proxies) {
|
|
return proxies.map(proxy => {
|
|
if (typeof proxy.name !== 'string') {
|
|
return proxy;
|
|
}
|
|
|
|
proxy.name = proxy.name
|
|
.replace(/悦[·・]\s*/g, '')
|
|
.replace(/AI解锁/g, 'AI')
|
|
.replace(/[💎]/gu, '')
|
|
.replace(/\s{2,}/g, ' ')
|
|
.trim();
|
|
|
|
return proxy;
|
|
});
|
|
}
|