Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

两点建议 #309

Closed
superen7527 opened this issue Apr 2, 2023 · 4 comments
Closed

两点建议 #309

superen7527 opened this issue Apr 2, 2023 · 4 comments
Labels
enhancement New update or improvement request

Comments

@superen7527
Copy link

superen7527 commented Apr 2, 2023

1.支持修改自定义镜像地址

比如谷歌翻译,国内不能用,但是自己搭建了反代,可以用自己的域名代替谷歌域名,除此之外http请求体格式完全一样。

2.支持添加自定义翻译接口

比如自己搭建的翻译接口,或者一些冷门没适配的接口,希望可以有一个地方用来写好地址和请求体就能添加进列表。

和上面有点类似,不过第一点只是替换域名,路径和请求体是一样的。而这里的是http地址和请求体都可以改。

总的来说实现了这个也能包括第一点的功能,只不过对于已知固定的请求体可以用原来的,用第一点的思路就不用再去找文档重复一遍了,简单一点。

@theowenyoung theowenyoung added the enhancement New update or improvement request label Apr 2, 2023
@theowenyoung
Copy link
Contributor

  1. 这个其实当前在开发者设置里,可以修改 user config 来实现,目前还没有做界面,因为可能会对普通用户造成困扰。类似这样,可以不填具体路径,如:https://your-domain.com 即可。
"translationServices": {
  "google": {
    "apiUrl":""
  }
}

文档: https://immersive-translate.owenyoung.com/advanced#%E7%BF%BB%E8%AF%91%E6%9C%8D%E5%8A%A1%E9%85%8D%E7%BD%AE

  1. 这个在未来有计划,短期可能还没时间做这个。

@superen7527
Copy link
Author

好的,感谢回复。不急 只是提及在这里,有空再做吧。

另外上面表达一点不完美我再修改一下,希望不会造成打扰。(不知道修改会不会发邮箱通知)

@theowenyoung
Copy link
Contributor

目前 第二点也已经支持了哈, 可以选择【自定义API】,见文档:

https://immersivetranslate.com/docs/services/custom/

@superen7527
Copy link
Author

目前 第二点也已经支持了哈, 可以选择【自定义API】,见文档:

https://immersivetranslate.com/docs/services/custom/

你好好像理解错了,自定义不了body{"text": "xxx", "source_lang": "auto", "target_lang": "ZH"}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New update or improvement request
Projects
None yet
Development

No branches or pull requests

2 participants