[MM-57194] Allow plugins to mark setting fields as secret (#27986)

Co-authored-by: Claudio Costa <cstcld91@gmail.com>
Этот коммит содержится в:
Ben Schumacher
2024-09-12 19:23:57 +02:00
коммит произвёл GitHub
родитель 84a0c09d56
Коммит 70fe2abea6
13 изменённых файлов: 311 добавлений и 45 удалений

Просмотреть файл

@@ -89,6 +89,10 @@ type PluginSetting struct {
// and the opposite environment is running the plugin, the setting will be hidden in the admin console UI.
// Note that this functionality is entirely client-side, so the plugin needs to handle the case of invalid submissions.
Hosting string `json:"hosting"`
// If true, the setting is sanitized before showing it in the System Console or returning it via the API.
// This is useful for settings that contain sensitive information.
Secret bool `json:"secret"`
}
type PluginSettingsSection struct {