2 Commits

Author SHA1 Message Date
IndieKKY
ee1eaf9e08 chore: release 1.11.11 2024-10-19 15:21:47 +08:00
IndieKKY
cc732de8e6 fix csp 2024-10-19 15:21:24 +08:00
4 changed files with 12 additions and 2 deletions

View File

@@ -51,6 +51,9 @@ node版本18.15.0
注:`./push.sh`是作者自用脚本,可以忽略。
提示本地edge开发调试可能有问题会报csp错误本地开发调试推荐用chrome。
构建后应该正常关键是fix.cjs里将use_dynamic_url设置为false的这个操作。
## 贡献指南
欢迎贡献代码或提出改进建议!如果您希望为该项目做出贡献,请遵循以下步骤:

View File

@@ -5,4 +5,11 @@ const fs = require('fs')
//copy index.html to sidepanel.html
fs.copyFileSync('./dist/index.html', './dist/sidepanel.html')
//set all use_dynamic_url to false
const manifest = require('./dist/manifest.json')
manifest.web_accessible_resources.forEach(resource => {
resource.use_dynamic_url = false
})
fs.writeFileSync('./dist/manifest.json', JSON.stringify(manifest, null, 2))
console.log('fix.js done');

View File

@@ -57,7 +57,7 @@ export default defineManifest(async (env) => ({
"resources": [
"index.html",
],
"use_dynamic_url": true
"use_dynamic_url": false
}
]
}))

View File

@@ -1,7 +1,7 @@
{
"private": true,
"name": "bilibili-subtitle",
"version": "1.11.10",
"version": "1.11.11",
"type": "module",
"description": "哔哩哔哩字幕列表",
"main": "index.js",