Update CHANGELOG.md && Clean the events check

pull/1419/head
Ahmed Hnewa 2 years ago
parent a0c5186cad
commit da40e5795a
No known key found for this signature in database
GPG Key ID: C488CC70BBCEF0D1
  1. 2
      CHANGELOG.md
  2. 2
      example/lib/pages/home_page.dart
  3. 2
      example/lib/universal_ui/real_ui.dart
  4. 2
      example/lib/widgets/demo_scaffold.dart
  5. 20
      flutter_quill_extensions/lib/embeds/builders.dart
  6. 6
      flutter_quill_extensions/lib/utils/quill_utils.dart
  7. 2
      flutter_quill_extensions/pubspec.yaml
  8. 4
      pubspec.yaml

@ -1,3 +1,5 @@
# [7.4.10]
- Update the minimum version of device_info_plus to 10.0.0
# [7.4.9]
- Style recognition fixes.

@ -1,6 +1,6 @@
import 'dart:async';
import 'dart:convert';
import 'dart:io';
import 'dart:io' show File, Platform;
import 'dart:ui';
import 'package:file_picker/file_picker.dart';

@ -1,4 +1,4 @@
import 'dart:ui' as ui;
import 'dart:ui' if (dart.library.html) 'dart:ui_web' as ui;
class PlatformViewRegistry {
static void registerViewFactory(String viewId, dynamic cb) {

@ -1,5 +1,5 @@
import 'dart:convert';
import 'dart:io';
import 'dart:io' show Platform;
import 'package:filesystem_picker/filesystem_picker.dart';
import 'package:flutter/foundation.dart';

@ -137,18 +137,12 @@ class ImageEmbedBuilder extends EmbedBuilder {
final imageFile = File(imageUrl);
final shouldRemoveImageEvent = shouldRemoveImageCallback;
var shouldRemoveImage = true;
if (shouldRemoveImageEvent != null) {
shouldRemoveImage = await shouldRemoveImageEvent(
imageFile,
);
}
if (!shouldRemoveImage) {
// Call the remove check callback if set
if (await shouldRemoveImageCallback?.call(imageFile) ==
false) {
return;
}
final offset = getEmbedNode(
controller,
controller.selection.start,
@ -159,10 +153,8 @@ class ImageEmbedBuilder extends EmbedBuilder {
'',
TextSelection.collapsed(offset: offset),
);
final afterRemoveImageEvent = onImageRemovedCallback;
if (afterRemoveImageEvent != null) {
await afterRemoveImageEvent(imageFile);
}
// Call the post remove callback if set
await onImageRemovedCallback?.call(imageFile);
},
);
return Padding(

@ -1,6 +1,6 @@
import 'dart:io' show Directory, File, Platform;
import 'package:flutter/foundation.dart';
import 'package:flutter/foundation.dart' show kIsWeb;
import 'package:flutter_quill/flutter_quill.dart' as quill;
import 'package:path/path.dart' as path;
@ -12,8 +12,8 @@ class QuillImageUtilities {
static void _webIsNotSupported(String functionName) {
if (kIsWeb) {
throw UnsupportedError(
'The static function $functionName()'
' on QuillImageUtilities is not supported in Web',
'The static function "$functionName()"'
' on class "QuillImageUtilities" is not supported in Web',
);
}
}

@ -1,6 +1,6 @@
name: flutter_quill_extensions
description: Embed extensions for flutter_quill including image, video, formula and etc.
version: 0.5.0
version: 0.5.1
homepage: https://bulletjournal.us/home/index.html
repository: https://github.com/singerdmx/flutter-quill/tree/master/flutter_quill_extensions

@ -20,8 +20,8 @@ dependencies:
characters: ^1.3.0
diff_match_patch: ^0.4.1
i18n_extension: ^9.0.2
device_info_plus: ^9.0.3
platform: ^3.1.2
device_info_plus: ^10.0.0
platform: ^3.1.3
pasteboard: ^0.2.0
# Dependencies for testing utilities

Loading…
Cancel
Save