# Blazor Floating Action Button Overview

The <a href="https://www.telerik.com/blazor-ui/floating-action-button" target="_blank">Blazor Floating Action Button</a> is a UI component that shows over the other page content and may not move during scrolling. The component can perform the most logical action expected from a user looking at a particular screen. You can configure the FloatingActionButton to display:

* A single button with a single action
* Additional related actions
* Speed dial actions

The Floating Action Button comes with built-in customization features that lets you fine-tune the [positioning and alignment](https://www.telerik.com/blazor-ui/documentation/components/floatingactionbutton/position-and-alignment) of the component, customize its [appearance](https://www.telerik.com/blazor-ui/documentation/components/floatingactionbutton/appearance), use icons, and attach click [events](https://www.telerik.com/blazor-ui/documentation/components/floatingactionbutton/events).

## Creating Blazor Floating Action Button

1. Use the `<TelerikFloatingActionButton>` tag to add the component to your razor page.
2. (optional) Customize the [appearance](https://www.telerik.com/blazor-ui/documentation/components/floatingactionbutton/appearance) of the Telerik Blazor Floating Action Button.

> caption Basic Blazor Floating Action Button

<demo metaUrl="client/floatingactionbutton/overview/example-1/" height="220"></demo>

## Position and Alignment

You can control how the Floating Action Button is positioned relative to its associated container. Read more about the [Blazor Floating Action Button positioning...](https://www.telerik.com/blazor-ui/documentation/components/floatingactionbutton/position-and-alignment)

## Events

The Blazor Floating Action Button fires events that you can handle and respond to user actions. [Read more about the Blazor Floating Action Button events...](https://www.telerik.com/blazor-ui/documentation/components/floatingactionbutton/events).

## Floating Action Button Parameters

The Blazor Floating Action Button provides various parameters that allow you to configure the component. Also check the [Floating Action Button public API](https://www.telerik.com/blazor-ui/documentation/api/telerik.blazor.components.telerikfloatingactionbutton).

<style>
    .article table {
        table-layout: auto;
        word-break: normal;
    }
</style>

| Parameter          | Type and Default Value                                   | Description                                                                                                                                                                                                                                                           |
| ------------------ | -------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `Enabled`          | `bool` <br /> (`true`)                                   | Whether the Floating Action Button is enabled.                                                                                                                                                                                                                        |
| `Id`               | `string`                                                 | The `id` attribute of the Floating Action Button.                                                                                                                                                                                                                     |
| `Icon`             | `object`                                                 | The icon rendered in the Floating Action Button. Can be set to a predefined Telerik icon or a custom one.                                                                                                                                                             |
| `IconVariant`      | `string`                                                 | Selects the [SVG icon variant](https://www.telerik.com/blazor-ui/documentation/common-features/icons#use-svg-icon-variants).                                                                                                                                          |
| `Title`            | `string`                                                 | The `title` attribute of the Floating Action Button.                                                                                                                                                                                                                  |
| `PositionMode`     | `FloatingActionButtonPositionMode` enum <br /> (`Fixed`) | The position of the Floating Action Button relative to the container.                                                                                                                                                                                                 |
| `HorizontalAlign`  | `FloatingActionButtonHorizontalAlign` <br /> (`End`)     | Determines if the left or the right side of the Floating Action Button will touch its parent container. [Read more about Floating Action Button positioning.](https://www.telerik.com/blazor-ui/documentation/components/floatingactionbutton/position-and-alignment) |
| `VerticalAlign`    | `FloatingActionButtonVerticalAlign` <br /> (`Bottom`)    | Determines if the Floating Action Button will touch the parent container with its top or bottom side.                                                                                                                                                                 |
| `HorizontalOffset` | `string` <br /> (`16px`)                                 | The horizontal offset value added to the button position, creating a blank space between the button and the parent.                                                                                                                                                   |
| `VerticalOffset`   | `string` <br /> (`16px`)                                 | The vertical offset value added to the button position, creating a blank space between the button and the parent.                                                                                                                                                     |

### Styling and Appearance

The following parameters enable you to customize the appearance of the Blazor Floating Action Button:

| Parameter    | Type                          | Description                                                                                                                                                                                                                                                                   |
| ------------ | ----------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `Class`      | `string`                      | Defines the custom CSS class rendered on `<button class="k-fab">`, which is the main wrapping element of the Floating Action Button component. Use it for [styling customizations](https://www.telerik.com/blazor-ui/documentation/styling-and-themes/override-theme-styles). |
| `Rounded`    | `string` <br /> `"full"`      | Defines how rounded the borders of the Floating Action Button are. Use predefined value constants from the static class `Telerik.Blazor.ThemeConstants.Button.Rounded`.                                                                                                       |
| `Size`       | `string` <br /> (`"md"`)      | Sets the size of the Floating Action Button. Set it to a predefined value constant from the static class `Telerik.Blazor.ThemeConstants.Button.Size`.                                                                                                                         |
| `ThemeColor` | `string` <br /> (`"primary"`) | Adjusts the background color of the Floating Action Button. Use predefined values from the static class `Telerik.Blazor.ThemeConstants.Button.ThemeColor`.                                                                                                                    |

## Next Steps

* [Explore the Floating Action Button Positioning and Alignment Settings](https://www.telerik.com/blazor-ui/documentation/components/floatingactionbutton/position-and-alignment)
* [Customize the Floating Action Button Appearance](https://www.telerik.com/blazor-ui/documentation/components/floatingactionbutton/appearance)

## See Also

* [Live Demo: Floating Action Button](https://demos.telerik.com/blazor-ui/floatingactionbutton/overview)
* [Floating Action Button Events](https://www.telerik.com/blazor-ui/documentation/components/floatingactionbutton/events)
* [Floating Action Button API Reference](https://www.telerik.com/blazor-ui/documentation/api/telerik.blazor.components.telerikfloatingactionbutton)
