Table of Contents

Interface IBrowserViewportObserver

Namespace
MudBlazor
Assembly
MudBlazor.dll

Represents an observer for browser viewport updates.

public interface IBrowserViewportObserver
Extension Methods

Properties

Id

Gets the unique identifier of the observer.

Guid Id { get; }

Property Value

Guid

ResizeOptions

Gets the resize options for the observer. When set to null, the global options provided during AddMudServices / AddMudBlazorResizeListener will be used. When specific options are provided, they will be used to observe the changes.

ResizeOptions? ResizeOptions { get; }

Property Value

ResizeOptions

Remarks

After you set the options, modifying the instance won't have any effect, including re-subscription, as C# and JS side doesn't support this, you need to UnsubscribeAsync(IBrowserViewportObserver) and subscribe again.

Methods

NotifyBrowserViewportChangeAsync(BrowserViewportEventArgs)

Notifies the observer of browser size and breakpoint change.

Task NotifyBrowserViewportChangeAsync(BrowserViewportEventArgs browserViewportEventArgs)

Parameters

browserViewportEventArgs BrowserViewportEventArgs

The event arguments containing information about the BrowserWindowSize and Breakpoint change.

Returns

Task

A task representing the asynchronous notification operation.