menu

Blazor

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class DropDownMenuAnimationSettings - Blazor API Reference | Syncfusion

    Show / Hide Table of Contents

    Class DropDownMenuAnimationSettings

    Configures the animation settings for the dropdown menu in a SfDropDownButton.

    Inheritance
    System.Object
    DropDownMenuAnimationSettings
    Namespace: Syncfusion.Blazor.SplitButtons
    Assembly: Syncfusion.Blazor.dll
    Syntax
    public class DropDownMenuAnimationSettings : OwningComponentBase
    Remarks

    The DropDownMenuAnimationSettings class provides options to customize the transitional effects of the dropdown menu, including animation duration, easing, and visual effects.

    Examples

    The following example demonstrates how to apply a zoom-in animation effect to the SfDropDownButton popup.

    <SfDropDownButton Content="Profile">
        <DropDownMenuItems>
            <DropDownMenuItem Text="Log out"></DropDownMenuItem>
        </DropDownMenuItems>
        <DropDownMenuAnimationSettings Effect="DropDownMenuAnimationEffect.ZoomIn" />
    </SfDropDownButton>

    Constructors

    DropDownMenuAnimationSettings()

    Declaration
    public DropDownMenuAnimationSettings()

    Properties

    Duration

    Gets or sets the duration, in milliseconds, for the dropdown menu animation.

    Declaration
    public double Duration { get; set; }
    Property Value
    Type Description
    System.Double

    A double value that specifies the animation duration. The default is 400.

    Remarks

    Use this property to adjust the speed of the animation.

    • A lower value (e.g., 200) results in a faster animation.
    • A higher value (e.g., 800) results in a slower animation.

    Easing

    Gets or sets the easing effect for the dropdown menu animation.

    Declaration
    public string Easing { get; set; }
    Property Value
    Type Description
    System.String

    A string that specifies the easing effect. The default value is "ease".

    Remarks

    Easing functions specify the rate of change of a parameter over time. Examples of supported values include:

    • "ease": A transition effect with a slow start, fast acceleration, and slow end.
    • "ease-in": A transition effect with a slow start.
    • "ease-out": A transition effect with a slow end.
    • "linear": A transition effect with the same speed from start to end.

    Effect

    Gets or sets the animation effect for the dropdown menu's appearance and disappearance.

    Declaration
    public DropDownMenuAnimationEffect Effect { get; set; }
    Property Value
    Type Description
    DropDownMenuAnimationEffect

    A DropDownMenuAnimationEffect enum that specifies the visual effect. The default is None.

    Remarks

    Available effects include:

    • None: No animation effect.
    • SlideDown: The dropdown menu slides down into view.
    • ZoomIn: The dropdown menu zooms in to appear.
    • FadeIn: The dropdown menu fades in.
    This property allows for a more visually engaging user experience.

    Methods

    Dispose(Boolean)

    Releases the resources used by the component.

    Declaration
    protected override void Dispose(bool disposing)
    Parameters
    Type Name Description
    System.Boolean disposing

    A bool that indicates whether the component is being disposed.

    OnInitializedAsync()

    Initializes the component and updates the parent's animation settings.

    Declaration
    protected override Task OnInitializedAsync()
    Returns
    Type Description
    System.Threading.Tasks.Task

    A System.Threading.Tasks.Task that represents the asynchronous initialization process.

    OnParametersSetAsync()

    Updates the parent's animation settings when parameters change.

    Declaration
    protected override Task OnParametersSetAsync()
    Returns
    Type Description
    System.Threading.Tasks.Task

    A System.Threading.Tasks.Task that represents the asynchronous parameter set process.

    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved