FluxFlow.Components.Designer 5.0.0

There is a newer prerelease version of this package available.
See the version list below for details.
dotnet add package FluxFlow.Components.Designer --version 5.0.0
                    
NuGet\Install-Package FluxFlow.Components.Designer -Version 5.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="FluxFlow.Components.Designer" Version="5.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="FluxFlow.Components.Designer" Version="5.0.0" />
                    
Directory.Packages.props
<PackageReference Include="FluxFlow.Components.Designer" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add FluxFlow.Components.Designer --version 5.0.0
                    
#r "nuget: FluxFlow.Components.Designer, 5.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package FluxFlow.Components.Designer@5.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=FluxFlow.Components.Designer&version=5.0.0
                    
Install as a Cake Addin
#tool nuget:?package=FluxFlow.Components.Designer&version=5.0.0
                    
Install as a Cake Tool

FluxFlow.Components.Designer

Reusable component presentation metadata and canonical application-editing contracts for FluxFlow. The package depends on FluxFlow.Composition, but not on FluxFlow.Engine or a rendering framework.

Registration

Use AddFluxFlowComponents() when a tool needs component catalogs without hosting an application. Family extensions target the returned FluxFlowRegistrationBuilder:

var services = new ServiceCollection();

services
    .AddFluxFlowComponents()
    .AddSources()
    .AddMapping()
    .AddTimers();

using var provider = services.BuildServiceProvider();
var runtimeCatalog = provider.GetRequiredService<ComponentCatalog>();
var designCatalog = provider.GetRequiredService<ComponentDesignMetadataCatalog>();

ComponentCatalog remains owned by Composition. Every designed AddComponent(...) registration automatically contributes to the immutable ComponentDesignMetadataCatalog; there is no terminal catalog-registration call and no second component registry. A chain containing only AddRuntimeComponent(...) registers only the runtime catalog.

Flat Designed Components

AddComponent(...) creates the runtime descriptor and presentation metadata from one authoritative, flat callback. The type appears once, the callback runs immediately, and no Build, Commit, nested builder, reflection, or scanning is involved.

There is no parallel metadata builder or option/resource metadata factory. Registration authors use this callback; standalone tooling constructs the immutable metadata records directly and passes them to ComponentDesignMetadataCatalog.

builder.AddComponent("sample.transform", component =>
{
    component.UseFactory(CreateTransformAsync);
    component.UseProcessing(CompositionProcessingCapabilities.Sequential);

    component.WithDisplay(
        displayName: "Sample Transform",
        category: "Samples",
        summary: "Transforms a sample value.",
        iconKey: "transform",
        preferredNodeName: "transform",
        suggestedEditorWidth: 420);

    component.AddInput<JsonElement>(
        "Input",
        displayName: "Input",
        group: "Values",
        order: 0,
        summary: "Value to transform.",
        isPrimary: true);

    component.AddOutput<JsonElement>(
        "Output",
        displayName: "Output",
        group: "Results",
        order: 0,
        summary: "Transformed value.",
        isPrimary: true);

    component.AddOption<string>(
        "expression",
        kind: OptionValueKind.Expression,
        displayName: "Expression",
        helperText: "Expression evaluated for each input.",
        isRequired: true,
        section: "Mapping",
        editor: OptionDesignMetadataAttributeValues.Expression);

    component.AddOption<string>(
        "mode",
        kind: OptionValueKind.Enum,
        displayName: "Mode",
        defaultValue: "strict");
    component.AddOptionChoice("mode", "strict", displayName: "Strict");
    component.AddOptionChoice("mode", "relaxed", displayName: "Relaxed");

    component.AddResource<IExpressionEngine>(
        "engine",
        displayName: "Engine",
        order: 0,
        summary: "Host-owned expression engine.",
        isRequired: true,
        ownership: ResourceDesignMetadataAttributeValues.HostOwned,
        pickerKind: ResourceDesignMetadataAttributeValues.ExpressionEngine);

    component.SetOptionAttribute("expression", "relatedResource", "engine");
    component.SetPortAttribute("Input", PortDirection.Input, "accepts", "json");
    component.AddAttribute("shape", "transform");
});

Root-level methods cover display information, ports, options, resources, choices, and attributes. References to unknown options, ports, or resources fail during registration. Duplicate names, invalid ranges, missing factories, reserved Events outputs, and invalid metadata also fail immediately.

Equivalent repeated built-in family registration is idempotent. A semantically different runtime descriptor or design registration for an existing type throws a clear conflict exception; registration never uses last-write-wins behavior.

Runtime-only components belong to FluxFlow.Composition and use the distinct AddRuntimeComponent(...) API, so Composition-only consumers do not need this package.

