-
Notifications
You must be signed in to change notification settings - Fork 849
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Ellet
committed
Dec 6, 2023
1 parent
c5c8083
commit 21a192f
Showing
23 changed files
with
576 additions
and
491 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
1. Removing the `QuillProvider` | ||
|
||
We got a lot of feedbacks about `QuillProvider`, while the provider help removing duplicate lines for simple usage, for more advance usage it become very messy | ||
So from now on we will use providers for the `QuillToolbar` and `QuillEditor` only internally, you don't need it anymore | ||
|
||
Instead you will need to pass the configurations directly in the `QuillToolbar` and `QuillEditor` | ||
|
||
**Old code**: | ||
|
||
```dart | ||
QuillProvider( | ||
configurations: QuillConfigurations( | ||
controller: _controller, | ||
sharedConfigurations: const QuillSharedConfigurations(), | ||
), | ||
child: Column( | ||
children: [ | ||
const QuillToolbar(), | ||
Expanded( | ||
child: QuillEditor.basic( | ||
configurations: const QuillEditorConfigurations( | ||
readOnly: false, // true for view only mode | ||
), | ||
), | ||
) | ||
], | ||
), | ||
) | ||
``` | ||
|
||
**New code**: | ||
|
||
```dart | ||
Column( | ||
children: [ | ||
QuillToolbar.simple( | ||
QuillSimpleToolbarConfigurations(controller: _controller)), | ||
Expanded( | ||
child: QuillEditor.basic( | ||
configurations: QuillEditorConfigurations(controller: _controller), | ||
), | ||
) | ||
], | ||
) | ||
``` | ||
|
||
2. Refactoring the Base Toolbar | ||
|
||
From now on, the `QuillToolbar` will be a widget that only provides the things that the buttons needs like localizations and `QuillToolbarProvider` | ||
So you can define your own toolbar from scratch just like in Quill JS | ||
|
||
The `QuillToolbar` is now accepting only `child` with no configurations so you can customize everything you wants, the `QuillToolbar.simple()` or `QuillSimpleToolbar` implements a simple toolbar that is based on `QuillToolbar`, you are free to use it but it just an example and not standard | ||
|
||
1. Source Code Structure | ||
|
||
Completly changed the way how the source code structured to more basic and simple way, organize folders and file names, if you use the library | ||
from `flutter_quill_extensions.dart` then there is nothing you need to do, but if you are using any other import then you need to re-imports | ||
|
||
4. Change the version system | ||
|
||
For [more details](https://github.com/singerdmx/flutter-quill/discussions/1560) | ||
|
||
5. Dependencies changes | ||
|
||
1. Add `gal_linux` in `flutter_quill_extensions` | ||
2. Replace `pasteboard` with `rich_cliboard` | ||
3. Remove `flutter_animate` | ||
|
||
6. Optional options for the buttons | ||
|
||
All the buttons from now on, have optional options parameter | ||
|
||
7. Improve Flutter Quill Extensions | ||
|
||
Bug fixes and new features, the extensions package keep getting better thanks to the community. | ||
|
||
8. Migrate to Material 3 | ||
|
||
We have migrated all of the buttons to material 3, removed a lot of old parameters, if you want to customize one or all the buttons to replacing it with completly different widget with the same state use the `base` in the button options for all or the button name for one | ||
|
||
We have also replaced the header style buttons with one dropdown button as a default, replaced the alignment buttons with less code and a lot more |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
extension UriExt on Uri { | ||
bool isHttpBasedUrl() { | ||
final uri = this; | ||
return uri.isScheme('HTTP') || uri.isScheme('HTTPS'); | ||
} | ||
|
||
bool isHttpsBasedUrl() { | ||
final uri = this; | ||
return uri.isScheme('HTTPS'); | ||
} | ||
} |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.