HtmlForgeX

API Reference

Class

SmartWizard

Namespace HtmlForgeX
Assembly HtmlForgeX
Base Element

SmartWizard component for creating step-by-step wizards with validation support.

Inheritance

Constructors

public SmartWizard() #

Initializes a new instance of the SmartWizard class.

Methods

AddStep 3 overloads
public SmartWizard AddStep(String title, Action<SmartWizardStep> configure = null) #
Returns: SmartWizard

Adds a new step to the wizard.

Parameters

title System.String requiredposition: 0
The step title.
configure System.Action{HtmlForgeX.SmartWizardStep} = null optionalposition: 1
Optional configuration action for the step.

Returns

The current instance for method chaining.

public SmartWizard AddStep(String title, TablerIconType icon, String subtitle = null, Action<SmartWizardStep> configure = null) #
Returns: SmartWizard

Adds a new step with icon and subtitle.

Parameters

title System.String requiredposition: 0
The step title.
icon HtmlForgeX.TablerIconType requiredposition: 1
The step icon.
subtitle System.String = null optionalposition: 2
The step subtitle.
configure System.Action{HtmlForgeX.SmartWizardStep} = null optionalposition: 3
Optional configuration action for the step.

Returns

The current instance for method chaining.

public SmartWizard AddStep(String title, TablerIconType icon, Action<SmartWizardStep> configure) #
Returns: SmartWizard

Adds a new step with icon and configuration.

Parameters

title System.String requiredposition: 0
The step title.
icon HtmlForgeX.TablerIconType requiredposition: 1
The step icon.
configure System.Action{HtmlForgeX.SmartWizardStep} requiredposition: 2
Configuration action for the step.

Returns

The current instance for method chaining.

public SmartWizard AddStepValidation(Int32 stepIndex, String validationFunction) #
Returns: SmartWizard

Adds a validation function for a specific step.

Parameters

stepIndex System.Int32 requiredposition: 0
The step index.
validationFunction System.String requiredposition: 1
The JavaScript validation function.

Returns

The current instance for method chaining.

public SmartWizard AsVertical() #
Returns: SmartWizard
EditorBrowsable(2)

Sets the wizard orientation to vertical.

Returns

The current instance for method chaining.

public SmartWizard AutoAdjustHeight(Boolean enabled = true) #
Returns: SmartWizard
EditorBrowsable(2)

Controls how the wizard decides the height of the step content area.

Parameters

enabled System.Boolean = true optionalposition: 0
When true (vendor mode), SmartWizard sets a fixed height on the content wrapper based on the measured height of the selected step. This enables smooth animated transitions between steps, but can lead to clipping or extra whitespace if the inner content changes size after the measurement (for example, nested tabs toggling, DataTables auto-sizing, accordions expanding, or images/fonts loading). When false (HFX natural mode), the content wrapper is allowed to size naturally (height:auto) and HtmlForgeX scripts (hfx-smartwizard.js, hfx-visibility.js) keep layout correct by recalculating after tab/collapse events and on resize. This is recommended for Guidance-like flows with nested tabs, grids, charts, and other dynamic content.

Returns

The current instance for method chaining.

public SmartWizard BackButtonSupport(Boolean enabled = true) #
Returns: SmartWizard
EditorBrowsable(2)

Enables or disables browser back button support.

Parameters

enabled System.Boolean = true optionalposition: 0
Whether to enable back button support.

Returns

The current instance for method chaining.

BuildInitializationScript() #

Builds the SmartWizard initialization script.

public SmartWizard ConfigureKeyboard(Action<SmartWizardKeyboard> configure) #
Returns: SmartWizard

Configures custom keyboard shortcuts.

Parameters

configure System.Action{HtmlForgeX.SmartWizardKeyboard} requiredposition: 0
Configuration action for keyboard settings.

Returns

The current instance for method chaining.

public SmartWizard ConfigureNavigation(Action<SmartWizardAnchor> configure) #
Returns: SmartWizard
EditorBrowsable(2)

Configures anchor navigation behavior.

Parameters

configure System.Action{HtmlForgeX.SmartWizardAnchor} requiredposition: 0
Configuration action for anchor settings.

Returns