Metadata Contracts

  • ComponentDesignMetadata describes display name, category, summary, icon, preferred node name, suggested width, processing capabilities, options, resources, ports, and attributes.
  • OptionDesignMetadata describes value kind, default, requiredness, helper text, numeric/duration range, choices, and editor attributes.
  • ResourceDesignMetadata describes a host-owned resource slot, order, value type hint, requiredness, summary, and picker attributes.
  • PortDesignMetadata describes direction, display name, grouping, order, message/value types, cardinality, primary status, and attributes.
  • ComponentDesignMetadataCatalog is a read-only, ordered snapshot. Its public constructor accepts metadata directly for standalone tooling; normal DI registration builds it automatically from designed components.

ComponentDesignMetadataValidator validates identifiers, null collections, duplicates, option kinds/defaults/ranges/choices, port directions and primary ports, resource/port ordering, and attributes. Designed registration adds the canonical processing hints and traced Events output, validates the complete metadata, and snapshots nested collections before changing DI. Direct catalog construction applies the same finalization, so later source mutations cannot change the catalog.

Option And Resource Hints

Option kinds are text, number, boolean, enum, multiline text, JSON, expression, duration, and secret. Enum options require choices. Min and Max apply to number and duration options.

Option attributes describe sections, importance, editor kind, syntax, and related resources. Resource attributes describe ownership, picker kind, key patterns, related options, and conditional requiredness. These are neutral host hints: the host still chooses controls, supplies keyed resources, owns secrets, and controls service lifetimes.

ComponentResourcePickerHints.Create(...) returns an ordered neutral view of host-owned picker hints. It does not enumerate, resolve, create, validate, or dispose host resources.

Canonical Application Persistence

DesignerApplicationPersistence loads and saves the same flat ApplicationDefinition used by Composition. It delegates JSON shape, address resolution, and link grammar to Composition rather than maintaining a second schema or parser.

var persistence = new DesignerApplicationPersistence(componentCatalog, metadataCatalog);
var loaded = persistence.Load(json);

var link = DesignerApplicationLink.Create(
    ApplicationAddress.WorkflowPort("Orders", "Read", "Output"),
    ApplicationAddress.WorkflowPort("Orders", "Validate", "Input"));

var edited = loaded.Document with
{
    Links = [.. loaded.Document.Links, link]
};

var savedJson = persistence.Serialize(edited, writeIndented: true);

Loads require exact canonical component and resource identities and return structured diagnostics for unknown values. Malformed component properties stay raw and round-trip unchanged. Conditional link validation can use an explicitly configured ApplicationLinkCompiler; there is no service discovery fallback.

Package Extensions

Component packages expose one normal extension over FluxFlowRegistrationBuilder and register every designed component with AddComponent(...):

public static FluxFlowRegistrationBuilder AddSampleTransforms(
    this FluxFlowRegistrationBuilder builder)
    => builder.AddComponent("sample.transform", component =>
    {
        component.UseFactory(CreateTransformAsync);
        component.WithDisplay(displayName: "Sample Transform", category: "Samples");
        component.AddInput<JsonElement>("Input", displayName: "Input");
        component.AddOutput<JsonElement>("Output", displayName: "Output");
    });

Packages remain explicit and Engine-independent. The Designer package does not execute workflows, own resources, render UI, scan assemblies, or provide global registries.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (20)

Showing the top 5 NuGet packages that depend on FluxFlow.Components.Designer:

Package Downloads
FluxFlow.Components.Mqtt.Composition

Canonical FluxFlow Composition resources and nodes for provider-neutral MQTT client control, publication, subscriptions, and client events.

FluxFlow.Components.Serialization.Composition

FluxFlow.Composition registration and Designer metadata for explicit FlowContent, JSON, text, and Base64 conversions.

FluxFlow.Components.Sources.Composition

Typed generated and sequence source registration and Designer metadata over host-owned clocks.

FluxFlow.Components.FileSystem.Composition

FluxFlow.Composition registration and Designer metadata for typed file-system transforms and sources over host-owned keyed clocks.

FluxFlow.Components.Routing.Composition

Typed JSON routing registration and Designer metadata over host-owned selectors and clocks.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
7.0.0-rc.1 227 9/5/2026
6.0.0-rc.1 299 8/9/2026
5.0.0 669 8/3/2026
2.17.1 133 7/3/2026
2.17.0 565 7/2/2026
2.16.0 623 7/2/2026
1.0.1 1,974 6/5/2026
1.0.0 265 6/4/2026
0.1.0-alpha.1 77 6/3/2026

Uses one flat designed-component registration path with automatic immutable catalogs and registration-time metadata finalization; removes competing metadata builders, factories, public declaration, mutable catalog, terminal registration, provider, fallback-resolution, and production friend surfaces.