PluginIndexModule · packages/server/src/plugin/index-config.ts:33

PluginIndexSettings

component

Declares the group the Settings dialog draws; nothing reads it here.

API

@Component({
  contributes: {
    "PluginConfigProvider.groups": [
      {
        id: "plugin-index",
        // Drawn inside the Plugin Sources card (source-settings.ts), between the npm registry
        // and the mirrors: one card on screen, saved under its own key (`plugin-config:plugin-index`).
        parent: "plugin-sources",
        order: 1,
        properties: {
          sources: {
            type: "list",
            title: "Plugin index",
            titleZh: "插件索引",
            description:
              "The plugin catalogues this deployment lists and installs from: one index.json document per address, tried in the order written, the earlier address winning a package a later one also lists. The published index this release ships with is on the list by default; remove it or add addresses as the deployment needs, or empty the list to read the shipped packages alone (no outbound request).",
            descriptionZh:
              "本部署列出与安装插件时读取的目录:每个地址一份 index.json,按书写顺序尝试,同一插件由更靠前的地址提供。随本版本发布的索引默认在列表中:按部署需要删除或追加地址,或清空列表只读随本服务器内置的插件(不发出任何网络请求)。",
            placeholder: "https://example.com/index.json",
            default: [
              "https://github.com/Prism-Shadow/penguin-harness-plugins/releases/download/nightly/index.json",
            ],
            pattern: "^https?://\\S+$",
            patternErrorMessage: "must be an http(s) URL",
          },
        },
      },
    ],
  },
})
export class PluginIndexSettings {}

Contributes

{
  "PluginConfigProvider.groups": [
    {
      "id": "plugin-index",
      "parent": "plugin-sources",
      "order": 1,
      "properties": {
        "sources": {
          "type": "list",
          "title": "Plugin index",
          "titleZh": "插件索引",
          "description": "The plugin catalogues this deployment lists and installs from: one index.json document per address, tried in the order written, the earlier address winning a package a later one also lists. The published index this release ships with is on the list by default; remove it or add addresses as the deployment needs, or empty the list to read the shipped packages alone (no outbound request).",
          "descriptionZh": "本部署列出与安装插件时读取的目录:每个地址一份 index.json,按书写顺序尝试,同一插件由更靠前的地址提供。随本版本发布的索引默认在列表中:按部署需要删除或追加地址,或清空列表只读随本服务器内置的插件(不发出任何网络请求)。",
          "placeholder": "https://example.com/index.json",
          "default": [
            "https://github.com/Prism-Shadow/penguin-harness-plugins/releases/download/nightly/index.json"
          ],
          "pattern": "^https?://\\S+$",
          "patternErrorMessage": "must be an http(s) URL"
        }
      }
    }
  ]
}

Target slots: PluginConfigProvider.groups