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

polls のカバー
パッケージ詳細v1.0.1

polls

Flutterウィジェットで、Twitterのアンケートシステムを模倣しています。データをアンケートに接続するだけで、投票と可視化が可能になります。

30日間ダウンロード
66
いいね数
109
Pub ポイント
50

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

flutter pub add polls

パッケージ概要

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

polls パッケージは、FlutterウィジェットとしてTwitterのポールインターフェースを再現し、アプリ内にインタラクティブな投票システムを作成できるようにします。リアルタイム投票と視覚フィードバックをサポートしており、ソーシャルメディア機能に最適です。開発者はデータソースを簡単に統合でき、最小限のセットアップで利用可能です。このパッケージはシンプルさと美学に焦点を当てており、ユーザーの意見を集めるための洗練された直感的な方法を提供します。既存のFlutterプロジェクトへのシームレスな統合を目的としています。

用途

  • ソーシャルメディアアプリ
  • ユーザーのフィードバック収集
  • コミュニティ参加ツール
  • リアルタイム投票機能
  • アプリ内のインタラクティブなコンテンツ

主な機能

  • TwitterスタイルのアンケートUI
  • 投票機能
  • データ駆動型世論調査
  • ビジュアル投票表現
  • カスタムデータとの簡単な統合

適している対象

  • ソーシャル機能を構築するFlutter開発者
  • ユーザーの意見収集が必要なアプリ
  • 軽量なポーリングシステムを必要とするプロジェクト
  • シンプルで魅力的な投票ウィジェットを探している開発者
  • インタラクティブなコンテンツを備えたモバイルアプリ

注意事項

  • 手動でのデータ管理が必要です
  • 組み込みのバックエンドサポートなし
  • 限定されたカスタマイズオプション
  • 高頻度ポーリングには最適化されていません
  • 更新には外部の状態管理に依存しています

元の README

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

Polls

pub package

GitHub

ScreenShots

Voting Not Voted Yet Voted

Usage

Basic:

import 'package:polls/polls.dart';
Polls(
    children: [
        // This cannot be less than 2, else will throw an exception
        Polls.options(title: 'Cairo', value: option1),
        Polls.options(title: 'Mecca', value: option2),
        Polls.options(title: 'Denmark', value: option3),
        Polls.options(title: 'Mogadishu', value: option4),
        ],
        question: Text('What is the capital of Egypt'),
        currentUser: this.user,
        creatorID: this.creator,
        voteData: usersWhoVoted,
        userChoice: usersWhoVoted[this.user],
        onVoteBackgroundColor: Colors.blue,
        leadingBackgroundColor: Colors.blue,
        backgroundColor: Colors.white,
        onVote: (choice) {

            setState(() {
              this.usersWhoVoted[this.user] = choice;
            });
            if (choice == 1) {
            setState(() {
                option1 += 1.0;
            });
            }
            if (choice == 2) {
            setState(() {
                option2 += 1.0;
            });
            }
            if (choice == 3) {
            setState(() {
                option3 += 1.0;
            });
            }
            if (choice == 4) {
            setState(() {
                option4 += 1.0;
            });
        }
    },
);
Poll View type
Polls(
  viewType: PollsType.creator
);
Polls(
viewType: PollsType.voter
);
Polls(
viewType: PollsType.readOnly
);

Why I made this plugin

Apparently, I have built 2 apps that required user voting processes, twice I had to implement same code on different apps. I also had to share the code with a friend, well I thought it would not be a bad idea to create a package off it, cause at this time there was no polls widget package on pub.dev

kindly follow on github

github

Kindly follow me on

twitter medium instagram

カテゴリー

依存関係

依存関係一覧 1 件

ソースリポジトリ

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

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