Table of Contents

Namespace Htmx.Components.Models

Classes

ActionGroup

An action item that can contain nested action items, combining individual item properties with container functionality. This class is useful for creating dropdown menus or hierarchical navigation structures.

ActionGroupConfig

Configuration class for ActionGroup initialization. This class extends ActionSetConfig with display properties and cannot be marked as internal because the base class is used as a type constraint in ActionItemsBuilder.

ActionItem

A basic implementation of an action item with label, icon, and CSS class properties. This class provides the fundamental display properties for actionable UI elements.

ActionModel

An action item with additional attributes support, primarily designed for HTMX attributes. This class extends the basic action item with a dictionary of custom attributes and active state tracking.

ActionSet

A container for grouping multiple action items without its own display properties. This class is useful for creating menus, toolbars, or navigation bars where the container itself doesn't need visual representation.

ActionSetConfig

Configuration class for ActionSet initialization. This class is used by builders to configure ActionSet instances and cannot be marked as internal because it is used as a type constraint in ActionItemsBuilder.

HtmxViewInfo

Contains information needed to render a view in an HTMX context, including out-of-band targeting details. This class encapsulates the view name, model data, and HTMX-specific rendering instructions.

InputModel<T, TProp>

Represents a strongly-typed input field for a specific property of type TProp on model type T.

InputSet

Represents a set of input fields.

ModelHandler

Abstract base class for model handlers that provide CRUD operations and UI generation. Handles the coordination between data operations and UI components for specific model types.

ModelHandler<T, TKey>

Strongly-typed model handler that provides CRUD operations and UI generation for a specific model type. Coordinates between data access, business logic, and UI presentation.

Result

Represents the result of an operation with success/error status and an optional message. This class provides a way to return both success and error states with descriptive messages, along with structured logging capabilities for error scenarios.

Result.ResultError

Represents error information that can be implicitly converted to a failed Result. This class encapsulates error messages for structured error handling.

Result<T>

Represents the result of an operation that returns a value, with optional success/error status and message. This generic result type extends the base Result class to include a typed value.

ViewPaths

Contains the default view paths used by the Htmx Components framework. This class centralizes the management of partial view paths for different component types, allowing for easy customization of the framework's rendering behavior.

Interfaces

IActionItem

Represents a visual item that can be displayed with a label, icon, and CSS styling. This interface forms the base for all actionable UI elements in the component system.

IActionSet

Represents a container for grouping multiple action items without display properties. This interface is useful for creating menus, toolbars, or navigation bars where the container itself doesn't need visual representation.

IInputModel

Represents a single input field.

IOobTargetable

Represents a model that can provide targeting information for HTMX out-of-band (OOB) updates. Models implementing this interface can specify where and how their rendered content should be placed in the DOM.

Enums

CrudFeatures

Defines the CRUD (Create, Read, Update, Delete) operations that a model handler supports. These flags determine which actions are available in the user interface and API.

InputKind

Specifies the type of input control to render. Determines the HTML input type and behavior for form fields.

ModelUI

Specifies the user interface context for model presentation. Determines which UI components and behaviors are used.

OobTargetDisposition

Specifies how content should be positioned when performing HTMX out-of-band updates. These values correspond to HTMX's OOB swap strategies for DOM manipulation.