Class UiModalParameters
Parameters for configuring a UI modal component.
Includes title, text, alignment, buttons, and associated signal type.
Namespace: Serenity.Modal.Application.Components
Assembly: Serenity.Modal.Application.dll
Syntax
public class UiModalParameters : UiComponentParameters, IUiModalParameters, IUiComponentParameters, IComponentParameters, IFoundationSettings
Constructors
UiModalParameters()
Initializes a new instance of the UiModalParameters class with default values.
Declaration
public UiModalParameters()
UiModalParameters(string, string, string, string, string, float, UiComponentAlignmentType, IFoundationViewElementFactory, AudioPlayerPlayClip, string, IUiThemeSounds, List<IUiInteractable>, List<SerializedComponentData>)
Initializes a new instance of the UiModalParameters class.
Declaration
public UiModalParameters(string id, string guid, string signalTypeName, string title, string text, float textFontSize, UiComponentAlignmentType alignment, IFoundationViewElementFactory foundationViewElementFactory, AudioPlayerPlayClip audioPlayerPlayClip, string audioServiceId, IUiThemeSounds themeSounds, List<IUiInteractable> buttons, List<SerializedComponentData> serializedButtons)
Parameters
| Type | Name | Description |
|---|---|---|
| string | id | The unique identifier for the modal. |
| string | guid | The globally unique identifier for the modal. |
| string | signalTypeName | The assembly qualified name of the signal type associated with the modal. |
| string | title | The title of the modal. |
| string | text | The main text content of the modal. |
| float | textFontSize | The font size of the main text. |
| UiComponentAlignmentType | alignment | The alignment of the modal content. |
| IFoundationViewElementFactory | foundationViewElementFactory | Factory for creating foundation view elements. |
| AudioPlayerPlayClip | audioPlayerPlayClip | Delegate for playing audio clips. |
| string | audioServiceId | The ID of the audio service to use. |
| IUiThemeSounds | themeSounds | The theme sounds associated with the modal. |
| List<IUiInteractable> | buttons | The list of buttons in the modal. |
| List<SerializedComponentData> | serializedButtons | Serialized data for reconstructing button components. |
Fields
Alignment
Declaration
public UiComponentAlignmentType Alignment
Field Value
| Type | Description |
|---|---|
| UiComponentAlignmentType | The alignment of the modal content. |
Buttons
Declaration
public List<IUiInteractable> Buttons
Field Value
| Type | Description |
|---|---|
| List<IUiInteractable> | The list of buttons in the modal. |
SerializedButtons
Declaration
public List<SerializedComponentData> SerializedButtons
Field Value
| Type | Description |
|---|---|
| List<SerializedComponentData> | Serialized data for reconstructing button components. |
SignalTypeName
Declaration
public string SignalTypeName
Field Value
| Type | Description |
|---|---|
| string | The assembly qualified name of the signal type associated with the modal. |
Text
Declaration
public string Text
Field Value
| Type | Description |
|---|---|
| string | The main text content of the modal. |
TextFontSize
Declaration
public float TextFontSize
Field Value
| Type | Description |
|---|---|
| float | The font size of the main text. |
Title
Declaration
public string Title
Field Value
| Type | Description |
|---|---|
| string | The title of the modal. |
Methods
GetSignalInstance()
Declaration
public EventDispatcherSignal GetSignalInstance()
Returns
| Type | Description |
|---|---|
| EventDispatcherSignal | Creates an instance of the signal type specified by SignalTypeName. |