Skip to content

Steer build-plugin to plain ui.json selection fields - #191

Merged
andrewmumblebee merged 6 commits into
mainfrom
work/ah/ui-selects
Nov 13, 2026
Merged

andrewmumblebee merged 6 commits into
mainfrom
work/ah/ui-selects

Conversation

@andrewmumblebee

@andrewmumblebee andrewmumblebee commented Nov 12, 2026 •

Copy link
Copy Markdown
Contributor

📋 Summary

This PR stops the build-plugin skill from building odd config forms, such as tabs or a grid of chips, to pick which objects to index.

Both forms came from ui.md. It recommended choiceChips "especially multi-select", and it called fieldGroupToggle a "collapsible/switchable group". In fact fieldGroupToggle is a switch that shows one child at a time and doesn't wrap, so long labels ran off the screen.

 ## Selection inputs
-radio for own-line options; switch for 2–3 modes; choiceChips for multi-select; checkbox/toggle for on/off
+Use the plainest field that fits:
+  one on/off             → toggle
+  some items, fixed set  → one checkbox per item, under a master toggle
+  one of 2–4, ≤ ~50 chars → switch (one line, no wrap; set defaultValue)
+  one of 2–5, long/desc  → radio
+  one of a long list     → autocomplete
+  typed IDs              → autocomplete isMulti
+  choiceChips            → a data stream's ui array only

 ## Layout
-displayAs: fieldGroupToggle is a collapsible/switchable group
+In ui.json, row/inlineFields only for fields on one line (host and port)
+tabs and fieldGroupToggle are for a data stream's ui array only
+fieldGroupToggle shows one child field at a time

The rules match what plugins in squaredup-plugin-repository already do:

  • Objects to index: Salesforce v2, Geodata, Jira and Prometheus v4 use one checkbox per object type. Prometheus v4 covers the same choices as the tabs form with three plain checkboxes.
  • choiceChips: no plugin uses it in ui.json. 15 plugins use it in data-stream ui, mostly for multi-select filters, so it stays for that.
  • Toggle and switch: since December 2025, maintainers have moved WebAPI on/off fields to toggle and short single choices to switch (also CSV, SCOM, AWS). radio stays for long labels or options with descriptions.
  • Switch width: in the widest config modal the field is 564px, which fits about 55 characters of switch labels in total. The limit is set at about 50 to leave some margin.
  • Long lists: autocomplete. Datadog moved from a 5-option radio to an autocomplete in v2.

🔍 Scope of change

  • Documentation only
  • Repository metadata or configuration
  • CI / automation
  • Other (please describe):

📚 Checklist

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Documentation
    • Updated guidance on choosing selection fields based on the number and length of options, and whether users can select one or multiple values.
    • Clarified that choice chips are available only in data-stream interfaces.
    • Specified which layouts suit one-line fields and data-stream interfaces. Field-group toggles show one child field at a time and require short child labels.

Add a rule list for picking a selection field. Use one checkbox per
item for a multi-select from a fixed set, as real plugins do.
Limit choiceChips and displayAs layouts to a data stream's ui array.
Correct the fieldGroupToggle description: it shows one child at a time.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Nov 12, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

Automatic approval withheld

Automatic approval is disabled by the configured approval policy for this pull request. Review comments and requests for changes continue normally.

Commit: 50445bd1f3d1.

No actionable comments were generated in the recent review.

Walkthrough

The plugin UI reference now recommends selection controls based on option count and input type. It also specifies where choiceChips and displayAs options apply, and describes how fieldGroupToggle displays child fields.

Changes: Build plugin UI reference

Layer / File(s) Summary
Selection control and layout guidance
.claude/skills/build-plugin/references/ui.md
The guidance recommends controls based on input type and option count. It limits choiceChips to data-stream ui arrays, and specifies the contexts for row, inlineFields, tabs and fieldGroupToggle. It describes fieldGroupToggle as showing one child field at a time and requires short child labels.
Merge Risk: Minimal · up to 50445

This is a documentation-only update to UI guidance for building plugins. It affects no runtime behavior, so merge risk is minimal.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: steering build-plugin guidance toward plain ui.json selection fields. The raw summary confirms the changed file is the build-plugin ui.md reference, which updates sele…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Pr Template Passed The PR body follows the "Miscellaneous change" template. The template in .github/PULL_REQUEST_TEMPLATE/Miscellaneous change.md has three headings: "📋 Summary", "🔍 Scope of change" and "📚 Checklist". T…
Full details: Title check

