Repository navigation
Phase 5b3: live choice lists and a live widget preview - #51
Merged
Merged
Conversation
Integrations publish named choice lists (IIntegration.GetChoicesAsync), and options point at one with SchemaOption.ChoicesFrom, keeping their own type and checks. Uptime Kuma publishes its monitors, so the monitor widget picks its monitor by name, with "Another value..." to type an ID and a fallback to the plain field when Kuma can't be read. The link dialog's preview now shows the link's widgets, saved or not, including the one being edited: rendered with cached results, the rest read one by one, never holding up the tile. The widget form shows what the edited widget reads, which is its test. Widget cache keys no longer include the widget ID, so a preview's read is shared with the saved widget. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
From the 5b2 soak: the Kuma widget's monitor was typed as an ID, and the link dialog's preview didn't show widgets.
Choice lists
IIntegration.GetChoicesAsync (listKey, ConnectionContext). A list is aChoiceListofOptionChoices, each with an optionalGroup.SchemaOption.ChoicesFrom, and keeps its own type and checks. Stored data doesn't change, so there's no migration and no backup version bump.monitors: groups first, then the rest, each listed as name (#id). The monitor widget'smonitorIduses it.ChoiceListReaderreads a list through the integration's first connection. The Editor'sChoiceshandler serves it, answering 200 with amessagewhen it can't be read and 404 for no such list.option-fields.jsshows a grouped dropdown with Another value…, which reveals the option's own field (that's the one posted).Live preview
data-widget-preview, sowidgets.jsnever polls them.link-dialog.jsthen reads each through the newWidgetPreviewhandler.The link's own monitor picker and the infrastructure group dialog keep
monitor-picker.jsuntil 5c and 5d.Test plan
LiveChoiceTests:ContinuousIntegrationBuild=trueis clean, andjb cleanupcodewas applied.🤖 Generated with Claude Code