import 'shortcut_platform_interface.dart';

class FlutterShortcut {
  Future<String?> createShortcut({
    required String id,
    required String label,
    required String action,
    String? iconAssetName,
  }) {
    return FlutterShortcutPlatform.instance.createShortcut(
      id: id,
      label: label,
      action: action,
      iconAssetName: iconAssetName,
    );
  }

  Future<void> getLaunchAction(
      void Function(String action) onActionReceived) async {
    return FlutterShortcutPlatform.instance.getLaunchAction(onActionReceived);
  }

  Stream<String> actionStream() {
    return FlutterShortcutPlatform.instance.actionStream();
  }
}
