|
2 rokov pred | |
---|---|---|
.. | ||
assets | 2 rokov pred | |
documentation | 2 rokov pred | |
example | 2 rokov pred | |
lib | 2 rokov pred | |
test | 2 rokov pred | |
.gitignore | 2 rokov pred | |
.metadata | 2 rokov pred | |
CHANGELOG.md | 2 rokov pred | |
LICENSE | 2 rokov pred | |
README.md | 2 rokov pred | |
analysis_options.yaml | 2 rokov pred | |
pubspec.yaml | 2 rokov pred |
A highly customizable rich-text editor for Flutter
Add the AppFlowy editor Flutter package to your environment.
flutter pub add appflowy_editor
flutter pub get
Start by creating a new empty AppFlowyEditor object.
final editorStyle = EditorStyle.defaultStyle();
final editorState = EditorState.empty(); // an empty state
final editor = AppFlowyEditor(
editorState: editorState,
editorStyle: editorStyle,
);
You can also create an editor from a JSON object in order to configure your initial state.
final json = ...;
final editorStyle = EditorStyle.defaultStyle();
final editorState = EditorState(StateTree.fromJson(data));
final editor = AppFlowyEditor(
editorState: editorState,
editorStyle: editorStyle,
);
Note: The parameters
localizationsDelegates
need to be assigned in MaterialApp widgetMaterialApp( localizationsDelegates: const [ AppFlowyEditorLocalizations.delegate, ], );
To get a sense for how the AppFlowy Editor works, run our example:
git clone https://github.com/AppFlowy-IO/AppFlowy.git
cd frontend/app_flowy/packages/appflowy_editor/example
flutter run
Please refer to our documentation on customizing AppFlowy for a detailed discussion about customizing components.
Below are some examples of component customizations:
Please refer to our documentation on customizing AppFlowy for a detailed discussion about customizing shortcut events.
Below are some examples of shortcut event customizations:
Please refer to the API documentation.
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
Please look at CONTRIBUTING.md for details.
Distributed under the AGPLv3 License. See LICENSE for more information.