mirror of
https://github.com/block/buzz.git
synced 2026-11-02 07:22:55 +00:00
Updates mobile toast animations and styling. | Sign in | Retry | Copied | | --- | --- | --- | |  |  |  | --------- Signed-off-by: kenny lopez <klopez4212@gmail.com> Co-authored-by: Terp <5856f6900e8e0a4e0ea1f4f8d2ee33e4753d2119bc122f94ecafc660b46c0511@buzz.block.builderlab.xyz>
15 lines
375 B
Dart
15 lines
375 B
Dart
import 'package:flutter/material.dart';
|
|
import 'package:flutter/services.dart';
|
|
|
|
import 'widgets/buzz_toast.dart';
|
|
|
|
Future<void> copyToClipboard(
|
|
BuildContext context,
|
|
String text, {
|
|
String message = 'Copied',
|
|
}) async {
|
|
await Clipboard.setData(ClipboardData(text: text));
|
|
if (!context.mounted) return;
|
|
showBuzzToast(context, message, kind: ToastKind.success);
|
|
}
|