Build plugin settings from the component's options schema, and define presets as app templates

オープン
#2,038 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 2 日以内に返信

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
35/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
活発
技術スタック
typescript, yaml
領域
frontend

調査の方向性

Start with the settings form work in #2031 and the related form building in #2016; inspect how Studio currently defines CLUSTER_PRESETS and where component settings are saved. Use page and API caching as the stated test case, since it has the most settings. Done means forms can be built from plugin options schemas and saved to the loading app's config.yaml, and presets can be represented as app templates that can be added to an existing cluster.

索引モデルが issue の本文から書いたものです。

説明

Problem

A component page's settings form is a hand-listed fields array with a handful of input types, saved to a table record (#2031). Plugin policy needs richer inputs, and belongs in the loading app's config.yaml rather than a table. Cluster presets are also defined in Studio's own source (CLUSTER_PRESETS), so adding a solution means a Studio release, and a preset can't be added to a cluster that already exists.

Proposal
  • Settings from the schema: once a plugin publishes an options schema (HarperFast/harper#3722), Studio builds its settings form from it and saves to the app's config.yaml.
  • Field types for policy: arrays, key-value maps, lists of nested objects, durations, datetimes, and select options loaded from the cluster (tables, roles). Most fall out of the schema.
  • Presets as app templates: a preset is data, not Studio code: the plugins to load, a prefilled config.yaml, and the few inputs the create form asks for. That takes CLUSTER_PRESETS out of Studio, and lets a cluster add a second solution later.
Related
  • #2016 builds settings forms for Harper's own settings. The two should share their form building.
  • #1267 asks to let a user enable and configure stock plugins.
Context

Raised in review of #2031 (comment). It suggests page and API caching as the test case, since it has the most settings.

🤖 Generated by Claude Code (Claude Opus 5.5); posted via @dawsontoth.

主要言語
TypeScript
スター
5
フォーク
4
平均マージ
1日 19時間
マージ済み PR(30日)
144

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

HarperFast/studio のほかの issue

HarperFast/studio の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。