docsy_toolbar 0.1.3 copy "docsy_toolbar: ^0.1.3" to clipboard
docsy_toolbar: ^0.1.3 copied to clipboard

A customizable toolbar for the Docsy Flutter editor. Includes ready-made buttons for bold, italic, headings, lists, links, and code blocks.

Docsy Toolbar #

A customizable toolbar for the Docsy editor. It provides buttons for common editing actions and pairs with RichTextEditor.

Try it Live

Features #

  • Bold, italic, and underline toggles
  • Insert and remove links
  • Insert headings, dividers, and code blocks
  • Undo and redo
  • Markdown and HTML export buttons

Installation #

Add both docsy and docsy_toolbar to your pubspec.yaml:

dependencies:
  docsy: ^0.1.3
  docsy_toolbar: ^0.1.3

Then run:

flutter pub get

Usage #

import 'package:docsy/docsy.dart';
import 'package:docsy_toolbar/docsy_toolbar.dart';
import 'package:flutter/material.dart';

class MyEditorPage extends StatefulWidget {
  const MyEditorPage({super.key});

  @override
  State<MyEditorPage> createState() => _MyEditorPageState();
}

class _MyEditorPageState extends State<MyEditorPage> {
  final controller = EditorController();

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(title: const Text('Docsy Editor with Toolbar')),
      body: Column(
        children: [
          DocsyToolbar(controller: controller),
          const Divider(height: 1),
          Expanded(
            child: RichTextEditor(controller: controller),
          ),
        ],
      ),
    );
  }
}

Notes #

  • The export buttons open copyable dialogs for Markdown and HTML.
  • The toolbar expects to share the same EditorController as the editor.

License #

This package is distributed under the MIT License. See LICENSE for details.

2
likes
150
points
146
downloads

Documentation

API reference

Publisher

verified publisherastrodevs.space

Weekly Downloads

A customizable toolbar for the Docsy Flutter editor. Includes ready-made buttons for bold, italic, headings, lists, links, and code blocks.

Homepage
Repository (GitHub)
View/report issues

License

MIT (license)

Dependencies

docsy, docsy_html, docsy_markdown, flutter

More

Packages that depend on docsy_toolbar