From 4bb77cf0f784c1d72939fe8795ff8e90aa8182d1 Mon Sep 17 00:00:00 2001 From: Joseph Doherty Date: Fri, 21 Aug 2026 08:01:37 -0400 Subject: [PATCH] =?UTF-8?q?docs(centralui):=20template=20picker=20on=20Cre?= =?UTF-8?q?ate=20Instance,=20New=20Instance=E2=80=A6=20from=20the=20Templa?= =?UTF-8?q?tes=20tree?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Claude-Session: https://claude.ai/code/session_01G2GHPnbbKGvyyfbr2XBRVH --- docs/plans/2026-08-21-create-instance-bindings-design.md | 6 +++++- docs/plans/2026-08-21-template-picker-design.md | 2 +- docs/plans/2026-08-21-template-picker.md.tasks.json | 6 +++--- docs/requirements/Component-CentralUI.md | 6 ++++-- 4 files changed, 13 insertions(+), 7 deletions(-) diff --git a/docs/plans/2026-08-21-create-instance-bindings-design.md b/docs/plans/2026-08-21-create-instance-bindings-design.md index feddd2e9..e20d4f07 100644 --- a/docs/plans/2026-08-21-create-instance-bindings-design.md +++ b/docs/plans/2026-08-21-create-instance-bindings-design.md @@ -42,8 +42,12 @@ Same `FlattenSession` memo, so it is one template-chain walk per call. ### 3.2 Create page (CentralUI `InstanceCreate.razor` + new code-behind) +- **Superseded 2026-08-21 (`docs/plans/2026-08-21-template-picker.md`):** the Template `` was unusable once the catalogue grew past a screenful and showed no folder context at all. + - **`?templateId=` preselects.** The page takes a `TemplateId` query parameter, which is what the Templates tree's "New Instance…" navigates with; combined with the existing `?siteId=`, the Connection Bindings card below is populated on first render. An id that no longer exists leaves the field blank and shows *"Template N no longer exists — choose another."* rather than failing the page. With no templates at all, **Choose…** is disabled and the field points at the Templates page. - **Connection Bindings at creation** (`InstanceCreate`, design `docs/plans/2026-08-21-create-instance-bindings-design.md`). Once a template AND a site are chosen, the create form grows a Connection Bindings card showing the SAME module groups the Configure page shows, so one Create can yield a deployable instance instead of always landing on Configure with 100% of the rows unbound. The groups come from `IFlatteningPipeline.PreviewAsync(templateId, siteId)` — a flatten of an *unsaved* instance with no overrides and no bindings — fed through the same `BindingGroupBuilder` Configure uses. **Group headers only**: per-member editing stays on Configure. - **Bind all to** — a connection + root object, then **Prefill groups** sets the connection on every group and fills *blank* Objects only: the `(instance)` group gets the root verbatim; a module group whose template defaults already carry a shared prefix keeps it (pill: *from template*); any other module group is suggested `{root}.{groupKey}` (pill: *suggested*). An Object the operator typed is never overwritten. Provenance pills exist because a suggestion is a guess about the address space — a sibling-object layout needs correcting before Create. - **Browse…** per group (and for the root) opens the shared `NodeBrowserDialog` with `SelectableNodeClasses = {Object, Variable}` — the create page binds a module to its **container** node, which the Variable-only default could not select. Picking a leaf *under* the module still works: `CreateBindingPlanner.ObjectFromPick` strips a trailing `.{memberTail}` matching any member of that group. Enabled only for browsable protocols (OPC UA, MxGateway), the same gate Configure applies.