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

flutter_stories のカバー
パッケージ詳細v0.3.1

flutter_stories

アプリにストーリー機能をもたらすウィジェット

AndroidiOSWebmacOSWindowsLinux
30日間ダウンロード
197
いいね数
69
Pub ポイント
140

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

flutter pub add flutter_stories

パッケージ概要

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

Flutter Stories は、ソーシャルメディアアプリに見られるストーリー閲覧メカニズムを実装する Flutter パッケージです。フルスクリーンでスワイプ可能な形式で画像、動画、テキストなどの順次コンテンツを表示できるカスタマイズ可能なウィジェットを提供します。クロスプラットフォーム対応で、Android、iOS、Web、macOS、Windows、Linux をサポートしています。このパッケージにより、開発者は最小限のセットアップと高いパフォーマンスで、アプリにストーリー風の体験を簡単に統合できます。

用途

  • ソーシャルメディアアプリの更新
  • ユーザーオンボーディングチュートリアル
  • プロダクトショーケース機能
  • インタラクティブなコンテンツスライド
  • リアルタイムイベントのハイライト

主な機能

  • ストーリー間のスワイプナビゲーション
  • カスタマイズ可能なストーリーの期間
  • 画像、動画、ウィジェットのサポート
  • クロスプラットフォーム互換性
  • 組み込みの進行状況インジケーター
  • 既存のUIとの簡単な統合

適している対象

  • ソーシャルアプリを開発する開発者
  • インタラクティブなオンボーディングフローを作成するチーム
  • ビジュアルストーリーテリングを実装するデザイナー
  • 時間制限付きコンテンツ表示を必要とするアプリ
  • 軽量なストーリーコンポーネントが必要なプロジェクト

注意事項

  • 大規模なメディアファイルの取り扱いには注意が必要です
  • ブランドの一貫性を保つためにカスタムスタイルが必要になる場合があります
  • 限定された組み込みアニメーションオプション
  • 非常に長いストーリーのシーケンスには最適化されていません
  • 動画再生には外部の依存関係に依存しています

元の README

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

flutter_stories

example

Widget that brings stories mechanism to your apps

Advantages:

  • Simple to use and intuitive API
  • Lightweight (~200 lines of code)
  • Feels familiar if you've used Instagram or Snapchat stories before
  • Can be used with Cupertino and Material packages independently

Usage

Add flutter_stories to your pubspec.yaml

Example

Full version can be found in example dir

showcase

Supported gestures

  • Tap the right portion of the screen to switch to the next moment. You can specify onFlashForward callback to control app behavior in this case or when story finishes
  • Tap the left portion of the screen to switch to the previous moment. Similar to right tap, but uses onFlashBack
  • Long press (hold) the screen to hide the progress segments and pause story, release to show controls and unpause

API

property type required description
momentCount int true Sets the number of moments in story
momentDurationGetter (int index) => Duration true Function that must return Duration for each moment
momentBuilder (BuildContext context, int index) => Widget true Builder that gets executed for each moment
onFlashForward () => void false Gets executed when user taps the right portion of the screen on the last moment in story or when story finishes playing
onFlashBack () => void false Gets executed when user taps the left portion of the screen on the first moment in story
startAt int false Defaults to 0. Sets the index of the first moment that will be displayed
momentSwitcherFraction double false Defaults to 0.33. `sets the ratio of left and right tappable portions of the screen: left for switching back, right for switching forward
progressSegmentBuilder (BuildContext context, double progress, double gap) => Widget false Defaults to Story.instagramProgressSegmentBuilder - Instagram-like minimalistic segment builder. Builder for each progress segment
progressSegmentGap double false Defaults to 2.0. Sets the gap between each progress segment
progressOpacityDuration Duration false Defaults to Duration(milliseconds: 300). Sets the duration for the progress bar show/hide animation
topOffset double false Defaults to MediaQuery.of(context).padding.top. Sets the top offset of progress container
fullscreen bool false Defaults to true. If true hides the status bar via SystemChrome service

カテゴリー

ソースリポジトリ

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

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