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

flutter_multiselect のカバー
パッケージ詳細v1.0.2

flutter_multiselect

iOS および Android と互換性があり、ニュートラルデザインを使用するマルチセレクトUIウィジェット用のFlutterパッケージ。

AndroidiOSWebmacOSWindowsLinux
30日間ダウンロード
279
いいね数
51
Pub ポイント
150

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

flutter pub add flutter_multiselect

パッケージ概要

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

iOS および Android と互換性のあるクロスプラットフォームのマルチセレクト UI ウィジェットを提供する Flutter パッケージです。ニュートラルなデザインで、リストから複数の項目を選択できる直感的な操作を可能にし、フォーム、フィルター、タグインターフェースに適しています。Web、macOS、Windows、Linux を含むさまざまなプラットフォームで一貫性を確保するように設計されています。アクセシビリティとパフォーマンスを重視して作られており、既存の Flutter アプリにスムーズに統合できます。

用途

  • 複数選択可能なフォーム入力
  • ダッシュボードでのフィルターオプション
  • コンテンツ分類のためのタグ選択
  • ユーザーの好み設定
  • 動的フォームフィールド

主な機能

  • クロスプラットフォーム互換性
  • ニュートラルでモダンなデザイン
  • 直感的なマルチセレクションジェスチャー
  • すべての主要なFlutterプラットフォームをサポート
  • 意味的ラベル経由でアクセス可能
  • カスタマイズ可能なチップスタイル

適している対象

  • 包括的でプラットフォームに依存しないアプリを開発する開発者
  • 柔軟な選択パターンを必要とするアプリ
  • 一貫性を重視するデザインシステム
  • フルスタック開発にFlutterを使用するチーム
  • 軽量で再利用可能なコンポーネントが必要なプロジェクト

注意事項

  • 制限された組み込み検証
  • キーボードナビゲーションのネイティブサポートなし
  • 選択状態の手動処理が必要です
  • 複雑なテーマには追加のスタイル設定が必要になる場合があります
  • ページングなしの大規模なデータセットに対して最適化されていない

元の README

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

flutter_multiselect

Flutter package for multi-select UI widget

pub package

Android and iOS screenshot- screenshot

Getting Started

  • Add the package into pubspec.yaml
dependencies:
  flutter_multiselect:
  • Import in your code
import 'package:flutter_multiselect/flutter_multiselect.dart';

Why? :wrench:

By default, there is no UI control for multi-select in iOS and Android, and my widget can be used to bridge this gap.

Example without customization :one:

child: MultiSelect(
  autovalidate: false,
  titleText: "Countries",
  validator: (value) {
    if (value == null) {
      return 'Please select one or more option(s)';
    }
  },
  errorText: 'Please select one or more option(s)',
  dataSource: [
    {
      "display": "Australia",
      "value": 1,
    },
    {
      "display": "Canada",
      "value": 2,
    },
    {
      "display": "India",
      "value": 3,
    },
    {
      "display": "United States",
      "value": 4,
    }
  ],
  textField: 'display',
  valueField: 'value',
  filterable: true,
  required: true,
  value: null,
  onSaved: (value) {
    print('The saved values are $value');
  }
),

Example with customization :two:

Check the colors and text to see the changes that it makes to the modal interface

child: MultiSelect(
    //--------customization selection modal-----------
    buttonBarColor: Colors.red,
    cancelButtonText: "Exit",
    titleText: "Custom Title",
    checkBoxColor: Colors.black,
    selectedOptionsInfoText: "Selected custom text (tap to remove)",
    selectedOptionsBoxColor: Colors.green,
    autovalidate: true,
    maxLength: 5, // optional
    //--------end customization selection modal------------
    validator: (dynamic value) {
      if (value == null) {
        return 'Please select one or more option(s)';
      }
      return null;
    },
    errorText: 'Please select one or more option(s)',
    dataSource: [
      {"name": "Afghanistan", "code": "AF"},
      {"name": "Åland Islands", "code": "AX"},
      {"name": "Albania", "code": "AL"},
    ],
    textField: 'name',
    valueField: 'code',
    filterable: true,
    required: true,
    onSaved: (value) {
      print('The saved values are $value');
    }),
    change: (value) {
      print('The selected values are $value');
    })

and of course you can check the full list of the parameters to personalize your modal!

Here, the complete list of parameters to modify the selection modal :clipboard:

Type Parameter
Color buttonBarColor
String cancelButtonText
IconData cancelButtonIcon
Color cancelButtonColor
Color cancelButtonTextColor
String saveButtonText
IconData saveButtonIcon
Color saveButtonColor
Color saveButtonTextColor
String clearButtonText
IconData clearButtonIcon
Color clearButtonColor
Color clearButtonTextColor
String deleteButtonTooltipText
IconData deleteIcon
Color deleteIconColor
Color selectedOptionsBoxColor
String selectedOptionsInfoText
Color selectedOptionsInfoTextColor
IconData checkedIcon
IconData uncheckedIcon
Color checkBoxColor
Color searchBoxColor
String searchBoxHintText
Color searchBoxFillColor
IconData searchBoxIcon
String searchBoxToolTipText
Size responsiveDialogSize

カテゴリー

ソースリポジトリ

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

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