layout: default title: ActionButton parent: Core Classes —

dymaptic.GeoBlazor.Core

dymaptic.GeoBlazor.Core.Components

ActionButton Class

A customizable button that performs a specific action(s) used in widgets such as the Popup, LayerList, and
BasemapLayerList.

public class ActionButton : dymaptic.GeoBlazor.Core.Components.ActionBase

Inheritance System.Object 🡒 Microsoft.AspNetCore.Components.ComponentBase 🡒 MapComponent 🡒 ActionBase 🡒 ActionButton

Constructors

ActionButton() Constructor

Parameterless constructor for use as a razor component.

public ActionButton();

ActionButton(string, string, string, Func, string, Nullable, Nullable, Nullable) Constructor

Constructor for use in code.

public ActionButton(string? title=null, string? image=null, string? id=null, System.Func<System.Threading.Tasks.Task>? callbackFunction=null, string? className=null, System.Nullable<bool> active=null, System.Nullable<bool> disabled=null, System.Nullable<bool> visible=null);

Parameters

title System.String

The title of the action.

image System.String

The URL to an image that will be used to represent the action. This property will be used as a background image

id System.String

The name of the ID assigned to this action.

callbackFunction System.Func<System.Threading.Tasks.Task>

The action function to perform on click.

className System.String

This adds a CSS class to the ActionButton’s node.

active System.Nullable<System.Boolean>

Set this property to true to display a spinner icon.

disabled System.Nullable<System.Boolean>

Indicates whether this action is disabled.

visible System.Nullable<System.Boolean>

Indicates if the action is visible.

Properties

ActionButton.ClassName Property

This adds a CSS class to the ActionButton’s node.

public string? ClassName { get; set; }

Property Value

System.String

ActionButton.Image Property

The URL to an image that will be used to represent the action. This property will be used as a background image for
the node. It may be used in conjunction with the className property or by itself. If neither image nor className
are specified, a default icon will display

public string? Image { get; set; }

Property Value

System.String

ActionButton.Type Property

Specifies the type of action. Choose between “button” or “toggle”.

public override string Type { get; }

Property Value

System.String