docs(markdown-files): improve readability

pull/1924/head
Ellet 10 months ago
parent e863a539bf
commit 9ce30bf1eb
  1. 86
      README.md
  2. 8
      doc/translation.md
  3. 179
      flutter_quill_extensions/README.md

@ -45,29 +45,29 @@ You can join our [Slack Group] for discussion.
> If you are viewing this page from [pub.dev](https://pub.dev/) page, then you > If you are viewing this page from [pub.dev](https://pub.dev/) page, then you
> might have some issues with opening some links, open it in the GitHub repo instead. > might have some issues with opening some links, open it in the GitHub repo instead.
## Table of contents ## 📚 Table of contents
- [Flutter Quill](#flutter-quill) - [Flutter Quill](#flutter-quill)
- [Table of contents](#table-of-contents) - [📚 Table of contents](#-table-of-contents)
- [Screenshots](#screenshots) - [📸 Screenshots](#-screenshots)
- [Installation](#installation) - [📦 Installation](#-installation)
- [Platform Specific Configurations](#platform-specific-configurations) - [🛠 Platform Specific Configurations](#-platform-specific-configurations)
- [Usage](#usage) - [🚀 Usage](#-usage)
- [Migration](#migration) - [🔄 Migration](#-migration)
- [Input / Output](#input--output) - [🔤 Input / Output](#-input--output)
- [Links](#links) - [🔗 Links](#-links)
- [Configurations](#configurations) - [ Configurations](#-configurations)
- [Links](#links-1) - [🔗 Links](#-links-1)
- [Font Family](#font-family) - [🖋 Font Family](#-font-family)
- [Embed Blocks](#embed-blocks) - [📦 Embed Blocks](#-embed-blocks)
- [Using the embed blocks from `flutter_quill_extensions`](#using-the-embed-blocks-from-flutter_quill_extensions) - [🛠 Using the embed blocks from `flutter_quill_extensions`](#-using-the-embed-blocks-from-flutter_quill_extensions)
- [Links](#links-2) - [🔗 Links](#-links-2)
- [Conversion to HTML](#conversion-to-html) - [🔄 Conversion to HTML](#-conversion-to-html)
- [Translation](#translation) - [🌐 Translation](#-translation)
- [Testing](#testing) - [🧪 Testing](#-testing)
- [Contributors](#contributors) - [👥 Contributors](#-contributors)
## Screenshots ## 📸 Screenshots
<details> <details>
<summary>Tap to show/hide screenshots</summary> <summary>Tap to show/hide screenshots</summary>
@ -81,7 +81,7 @@ You can join our [Slack Group] for discussion.
</details> </details>
## Installation ## 📦 Installation
```yaml ```yaml
dependencies: dependencies:
@ -102,15 +102,14 @@ dependencies:
> being part of the open-source community! > being part of the open-source community!
> >
## Platform Specific Configurations ## 🛠 Platform Specific Configurations
Before using the package, we must inform you the package uses the following plugins: Before using the package, we must inform you the package uses the following plugins:
``` 1. [url_launcher](https://pub.dev/packages/url_launcher) to open links.
url_launcher 2. [device_info_plus](https://pub.dev/packages/device_info_plus) to view info about the current device.
flutter_keyboard_visibility 3. [flutter_keyboard_visibility](https://pub.dev/packages/flutter_keyboard_visibility) to listen for keyboard visibility
device_info_plus changes.
```
All of them don't require any platform-specific setup. All of them don't require any platform-specific setup.
@ -118,7 +117,7 @@ All of them don't require any platform-specific setup.
> to [FlutterQuill Extensions], to use rich text features, support pasting images, gif files, take a look > to [FlutterQuill Extensions], to use rich text features, support pasting images, gif files, take a look
> at `flutter_quill_extensions` Readme. > at `flutter_quill_extensions` Readme.
## Usage ## 🚀 Usage
First, you need to instantiate a controller First, you need to instantiate a controller
@ -157,12 +156,12 @@ in most cases, it's better to.
Check out [Sample Page] for more advanced usage. Check out [Sample Page] for more advanced usage.
## Migration ## 🔄 Migration
Starting from version `8.0.0` Starting from version `8.0.0`
We have added [Migration Guide](/doc/migration.md) for migration from different versions We have added [Migration Guide](/doc/migration.md) for migration from different versions
## Input / Output ## 🔤 Input / Output
This library uses [Quill Delta](https://quilljs.com/docs/delta/) This library uses [Quill Delta](https://quilljs.com/docs/delta/)
to represent the document content. to represent the document content.
@ -195,7 +194,7 @@ final json = jsonDecode(r'{"insert":"hello\n"}');
_controller.document = Document.fromJson(json); _controller.document = Document.fromJson(json);
``` ```
### Links ### 🔗 Links
- [Quill Delta](https://quilljs.com/docs/delta/) - [Quill Delta](https://quilljs.com/docs/delta/)
- [Quill Delta Formats](https://quilljs.com/docs/formats) - [Quill Delta Formats](https://quilljs.com/docs/formats)
@ -204,12 +203,12 @@ _controller.document = Document.fromJson(json);
- [Quill JS Interactive Playground](https://quilljs.com/playground/) - [Quill JS Interactive Playground](https://quilljs.com/playground/)
- [Quill JS GitHub repo](https://github.com/quilljs/quill) - [Quill JS GitHub repo](https://github.com/quilljs/quill)
## Configurations ## Configurations
The `QuillToolbar` and `QuillEditor` widgets let you customize a lot of things The `QuillToolbar` and `QuillEditor` widgets let you customize a lot of things
[Sample Page] provides sample code for advanced usage and configuration. [Sample Page] provides sample code for advanced usage and configuration.
### Links ### 🔗 Links
- [Using Custom App Widget](./doc/configurations/using_custom_app_widget.md) - [Using Custom App Widget](./doc/configurations/using_custom_app_widget.md)
- [Localizations Setup](./doc/configurations/localizations_setup.md) - [Localizations Setup](./doc/configurations/localizations_setup.md)
@ -217,7 +216,7 @@ The `QuillToolbar` and `QuillEditor` widgets let you customize a lot of things
- [Font Family](#font-family) - [Font Family](#font-family)
- [Custom Toolbar buttons](./doc/configurations/custom_buttons.md) - [Custom Toolbar buttons](./doc/configurations/custom_buttons.md)
### Font Family ### 🖋 Font Family
To use your own fonts, update your [Assets](./example/assets/fonts) folder and pass in `fontFamilyValues`. To use your own fonts, update your [Assets](./example/assets/fonts) folder and pass in `fontFamilyValues`.
More details More details
@ -225,7 +224,7 @@ on [this commit](https://github.com/singerdmx/flutter-quill/commit/71d06f6b7be1b
[this article](https://stackoverflow.com/questions/55075834/fontfamily-property-not-working-properly-in-flutter) [this article](https://stackoverflow.com/questions/55075834/fontfamily-property-not-working-properly-in-flutter)
and [this](https://www.flutterbeads.com/change-font-family-flutter/). and [this](https://www.flutterbeads.com/change-font-family-flutter/).
## Embed Blocks ## 📦 Embed Blocks
As of version 6.0, embed blocks are not provided by default as part of this package. As of version 6.0, embed blocks are not provided by default as part of this package.
@ -236,17 +235,17 @@ package [`flutter_quill_extensions`](https://pub.dev/packages/flutter_quill_exte
Provide a list of embed Provide a list of embed
### Using the embed blocks from `flutter_quill_extensions` ### 🛠 Using the embed blocks from `flutter_quill_extensions`
To see how to use the extension package, please take a look at the [README](./flutter_quill_extensions/README.md) To see how to use the extension package, please take a look at the [README](./flutter_quill_extensions/README.md)
of [FlutterQuill Extensions] of [FlutterQuill Extensions]
### Links ### 🔗 Links
- [Custom Embed Blocks](./doc/custom_embed_blocks.md) - [Custom Embed Blocks](./doc/custom_embed_blocks.md)
- [Custom Toolbar](./doc/custom_toolbar.md) - [Custom Toolbar](./doc/custom_toolbar.md)
## Conversion to HTML ## 🔄 Conversion to HTML
Having your document stored in Quill Delta format is sometimes not enough. Often you'll need to convert Having your document stored in Quill Delta format is sometimes not enough. Often you'll need to convert
it to other formats such as HTML to publish it, or send an email. it to other formats such as HTML to publish it, or send an email.
@ -271,18 +270,18 @@ You have two options:
Typescript/Javascript package. Typescript/Javascript package.
this package doesn't convert the HTML back to Quill Delta as far as we know this package doesn't convert the HTML back to Quill Delta as far as we know
## Translation ## 🌐 Translation
The package offers translations for the quill toolbar and editor, it will follow the system locale unless you set your The package offers translations for the quill toolbar and editor, it will follow the system locale unless you set your
own locale. own locale.
Open this [page](./doc/translation.md) for more info Open this [page](./doc/translation.md) for more info
## Testing ## 🧪 Testing
Please use [flutter_quill_test](https://pub.dev/packages/flutter_quill_test) for testing Please use [flutter_quill_test](https://pub.dev/packages/flutter_quill_test) for testing
## Contributors ## 👥 Contributors
- Special thanks to everyone who has contributed to this project... - Special thanks to everyone who has contributed to this project...
@ -306,8 +305,7 @@ Made with [contrib.rocks](https://contrib.rocks).
We welcome all contributions! We welcome all contributions!
Please follow these guidelines when contributing to the project. Please follow these guidelines when contributing to the project.
See [CONTRIBUTING.md](./CONTRIBUTING.md) for more See [CONTRIBUTING.md](./CONTRIBUTING.md) for more details.
details.
<br> <br>
The [CONTRIBUTING.md](./CONTRIBUTING.md) has development notes, if you're planning on contributing to the package, The [CONTRIBUTING.md](./CONTRIBUTING.md) has development notes, if you're planning on contributing to the package,

@ -1,4 +1,4 @@
# Translation # 🌍 Translation
The package offers translations for the quill toolbar and editor, it will follow the locale that is defined in The package offers translations for the quill toolbar and editor, it will follow the locale that is defined in
your `WidgetsApp` for example `MaterialApp` which usually follows the system locally unless you set your own locale your `WidgetsApp` for example `MaterialApp` which usually follows the system locally unless you set your own locale
@ -25,7 +25,7 @@ Expanded(
) )
``` ```
## Supported Locales ## 🌐 Supported Locales
Currently, translations are available for these 41 locales: Currently, translations are available for these 41 locales:
@ -36,7 +36,7 @@ Currently, translations are available for these 41 locales:
* `Locale('da')`, `Locale('fr')`, `Locale('ko')`, `Locale('no')`, `Locale('ru')`, `Locale('tr')`, `Locale('zh', 'HK')` * `Locale('da')`, `Locale('fr')`, `Locale('ko')`, `Locale('no')`, `Locale('ru')`, `Locale('tr')`, `Locale('zh', 'HK')`
* `Locale('de')`, `Locale('he')`, `Locale('ku')`, `Locale('pl')`, `Locale('ar')`, `Locale('sk')`, `Locale('uk')` * `Locale('de')`, `Locale('he')`, `Locale('ku')`, `Locale('pl')`, `Locale('ar')`, `Locale('sk')`, `Locale('uk')`
## Contributing to translations ## 📌 Contributing to translations
The translation files are located in the [l10n](../lib/src/l10n/) folder. Feel free to contribute your own translations. The translation files are located in the [l10n](../lib/src/l10n/) folder. Feel free to contribute your own translations.
@ -93,7 +93,7 @@ dart format ./lib/src/l10n/generated
The script above will generate Dart files from the Arb files to test the changes and take effect, otherwise you The script above will generate Dart files from the Arb files to test the changes and take effect, otherwise you
won't notice a difference. won't notice a difference.
> If you added or removed translations in the template file, make sure to update `_expectedTranslationKeysLength` > 🔧 If you added or removed translations in the template file, make sure to update `_expectedTranslationKeysLength`
> variable in [scripts/ensure_translations_correct.dart](../scripts/ensure_translations_correct.dart) <br> > variable in [scripts/ensure_translations_correct.dart](../scripts/ensure_translations_correct.dart) <br>
> Otherwise you don't need to update it. > Otherwise you don't need to update it.

@ -3,37 +3,38 @@
An extensions for [flutter_quill](https://pub.dev/packages/flutter_quill) An extensions for [flutter_quill](https://pub.dev/packages/flutter_quill)
to support embedding widgets like images, formulas, videos, and more. to support embedding widgets like images, formulas, videos, and more.
Check [Flutter Quill](https://github.com/singerdmx/flutter-quill) for details of use. Check [Flutter Quill](https://github.com/singerdmx/flutter-quill) for details of use.
## Table of Contents ## 📚 Table of Contents
- [Flutter Quill Extensions](#flutter-quill-extensions) - [Flutter Quill Extensions](#flutter-quill-extensions)
- [Table of Contents](#table-of-contents) - [📚 Table of Contents](#-table-of-contents)
- [About](#about) - [📝 About](#-about)
- [Installation](#installation) - [📦 Installation](#-installation)
- [Platform Specific Configurations](#platform-specific-configurations) - [🛠 Platform Specific Configurations](#-platform-specific-configurations)
- [Usage](#usage) - [🚀 Usage](#-usage)
- [Configurations](#configurations) - [ Configurations](#-configurations)
- [Embed Blocks](#embed-blocks) - [📦 Embed Blocks](#-embed-blocks)
- [Element properties](#element-properties) - [🔍Element properties](#element-properties)
- [Custom Element properties](#custom-element-properties) - [🔧 Custom Element properties](#-custom-element-properties)
- [Image Assets](#image-assets) - [🖼 Image Assets](#-image-assets)
- [Drag and drop feature](#drag-and-drop-feature) - [🎯 Drag and drop feature](#-drag-and-drop-feature)
- [Features](#features) - [💡 Features](#-features)
- [Contributing](#contributing) - [🤝 Contributing](#-contributing)
- [Acknowledgments](#acknowledgments) - [🌟 Acknowledgments](#-acknowledgments)
## 📝 About
## About
Flutter Quill is a rich editor text.
Flutter Quill is a rich editor text. It'd allow you to customize a lot of things, It'd allow you to customize a lot of things,
it has custom embed builders that allow you to render custom widgets in the editor <br> it has custom embed builders that allow you to render custom widgets in the editor <br>
this is an extension to extend its functionalities by adding more features like images, videos, and more
## Installation This is an extension to extend its functionalities by adding more features like images, videos, and more
## 📦 Installation
Before starting using this package, please make sure to install Before starting using this package, please make sure to install
[flutter_quill](https://github.com/singerdmx/flutter-quill) package first and follow [flutter_quill](https://github.com/singerdmx/flutter-quill) package first and follow
its usage instructions. its usage instructions.
```yaml ```yaml
@ -50,46 +51,68 @@ dependencies:
path: flutter_quill_extensions path: flutter_quill_extensions
``` ```
## Platform Specific Configurations ## 🛠 Platform Specific Configurations
The package use the following plugins: The package uses the following plugins:
1. [`gal`](https://github.com/natsuk4ze/) plugin to save images. 1. [`gal`](https://github.com/natsuk4ze/) plugin to save images.
For this to work, you need to add the appropriate configurations For this to work, you need to add the appropriate configurations
See <https://github.com/natsuk4ze/gal#-get-started> to add the needed lines. See <https://github.com/natsuk4ze/gal#-get-started> to add the needed lines.
1. [`image_picker`](https://pub.dev/packages/image_picker) plugin for picking images so please make sure to follow the instructions 2. [`image_picker`](https://pub.dev/packages/image_picker) plugin for picking images so please make sure to follow the
2. [youtube_player_flutter](https://pub.dev/packages/youtube_player_flutter) plugin which uses [flutter_inappwebview](https://pub.dev/packages/flutter_inappwebview) which has requirement on web, please follow this [link](https://pub.dev/packages/flutter_inappwebview#installation) in order to setup the support for web instructions
3. [image_picker](https://pub.dev/packages/image_picker) which also 3. [youtube_player_flutter](https://pub.dev/packages/youtube_player_flutter) plugin which
requires some configurations, follow this [link](https://pub.dev/packages/image_picker#installation). It's needed for Android, iOS, and macOS, we must inform you that you can't pick photos using the camera on a desktop so make sure to handle that if you plan on adding support for the desktop, this may change in the future, and for more info follow this [link](https://pub.dev/packages/image_picker#windows-macos-and-linux) uses [flutter_inappwebview](https://pub.dev/packages/flutter_inappwebview) which has a requirement on web, please
4. [super_clipboard](https://pub.dev/packages/super_clipboard) which needs some setup on Android only, it's used to support copying images and pasting them into editor then you must setup it, open the page in pub.dev and read the `README.md` or click on this [link](https://pub.dev/packages/super_clipboard#android-support) to get the instructions. follow this [link](https://pub.dev/packages/flutter_inappwebview#installation) to set up the support for web
4. [image_picker](https://pub.dev/packages/image_picker) which also
requires some configurations, follow this [link](https://pub.dev/packages/image_picker#installation).
It's needed for
Android, iOS, and macOS, we must inform you that you can't pick photos using the camera on a desktop so make sure to
handle that if you plan on adding support for the desktop, this may change in the future, and for more info follow
this [link](https://pub.dev/packages/image_picker#windows-macos-and-linux)
5. [super_clipboard](https://pub.dev/packages/super_clipboard) which needs some setup on Android only, it's used to
support copying images and pasting them into editor then you must set up it, open the page in pub.dev and read
the `README.md` or click on this [link](https://pub.dev/packages/super_clipboard#android-support) to get the
instructions.
The minSdkVersion is `23` as `super_clipboard` requires it The minSdkVersion is `23` as `super_clipboard` requires it
> For loading the image from the internet <br> <br> > For loading the image from the internet <br> <br>
> **Android**: you need to add permissions in `AndroidManifest.xml`, Follow this [Android Guide](https://developer.android.com/training/basics/network-ops/connecting) or [Flutter Networking](https://docs.flutter.dev/data-and-backend/networking#android) for more info, the internet permission is included by default only for debugging so you need to follow this link to add it in the release version too. you should allow loading images and videos only for the `https` protocol but if you want http too then you need to configure your Android application to accept `http` in the release mode, follow this [Android Cleartext / Plaintext HTTP](https://developer.android.com/privacy-and-security/risks/cleartext) page for more info. <br> <br> > **Android**: you need to add permissions in `AndroidManifest.xml`, Follow
> **macOS**: you need to include a key in your `Info.plist`, follow this [link](https://docs.flutter.dev/data-and-backend/networking#macos) to add the required configurations > this [Android Guide](https://developer.android.com/training/basics/network-ops/connecting)
> or [Flutter Networking](https://docs.flutter.dev/data-and-backend/networking#android) for more info, the internet
> permission is included by default only for debugging, you need to follow this link to add it in the release version
> too. you should allow loading images and videos only for the `https` protocol but if you want http too then you need
> to
> configure your Android application to accept `http` in the release mode, follow
> this [Android Cleartext / Plaintext HTTP](https://developer.android.com/privacy-and-security/risks/cleartext) page for
> more info. <br> <br>
> **macOS**: you need to include a key in your `Info.plist`, follow
> this [link](https://docs.flutter.dev/data-and-backend/networking#macos) to add the required configurations
> >
## Usage ## 🚀 Usage
Start using the package in 3 steps: Start using the package in 3 steps:
1. Besure to to follow the [Installation](#installation) section. 1. Be sure to follow the [Installation](#installation) section.
2. This package already include `super_clipboard` and will be used internally in this package, to use it in `flutter_quill`, call this function before using any of the widgets or functionalities 2. This package already include `super_clipboard` and will be used internally in this package, to use it
in `flutter_quill`, call this function before using any of the widgets or functionalities
```dart ```dart
FlutterQuillExtensions.useSuperClipboardPlugin(); FlutterQuillExtensions.useSuperClipboardPlugin();
``` ```
`super_clipboard` is comprehensive plugin that provide many clipboard features for reading and writing of rich text, images and other formats. `super_clipboard` is comprehensive plugin that provides many clipboard features for reading and writing of rich text,
images and other formats.
Executing this function will allow `flutter_quill` to use modern rich text features to paste HTML and Markdown, support for Gif files, and other formats. Executing this function will allow `flutter_quill` to use modern rich text features to paste HTML and Markdown,
support for Gif files, and other formats.
3. Set the `embedBuilders` and `embedToolbar` params in configurations of `QuillEditor` and `QuillToolbar` with the 3. Set the `embedBuilders` and `embedToolbar` params in configurations of `QuillEditor` and `QuillToolbar` with the
values provided by this repository. values provided by this repository.
**Quill Toolbar**: **Quill Toolbar**:
```dart ```dart
QuillToolbar( QuillToolbar(
configurations: QuillToolbarConfigurations( configurations: QuillToolbarConfigurations(
@ -98,7 +121,7 @@ Start using the package in 3 steps:
), ),
``` ```
**Quill Editor** **Quill Editor**
```dart ```dart
Expanded( Expanded(
child: QuillEditor.basic( child: QuillEditor.basic(
@ -109,31 +132,35 @@ Start using the package in 3 steps:
) )
``` ```
## Configurations ## Configurations
### Embed Blocks ### 📦 Embed Blocks
As of version [flutter_quill](https://pub.dev/packages/flutter_quill) `6.0.x`, embed blocks are not provided by default as part of Flutter quill. Instead, it provides an interface for all the users to provide their implementations for embed blocks. Implementations for image, video, and formula embed blocks are proved in this package As of version [flutter_quill](https://pub.dev/packages/flutter_quill) `6.0.x`, embed blocks are not provided by default
as part of Flutter quill.
Instead, it provides an interface for all the users to provide their implementations for embed
blocks.
Implementations for image, video, and formula embed blocks are proved in this package
The instructions for using the embed blocks are in the [Usage](#usage) section The instructions for using the embed blocks are in the [Usage](#usage) section
### Element properties ### 🔍Element properties
Currently the library has limitied support for the image and video properties Currently, the library has limited support for the image and video properties,
and it supports only `width`, `height`, `margin` and it supports only `width`, `height`, `margin`
```json ```json
{ {
"insert": { "insert": {
"image": "https://user-images.githubusercontent.com/122956/72955931-ccc07900-3d52-11ea-89b1-d468a6e2aa2b.png" "image": "https://user-images.githubusercontent.com/122956/72955931-ccc07900-3d52-11ea-89b1-d468a6e2aa2b.png"
}, },
"attributes": { "attributes": {
"style":"width: 50px; height: 50px; margin: 10px;" "style": "width: 50px; height: 50px; margin: 10px;"
} }
} }
``` ```
### Custom Element properties ### 🔧 Custom Element properties
Doesn't apply to official Quill JS Doesn't apply to official Quill JS
@ -141,18 +168,18 @@ Define flutterAlignment` as follows:
```json ```json
{ {
"insert": { "insert": {
"image": "https://user-images.githubusercontent.com/122956/72955931-ccc07900-3d52-11ea-89b1-d468a6e2aa2b.png" "image": "https://user-images.githubusercontent.com/122956/72955931-ccc07900-3d52-11ea-89b1-d468a6e2aa2b.png"
}, },
"attributes":{ "attributes": {
"style":"flutterAlignment: topLeft" "style": "flutterAlignment: topLeft"
} }
} }
``` ```
This works for all platforms except Web This works for all platforms except Web
### Image Assets ### 🖼 Image Assets
If you want to use image assets in the Quill Editor, you need to make sure your assets folder is `assets` otherwise: If you want to use image assets in the Quill Editor, you need to make sure your assets folder is `assets` otherwise:
@ -172,22 +199,27 @@ QuillEditor.basic(
); );
``` ```
This info is needed by the package to check if it asset image to use the `AssetImage` provider This info is needed by the package to check if its asset image to use the `AssetImage` provider
### 🎯 Drag and drop feature
### Drag and drop feature Currently, the drag-and-drop feature is not officially supported, but you can achieve this very easily in the following
Currently, the drag-and-drop feature is not officially supported, but you can achieve this very easily in the following steps: steps:
1. Drag and drop require native code, you can use any Flutter plugin you like, if you want a suggestion we recommend [desktop_drop](https://pub.dev/packages/desktop_drop), it was originally developed for desktop but it has support for the web as well as Android (that is not the case for iOS) 1. Drag and drop require native code, you can use any Flutter plugin you like, if you want a suggestion we
recommend [desktop_drop](https://pub.dev/packages/desktop_drop), it was originally developed for desktop.
It has support for the web as well as Android (that is not the case for iOS)
2. Add the dependency in your `pubspec.yaml` using the following command: 2. Add the dependency in your `pubspec.yaml` using the following command:
```yaml ```yaml
flutter pub add desktop_drop flutter pub add desktop_drop
``` ```
and import it with and import it with
```dart ```dart
import 'package:desktop_drop/desktop_drop.dart'; import 'package:desktop_drop/desktop_drop.dart';
``` ```
3. in the configurations of `QuillEditor`, use the `builder` to wrap the editor with `DropTarget` which comes from `desktop_drop` 3. in the configurations of `QuillEditor`, use the `builder` to wrap the editor with `DropTarget` which comes
from `desktop_drop`
```dart ```dart
import 'package:flutter_quill_extensions/flutter_quill_extensions.dart'; import 'package:flutter_quill_extensions/flutter_quill_extensions.dart';
@ -208,6 +240,7 @@ Currently, the drag-and-drop feature is not officially supported, but you can ac
) )
``` ```
4. Implement the `_onDragDone`, it depends on your use case but this is just a simple example 4. Implement the `_onDragDone`, it depends on your use case but this is just a simple example
```dart ```dart
const List<String> imageFileExtensions = [ const List<String> imageFileExtensions = [
'.jpeg', '.jpeg',
@ -247,23 +280,25 @@ OnDragDoneCallback get _onDragDone {
} }
``` ```
## Features ## 💡 Features
```markdown ```markdown
## Features ## Features
— Easy to use and customizable — Easy to use and customizable
- Rich text, images and other formats - Rich text, images and other formats
- Useful utilities and widgets - Useful utilities and widgets
``` ```
## Contributing ## 🤝 Contributing
We welcome contributions! We welcome contributions!
Please follow these guidelines when contributing to our project. See [CONTRIBUTING.md](../CONTRIBUTING.md) for more details. Please follow these guidelines when contributing to our project. See [CONTRIBUTING.md](../CONTRIBUTING.md) for more
details.
## Acknowledgments ## 🌟 Acknowledgments
- Thanks to the [Flutter Team](https://flutter.dev/) - Thanks to the [Flutter Team](https://flutter.dev/)
- Thanks to the welcoming community, the volunteers who helped along the journey, developers, contributors - Thanks to the welcoming community, the volunteers who helped along the journey, developers, contributors

Loading…
Cancel
Save