Explanation

The title names the main change: steering build-plugin guidance toward plain ui.json selection fields. The raw summary confirms the changed file is the build-plugin ui.md reference, which updates selection-input field guidance and limits choiceChips, tabs and fieldGroupToggle to a data stream's ui array. The title is specific and concise, and it matches the objectives.

Full details: Pr Template

Explanation

The PR body follows the "Miscellaneous change" template. The template in .github/PULL_REQUEST_TEMPLATE/Miscellaneous change.md has three headings: "📋 Summary", "🔍 Scope of change" and "📚 Checklist". The PR body contains all three, and it is not the template picker from .github/pull_request_template.md. The body is not free text. The changed-file inventory (refs/coderabbit/pre-merge-check/base to head) contains one file: .claude/skills/build-plugin/references/ui.md. No file under plugins/ changes, so the rule that fails a "Miscellaneous change" touching plugins/ does not apply. The PR is documentation for a skill, so the "Miscellaneous change" choice fits. The check does not require a testing section for this template. The author's extra "Scope of change" and "Checklist" content is acceptable. The PR author is andrewmumblebee. The author does not affect this check.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Automatic approval policy

Commit: 50445bd1f3d1.

Setting Effective value Source
Automatic approvals Disabled Override 1
Merge risk Low Global configuration
Security risk Not set Global configuration

Matching overrides (numbered as in the resolved configuration):

  • Override 1 — any author; paths: .coderabbit.yaml, REVIEW.md, AGENTS.md, CLAUDE.md, .claude/**, .github/**; automatic approvals: disabled.

Any matching disabled override withholds approval, regardless of risk. Otherwise, the strictest explicitly set limit wins for each score. Limits omitted by all matching overrides inherit the global configuration.

Not set means no limit was configured after inheritance. Use @coderabbitai configuration to inspect the resolved settings and their sources.

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 1d32ace and 50445bd.

Files selected for processing: 1

  • .claude/skills/build-plugin/references/ui.md
Files skipped from review as they are similar to previous changes: 1

  • .claude/skills/build-plugin/references/ui.md

Included review availability: This review used your included allowance. 0 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 2 reviews per hour.

Use row or inlineFields in ui.json for fields that read as one line,
such as a host and port. Keep tabs and fieldGroupToggle for a data
stream's ui array.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@andrewmumblebee
andrewmumblebee marked this pull request as ready for review November 12, 2026 07:25
@andrewmumblebee
andrewmumblebee requested a review from a team November 12, 2026 07:25
andrewmumblebee and others added 4 commits November 13, 2026 09:00
Use a toggle for one on/off and as the master over per-item
checkboxes. Use a switch for 2-4 short options, with a defaultValue.
Keep radio for long labels or options with descriptions. This matches
the WebAPI, SCOM, CSV and AWS changes since December 2025.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Start each single-choice rule with "One of N" so that an on/off field
with a long label does not match the radio rule.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Give the reason for the short-label limit, so the agent checks the
total width of all options.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The switch draws all options on one line. In the widest config modal
about 55 characters of label text fit, so set the limit at about 50
characters for all labels together, not 20 per label.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

🧩 Plugin PR Summary

ℹ️ No plugins were modified in this PR.

@andrewmumblebee

Copy link
Copy Markdown
Contributor Author

@clarkd made some tweaks based on your review and an audit of existing squaredup-plugin-repository plugins

  • One on/off: now toggle, matching your WebAPI changes from Dec 2025.
  • Optional set of items: a master toggle ("Configure your import") with one checkbox per item under it.
  • One of 2–4 options: now switch, if all the labels together are about 50 characters or less. This was based on measuring in the app at full modal width, there is possibly a bug fix here to allow it to wrap, as narrow screens still can break that.
  • Radio: kept for 2–5 options with long labels or option descriptions, which a switch can't show.

@andrewmumblebee
andrewmumblebee merged commit 13891d1 into main Nov 13, 2026
2 checks passed
@andrewmumblebee
andrewmumblebee deleted the work/ah/ui-selects branch November 13, 2026 15:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants