handleTap method

Future<void> handleTap(
  1. BuildContext context
)

Handles the tap event when the button is pressed.

Implementation

Future<void> handleTap(BuildContext context) async {
  if (isEnabled && valueText.isNotEmpty) {
    await Clipboard.setData(ClipboardData(text: valueText));

    if (showNotification) {
      // ignore: use_build_context_synchronously
      FastNotificationCenter.info(context, message ?? _getDefaultValueText());
    }
  }
}