codeをspanに置き換え
プログラミングのドキュメントを翻訳したときに、文章内の<code>要素が無視されて翻訳されないのを修正します。なるべく文章内のキーワードのみをターゲットにするようにしています。拡張機能のオプションでcodeからコピーするスタイルを変更できます。
Additional files are visible only to premium users
manifest.json
{
"manifest_version": 3,
"name": "codeã‚’spanã«ç½®ãæ›ãˆ",
"version": "4",
"description": "プãƒã‚°ãƒ©ãƒŸãƒ³ã‚°ã®ãƒ‰ã‚ュメントを翻訳ã—ãŸã¨ãã«ã€æ–‡ç« 内ã®<code>è¦ç´ ãŒç„¡è¦–ã•ã‚Œã¦ç¿»è¨³ã•ã‚Œãªã„ã®ã‚’ä¿®æ£ã—ã¾ã™ã€‚ãªã‚‹ã¹ãæ–‡ç« å†…ã®ã‚ーワードã®ã¿ã‚’ターゲットã«ã™ã‚‹ã‚ˆã†ã«ã—ã¦ã„ã¾ã™ã€‚拡張機能ã®ã‚ªãƒ—ションã§codeã‹ã‚‰ã‚³ãƒ”ーã™ã‚‹ã‚¹ã‚¿ã‚¤ãƒ«ã‚’変更ã§ãã¾ã™ã€‚",
"homepage_url": "https://github.com/matoritori/code-translate",
"icons": {
"16": "icon16.png",
"128": "logo.png"
},
"content_security_policy": {
"extension_pages": "default-src 'self'"
},
"permissions": [
"webNavigation",
"storage"
],
"background": {
"service_worker": "dist/background.js"
},
"content_scripts": [
{
"matches": [
"https://*/*"
],
"js": [
"dist/content-script.js"
]
}
],
"options_page": "options.html",
"action": {
"default_popup": "popup.html",
"default_icon": {
"16": "icon16.png",
"24": "icon24.png",
"32": "logo.png"
}
},
"update_url": "https://edge.microsoft.com/extensionwebstorebase/v1/crx"
}