The current instance for method chaining.

public SmartWizard EnableNavigation(Boolean enabled = true, Boolean alwaysEnabled = false) #
Returns: SmartWizard
EditorBrowsable(2)

Enables or disables step navigation.

Parameters

enabled System.Boolean = true optionalposition: 0
Whether to enable step navigation.
alwaysEnabled System.Boolean = false optionalposition: 1
Whether navigation is always enabled.

Returns

The current instance for method chaining.

public SmartWizard EnableUrlHash(Boolean enabled = true) #
Returns: SmartWizard
EditorBrowsable(2)

Enables or disables URL hash navigation.

Parameters

enabled System.Boolean = true optionalposition: 0
Whether to enable URL hash navigation.

Returns

The current instance for method chaining.

public String GoToNext() #
Returns: String

Generates JavaScript code to navigate to the next step.

Returns

JavaScript method call string.

public String GoToPrevious() #
Returns: String

Generates JavaScript code to navigate to the previous step.

Returns

JavaScript method call string.

public String GoToStep(Int32 index, Boolean force = false) #
Returns: String

Generates JavaScript code to navigate to a specific step.

Parameters

index System.Int32 requiredposition: 0
The step index.
force System.Boolean = false optionalposition: 1
Whether to force navigation.

Returns

JavaScript method call string.

public SmartWizard Justified(Boolean justified = true) #
Returns: SmartWizard
EditorBrowsable(2)

Sets whether navigation menu should be justified.

Parameters

justified System.Boolean = true optionalposition: 0
Whether to justify navigation menu.

Returns

The current instance for method chaining.

public SmartWizard OnInitialized(String handler) #
Returns: SmartWizard

Adds an event handler for the initialized event.

Parameters

handler System.String requiredposition: 0
The JavaScript event handler code.

Returns

The current instance for method chaining.

public SmartWizard OnLeaveStep(String handler) #
Returns: SmartWizard

Adds an event handler for the leaveStep event.

Parameters

handler System.String requiredposition: 0
The JavaScript event handler code.

Returns

The current instance for method chaining.

public SmartWizard OnLoaded(String handler) #
Returns: SmartWizard

Adds an event handler for the loaded event.

Parameters

handler System.String requiredposition: 0
The JavaScript event handler code.

Returns

The current instance for method chaining.

public SmartWizard OnShowStep(String handler) #
Returns: SmartWizard

Adds an event handler for the showStep event.

Parameters

handler System.String requiredposition: 0
The JavaScript event handler code.

Returns

The current instance for method chaining.

RegisterLibraries() #

Registers the required libraries for SmartWizard.

public String Reset() #
Returns: String

Generates JavaScript code to reset the wizard.

Returns

JavaScript method call string.

public String SetState(Int32[] stepIndexes, SmartWizardStepState state) #
Returns: String

Generates JavaScript code to set step state.

Parameters

stepIndexes System.Int32[] requiredposition: 0
The step indexes.
state HtmlForgeX.SmartWizardStepState requiredposition: 1
The state to set.

Returns

JavaScript method call string.

public SmartWizard Settings(Action<SmartWizardSettings> configure) #
Returns: SmartWizard

Groups less-common options under a single fluent entry point to keep IntelliSense lean.

Parameters

configure System.Action{HtmlForgeX.SmartWizardSettings} requiredposition: 0
public override String ToString() #
Returns: String

Builds the SmartWizard HTML markup.

UpdateStepStates() #

Sets step states based on the current step configuration.

public SmartWizard WithButtonText(String nextText = "Next", String previousText = "Previous") #
Returns: SmartWizard

Sets the button text for the wizard.

Parameters

nextText System.String = "Next" optionalposition: 0
Text for the Next button.
previousText System.String = "Previous" optionalposition: 1
Text for the Previous button.

Returns

The current instance for method chaining.

public SmartWizard WithContainerClass(String cssClass) #
Returns: SmartWizard
EditorBrowsable(2)

Sets custom CSS classes for the container.

Parameters

cssClass System.String requiredposition: 0
The CSS class names.

Returns

The current instance for method chaining.

public SmartWizard WithContentClass(String cssClass) #
Returns: SmartWizard
EditorBrowsable(2)

