ChatReactionsConfig constructor

const ChatReactionsConfig({
  1. List<String> availableReactions = const ['👍', '❤️', '😂', '😮', '😢', '😠', '➕'],
  2. List<MenuItem> menuItems = const [MenuItem(label: 'Reply', icon: "assets/reaction_chat/reply_item.png"), MenuItem(label: 'Copy', icon: "assets/reaction_chat/copy_item.png"), MenuItem(label: 'Select and copy', icon: "assets/reaction_chat/copy_item.png"), MenuItem(label: 'Delete', icon: "assets/reaction_chat/delete_item.png", isDestructive: true)],
  3. Duration animationDuration = const Duration(milliseconds: 300),
  4. Duration dialogTransitionDuration = const Duration(milliseconds: 300),
  5. bool showAddReactionButton = true,
  6. bool enableHapticFeedback = true,
  7. bool enableLongPress = true,
  8. bool enableDoubleTap = false,
  9. int maxReactionsToShow = 5,
  10. double reactionSize = 25.0,
  11. double stackedValue = 4.0,
  12. EdgeInsets dialogPadding = const EdgeInsets.all(20.0),
  13. BorderRadius? dialogBorderRadius,
  14. Color? dialogBackgroundColor,
  15. String? reactionAddIcon,
  16. Color? itemTextColor,
  17. double dialogBlurSigma = 5.0,
  18. double heightMessageBox = 400.0,
  19. double widthMessageBox = 275.0,
  20. bool dismissOnTapOutside = true,
  21. bool showContextMenu = true,
  22. Widget emojiPickerBuilder(
    1. BuildContext,
    2. dynamic onEmojiSelected(
      1. String
      )
    )? = _defaultEmojiPickerBuilder,
  23. Widget customReactionBuilder(
    1. String,
    2. bool
    )?,
  24. Widget customMenuItemBuilder(
    1. MenuItem,
    2. VoidCallback
    )?,
})

Implementation

const ChatReactionsConfig({
  this.availableReactions = const ['👍', '❤️', '😂', '😮', '😢', '😠', '➕'],
  this.menuItems = const [
    MenuItem(label: 'Reply', icon: "assets/reaction_chat/reply_item.png"),
    MenuItem(label: 'Copy', icon: "assets/reaction_chat/copy_item.png"),
    MenuItem(label: 'Select and copy', icon: "assets/reaction_chat/copy_item.png"),
    MenuItem(
        label: 'Delete', icon: "assets/reaction_chat/delete_item.png", isDestructive: true),
  ],
  this.animationDuration = const Duration(milliseconds: 300),
  this.dialogTransitionDuration = const Duration(milliseconds: 300),
  this.showAddReactionButton = true,
  this.enableHapticFeedback = true,
  this.enableLongPress = true,
  this.enableDoubleTap = false,
  this.maxReactionsToShow = 5,
  this.reactionSize = 25.0,
  this.stackedValue = 4.0,
  this.dialogPadding = const EdgeInsets.all(20.0),
  this.dialogBorderRadius,
  this.dialogBackgroundColor,
  this.reactionAddIcon,
  this.itemTextColor,
  this.dialogBlurSigma = 5.0,
  this.heightMessageBox = 400.0,
  this.widthMessageBox = 275.0,
  this.dismissOnTapOutside = true,
  this.showContextMenu = true,
  this.emojiPickerBuilder = _defaultEmojiPickerBuilder,
  this.customReactionBuilder,
  this.customMenuItemBuilder,
});