Skip to content

Commit

Permalink
chore: deprecate FlutterQuillExtensions
Browse files Browse the repository at this point in the history
  • Loading branch information
EchoEllet committed Sep 21, 2024
1 parent 3850156 commit d1735c0
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
1 change: 1 addition & 0 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ void main() async {
? HydratedStorage.webStorageDirectory
: await getApplicationDocumentsDirectory(),
);
// ignore: deprecated_member_use
FlutterQuillExtensions.useSuperClipboardPlugin();
runApp(const MyApp());
}
Expand Down
15 changes: 12 additions & 3 deletions flutter_quill_extensions/lib/flutter_quill_extensions.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ library flutter_quill_extensions;

// ignore: implementation_imports
import 'package:flutter_quill/src/editor_toolbar_controller_shared/clipboard/clipboard_service_provider.dart';
import 'package:meta/meta.dart' show immutable;
import 'package:meta/meta.dart' show experimental;

import 'src/editor_toolbar_controller_shared/clipboard/super_clipboard_service.dart';

Expand Down Expand Up @@ -38,9 +38,12 @@ export 'src/toolbar/video/models/video.dart';
export 'src/toolbar/video/models/video_configurations.dart';
export 'src/toolbar/video/video_button.dart';

@immutable
@Deprecated(
'Should not be used as will removed soon in future releases.',
)
@experimental
class FlutterQuillExtensions {
const FlutterQuillExtensions._();
FlutterQuillExtensions._();

@Deprecated(
'''
Expand All @@ -51,6 +54,7 @@ class FlutterQuillExtensions {
Calling this function will no longer activate the feature.
''',
)
@experimental
static void useSpellCheckerService(String language) {
// This feature has been removed from the package.
// See https://github.com/singerdmx/flutter-quill/issues/2142
Expand All @@ -59,6 +63,11 @@ class FlutterQuillExtensions {
/// Override default implementation of [ClipboardServiceProvider.instance]
/// to allow `flutter_quill` package to use `super_clipboard` plugin
/// to support rich text features, gif and images.
@Deprecated(
'Should not be used anymore as super_clipboard will moved outside of flutter_quill_extensions soon.\n'
'A replacement is being made in https://github.com/singerdmx/flutter-quill/pull/2230',
)
@experimental
static void useSuperClipboardPlugin() {
ClipboardServiceProvider.setInstance(SuperClipboardService());
}
Expand Down

0 comments on commit d1735c0

Please sign in to comment.