Sets custom CSS classes for the content container.

Parameters

cssClass System.String requiredposition: 0
The CSS class names.

Returns

The current instance for method chaining.

public SmartWizard WithKeyboardNavigation(Boolean enabled = true) #
Returns: SmartWizard
EditorBrowsable(2)

Configures keyboard navigation.

Parameters

enabled System.Boolean = true optionalposition: 0
Whether to enable keyboard navigation.

Returns

The current instance for method chaining.

public SmartWizard WithNavClass(String cssClass) #
Returns: SmartWizard
EditorBrowsable(2)

Sets custom CSS classes for the nav container.

Parameters

cssClass System.String requiredposition: 0
The CSS class names.

Returns

The current instance for method chaining.

public SmartWizard WithSelectedStep(Int32 index) #
Returns: SmartWizard
EditorBrowsable(2)

Sets the initially selected step.

Parameters

index System.Int32 requiredposition: 0
The zero-based index of the step to select.

Returns

The current instance for method chaining.

public SmartWizard WithSurface(SmartWizardSurfaceStyle style) #
Returns: SmartWizard
EditorBrowsable(2)

Applies a reusable HtmlForgeX surface style around the SmartWizard frame.

Parameters

style HtmlForgeX.SmartWizardSurfaceStyle requiredposition: 0
The surface style to apply.

Returns

The current instance for method chaining.

public SmartWizard WithTheme(SmartWizardTheme theme) #
Returns: SmartWizard
EditorBrowsable(2)

Sets the theme for the SmartWizard.

Parameters

theme HtmlForgeX.SmartWizardTheme requiredposition: 0
The theme to apply.

Returns

The current instance for method chaining.

public SmartWizard WithToolbar(SmartWizardToolbarPosition position) #
Returns: SmartWizard
EditorBrowsable(2)

Configures the toolbar position.

Parameters

position HtmlForgeX.SmartWizardToolbarPosition requiredposition: 0
The toolbar position.

Returns

The current instance for method chaining.

public SmartWizard WithToolbarButtons(Boolean showNext = true, Boolean showPrevious = true) #
Returns: SmartWizard
EditorBrowsable(2)

Configures toolbar buttons.

Parameters

showNext System.Boolean = true optionalposition: 0
Whether to show Next button.
showPrevious System.Boolean = true optionalposition: 1
Whether to show Previous button.

Returns

The current instance for method chaining.

WithToolbarContent 2 overloads
public SmartWizard WithToolbarContent(Element element) #
Returns: SmartWizard

Adds extra HTML content to the toolbar.

Parameters

html System.String requiredposition: 0
The HTML content to add.

Returns

The current instance for method chaining.

WithToolbarContent(HtmlForgeX.Element element) #

Adds extra toolbar content using a typed element (no raw HTML string required). The element is attached to the logical tree so libraries can be registered correctly.

Parameters

element HtmlForgeX.Element required
public SmartWizard WithTransition(SmartTabAnimation animation, Int32 speed = 400, String easing = null) #
Returns: SmartWizard
EditorBrowsable(2)

Configures the transition animation.

Parameters

animation HtmlForgeX.SmartTabAnimation requiredposition: 0
The animation type.
speed System.Int32 = 400 optionalposition: 1
The animation speed in milliseconds.
easing System.String = null optionalposition: 2
The easing function.

Returns

The current instance for method chaining.

Properties

public String Id { get; } #

Gets the unique identifier for this SmartWizard instance.

public List<SmartWizardStep> Steps { get; } #

Gets the list of wizard steps.

public SmartWizardOptions Options { get; } #

Gets the configuration options.

public Boolean IsVertical { get; set; } #

Gets or sets the orientation (horizontal or vertical).

public String ContainerClass { get; set; } #

Gets or sets custom CSS classes for the container.

public String NavClass { get; set; } #

Gets or sets custom CSS classes for the nav container.

public String ContentClass { get; set; } #

Gets or sets custom CSS classes for the content container.

ContentPaddingY #

Optional vertical padding for the content area (maps to Bootstrap py-*).

Fields

_eventHandlers #

Event handlers for SmartWizard events.

_validationFunctions #

Custom validation functions for steps.