FabConfiguration class abstract

Configuration for the floating action button (FAB) that opens the chat.

Controls the appearance and behavior of the button that users click to open the chatbot interface.

Available extensions
Annotations
  • @freezed

Constructors

FabConfiguration({String? icon, double? iconSize, String? iconColor, String? backgroundColor, double? buttonSize, double? borderRadius, bool? useAvatarAsIcon})
const
factory
FabConfiguration.fromJson(Map<String, Object?> json)
factory

Properties

backgroundColor String?
Background color of the FAB in hex format.
no setterinherited
borderRadius double?
Border radius for rounded corners in logical pixels.
no setterinherited
buttonSize double?
Size of the entire FAB button in logical pixels.
no setterinherited
copyWith → $FabConfigurationCopyWith<FabConfiguration>
Create a copy of FabConfiguration with the given fields replaced by the non-null parameter values.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
icon String?
Icon name for the FAB button (e.g., 'chat_bubble').
no setterinherited
iconColor String?
Color of the icon in hex format.
no setterinherited
iconSize double?
Size of the icon inside the FAB in logical pixels.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
useAvatarAsIcon bool?
Whether to use the bot's avatar image as the FAB icon.
no setterinherited

Methods

map<TResult extends Object?>(TResult $default(_FabConfiguration value)) → TResult

Available on FabConfiguration, provided by the FabConfigurationPatterns extension

A switch-like method, using callbacks.
mapOrNull<TResult extends Object?>(TResult? $default(_FabConfiguration value)?) → TResult?

Available on FabConfiguration, provided by the FabConfigurationPatterns extension

A variant of map that fallback to returning null.
maybeMap<TResult extends Object?>(TResult $default(_FabConfiguration value)?, {required TResult orElse()}) → TResult

Available on FabConfiguration, provided by the FabConfigurationPatterns extension

A variant of map that fallback to returning orElse.
maybeWhen<TResult extends Object?>(TResult $default(String? icon, double? iconSize, String? iconColor, String? backgroundColor, double? buttonSize, double? borderRadius, bool? useAvatarAsIcon)?, {required TResult orElse()}) → TResult

Available on FabConfiguration, provided by the FabConfigurationPatterns extension

A variant of when that fallback to an orElse callback.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Serializes this FabConfiguration to a JSON map.
inherited
toString() String
A string representation of this object.
inherited
when<TResult extends Object?>(TResult $default(String? icon, double? iconSize, String? iconColor, String? backgroundColor, double? buttonSize, double? borderRadius, bool? useAvatarAsIcon)) → TResult

Available on FabConfiguration, provided by the FabConfigurationPatterns extension

A switch-like method, using callbacks.
whenOrNull<TResult extends Object?>(TResult? $default(String? icon, double? iconSize, String? iconColor, String? backgroundColor, double? buttonSize, double? borderRadius, bool? useAvatarAsIcon)?) → TResult?

Available on FabConfiguration, provided by the FabConfigurationPatterns extension

A variant of when that fallback to returning null

Operators

operator ==(Object other) bool
The equality operator.
inherited