decky-plugin-template icon indicating copy to clipboard operation
decky-plugin-template copied to clipboard

[enhancement] Can you provide i18n templates or native support?

Open XTsat opened this issue 4 months ago • 1 comments

Providing native support makes it easier for developers to provide i18n, and it also helps us to easily add our own language support

Structures like this

locales
├── index_en-US.js
├── index_zh-CN.js
├── ...
└── <contry-code>.js

or

locales
├── index.js
├── i18n
  ├── en-US.js
  ├── zh-CN.js
  └── <contry-code>.js

Is the "name" of plugin.json a unique field? Can you also add a non-unique field to provide i18n display?

like this

"name": "decky-plugin-template",
"name_i18n": {
  "en_US": "decky-plugin-template",
  "zh_CN": "decky 插件模板",
  "<contry-code>": "<contry language>"
},

These are just directions that I think can be done, and it would be better if there was a better way to implement it

XTsat avatar Sep 01 '25 04:09 XTsat

We have no plans to include default localization in the template as it is not a focus of ours at this time. If a contributor was to provide us such a a thing I'm sure we'd be willing to review and hopefully accept it.

Plugin names are not in a position to be localized right now as the name field is a unique field used to generate the plugin in our CI. Someone submitting such a feature would need to make changes to our CLI tool, our CI scripts and so on.

TrainDoctor avatar Sep 03 '25 11:09 TrainDoctor