パッケージ、リポジトリ、アプリカテゴリを検索

パッケージ詳細v0.1.9

flutterbook

Flutterウィジェットの開発を加速するためのストーリーボードツール。

AndroidiOSmacOSWindowsLinux
30日間ダウンロード
235
いいね数
42
Pub ポイント
130

パッケージをインストール

flutter pub add flutterbook

パッケージ概要

公開情報に基づく選定ガイドです。参考としてご利用ください。

FlutterBookは、コンポーネント駆動のUIデザインを可能にすることで、Flutterウィジェットの開発を加速するストーリーボードツールです。開発者とデザイナーが個々のウィジェットを分離して可視化・テスト・反復できるようにし、複数プラットフォームでリアルタイムプレビューを提供します。迅速なプロトタイピングを目的としており、視覚インターフェース内で動的な構成および状態管理をサポートしています。シンプルなpub addコマンドでFlutterワークフローにシームレスに統合でき、オープンソースであるためコミュニティの貢献を促進しています。一貫性があり再利用可能なUIコンポーネントに注力するチームに最適です。

用途

  • 迅速なUIプロトタイピング
  • コンポーネントライブラリ開発
  • クロスプラットフォームウィジェットテスト
  • デザインシステムの実装
  • 共同UIレビュー

主な機能

  • 複数プラットフォーム間でのリアルタイムプレビュー
  • インタラクティブなウィジェット設定
  • 複数のデバイスサイズに対応
  • 組み込みの状態管理
  • オープンソースかつ拡張可能

適している対象

  • Flutter を使用する UI/UX デザイナー
  • 再利用可能なコンポーネントを構築するフロントエンド開発者
  • デザインシステムを使用するチーム
  • UIのマックアップを繰り返し改善するプロダクトチーム
  • より迅速なフィードバックループを求める開発者

注意事項

  • 既存のFlutterプロジェクトへの統合が必要です
  • ウィジェットレベルの可視化に限定
  • Figmaのような完全なデザインツールではない
  • コンポーネント中心のワークフローに最適
  • 複雑な状態のための追加設定が必要になる場合があります

元の README

関連するソースリポジトリの README 原文のスナップショットです。最新の内容はリポジトリをご覧ください。

Flutterbook

Flutterbook

A storyboarding tool to accelerate the development of Flutter widgets. Inspired by Storybook.js.

The package is built to support Windows and Web layouts. There is no support for mobile support at the moment. This is new and still under heavy development, expect many changes to occur with usage.

License: MIT


Go subscribe to my YouTube channel to support development.

MOONSDONTBURN Header

Demo

Demo Link Here

Overview ✨

Creating the Main

Start by creating the storyboard widget. This will wrap the Flutterbook widget so that when it is edited, it will hot reload.

class Storyboard extends StatelessWidget {
  const Storyboard({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return FlutterBook(
      categories: [
          // organizers ...
      ],
    );
  }
}

After creating the Storyboard widget, you can run it by using the main. I recommend making another file named main_storyboard.dart to maintain your storyboard.

void main() {
  runApp(const Storyboard());
}
// Or run it directly, but this will cost the hot reload.
// void main() {
//   runApp(const Flutterbook(categories:[...]));
// }
How to add Widgets

To add widgets, you simply put Organizers, aka Category, Folder, Component, and ComponentState.

The hierarchy goes

Category > Folder > Component > ComponentState

but you may also do

Category > Component > ComponentState

or

Category > Folder > Folder > Component > ComponentState

Here is a complex example of a single Category. In the example, we use the builder where we are able to access different controls.

Category(
    categoryName: 'LIBRARY',
    organizers: [
    Folder(
        folderName: 'Charts',
        organizers: [
        Component(
            componentName: 'LineGraph',
            states: [
            ComponentState.child(
                stateName: 'Default Container',
                child: Container(),
            ),
            ],
        ),
        ],
    ),
    Component(
        componentName: 'Button',
        compenentMarkdoown: """##A global button component""",
        states: [
        ComponentState(
            stateName: 'Primary',
            markdown: """Used for the main action to be performed"""
            codeSample:  r'''
Button.primary(
  child: Text('Primary Button'),
  onPressed: () {},
);
'''
            builder: (context, c) {
            return Center(
                child: SizedBox(
                width: c.number(
                    label: 'Number',
                    initial: 50,
                    min: 50,
                    max: 250,
                ),
                height: c.number(
                    label: 'height',
                    initial: 50,
                    min: 50,
                    max: 250,
                    description: 'random stuff',
                ),
                child: CupertinoButton.filled(
                    onPressed: c.boolean(
                    label: 'boolean',
                    initial: true,
                    )
                        ? () {}
                        : null,
                    child: Text(
                    c.text(label: 'Text', initial: 'Hello World'),
                    ),
                ),
                ),
            );
            },
        ),
        ],
    ),
    ],
),
That's it!

Roadmap 🚧

  • [ ] Mobile Support
  • [ ] 100% Code Coverage Testing
  • [X ] Documentation Support in ComponentState's
  • [ ] Better Docs
  • [X ] Device Previews
  • [ ] Shareable Handoffs
  • [ ] Optimization

Contributors 🔥

Your name could be here 😉

カテゴリー

依存関係

依存関係一覧 8 件

ソースリポジトリ

このパッケージを使用しているプロジェクト

データはまだありません。