logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Class UnityUiThemeComponents

    Unity-specific implementation of UI theme components configuration.
    Contains GameObject prefab templates for all UI component types used in the Serenity Unity UI system.
    Implements IUiThemeComponents interface to provide foundation-agnostic access while maintaining Unity-specific functionality.

    Inheritance
    object
    UnityUiThemeComponents
    Implements
    IUiThemeComponents
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    Namespace: Serenity.Ui.Infrastructure.Entities
    Assembly: Serenity.UnityUi.Infrastructure.dll
    Syntax
    public class UnityUiThemeComponents : IUiThemeComponents

    Constructors

    UnityUiThemeComponents()

    Declaration
    public UnityUiThemeComponents()

    Fields

    CascadeViewTemplate

    Declaration
    public GameObject CascadeViewTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for a cascade-menu panel (one navigable column/level).
    Carries a UnityCascadePanel with header + options-container slots; the cascade renderer instantiates one per column and fills it with the theme's submittable option components, so the cascade matches the active theme instead of being drawn procedurally. Optional (the cascade falls back to a procedural panel when unset).

    DropdownTemplate

    Declaration
    public GameObject DropdownTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for dropdown selection UI components.
    Used to instantiate dropdown menus for option selection with expandable lists.

    HudElementTemplate

    Declaration
    public GameObject HudElementTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for one HUD element's text, so a HUD picks up the theme's font and styling instead of being drawn bare. Must contain a TMP_Text somewhere in its hierarchy. Optional: the HUD falls back to the shared widget label and then to a plain text object, so it still renders on a theme that predates this slot.

    HudStyle

    Declaration
    public UnityUiThemeHudStyle HudStyle
    Field Value
    Type Description
    UnityUiThemeHudStyle

    The theme's HUD visual language: bar chrome, pip sprites, sizes and tints shared by every HUD element, so a HUD inherits the theme's look instead of each element inventing one.

    InputTemplate

    Declaration
    public GameObject InputTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for text input UI components.
    Used to instantiate input fields for text entry and editing functionality.

    LeaderboardTemplate

    Declaration
    public GameObject LeaderboardTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for a leaderboard panel (rankings display).
    Carries a UnityLeaderboardPanel with the entry-row and header slots the leaderboard renderer fills with ranked entries, so the leaderboard matches the active theme instead of being drawn procedurally. Optional (unset falls back to whatever the leaderboard view does without a theme).

    LoadingProgressTemplate

    Declaration
    public GameObject LoadingProgressTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for the gameplay loading-progress bar.
    A dedicated (typically non-interactive) variant of the slideable template used by the loading overlay so the progress bar does not inherit hover/selection behavior.

    ModalTemplate

    Declaration
    public GameObject ModalTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for modal dialog UI components.
    Used to instantiate popup dialogs and overlay windows for user interaction.

    PrimaryInputPromptTemplate

    Declaration
    public GameObject PrimaryInputPromptTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for primary input prompt UI components.
    Used to instantiate device detection prompts for initial player input assignment.

    SelectableTemplate

    Declaration
    public GameObject SelectableTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for selectable option UI components.
    Used to instantiate menu items and selectable elements with navigation support.

    SlideableTemplate

    Declaration
    public GameObject SlideableTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for slider/range UI components.
    Used to instantiate slider controls for numeric value selection within defined ranges.

    SubmittableTemplate

    Declaration
    public GameObject SubmittableTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for submit button UI components.
    Used to instantiate action buttons for form submission and confirmation operations.

    TitleTemplate

    Declaration
    public GameObject TitleTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for title UI components.
    Used to instantiate title elements for menu and section headings.

    ToastTemplate

    Declaration
    public GameObject ToastTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for toast (transient notification) UI components.
    Used by UnityToastComponent as the default visual when no per-component prefab is assigned, so toasts inherit the active theme's look rather than being configured per scene.

    ToggleableTemplate

    Declaration
    public GameObject ToggleableTemplate
    Field Value
    Type Description
    GameObject

    GameObject prefab template for toggle/checkbox UI components.
    Used to instantiate boolean option controls for on/off and yes/no selections.

    Methods

    ToString()

    Provides a comprehensive string representation of all configured component templates.
    Lists all template prefab assignments for debugging and validation purposes.

    Declaration
    public override string ToString()
    Returns
    Type Description
    string

    Formatted string containing all template prefab information

    Overrides
    object.ToString()

    Implements

    IUiThemeComponents
    In this article
    © 2026 Serenity. All Rights Reserved